Staredit Network > Forums > SC1 UMS Mapmaking Assistance > Topic: Constant spawning units
Constant spawning units
This topic is locked. You can no longer write replies here.
Dec 13 2009, 4:57 am
By: Alzarath  

Dec 13 2009, 4:57 am Alzarath Post #1

Praetor

What I would like to happen is for units to spawn at a structure as long as that structure is there. I have 7 of these triggers for 1 player, then 2 for another. Here is what I have it set up as:



etc.

How it ends up in game... The units spawn once, then never spawn again. I've done much experimenting with this. I tried giving a trigger to another player, and it worked. But then I gave another to that player, and it stopped working again. So it seems it only works when only 1 player is using only 1 trigger. So, how would I go about fixing this?

Previously i had Hyper Triggers on, then decided to take them off as a test, that had no effect.



None.

Dec 13 2009, 5:08 am Positively Post #2



Uhh. If you have hyper triggers mixed in with Player 1... Hyper Trigger + Wait Commands for the same force/person is a no-no. That's the only reason I can think of other than.. trigger's don't like you >:].

In other words. :0. If you have Hyper Triggers for Player 1 while using "Wait" commands... it'll work once but simply stop working and/or get messed up.



None.

Dec 13 2009, 5:30 am Alzarath Post #3

Praetor

Quote from Positively
Uhh. If you have hyper triggers mixed in with Player 1... Hyper Trigger + Wait Commands for the same force/person is a no-no. That's the only reason I can think of other than.. trigger's don't like you >:].

In other words. :0. If you have Hyper Triggers for Player 1 while using "Wait" commands... it'll work once but simply stop working and/or get messed up.

Quote from name:Artanis186
Previously i had Hyper Triggers on, then decided to take them off as a test, that had no effect.




None.

Dec 13 2009, 5:39 am ImagoDeo Post #4



You're suffering from Wait Blocks.

The game can only run one Wait action per player at a time. So your game is running the first trigger, and when it gets to the wait, it checks the other triggers to see if it can run them. Oh! It can. So it runs the spawn for them, but can't run the wait because one wait is already running. After twenty seconds, the game will just reset to the first spawn.

Use death count timers.



None.

Dec 13 2009, 7:56 am NudeRaider Post #5

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 ImagoDeo
but can't run the wait because one wait is already running. After twenty seconds, the game will just reset to the first spawn.
Yes, it's Wait Blocks, but your explanation of what happens is wrong. The problem: A player can only run 1 wait at a time. If you run another while there's already one active StarCraft will act up:

The triggers will run fine the first time. All of them but only until they hit the first wait. However since the wait is the last actions they will spawn the units normally. But the waits will be blocking each other, basically multiplying the wait duration instead of adding to it.
So they won't reset after 20 seconds, they just won't finish until after a ridiculously high wait time, and of course won't rerun until they are finished.

While death counters are generally preferable you can also use waits as long as you make sure only 1 is running at a time.
The following triggers are not recommended, as they are inefficient compared to death counters. They are only for demonstration purposes.

What I did was basically putting the wait into a single trigger and setting a switch with it that triggers the spawns.

P7
Conditions:

Always
Actions:
Wait(10,000)
Set Switch 1
Preserve Trigger

P7
Condtions:

Switch 1 is set
P7 brings at least 1 Barracks to G1
Actions:
Create swordsmen at G1
Order swordsmen
Preserve trigger

P7
Condtions:

Switch 1 is set
P7 brings at least 1 Barracks to G2
Actions:
Create swordsmen at G2
Order swordsmen
Preserve trigger

... for all spawning triggers

and in the end just clear the switch - it will be set again in 10 seconds by the first trigger.

P7
Conditions:

Switch 1 is set
Actions:
Clear Switch 1
Preserve Trigger

Order is obviously important here.




Dec 14 2009, 7:59 am Alzarath Post #6

Praetor

Quote from ImagoDeo
You're suffering from Wait Blocks.

The game can only run one Wait action per player at a time. So your game is running the first trigger, and when it gets to the wait, it checks the other triggers to see if it can run them. Oh! It can. So it runs the spawn for them, but can't run the wait because one wait is already running. After twenty seconds, the game will just reset to the first spawn.

Use death count timers.

Thank you, this helped a lot. My map is now in working order. ^.^

Now all I need is some more ideas for the map. Maybe I'll do a complete overhaul of the terrain.



None.

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[03:08 pm]
Sylph-Of-Space -- woah! nice! thank you!
[2024-5-20. : 4:05 am]
O)FaRTy1billion[MM] -- the setting exists, it's just hidden in a weird place
[2024-5-20. : 4:04 am]
O)FaRTy1billion[MM] -- instead change "Microtile Overlay" to "Impassable"
[2024-5-20. : 4:04 am]
O)FaRTy1billion[MM] -- er, wait, idk why i was looking for height
[2024-5-20. : 4:03 am]
O)FaRTy1billion[MM] -- below the minimap should be a thing that says "Overlay Settings" with a little + button in the corner, press the + to expand it, uncheck Use Defaults, then change "Tile Overlay" to "Height"
[2024-5-20. : 3:57 am]
Sylph-Of-Space -- Unless I'm dum (possible)
[2024-5-20. : 3:57 am]
Sylph-Of-Space -- It would be so so so nice if SCMDraft had some kind of dedicated "walkability" view for the tilesets.
[2024-5-20. : 3:53 am]
Sylph-Of-Space -- :'( dont cry for me cat-gentina
[2024-5-19. : 9:18 pm]
Ultraviolet -- 🔪🐈
[2024-5-19. : 12:34 pm]
NudeRaider -- curiosity kills the cat!
Please log in to shout.


Members Online: Roy, NudeRaider