• Check out the results of the Techtree Contest #19!
  • 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.
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!

Hero Re-Spawn, need help!

Status
Not open for further replies.

Mr.Jagil

M

Mr.Jagil

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.
 
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
 
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...
 
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...
 
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
 
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.
Back
Top