I have a hero that needs to be able to die and revive at a building. I have that part set up all good through the revive ability. The only problem is that some of my behaviors that the hero uses are required to stay on him through his death and still be on him after he revives. Anyone have any idea how I could do something like this? If I am not being clear on what I want let me know.
Just gave the permanent thing a shot, no go. Even turned the unit into a hero just to see what would happen. Is the fact i'm creating the unit through triggers having an affect on this?
In case you want to add items that can be equipped by your hero(es) later on I suggest that you don't let you hero die at all; you make it look like he dies. You just need to have a trigger checking for when he receives the killing blow, then you make your hero invulnerable, hide and deselect your hero, and create a model actor resembling the hero, face it the facing angle of the hero and play the model's death animation.
Then you can simply show your hero whenever you want and remove the invulnerability behavior.
I use the "Hero Death Prevention" behavior for this job, with a few modificaitons. For instance, I removed the duration and the "Stand up" effect, so that I could use trigger timers for "reviving" my hero.
Create effects to apply those behaviors, and then create abilities which activate those effects when used. You'll want abilities to be of the type (Effect - Instant). Ensure that auto-cast is available and enabled, the ability is transient, and that you create a validator so that it only casts if the behavior is not present on the unit. Give this ability to your unit(s). However, DO NOT give it a button on the command card.
i have the same issue right now, and i really dont want to use this death prevention system.
this thread is really old, so i thought i just "ask" here if there is an better easier way now.. several patches etc. changed some things, so probably this works now with just one flag anywhere or whatever..
any ideas?
problem on my map is, that i use attributes and the heroes are able to "buy" attributes - really much of them.
so the have to stay on a hero even if he dies, but counting them, storing in variables and reapplying would just suck - also like i said death prevention is something i dont want to use right now.
If is not that hard to create a death prevention system based on the Valerian03 heros and you can always use the actor events to make it look like it is dying.
Rollback Post to RevisionRollBack
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
If is not that hard to create a death prevention system based on the Valerian03 heros and you can always use the actor events to make it look like it is dying.
okay so.. how would that work?
obviously there is this Hero incapacitated behaviour, and it works kinda easy, i put that on my unit and as soon as it would receive the killing damage its just incapacitated and stands up again after soem seconds.
now i just have to make it look like it dies, and after that implement it into my revive trigger - but how?
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
I have a hero that needs to be able to die and revive at a building. I have that part set up all good through the revive ability. The only problem is that some of my behaviors that the hero uses are required to stay on him through his death and still be on him after he revives. Anyone have any idea how I could do something like this? If I am not being clear on what I want let me know.
did you make the buff as "permanent" in the fields?
@Jinxxx123: Go
Just gave the permanent thing a shot, no go. Even turned the unit into a hero just to see what would happen. Is the fact i'm creating the unit through triggers having an affect on this?
@Antimatterthunder: Go
In case you want to add items that can be equipped by your hero(es) later on I suggest that you don't let you hero die at all; you make it look like he dies. You just need to have a trigger checking for when he receives the killing blow, then you make your hero invulnerable, hide and deselect your hero, and create a model actor resembling the hero, face it the facing angle of the hero and play the model's death animation.
Then you can simply show your hero whenever you want and remove the invulnerability behavior.
I use the "Hero Death Prevention" behavior for this job, with a few modificaitons. For instance, I removed the duration and the "Stand up" effect, so that I could use trigger timers for "reviving" my hero.
Good luck! :)
Here's a quick and dirty:
Create effects to apply those behaviors, and then create abilities which activate those effects when used. You'll want abilities to be of the type (Effect - Instant). Ensure that auto-cast is available and enabled, the ability is transient, and that you create a validator so that it only casts if the behavior is not present on the unit. Give this ability to your unit(s). However, DO NOT give it a button on the command card.
hey guys.
i have the same issue right now, and i really dont want to use this death prevention system.
this thread is really old, so i thought i just "ask" here if there is an better easier way now.. several patches etc. changed some things, so probably this works now with just one flag anywhere or whatever..
any ideas?
problem on my map is, that i use attributes and the heroes are able to "buy" attributes - really much of them.
so the have to stay on a hero even if he dies, but counting them, storing in variables and reapplying would just suck - also like i said death prevention is something i dont want to use right now.
If is not that hard to create a death prevention system based on the Valerian03 heros and you can always use the actor events to make it look like it is dying.
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg
okay so.. how would that work?
obviously there is this Hero incapacitated behaviour, and it works kinda easy, i put that on my unit and as soon as it would receive the killing damage its just incapacitated and stands up again after soem seconds.
now i just have to make it look like it dies, and after that implement it into my revive trigger - but how?