Staredit Network > Forums > SC1 UMS Mapmaking Assistance > Topic: [SOLVED] Need Help With Stopping Triggers Midway
[SOLVED] Need Help With Stopping Triggers Midway
This topic is locked. You can no longer write replies here.
Aug 14 2012, 12:14 am
By: Radical924
Pages: < 1 2 3 >
 

Aug 14 2012, 7:12 am staxx Post #21



You can't run triggers for extended players so having your hyper triggers on player 9 does absolutely nothing which would explain why your triggers "constantly loop". Theyre not actually constantly looping as you refer, its just that no hyper triggers are running so it takes for ever for the death count to subtract.

Give the hyper triggers to all players and then try, it should work then.


should look like this

All Players

Always

Wait 0 (63 times)
Preserve trigger

Then copy that trigger 3 times so that there are 4 of them in total and move them to the bottom of your all players list.



None.

Aug 14 2012, 7:19 am Radical924 Post #22



Quote from staxx
You can't run triggers for extended players so having your hyper triggers on player 9 does absolutely nothing which would explain why your triggers "constantly loop". Theyre not actually constantly looping as you refer, its just that no hyper triggers are running so it takes for ever for the death count to subtract.

Give the hyper triggers to all players and then try, it should work then.


should look like this

All Players

Always

Wait 0 (63 times)
Preserve trigger

Then copy that trigger 3 times so that there are 4 of them in total and move them to the bottom of your all players list.

Ummmmmm u r confused the looping is a different issue with different triggers...... that is why I used different colors in my post to separate issues. sorry



None.

Aug 14 2012, 7:23 am NudeRaider Post #23

We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch

This is one of the cases where I'd suggest not giving him the complete system in trigger form but explain to him step by step what he has to do. Not much is gained if he copy and pastes triggers he doesn't understand.

Also afaik displaying the countdown timer doesn't cause a desync, but when you base global actions on it, it does. (Ignore this sentence, Radical it's directed to Azrael)

Hyper trigger can only be made of waits. It's the special property of waits (that when they are executed they initiate a new trigger loop) that create the speed up effect. But when you run hyper triggers it's easier to run into Wait Blocks. The easiest way to avoid wait blocks is to replace all your waits with death counters (except hypers). Sometimes you still want to use waits, which is possible, but this is where you have to know what you're doing.
The most common way is to give the hypers to All Players AND move them to the bottom of the trigger list (and again when you've added more triggers containing waits). That way wait blocks will only occur when every player in the game runs a wait simultaneously, which you as the mapper, should be able to avoid.
The other method is to give the hypers to a player that doesn't ever run waits. Typically a computer player. No moving to the bottom of the list is required here.

Player 9 (and above) can't run triggers. So giving them hypers (or any other trigger for that matter) will do nothing.




Aug 14 2012, 7:27 am Radical924 Post #24



oh so since I am using wait as my hyper trigger it will affect any other triggers in my map that use wait... making the wait action impossible?

If that is the case how do I use death counters to make hyper triggers? I am using all players as my area to put the hyper triggers and I am putting them at the bottom of the list.

OR is it the other way around where instead of using wait actions for other triggers I use death counters. And for my hyper trigger I use the wait action?



None.

Aug 14 2012, 7:28 am Sacrieur Post #25

Still Napping

Quote
Also afaik displaying the countdown timer doesn't cause a desync, but when you base global actions on it, it does. (Ignore this sentence, Radical it's directed to Azrael)

That's perfect, then. When the timer reaches zero it would trigger a defeat, so desync is fine.



None.

Aug 14 2012, 7:29 am staxx Post #26



Yes, you put the .wav on the trigger that constantly runs when there are 0 buildings. So naturally it will loop over and over until the player builds something.

Once you change the hypers from player 9 to all players and move them to the bottom of the list your system should run fine. I also suggest taking the .wav off of that trigger unless its something you want to keep playing over and over when a player has 0 buildings might get annoying though :bleh:

*EDIT*

Make your wait triggers how i described in the post at the top

@Sac, don't confuse him with EUD's lol they're not needed.



None.

Aug 14 2012, 7:33 am Radical924 Post #27



Quote from staxx
Yes, you put the .wav on the trigger that constantly runs when there are 0 buildings. So naturally it will loop over and over until the player builds something.

Once you change the hypers from player 9 to all players and move them to the bottom of the list your system should run fine. I also suggest taking the .wav off of that trigger unless its something you want to keep playing over and over when a player has 0 buildings might get annoying though :bleh:

