Why is this trigger not working?

romanandre

New Member
Reaction score
2
Can someone explain to me why it won't work?

Trigger:
  • Wave 2 A
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Owner of (Dying unit)) Equal to Player 12 (Brown)
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Number of units in (Units in (Playable map area) owned by Player 12 (Brown))) Equal to 0
        • Then - Actions
          • Trigger - Run Wave 2 B <gen> (ignoring conditions)
        • Else - Actions
          • Do nothing


Trigger:
  • Wave 2 B
    • Events
    • Conditions
    • Actions
      • Player - Set Player 1 (Red) Current gold to 750
      • Countdown Timer - Create a timer window for Timer with title Level two in:
      • Set TimerWindow = (Last created timer window)
      • Countdown Timer - Show TimerWindow
      • Countdown Timer - Start Timer as a One-shot timer that will expire in 10.00 seconds
 

Laiev

Hey Listen!!
Reaction score
188
Trigger:
  • Wave 2 B
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
      • (Number of units in (Units in (Playable map area) owned by Player 12 (Brown))) Equal to 0
    • Actions
      • Player Group - Pick every player in (players) and do actions
        • Player - Add 750 gold to (Picked player)
      • Countdown Timer - Create a timer window for Timer with title Level two in:
      • Set TimerWindow = (Last created timer window)
      • Countdown Timer - Show TimerWindow
      • Countdown Timer - Start Timer as a One-shot timer that will expire in 10.00 seconds

Set gold change your current gold, this will just add to your current
I don't know how countdown timer work.. but you can change the player group in a variable to make it more explained..
You can do all in one trigger...

Freehand, sorry :(
 

romanandre

New Member
Reaction score
2
I can't make it "Every 1.00 seconds of game time" because the trigger has to go off only after the first wave is down (Tower defense). If I do that it will spam the trigger before level 1 even starts.
 

Laiev

Hey Listen!!
Reaction score
188
I can't make it "Every 1.00 seconds of game time" because the trigger has to go off only after the first wave is down (Tower defense). If I do that it will spam the trigger before level 1 even starts.

No, this trigger will check if has unit in map owned by neutral, if not then will run the trigger, also, you can use other trigger to turn on/off this trigger, the important think is make it work

At the start of this trigger, you can "turn off this trigger" also you turn on when other lane start
 

romanandre

New Member
Reaction score
2
I tried this:
Trigger:
  • Wave 2 A
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
      • (Number of units in (Units in (Playable map area) owned by Player 12 (Brown))) Equal to 0
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Level Equal to 1
        • Then - Actions
          • Trigger - Run Wave 2 B <gen> (ignoring conditions)
        • Else - Actions
          • Do nothing


but it didnt work... D:

"Level" is an integer variable, does that work?
 

Laiev

Hey Listen!!
Reaction score
188
First, remove all DO NOTHING cuz this line trigger DO NOTHING -.- so you can leave in blank...

Also you set Level equal to 1 in a variable when the first lane end?
 

Laiev

Hey Listen!!
Reaction score
188
don't work?

at least the second trigger run? i mean, you get gold?
 

Laiev

Hey Listen!!
Reaction score
188
delete the second trigger, and in the first trigger, after checked if level equal to 1, in THEN add ALL actions from another trigger to this...

and test

i mean like this:

actions:
if
level equal to 1
then
add 600 gold
create timer
bla bla bla
 

romanandre

New Member
Reaction score
2
Didn't work, it's something in the condition I think... But the only "unit" that could be left for brown is the starting location, without any townhall or workers...
 

Laiev

Hey Listen!!
Reaction score
188
why used brow? lol

hmmm

set instead of "equal to 0" put less then or equal to 0 :S

probably make no change lol but just to check...

Also you can add ALL units spawned by the trigger (the lane which create the units) to a group, and change conditions when group have no unit, do action, is the same but not checking map, just checking the group

and HAVE some brow unit in your map lol, you can test it removing the condition and test without cond :D

i'll wash me :D

brb, try what i say
 

romanandre

New Member
Reaction score
2
I'm using brown as the enemy, thats why. ;p

I know whats wrong now. The trigger is only activating once, I tried this
Trigger:
  • Wave 2 A
    • Events
      • Time - Every 2.00 seconds of game time
    • Conditions
      • (Number of units in (Units in (Playable map area) owned by Player 12 (Brown))) Less than or equal to 0
    • Actions
      • Player - Set Player 1 (Red) Current gold to 750
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Level Equal to 1
        • Then - Actions
          • Player - Set Player 1 (Red) Current gold to 750
        • Else - Actions
          • Do nothing


and it only gave me gold once, I don't know why its only running once though... when the map starts it goes and then it stops...
 

Laiev

Hey Listen!!
Reaction score
188
back :)
probably one trigger create a unit (dummy or invisible) and you don't know when map start

REMOVE THAT DO NOTHING LOL

and change set to add (gold)
 

skyblader

You're living only because it's illegal killing.
Reaction score
159
It must've some problems with your level adding then.

Trigger:
  • td
    • Events
      • Unit - A unit Dies
    • Conditions
      • And - All (Conditions) are true
        • Conditions
          • ((Triggering unit) belongs to an enemy of Player 1 (Red)) Equal to True
          • (Number of units in (Units in (Playable map area) owned by Player 12 (Brown))) Equal to 0
    • Actions
      • Player - Add 1000 to Player 1 (Red) Current gold
      • Countdown Timer - Start timer as a One-shot timer that will expire in 30.00 seconds
      • Countdown Timer - Create a timer window for (Last started timer) with title Title
      • Set timerWindow = (Last created timer window)
      • Countdown Timer - Hide timerWindow
      • -------- Change whatever you want here --------
      • Countdown Timer - Show timerWindow
      • Wait 30.00 seconds
      • Countdown Timer - Destroy timerWindow


Make sure the creep is Brown. Make sure Brown is an enemy of Red. Change 1k gold to whatever you want. Change the 30 seconds for the timer AND the wait. This should work. + rep is appreciated.:thup:
 

Dameon

"All the power in the world resides in the eyes"
Reaction score
127
Make sure you're looking for living creeps in the playable map area, a dead creep still counts as a creep till it's bones vanish, so just change the condition to number of living units owned by player 12 equal to 0
 

jomik

New Member
Reaction score
17
Don't ask for +rep :D

- This wont check for the level though mate, I think he wants that :p
 

skyblader

You're living only because it's illegal killing.
Reaction score
159
I didn't really ask for a +rep. I just said it is appreciated if you do.
 

jomik

New Member
Reaction score
17
Np skyblade :D Dameon is right btw :O I usually remove creeps when they die if I make a td though :D Or they might lag.
 
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