Some TD Trigger Help here!

yami-joey

TH.net Regular
Reaction score
20
I am making a new TD map and I need some trigger help. :)
So, my TD map is in grid form like this:

--------------------------------
|X = CREEP SPAWN HERE
--------------------------------
|X = CREEP SPAWN HERE
--------------------------------
|X = CREEP SPAWN HERE
--------------------------------

The spaces between the lines are where you can place your towers (X). But I wanted it so that the towers you place there only attack in a horizontal direction and NOT attack the other creeps that arrive from the other lanes. (Think Plants Vs Zombies).

Is it even possible?

Oh, and, is there a trigger for when you make a building that when you build it you gain 25 gold per XX seconds. So if you have 3 of those you get 75 gold per XX seconds...

Thank you in advance.
 

jig7c

Stop reading me...-statement
Reaction score
123
Trigger:
  • Trigger 1
    • Events
      • A unit finishes constructing
    • Conditions
      • Constructed Structure equal to Unit-type of <Your Building>
    • Actions
      • Set Count[Player number of (Owner of (Constructed Structure))] = Count[Player number of (Owner of (Constructed Structure))] + 1
    • -----Count is an integer array, with initial value of 0



Trigger:
  • Trigger 2
    • Events
      • Every XX seconds
    • Conditioins
    • Actions
      • Pick every players in (All Players) and do
        • Loop
          • Player - Add (Count[Player number of (Owner of (Picked Player))] x 3) Gold to (Picked Player)


rough draft!
I don't get your TD from that drawing.. but if you only want a player's towers to attack only their creeps,
a) make it so the range isn't that long enough/spread out the players on the map
b) trigger it so when player 1 attacks a unit from a different lane, order that tower to stop
-every time the creeps spawn, add those creeps to an unit group.. player1group, player2group, etc...
and then, when the units die, remove them from the group... and when there is no unit left in that group.. destroy that group! and when a player 1's tower tries to attack player2group units.. order that tower to stop!
 

Nherwyziant

Be better than you were yesterday :D
Reaction score
96
OT... : Mby he's making a part of the map for a mini game or sth like a TD...

No lol, his map is already full of terrain. He can't place something like that. And as what he said "I am making a new TD map"
 

yami-joey

TH.net Regular
Reaction score
20
No lol, his map is already full of terrain. He can't place something like that. And as what he said "I am making a new TD map"
No, I'm not leaving PW. I'm just working on a sub-map while the people who help me are working on PW. :D
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      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