*EDIT*

Make your wait triggers how i described in the post at the top

@Sac, don't confuse him with EUD's lol they're not needed.
so if i fix my hyper triggers the loss timer system should work? also the wavs arent playing all the way through they are looping at the beginning. How would I causew the wav to play only once if the player has 0 buildings at the time?



None.

Aug 14 2012, 7:42 am NudeRaider Post #28

We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch

As I've said
Quote from NudeRaider
Hyper trigger can only be made of waits. It's the special property of waits (that when they are executed they initiate a new trigger loop) that create the speed up effect.
So it's gonna have to be this
Quote from Radical924
OR is it the other way around where instead of using wait actions for other triggers I use death counters. And for my hyper trigger I use the wait action?

Quote from Radical924
How would I causew the wav to play only once if the player has 0 buildings at the time?
not preserving seems the easiest way. Otherwise just set a switch or something so it can only play once. If you need it again later you can disable the switch after [length of wav in seconds] * 12 death counts. (Create a new timer for it)




Aug 14 2012, 7:46 am Radical924 Post #29



Quote from NudeRaider
As I've said
[quote=name:NudeRaider]Hyper trigger can only be made of waits. It's the special property of waits (that when they are executed they initiate a new trigger loop) that create the speed up effect.
So it's gonna have to be this
Quote from Radical924
OR is it the other way around where instead of using wait actions for other triggers I use death counters. And for my hyper trigger I use the wait action?

ok makes more sense I was just getting confused so I changed the hyper trigger to "waits".... but I still don't know how I am supposed to use death counters instead of waits in other triggers...



None.

Aug 14 2012, 7:48 am NudeRaider Post #30

We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch

http://www.staredit.net/?p=oldwiki&s=20 Scroll a bit down to Timers.




Aug 14 2012, 7:52 am Radical924 Post #31



Quote from NudeRaider
not preserving seems the easiest way. Otherwise just set a switch or something so it can only play once. If you need it again later you can disable the switch after [length of wav in seconds] * 12 death counts. (Create a new timer for it)



YES but how do I use a "switch".......this is all fairly new to me and I thought this would be simpler lol



None.

Aug 14 2012, 8:03 am staxx Post #32



No nude, if he takes off the preserve from that trigger that subtracts 1 from the death count his entire system will be broken.

Your wav constantly plays over and over because that is the actual ticker of the system its activated 12 times per second and will only keep playing the beginning of your wav because of this.

Just use the triggers as Azrael posted, move your hyper triggers from P9 to All Players and everything will work.



None.

Aug 14 2012, 8:05 am Radical924 Post #33



Quote from staxx
No nude, if he takes off the preserve from that trigger that subtracts 1 from the death count his entire system will be broken.

Your wav constantly plays over and over because that is the actual ticker of the system its activated 12 times per second and will only keep playing the beginning of your wav because of this.

I think Sacrieur is making me a newer system like Roy/Arael's so currently I do not have there loss timer system on my map as in testing it did that play wav thing lol

Oh and I will try putting there trigger system back and retest with the fixed hyper triggers



None.

Aug 14 2012, 8:53 am Sacrieur Post #34

Still Napping

If you've played the Starcraft missions you may have noticed a timer that pops up in a few them. This is called the countdown timer and has its own special conditions and actions. It appears as a timer on the screen and counts down game seconds (can't be changed to count up).

Countdown Timer (Condition)
-
Returns true (a bit of programmer jargon to mean the computer reports the condition as true) when the countdown timer is quantitymod (at least, at most, exactly) quantitynum (any number). For example, "Countdown timer is at most 10 seconds," would return true as soon as the timer hit 10 seconds, but also if the timer is set to any value below 10 seconds.

Set Countdown Timer (Action)
-
Modifies the countdown timer with modifier duration seconds. This allows you to add, set, or subtract from the countdown timer. For example, "Modify countdown timer: set to 10 seconds," would change the countdown timer to be at 10 seconds.

Pause Timer (Action)
-
Pauses the countdown timer so that it won't count down. The numbers will still be stored on the screen though.

Unpause Timer (Action)
-
Causes a paused countdown timer to continue counting down. Won't do anything to the timer if it isn't paused.

You should be able to see right away how these can help you extensively, and give you everything that you want. It's a nice built-in function that displays itself professionally, not in choppy display text that can fowl up player messaging.

