ReviveHeroLoc

Parameters
whichHero unit
loc location

Location on map.

doEyecandy boolean

True to revive with revival special effects, false without. Special effects include: sound, visual effect.

comment

Revives a dead hero at target location, with or without special effects.

Returns true if hero was dead and revived. Returns false otherwise (hero alive, unit isn't a hero/doesn't exist etc.)

note

If the unit has a food cost != 0 (greater or less than 0), for the revival to be successful, the owning player of the unit must not exceed the maximum food limit (including the revived unit's food cost), i.e., PLAYER_STATE_RESOURCE_FOOD_USED + unit's food cost <= PLAYER_STATE_FOOD_CAP_CEILING.

note

See: ReviveHero.

patch

1.00

Source
common.j
return type
boolean
Source code
native          ReviveHeroLoc       takes unit whichHero, location loc, boolean doEyecandy returns boolean