Turn on/off triggers and remove units

BlightWarden

New Member
Reaction score
6
How to Remove a unit!

[edit] Changed due to having finished the triggers. New Question!!

I seem to be having trouble (no suprise!:D) Figuring out how to remove a unit from a region.

So here's what I need to figure out.

Trigger A turns off.
Remove all units in region X owned by player X
Wait 0.03 seconds
Turn off this trigger.

I will need this trigger to run twice. Once at when Tier 1 ends and once when tier 2 ends, leaving tier 3 perment.

Thanks for any and all replies. +rep for help (if I can give you rep;))


[edit2] Is this trigger what I need?
Trigger:
  • Unit remover
    • Events
    • Conditions
    • Actions
      • Unit Group - Remove all units from (Units in F1CedarRegion1 <gen>)
 

Gtam

Lerning how to write and read!! Yeah.
Reaction score
164
Yes and another to detect if units are in a region a turn ur one on and off
 

BlightWarden

New Member
Reaction score
6
[edit] ok, I got the removal trigger to work, but there is a very long delay between removal and creation. I will post my triggers so bare with me as they are kinda long. I need to fix the delay and figure out if I can make a single removal trigger for all locations or if I need to make triggers for each location.

(my removal trigger)
Trigger:
  • Unit remover
    • Events
      • Time - Elapsed game time is 59.00 seconds
    • Conditions
    • Actions
      • Set Temp_Group_A1 = (Units in F1CedarRegion1 <gen> matching (((Unit-type of (Matching unit)) Equal to |CFFFF0000Cedar Wretch |R) and (((Matching unit) is alive) Equal to True)))
      • Unit Group - Pick every unit in (Units in F1CedarRegion1 <gen> owned by Neutral Hostile) and do (Actions)
        • Loop - Actions
          • Unit - Remove (Picked unit) from the game
      • Custom script: call DestroyGroup(udg_Temp_Group_A1)
      • Trigger - Turn off (This trigger)


