• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Making a TD run smoothly

Status
Not open for further replies.
Level 6
Joined
Feb 25, 2005
Messages
230
Hullo!

Im creating a TD wars where you play in teams, 2 v 2.
Minimap.jpg (The red lines represent the path the creeps take)

What i've done to prevent blocking is to have the creeps attack1 enabled, and have towers vulnerable. So when blocked, the creeps will go to attack. To make them soldier on after killing a tower i use this simple trigger:

  • unit is attacked
    • Events
      • Unit - A unit Is attacked
    • Conditions
    • Actions
      • -------- Order attacking creep to move --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Owner of (Attacking unit)) Equal to Player 3 (Teal)
        • Then - Actions
          • Wait 0.30 seconds
          • Unit - Order (Attacking unit) to Move To (Center of Team1 finish <gen>)
        • Else - Actions
          • Wait 0.30 seconds
          • If ((Owner of (Attacking unit)) Equal to Player 6 (Orange)) then do (Unit - Order (Attacking unit) to Move To (Center of Team2 finish <gen>)) else do (Do nothing)
It works just fine. The problem is that sometimes the creeps go crazy, and a bunch of towers just explode... and i guess that happens when there are alot of creeps and they all get stuck on eachother.

What i want is tips of how to make it go smooth . Heres what ive done so far:

- Reduced the max stock amount for the creeps you'r sending.
- Having more expensive creeps more worth the money than many of the cheaper types.
- Reduced the collision size of all creeps to 0 (This doesnt seem to help all to much)

What im thinking about doing is to have each creep have a food cost = 1, and then using triggers to notify the player when you have reached max (the creeps you send are spawned for a cpu player, so you cant use the players own food cost)

Except for what i've said here, do you have any tricks up your sleeve to get a TD to handle a quite high amount of units?
A TD-wars that cant handle the units in the game is a sucky map. I dont want a sucky map.
 
Level 3
Joined
Jun 17, 2007
Messages
62
The Attackspeed and the time you wait to order the creeps can effect their will to attack.

Slow Attack + good amount of time to wait in ur trigger can cause them not to go nuts that fast.

You have to set the right values.
Too high attackspeed will let them never attack. (not wanted if you want to destroy blocking towers.

Too much waiting time to order them will get them attacking too soon.

Just try.
 
Status
Not open for further replies.
Top