• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Hero Re-Spawn, need help!

Status
Not open for further replies.
Level 2
Joined
Dec 30, 2004
Messages
6
As the headline says, i dont know how to make hero's respawn, in a specific region, when they die. Could anyone explain how? And plz, simpify it as much as possible, 'cause im kinda dumb.
 
Level 3
Joined
Jan 10, 2005
Messages
72
this is the most simplest way:
Hero Respawn
Events
Unit - A unit owned by Player 1 (Red) Dies
Conditions
(Unit-type of (Dying unit)) Equal to Paladin <-- chose hero type you want
Actions
Hero - Instantly revive (Dying unit) at (Center of (Playable map area)), Hide revival graphics

you can also add 'Wait' action before revive if you want delay in respawning
 
Level 2
Joined
Dec 30, 2004
Messages
6
Yay, it worked... But i got like 5 heros in my map, do i have to make a trigger to each of them? Somebody once told me that the more triggers you have, the more it laggs...
 
Level 22
Joined
May 11, 2004
Messages
2,863
If you have that many heroes, you will need to use condition.

I.e.

Event- unit dies

Condition- owner of triggering unit is (player)
Dying unit is equal to (hero) <---only works if the heroes are pre-placed and selected in the map editor, not built or spawned.

Action- Revived last killed hero/triggering unit/hero name, ect...
 
Level 9
Joined
Nov 27, 2004
Messages
465
At least if unit is spawned in the game you may kill "2 rabbits by 1 shot"

1 trigger:
when player choose his new hero just add this sentence
(needed a new "unit" variable)

set :user(number of player of ls created unit)) = last created unit

trigger 2

Event
Unit-dies
Condition
Dying unit equal to user(x)
Action:
wait for lalala
Revive dying unit at location "your location"


HINT1 (if you want to make different respawn places for deifferent players,than you'll need to make so much triggers how many users max may play that map)

HINT2 (If you want to make different respawn places for different UNITs you may remake condition to:

Condition
or
dying unit equal to user(x)
dying unit equal to user(x1)
lalala
Action
if
__unit-type of dying unit equal to herotype1
then
___ wait lalala
____revive dying unit at location {place1}
if
__unit-type of dying unit equal to herotype2
then
___ wait lalala
____revive dying unit at location {place2}
and so on
 
Level 5
Joined
Jul 15, 2004
Messages
148
If you will need the capability of reviving multiple heroes at one (if one dies, and then another dies after), download This . This should help you out a bit. It uses quite a bit of custom script, but if you know how to use world editor, this won't be too hard to understand.
 
Status
Not open for further replies.
Top