Turn off Tier 1 creep respawn trigger (long)
Trigger:
  • Tier 1 Creep Respawn Shutoff 900 seconds
    • Events
      • Time - Elapsed game time is 59.00 seconds
    • Conditions
    • Actions
      • Trigger - Turn off Cedar Wretch F1 R1 <gen>
      • Trigger - Turn off Cedar Wretch F1 R2 <gen>
      • Trigger - Turn off Cedar Wretch F1 R3 <gen>
      • Trigger - Turn off Cedar Wretch F1 R4 <gen>
      • Trigger - Turn off Cedar Wretch F2 R1 <gen>
      • Trigger - Turn off Cedar Wretch F2 R2 <gen>
      • Trigger - Turn off Cedar Wretch F2 R3 <gen>
      • Trigger - Turn off Cedar Wretch F2 R4 <gen>
      • Trigger - Turn off Troll F1 R1 <gen>
      • Trigger - Turn off Troll F1 R2 <gen>
      • Trigger - Turn off Troll F1 R3 <gen>
      • Trigger - Turn off Troll F1 R4 <gen>
      • Trigger - Turn off Troll F2 R1 <gen>
      • Trigger - Turn off Troll F2 R2 <gen>
      • Trigger - Turn off Troll F2 R3 <gen>
      • Trigger - Turn off Troll F2 R4 <gen>
      • Trigger - Turn off Gnoll F1 R1 <gen>
      • Trigger - Turn off Gnoll F1 R2 <gen>
      • Trigger - Turn off Gnoll F2 R1 <gen>
      • Trigger - Turn off Gnoll F2 R2 <gen>
      • Trigger - Turn off DaemonWarrior R1 <gen>
      • Trigger - Turn off DaemonWarrior R2 <gen>
      • Trigger - Turn off Magori F1 R1 <gen>
      • Trigger - Turn off Magori F1 R2 <gen>
      • Trigger - Turn off Magori F1 R3 <gen>
      • Trigger - Turn off Magori F1 R4 <gen>
      • Trigger - Turn off Magori F2 R1 <gen>
      • Trigger - Turn off Magori F2 R2 <gen>
      • Trigger - Turn off Magori F2 R3 <gen>
      • Trigger - Turn off Magori F2 R4 <gen>
      • Trigger - Turn off Owlbear F1 R1 <gen>
      • Trigger - Turn off Owlbear F1 R2 <gen>
      • Trigger - Turn off Owlbear F1 R3 <gen>
      • Trigger - Turn off Owlbear F1 R4 <gen>
      • Trigger - Turn off Owlbear F2 R1 <gen>
      • Trigger - Turn off Owlbear F2 R2 <gen>
      • Trigger - Turn off Owlbear F2 R3 <gen>
      • Trigger - Turn off Owlbear F2 R4 <gen>
      • Trigger - Turn off Sang R1 <gen>
      • Trigger - Turn off Sang R2 <gen>
      • Trigger - Turn off Sang R3 <gen>
      • Trigger - Turn off Sang R4 <gen>
      • Trigger - Turn off Saqualaminoi F1 R1 <gen>
      • Trigger - Turn off Saqualaminoi F1 R2 <gen>
      • Trigger - Turn off Saqualaminoi F1 R3 <gen>
      • Trigger - Turn off Saqualaminoi F2 R1 <gen>
      • Trigger - Turn off Saqualaminoi F2 R2 <gen>
      • Trigger - Turn off Saqualaminoi F2 R3 <gen>
      • Trigger - Turn off SeaOgre R1 <gen>
      • Trigger - Turn off SeaOgre R2 <gen>
      • Trigger - Turn off SeaOgre R3 <gen>
      • Trigger - Turn off SeaOgre R4 <gen>
      • Trigger - Turn off SeaOgre R5 <gen>
      • Trigger - Turn off SeaOgre R6 <gen>
      • Trigger - Turn off Thanoi F1 R1 <gen>
      • Trigger - Turn off Thanoi F1 R2 <gen>
      • Trigger - Turn off Thanoi F1 R3 <gen>
      • Trigger - Turn off Thanoi F1 R4 <gen>
      • Trigger - Turn off Thanoi F2 R1 <gen>
      • Trigger - Turn off Thanoi F2 R2 <gen>
      • Trigger - Turn off Thanoi F2 R3 <gen>
      • Trigger - Turn off Thanoi F2 R4 <gen>
      • Trigger - Turn off UndeadOgre F1 R1 <gen>
      • Trigger - Turn off UndeadOgre F1 R2 <gen>
      • Trigger - Turn off UndeadOgre F2 R1 <gen>
      • Trigger - Turn off UndeadOgre F2 R2 <gen>
      • Trigger - Turn off WhisperSpider F1 R1 <gen>
      • Trigger - Turn off WhisperSpider F1 R2 <gen>
      • Trigger - Turn off WhisperSpider F2 R1 <gen>
      • Trigger - Turn off WhisperSpider F2 R2 <gen>
      • Trigger - Turn off WildOgre F1 R1 <gen>
      • Trigger - Turn off Wild Ogre F1 R2 <gen>
      • Trigger - Turn off WildOgre F2 R1 <gen>
      • Trigger - Turn off WildOgre F2 R2 <gen>
      • Trigger - Turn off YaggolElite F1 R1 <gen>
      • Trigger - Turn off YaggolElite F1 R2 <gen>
      • Trigger - Turn off YaggolElite F2 R1 <gen>
      • Trigger - Turn off YaggolElite F2 R2 <gen>
      • Trigger - Turn off YaggolSavage F1 R1 <gen>
      • Trigger - Turn off YaggolSavage F1 R2 <gen>
      • Trigger - Turn off YaggolSavage F2 R1 <gen>
      • Trigger - Turn off YaggolSavage F2 R2 <gen>
      • Trigger - Turn off (This trigger)


