Staredit Network > Forums > SC1 UMS Mapmaking Assistance > Topic: Trigger Question
Trigger Question
Jul 23 2008, 6:00 pm
By: BaneOfRome  

Jul 23 2008, 6:00 pm BaneOfRome Post #1



I've been working on a Civilization World type map that is based on the Dungeons and Dragons game. One of the wonders that I have in the scenario gives the owner a random unit every minute or so. Unfortunately, I cannot find the trigger in order to do this. Can anyone explain to me how to make a random unit appear for a player?



None.

Jul 23 2008, 6:14 pm O)FaRTy1billion[MM] Post #2

👻 👾 👽 💪

You use Switch's Randomize state.
Falkoner's site has a nice switch tutorial (if you ignore the red and yellow colors :P.)

So, as an example I'll use two switches... If you are using more than like 4 switches it would be best to do the binary thingy where you add them all up.

Quick example... This just detects every single possibility.
Collapsable Box


Be careful how many siwtches you use... To figure out the possibilities, do 2x, where x is the number of switches. 21=2 possibilities, 22=4 possibilities, 23=8, possibilities, 24=16, 25=32, 26=64, etc.



TinyMap2 - Latest in map compression! ( 7/09/14 - New build! )
EUD Action Enabler - Lightweight EUD/EPD support! (ChaosLauncher/MPQDraft support!)
EUDDB - topic - Help out by adding your EUDs! Or Submit reference files in the References tab!
MapSketch - New image->map generator!
EUDTrig - topic - Quickly and easily convert offsets to EUDs! (extended players supported)
SC2 Map Texture Mask Importer/Exporter - Edit texture placement in an image editor!
\:farty\: This page has been viewed [img]http://farty1billion.dyndns.org/Clicky.php?img.gif[/img] times!

Jul 23 2008, 7:59 pm Falkoner Post #3



You can also use a death count in combination with a switch and just constantly randomize whether or add 1 or not to the death, and then when it's time to pick the unit, you can just decide which unit to pick based on what the death count currently is.



None.

Jul 23 2008, 9:04 pm BaneOfRome Post #4



I tried this but I ended up with a player having 5 hero battlecruisers that are supposed to be unique to a wonder. How do I fix this?

Post has been edited 1 time(s), last time on Jul 23 2008, 10:34 pm by BaneOfRome.



None.

Jul 23 2008, 10:12 pm Falkoner Post #5



It sounds like you didn't rerandomize the switches every time you checked them, so you got the same outcome every time, you have to randomize them each time.



None.

Jul 23 2008, 10:34 pm BaneOfRome Post #6



I did randomize them and I got a mixture of units but the problem was with the multiple unique units (instead of one unit every minute, I did one unit every five seconds).



None.

Jul 23 2008, 10:51 pm Falkoner Post #7



Oh... You may need a system that detects if it's a unique unit, then if it is, it rerandomizes and tries again.



None.

Jul 23 2008, 10:58 pm BaneOfRome Post #8



How do I do that?



None.

Jul 23 2008, 11:05 pm Falkoner Post #9



Set a switch at the time when a unit needs to be created, instead of immediately checking the random, then while the switch is set, randomize it, and on the conditions to create the unit, make sure that special unit isn't already out, and make sure the switch is set, and the switches are randomized in the correct combination. If all those conditions are met, create the unit and clear the switch, and have another trigger that randomizes if the switch is still set.



None.

Jul 24 2008, 1:26 am BaneOfRome Post #10



Ok, I get it now. Thanks :)



None.

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[10:09 am]
NimoStar -- It can by playing the same map thousands of times. It is similar to AI speedrunning games
[02:30 am]
Symmetry -- I dreamed about that as a kid. The idea of a computer capable of analyzing a starcraft map and calculating the fastest possible way to hit the victory condition
[02:29 am]
Symmetry -- But can AI beat my custom maps?
[12:32 pm]
Oh_Man -- yea APM vs eAPM
[2026-9-22. : 8:48 am]
NimoStar -- plus most of the human APM is just spam clicking APM inflation
[2026-9-22. : 8:47 am]
NimoStar -- the thing with the "*12" thing is completely misleading. The AI isn't using two control groups, it can use each of those actions to command a single unit individually and issue different commands to each single unit.
[2026-9-22. : 8:06 am]
NudeRaider -- NudeRaider
NudeRaider shouted: Oh_Man Artosis hasn't caught on how devastating the perfect focus fire is. With the mutas he was like "the Mutas always seem to have less hp than against a human". But he didn't notice that the flock he had selected always just had one muta that was hurt. Same with the wraiths here. He's talking about how valks+wraith is gonna destroy Pluto's valks, then 5s later he's dumbfounded the human player's air is just gone and he never figured out why. And for some reason didn't even think to go back and look at the battle.
*Pluto's wraiths
[2026-9-22. : 8:05 am]
NudeRaider -- Oh_Man Artosis hasn't caught on how devastating the perfect focus fire is. With the mutas he was like "the Mutas always seem to have less hp than against a human". But he didn't notice that the flock he had selected always just had one muta that was hurt. Same with the wraiths here. He's talking about how valks+wraith is gonna destroy Pluto's valks, then 5s later he's dumbfounded the human player's air is just gone and he never figured out why. And for some reason didn't even think to go back and look at the battle.
[2026-9-22. : 2:18 am]
Oh_Man -- Close enuf
[2026-9-21. : 4:14 pm]
Vrael -- perhaps there is a small professional player trapped in a box in the server rack where pluto is running? hmm?
Please log in to shout.


Members Online: jun3hong