However, there is one problem: the countdown timer is universal. This is to say that modifying the countdown timer for one player will modify the countdown timer for everyone, there aren't any individual timers. Now, if your map was single-player, then that would be okay, but if it's not so it's definitely an issue. If we just stuck in normally when one player loses the rest of them would also lose, and we couldn't have two players losing at the same time.

With some more sophisticated techniques, we can remedy this problem. The method is called EUDs (or Extended Unit Deaths), and are a way of reading game memory straight from the RAM. Some of the memory Starcraft stores in the RAM is local; that is, it is stored only on your computer and other people playing the game won't have it in their RAM. The other memory is shared, meaning all people playing the game have the same information in their RAM.

If you don't understand it, don't worry, just know local memory is stuff just for you and shared is stuff that's for everyone. Like a marine on the screen is on the screen in the same place for everyone, and if one player moves the marine, it moves for all the players. That marine is stored for everyone. Just suppose, for a moment, that you were able to move the marine on one computer, but not the others. What would happen?

The answer is what we call a desync (desynchronization). To remedy the problem Starcraft will cut your connection with the other computers because the shared memory doesn't match. Now what we're going to do is very simple to implement, but it's a bit harder to explain and may seem a bit crazy.

We're going to set it up so that the countdown timer isn't the same for everyone -- we're changing what should be a shared address. This won't result in a desync until we do something with it though. So as long as it just displays and we don't base any other actions that could affect other computers, Starcraft won't cut the connection.

