• 🏆 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!

how to revive (respawn) unit at a building ,when i build a tower

Status
Not open for further replies.
Level 6
Joined
Mar 9, 2009
Messages
175
how to revive (respawn) unit from a building ,when i build a tower

How to (respawn) unit from a building ,when i build a building .:wink:
 
Last edited:
Level 7
Joined
Jul 29, 2009
Messages
276
Respawn? as in spawning something Agian?

You should make yourself more clear if you want people to help you.
 
Level 9
Joined
Aug 27, 2009
Messages
473
This should work:
  • Respawn
    • Events
      • Time - Every 30.00 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in (Units of type Barracks) and do (Actions)
        • Loop - Actions
          • Set ele_LeakPoint = (Position of (Picked unit))
          • Unit - Create 1 Footman for (Owner of (Picked unit)) at ele_LeakPoint facing Default building facing degrees
          • Custom script: call RemoveLocation( udg_ele_LeakPoint)
Enjoy :D
 
Level 9
Joined
Aug 27, 2009
Messages
473
^The unit group leaks, which is bad since tthe trigger might run many many times for several units.

Ur right! My bad..

  • Respawn
    • Events
      • Time - Every 30.00 seconds of game time
    • Conditions
    • Actions
      • Set ele_UnitGroupLeak = (Units of type Barracks)
      • Unit Group - Pick every unit in ele_UnitGroupLeak and do (Actions)
        • Loop - Actions
          • Set ele_LeakPoint = (Position of (Picked unit))
          • Unit - Create 1 Footman for (Owner of (Picked unit)) at ele_LeakPoint facing Default building facing degrees
          • Custom script: call RemoveLocation( udg_ele_LeakPoint)
        • Custom script: call DestroyGroup( udg_ele_UnitGroupLeak)
 
Level 6
Joined
Mar 9, 2009
Messages
175
nonono sry guys , sry i had never explain properbly :( ~~ i mean when i build a tower and i wan dying unit respawn from the tower .
 
Status
Not open for further replies.
Top