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

[Trigger] Hero Resurrect

Status
Not open for further replies.
Level 3
Joined
Jul 26, 2008
Messages
58
Hero death:

  • Unit - A unit owned by Player 1 (Red) dies.
  • Set dyingunit1 = (Dying unit)
  • Unit - Create 1 Grave for Player 1 (Red) at (Position of dyingunit1) facing Default building facing (270.0) degrees
  • Unit - Make (Last created unit) Invulnerable
  • Set deadunit1 = (Last created unit)
Resurrection Trigger:

  • Unit - A unit Start the effect of an ability
  • (Ability being cast) Equal to Resurrection
  • (Owner of deadunit1) Equal to Player 1 (Red)
  • (Unit-type of deadunit1) Equal to Grave
  • Hero - Instantly revive dyingunit1 at (Position of deadunit1), Show revival graphics
  • Remove deadunit1 from the game
All is seems to be ok, but that Grave i've spawned never can be destroyed. If i manually kill it, theres immidiatly appearing another one.. What i should fix?
 
For starters, add

  • ((Dying unit) is A Hero) Equal to True
as a condition to the hero death trigger.

Other than that, I don't know what's the problem. You set the grave to be invulnerable, so units can't destroy it. What do you mean by manually killing it?

I tested the trigger by killing a hero, and spawning a footman upon death, and reviving occuring when Blink ability is used. It works fine.
 
You also have to remove the leaks.
  • Events
    • Unit - a unit owned by Player 1 (red) dies
  • Conditions
    • Dying unit is a (hero) equal to true
  • Actions
    • Set dyingunit1= (dying unit)
    • Set temploc = position of dyingunit1
    • Unit - create 1 graveyard for owner of dyingunit1 at temploc facing Default building facing (270.0) degrees
    • Custom script: call RemoveLocation(udg_temploc)
And then you need to do it again for deadunit1. I don't see anything wrong with the trigger itself. Unless you got a conflicting one. that uses the same unit-type
 
For starters, add

  • ((Dying unit) is A Hero) Equal to True

Guys, i know about that, and i know about leaks. But now i have problems with Grave, i need to fix it. I'll try to set as "Triggering unit" (why? o_O) and try to change unit "Grave".
Manually killed - i just removed invulnerablity

I understood how dumb was i :X
  • ((Dying unit) is A Hero) Equal to True
ofc it MUST be there, cuz grave can spawn another one grave, right?
But.. Grave still doesnt want to remove. But when i kill it, it disappears.
So still need help with its triggered removing.
 
Last edited by a moderator:
Because you kill a unit which will fire the trigger again, thats why you must add condition so that every time the 'Graveyard' is killed the trigger fires again and create another 'Grave'.

Look at my prev post :)
Else, i thought problem was in my base unit - Phoenix' egg. But i changed it into farm and got no effect..
 
Look at my prev post :)
Else, i thought problem was in my base unit - Phoenix' egg. But i changed it into farm and got no effect..

Yes I know I wrote it then I found you post in front of me.

And as for your problem removing the grave 'Remove deadpoint 1 from the game' works right IF the first "Grave" hasn't destroyed; deadpoint 1 will refer to a dead unit if the first Grave was destroyed.
 
So, there is no way to REMOVE the grave?
I don't know but Remove UNIT from the game is supposed to work perfectly. May be the problem is in the variable that it is not refering to the Grave.

Ok, try displaying a msg that tells of the type of the unit deadpoint 1 variable is refering to and see if the problem is in the variable or other.
 
I dont think so.. I tried to change variable "deadunit1" to "Target of the ability being cast", got the same problem.
 
I dont think so.. I tried to change variable "deadunit1" to "Target of the ability being cast", got the same problem.

No, set deadunit 1 = Last Created Unit (which will be the grave)

Then when someone cast resurection remove deadunit 1 from the game, whats wrong with that ?!!!

Try it again and check your variables correctly and if it doesn't work tell me so I could try and code it myself.
 
Dying Unit says itself, your trigger has a Unit Dies, the Dying Unit, is for the unit who is about to die, Event Response - Triggering Unit will be set of to the one who completes your event

But all is ok with dying unit trigger, something wrong only with spawned unit..
And all is ok with variables, as i can see...
 
Last edited:
I used that fuction, and, true, all worked fine.. I dont know what happened now.
Anyway, wish you luck with my problem :)

