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

[Trigger] Issues using [Hero - Instantly Revive]

Status
Not open for further replies.
Level 2
Joined
Dec 30, 2018
Messages
4
Greetings, I'll try to keep this thread as informative as possible. If you find that I've failed to include important information in order for you to help, please comment below and I will add it as soon as I can.

I recently got into map making, and decided to take on the task of a simple, spawn in with a normal unit, select a hero and fight. If you die you should revive after x amount of seconds in a specific region.

Spawning in with a normal unit and creating triggers for selecting a hero went smooth, and that is when I ran into trying reviving the hero... its simply not working for me, and either its a bug of sorts, or I've made a mistake somewhere along the process (Most likely). I've been searching for a good 3 hours on different methods, and tried a bunch of different alternatives, I'm out of guesses and hope to find some help.

I've included the triggers below which I use to select a hero and for reviving the hero. (Ops: The reason I've included the select hero trigger is in case that in someway interfere with the reviving part.)
I'm in no way an expert on this, just a guy with a lot of general programming knowledge, so focus less on suggesting improvements to the code that is unrelated to the functional part of reviving the hero.


I've also included a GIF that should demonstrate the above.
Screen capture - cf026528d46ef1a1fe1b135517973e88 - Gyazo

- Selecting the paladin
  • Select Hero Paladin
    • Events
      • Unit - A unit enters Select Unit Paladin <gen>
    • Conditions
      • (Unit-type of (Entering unit)) Equal to Slave
    • Actions
      • Unit - Create 1 Paladin for (Owner of (Entering unit)) at (Center of Spawn Hero <gen>) facing 270.00 degrees
      • Unit - Remove (Entering unit) from the game
- Reviving the hero
  • Respawn Hero
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Triggering unit) is A Hero) Equal to True
      • ((Owner of (Triggering unit)) controller) Equal to User
    • Actions
      • Wait 2.00 seconds
      • Hero - Instantly revive (Triggering unit) at (Center of Starting Point <gen>), Show revival graphics
<I have tried with and without the Wait>
Thank you for reading through my thread, and hopefully I've included enough information to spot any mistakes I might've made.

Edit: Solution posted below (Food Limit)
 
Last edited:
Level 2
Joined
Dec 30, 2018
Messages
4
I have no idea why it is not working, try to remove the conditions and test it again.


Here is a simple Hero Respawn System just change the conditions and Respawn time.
Is there any setting in the world editor that may cause it not to work?
 
Level 2
Joined
Dec 30, 2018
Messages
4
The issue was due to food limitation, I didn't know it played a factor in ReviveHeroLoc, thanks to TriggerHappy for the help, and I appeciate your responses Shunpomaster!
 
Level 2
Joined
Dec 30, 2018
Messages
4
Didn't know about that too.
Me neither, but it looks like a simple check (If you don't have enough food to revive the hero, it won't.

Funny enough, after 4 hours of googling, I found nothing relating to this either, but I'm glad it is solved :)
 
Status
Not open for further replies.
Top