Turn on Tier 2 Creep Respawn trigger (long)
Trigger:
  • Tier 2 Creep Respawn Activation 902 seconds
    • Events
      • Time - Elapsed game time is 60.00 seconds
    • Conditions
    • Actions
      • Trigger - Turn on Cedar Champion F1 R1 <gen>
      • Trigger - Turn on Cedar champion f1 r2 <gen>
      • Trigger - Turn on cedar champion f1 r3 <gen>
      • Trigger - Turn on cedar champion f1 r4 <gen>
      • Trigger - Turn on Cedar Wretchchamp f2 r1 <gen>
      • Trigger - Turn on Cedar Wretchchamp f2 r2 <gen>
      • Trigger - Turn on Cedar Wretch champ f2 r3 <gen>
      • Trigger - Turn on Cedar Wretch champ f2 r4 <gen>
      • Trigger - Turn on DaemonWarriorchamp r1 <gen>
      • Trigger - Turn on DaemonWarrior champ r2 <gen>
      • Trigger - Turn on Magori champ f1 r1 <gen>
      • Trigger - Turn on Magori champ f1 r2 <gen>
      • Trigger - Turn on Magori champ f1 r3 <gen>
      • Trigger - Turn on Magori champ f1 r4 <gen>
      • Trigger - Turn on Magori champ f2 r1 <gen>
      • Trigger - Turn on Magori champ f2 r2 <gen>
      • Trigger - Turn on Magori champ f2 r3 <gen>
      • Trigger - Turn on Magori champ f2 r4 <gen>
      • Trigger - Turn on Owlbear champ f1 r1 <gen>
      • Trigger - Turn on Owlbear champ f1 r2 <gen>
      • Trigger - Turn on Owlbear champ f1 r3 <gen>
      • Trigger - Turn on Owlbear champ f1 r4 <gen>
      • Trigger - Turn on Owlbear champ f2 r1 <gen>
      • Trigger - Turn on Owlbear champ f2 r2 <gen>
      • Trigger - Turn on Owlbear champ f2 r3 <gen>
      • Trigger - Turn on Owlbear champ f2 r4 <gen>
      • Trigger - Turn on Sang champ r1 <gen>
      • Trigger - Turn on Sang champ r2 <gen>
      • Trigger - Turn on Sang champ r3 <gen>
      • Trigger - Turn on Sang champ r4 <gen>
      • Trigger - Turn on Saqualaminoi champ f1 r1 <gen>
      • Trigger - Turn on Saqualaminoi champ f1 r2 <gen>
      • Trigger - Turn on Saqualaminoi champ f1 r3 <gen>
      • Trigger - Turn on Saqualaminoi champ f2 r1 <gen>
      • Trigger - Turn on Saqualaminoi champ f2 r2 <gen>
      • Trigger - Turn on Saqualaminoi champ F2 R3 <gen>
      • Trigger - Turn on SeaOgre champ r1 <gen>
      • Trigger - Turn on SeaOgre champ r2 <gen>
      • Trigger - Turn on SeaOgre champ r3 <gen>
      • Trigger - Turn on SeaOgre champ r4 <gen>
      • Trigger - Turn on SeaOgre champ r5 <gen>
      • Trigger - Turn on SeaOgre champ r6 <gen>
      • Trigger - Turn on Thanoi champ f1 r1 <gen>
      • Trigger - Turn on ThanoiH champ f1r2 <gen>
      • Trigger - Turn on Thanoi champ f1 r3 <gen>
      • Trigger - Turn on ThanoiH champ f1 r4 <gen>
      • Trigger - Turn on Thanoi champ f2 r1 <gen>
      • Trigger - Turn on Thanoi champ f2 r2 <gen>
      • Trigger - Turn on Thanoi champ f2 r3 <gen>
      • Trigger - Turn on Thanoi champ f2 r4 <gen>
      • Trigger - Turn on UndeadOgre champ f1 r1 <gen>
      • Trigger - Turn on UndeadOgre champ f1 r2 <gen>
      • Trigger - Turn on UndeadOgre champ f2 r1 <gen>
      • Trigger - Turn on UndeadOgre champ f2 r2 <gen>
      • Trigger - Turn on WhisperSpider champ f1 r1 <gen>
      • Trigger - Turn on WhisperSpider champ f1 r2 <gen>
      • Trigger - Turn on WhisperSpider champ f2 r1 <gen>
      • Trigger - Turn on WhisperSpider champ f2 r2 <gen>
      • Trigger - Turn on YaggolElite champ f1 r1 <gen>
      • Trigger - Turn on YaggolElite champ f1 r2 <gen>
      • Trigger - Turn on YaggolElite champ f2 r1 <gen>
      • Trigger - Turn on YaggolElite champ f2 r2 <gen>
      • Trigger - Turn on YaggolSavage champ f1 r1 <gen>
      • Trigger - Turn on YaggolSavage champ f1 r2 <gen>
      • Trigger - Turn on YaggolSavage champ f2 r1 <gen>
      • Trigger - Turn on YaggolSavagechamp f2 r2 <gen>
      • Trigger - Turn on troll champion f1 r1 <gen>
      • Trigger - Turn on troll champ f1 r2 <gen>
      • Trigger - Turn on troll champ f1 r3 <gen>
      • Trigger - Turn on troll champ f1 r4 <gen>
      • Trigger - Turn on troll champ f2 r1 <gen>
      • Trigger - Turn on troll champ f2 r2 <gen>
      • Trigger - Turn on troll champ f2 r3 <gen>
      • Trigger - Turn on troll champ f2 r4 <gen>
      • Trigger - Turn on wildogre champ f1 r1 <gen>
      • Trigger - Turn on wild ogre champ f1 r2 <gen>
      • Trigger - Turn on wildogre champ f2 r1 <gen>
      • Trigger - Turn on WildOgrechamp f2 r2 <gen>