-nothing here-
 
Last edited by a moderator:
It wont work, cuz grave must stay as long as dead hero will be resurrected by someone, or player clicks the button to revive at town
 
-nothing here-

Sorry I got distracted but I'll work on it.

It works very fine for me and here is the triggers.

  • Unit Death
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Owner of (Triggering unit)) Equal to Player 1 (Red)
    • Actions
      • Set DeadUnit = (Triggering unit)
      • Set DeathPoint = (Position of DeadUnit)
      • Unit - Create 1 Grave for (Owner of DeadUnit) at DeathPoint facing 270.00 degrees
      • Set Grave = (Last created unit)
  • Revive
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Resurrection
    • Actions
      • Hero - Instantly revive DeadUnit at DeathPoint, Show revival graphics
      • Unit - Remove Grave from the game
Remove the leaks by yourself.

Variables:
- DeadUnit, Grave > Units
- DeathPoint > Point

Grave in Create 1 Grave for ... is a dummy unit.

(Owner of (Triggering unit)) Equal to Player 1 (Red) change this cond. as you see fit but note that without a condition every unit will die will cause the triggers to fire a ruin everything.
 
Last edited by a moderator:
I fixed my trigger many times and now this is really increadible.
I created excatly ur trigger, and all works fine.
But.. Then i looked at my trigger... Result: ABSOLUTELY same triggers, except variables names. So what the *bad word* is that?.. =|
P.S. And i even dont know what means GUI, MUI or others, i never learnt anything about wc3editor =D
Anyway, Starquizer, big thanks to you.
 
P.S. And i even dont know what means GUI, MUI or others, i never learnt anything about wc3editor =D
Anyway, Starquizer, big thanks to you.

There are tutorials to learn more about the editor.
MUI stands for Multi-Unit Instancible; it is what makes the spell cast at any time by more than one unit without any bugs

GUI is the normal triggers in the editor, there is JASS its more advanced than GUI but can do more miracles than GUI.
 
Uhm.. Im not enough good in english, so it will be hard, but, guess, i still need to learn about MUI, cuz i need to duplicate such triggers for 8players usage. Ty for the advice.
 
Can anyone do that trigger at MUI please? Remove the leaks, make this trigger correctly work for 8 players and so on, so i hope i can do the same just at one example.
 
Yea, Slaydon is right, only for heroes :)
Theres res system - you can be resurrected by some spell, or you can just revive urself at town.
Actually creating dialog like "x wants to ressurect you, do you accept?| yes/no" will be nice, but its not neccesarry.
 
I got PC crash at first, and i have no idead about MUI at seconds.
I asked to make this trigger in MUI for 8 players without leaks, so i can make another ones just at this example.
 
I got PC crash at first, and i have no idead about MUI at seconds.
I asked to make this trigger in MUI for 8 players without leaks, so i can make another ones just at this example.

The best thing to learn is to try it yourself and post your triggers here and discuss it but if we make to you a complete example you will not learn anything.

I was once like you when I was trying to make a spell with vJASS and asked for a step-by-step help, then Element of Water told that I should try it myself and I am telling you when you make it on your own is much better.

Still, if you insists that one make it for you then so be it.
 
I asked to make 1 trigger for me, and i supposed to learn how i can do _that type_ MUI-triggers. At the time, i dont interested at anothers, cuz i havent got much time for learning all-about.
 
Invulnerable. I also did the one possible "Ressurect" target - Invulnerables :)
Grave can be target of "Ressurect" and it has ability "Revive at altar", which revives dead hero at town.
 
Invulnerable. I also did the one possible "Ressurect" target - Invulnerables :)
Grave can be target of "Ressurect" and it has ability "Revive at altar", which revives dead hero at town.
No grave are just a mere unit to indicate the location of death the hero will be stored in a variable and when you click the resurect button it will revive that hero and remove the grave.
 
Hm.. Actually, i did that Grave can be target of "Ressurect", so revives the hero in that way, AND grave has an ability to resurrect dead hero at town, is that hard or smth?
 
Hm.. Actually, i did that Grave can be target of "Ressurect", so revives the hero in that way, AND grave has an ability to resurrect dead hero at town, is that hard or smth?

So you want the grave has an ability that resurect the dead hero at town and after the hero is resurected you remove that grave, is that what you want ?
 
Status
Not open for further replies.
Back
Top