The end result is that everyone has individual countdown timers. Now when that timer hits zero and you run a defeat trigger based on that, that person is going to have their connection cut (but that's okay).

Here are your triggers:

Trigger
Players
None specified.
Conditions
  • Current Player commands at most 0 [buildings].
  • Memory at Death Table + 331552 is at least 0
  • Memory at Death Table + 331552 is at most 100
  • Current Player has suffered exactly 0 deaths of Vespene Geyser
  • Actions
  • Set countdown timer: set to 60 seconds.
  • Modify death counts for Current Player: set to 1 for Vespene Geyser.
  • Preserve trigger.


  • Trigger
    Players
    None specified.
    Conditions
  • Current player commands at most 0 buildings.
  • Current Player suffers exactly 1 death of Vespene Geyser.
  • Actions
  • Set deaths for Current Player: set to 2 for Vespene Geyser.
  • Unpause timer.
  • Preserve trigger.


  • Trigger
    Players
    None specified.
    Conditions
  • Current Player has suffered exactly 1 deaths of Vespene Geyser
  • Actions
  • Pause timer.
  • Preserve trigger.


  • Trigger
    Players
    None specified.
    Conditions
  • Current Player has suffered at least 1 deaths of Vespene Geyser
  • Actions
  • Set deaths for Current Player: set to 1 for Vespene Geyser.
  • Preserve trigger.


  • You should be able to handle the rest. When the countdown timer hits zero, give them a game over.

    ---

    For everyone else: I used digital volume (range 0 - 100) to cause desync. Should work, yeah?



    None.

    Aug 14 2012, 9:13 am staxx Post #35



    Ok, so what about the wav that he wants to get played at xx amount of seconds?

    With your solution Sac the wav will loop over itself 12 times, where as if he just uses the method provided by Azrael he can get it to only play once if he wishes at as many intervals throughout the death counter.

    I realized this is what he was trying to do after talking with him in the shoutbox.

    Run AZ's triggers
    Set up your wav on the trigger that displays "you have 1 minute to build" (if you want it played at other intervals let us know)
    Put hyper triggers on all players and move them to the bottom of the list

    Problem solved



    None.

    Aug 14 2012, 10:08 am NudeRaider Post #36

    We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch

    Quote from Radical924
    Quote from NudeRaider
    not preserving seems the easiest way. Otherwise just set a switch or something so it can only play once. If you need it again later you can disable the switch after [length of wav in seconds] * 12 death counts. (Create a new timer for it)

    YES but how do I use a "switch".......this is all fairly new to me and I thought this would be simpler lol
    http://classic.battle.net/scc/faq/triggers.shtml - scroll down to "What are switches?".

    There's conditions for checking switches and actions for setting them. You can also rename them.

    However if you're actually using a play wav in the same trigger that controls a timer you're doing something wrong. You need to separate them. Play the wav in a trigger that's condition is a certain state of said timer (e.g. death count = x or Countdown timer = x)




    Aug 14 2012, 12:23 pm Sacrieur Post #37

    Still Napping

    Quote
    With your solution Sac the wav will loop over itself 12 times, where as if he just uses the method provided by Azrael he can get it to only play once if he wishes at as many intervals throughout the death counter.

    16 times, actually, but that's not hard to fix.



    None.

    Aug 14 2012, 6:42 pm Azrael Post #38



    Quote from NudeRaider
    Also afaik displaying the countdown timer doesn't cause a desync, but when you base global actions on it, it does. (Ignore this sentence, Radical it's directed to Azrael)

    Nice, it would be cool to incorporate that into a future system. I'll likely do so at some point, it's a neat idea.

    It seems rather too complex for this situation, however. I think that we should just focus on the basics ^^

    Quote from Sacrieur
    For everyone else: I used digital volume (range 0 - 100) to cause desync. Should work, yeah?

    No, because everyone's digital volume is between 0 and 100, so it will be true for everyone. You need a different trigger for every player, and their condition has to be uniquely true to them.




    Aug 19 2012, 6:51 am Wormer Post #39



    There is a little problem with Roy's triggers that if player got paused while the message is being displayed he will be spammed. Make additional counter subtraction after the message have been displayed. The first message is a great place to play the sound. Also, the last 2 conditions aren't really needed to defeat the player, because condition "Current Player suffered Exactly 0 deaths of Cave-In" implies that the trigger which subtracts 1 from Cave-In have been executed which implies that both "Current Player commands At Most 0 [Buildings]" and "Current Player commands At Least 1 [Men]" are true, but that doesn't really matter. All in all I made these corrections:

    Corrections to Sample Implementation




    Some.

    Aug 19 2012, 8:54 am Azrael Post #40



    Quote from Wormer
    There is a little problem with Roy's triggers that if player got paused while the message is being displayed he will be spammed. Make additional counter subtraction after the message have been displayed. The first message is a great place to play the sound. Also, the last 2 conditions aren't really needed to defeat the player, because condition "Current Player suffered Exactly 0 deaths of Cave-In" implies that the trigger which subtracts 1 from Cave-In have been executed which implies that both "Current Player commands At Most 0 [Buildings]" and "Current Player commands At Least 1 [Men]" are true, but that doesn't really matter. All in all I made these corrections:

    Corrections to Sample Implementation

    :|

    I feel obligated to point out that I already posted a functional version of Roy's triggers (the actual triggers themselves) in this thread, which already included those corrections, and the thread creator is already using my triggers with said corrections.

    Edit: Also, there is a little problem with your triggers where the player will immediately lose the game if they don't start with buildings.

    Post has been edited 1 time(s), last time on Aug 19 2012, 9:04 am by Azrael.




    Options
    Pages: < 1 2 3 >
      Back to forum
    Please log in to reply to this topic or to report it.
    Members in this topic: None.
    [07:46 am]
    RIVE -- :wob:
    [2024-4-22. : 6:48 pm]
    Ultraviolet -- :wob:
    [2024-4-21. : 1:32 pm]
    Oh_Man -- I will
    [2024-4-20. : 11:29 pm]
    Zoan -- Oh_Man
    Oh_Man shouted: yeah i'm tryin to go through all the greatest hits and get the runs up on youtube so my senile ass can appreciate them more readily
    You should do my Delirus map too; it's a little cocky to say but I still think it's actually just a good game lol
    [2024-4-20. : 8:20 pm]
    Ultraviolet -- Goons were functioning like stalkers, I think a valk was made into a banshee, all sorts of cool shit
    [2024-4-20. : 8:20 pm]
    Ultraviolet -- Oh wait, no I saw something else. It was more melee style, and guys were doing warpgate shit and morphing lings into banelings (Infested terran graphics)
    [2024-4-20. : 8:18 pm]
    Ultraviolet -- Oh_Man
    Oh_Man shouted: lol SC2 in SC1: https://youtu.be/pChWu_eRQZI
    oh ya I saw that when Armo posted it on Discord, pretty crazy
    [2024-4-20. : 8:09 pm]
    Vrael -- thats less than half of what I thought I'd need, better figure out how to open SCMDraft on windows 11
    [2024-4-20. : 8:09 pm]
    Vrael -- woo baby talk about a time crunch
    [2024-4-20. : 8:08 pm]
    Vrael -- Oh_Man
    Oh_Man shouted: yeah i'm tryin to go through all the greatest hits and get the runs up on youtube so my senile ass can appreciate them more readily
    so that gives me approximately 27 more years to finish tenebrous before you get to it?
    Please log in to shout.


    Members Online: Ultraviolet, Roy