So how can I remove the delay? Its like 10-20 seconds between Tier 1 being removed and Tier 2 spawning in the region. Also Can I make a single trigger to remove all Tier1 units or do I need to make 1 trigger for each region?

Thanks for any and all replies.
 

Gtam

Lerning how to write and read!! Yeah.
Reaction score
164
Make both tier 1 + 2 events 59 sec ane in tier 2 make wait 1 sec at start of actions
 

BlightWarden

New Member
Reaction score
6
Make both tier 1 + 2 events 59 sec ane in tier 2 make wait 1 sec at start of actions

I set the times to 59sec and added in a 1sec wait but it only made the delay longer.:confused: I also get a good amount of lag when Tier 2 units initially spawn the first time. This lag happened before I added the wait and still happens.
 

Gtam

Lerning how to write and read!! Yeah.
Reaction score
164
Try spliting it up makeing it smaller and se if it works
 

BlightWarden

New Member
Reaction score
6
Try spliting it up makeing it smaller and se if it works

Hmm, I was trying to avoid that because I already have many, many triggers and need to add many more. But I will try it and see if that helps. Thanks.

[edit] Nope, the delay is still there but the lag is reduced to a faction of a second so you almost can't notice it. I may just have to accept the delay if I can't fix it and I don't know how bad the lagspike will be with 100+ units being removed/created all in a few seconds. But I have no way around it. I can't reduce the number of creeps or tiers.

[edit2] Reduced the wait to 0.01 and now the delay is practically gone. Tier 1 is removed and Tier 2 spawns about a second after that. So thanks for the help! Now I guess I just have to make seperate triggers for all the unit groups and hope that doesnt cause a lagspike or a longer delay!

+rep if I can, Might need to spread it around. Gotta spread it around so I owe you some rep. Thanks again!
 

Gtam

Lerning how to write and read!! Yeah.
Reaction score
164
Ya see i had that problem to 1 trig was every 60 sec and othe ever 61 sec and see when 60 seconds past 1 later it runs the second thennext time 2 seconds later then 3seconds later do u under stand eventualy irt will be 60 seconds later and then the first triger would run 2 times before the second one

the reason i said split it up was to see if that was the problem
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • Ghan Ghan:
    Still lurking
    +3
  • The Helper The Helper:
    I am great and it is fantastic to see you my friend!
    +1
  • The Helper The Helper:
    If you are new to the site please check out the Recipe and Food Forum https://www.thehelper.net/forums/recipes-and-food.220/
  • Monovertex Monovertex:
    How come you're so into recipes lately? Never saw this much interest in this topic in the old days of TH.net
  • Monovertex Monovertex:
    Hmm, how do I change my signature?
  • tom_mai78101 tom_mai78101:
    Signatures can be edit in your account profile. As for the old stuffs, I'm thinking it's because Blizzard is now under Microsoft, and because of Microsoft Xbox going the way it is, it's dreadful.
  • The Helper The Helper:
    I am not big on the recipes I am just promoting them - I use the site as a practice place promoting stuff
    +2
  • Monovertex Monovertex:
    @tom_mai78101 I must be blind. If I go on my profile I don't see any area to edit the signature; If I go to account details (settings) I don't see any signature area either.
  • The Helper The Helper:
    You can get there if you click the bell icon (alerts) and choose preferences from the bottom, signature will be in the menu on the left there https://www.thehelper.net/account/preferences
  • The Helper The Helper:
    I think I need to split the Sci/Tech news forum into 2 one for Science and one for Tech but I am hating all the moving of posts I would have to do
  • The Helper The Helper:
    What is up Old Mountain Shadow?
  • The Helper The Helper:
    Happy Thursday!
    +1
  • Varine Varine:
    Crazy how much 3d printing has come in the last few years. Sad that it's not as easily modifiable though
  • Varine Varine:
    I bought an Ender 3 during the pandemic and tinkered with it all the time. Just bought a Sovol, not as easy. I'm trying to make it use a different nozzle because I have a fuck ton of Volcanos, and they use what is basically a modified volcano that is just a smidge longer, and almost every part on this thing needs to be redone to make it work
  • Varine Varine:
    Luckily I have a 3d printer for that, I guess. But it's ridiculous. The regular volcanos are 21mm, these Sovol versions are about 23.5mm
  • Varine Varine:
    So, 2.5mm longer. But the thing that measures the bed is about 1.5mm above the nozzle, so if I swap it with a volcano then I'm 1mm behind it. So cool, new bracket to swap that, but THEN the fan shroud to direct air at the part is ALSO going to be .5mm to low, and so I need to redo that, but by doing that it is a little bit off where it should be blowing and it's throwing it at the heating block instead of the part, and fuck man
  • Varine Varine:
    I didn't realize they designed this entire thing to NOT be modded. I would have just got a fucking Bambu if I knew that, the whole point was I could fuck with this. And no one else makes shit for Sovol so I have to go through them, and they have... interesting pricing models. So I have a new extruder altogether that I'm taking apart and going to just design a whole new one to use my nozzles. Dumb design.
  • Varine Varine:
    Can't just buy a new heatblock, you need to get a whole hotend - so block, heater cartridge, thermistor, heatbreak, and nozzle. And they put this fucking paste in there so I can't take the thermistor or cartridge out with any ease, that's 30 dollars. Or you can get the whole extrudor with the direct driver AND that heatblock for like 50, but you still can't get any of it to come apart
  • Varine Varine:
    Partsbuilt has individual parts I found but they're expensive. I think I can get bits swapped around and make this work with generic shit though
  • Ghan Ghan:
    Heard Houston got hit pretty bad by storms last night. Hope all is well with TH.
  • The Helper The Helper:
    Power back on finally - all is good here no damage
    +2
  • V-SNES V-SNES:
    Happy Friday!
    +1
  • The Helper The Helper:
    New recipe is another summer dessert Berry and Peach Cheesecake - https://www.thehelper.net/threads/recipe-berry-and-peach-cheesecake.194169/

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top