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

[Spell] Idea: How to make feign death?

Status
Not open for further replies.
So I was wonderign how to make Feign Death spell: the untis feigns death tricking enemy units to ignore it. Any action taken will cancel the effect.
I want the unit to play its death animation and stay dead corpse with invulnerability for the duration of the spell.

Any ideas how this would happen?

One way is edit the model of the unit's decay flesh animation to stand and improt it, and make morphin ability with death animation, but there must be easier way.
 
Last edited:

Jampion

Code Reviewer
Level 15
Joined
Mar 25, 2016
Messages
1,327
There are a few options to make a unit unselectable.

Locust - well bad.
automatically deselect on selection - people will still see that there is a unit (cursor changes when hovered over units) also maybe not instant?
make the unit dead/hide the unit - makes it unselectable for owner as well
teleport unit to an unreachable location - could work, but is ugly for the owner, if his unit is for some reason in a corner of the map
invisibility? burrow? - I think these are two different invisibilities. Let's say you use invisible units in your map, make sure nothing can detect burrowed units and let the caster burrow.
^ I think this could do the trick


Maybe GetLocalPlayer() can do some magic, but I mostly do single player maps, so I don't have experience with this function.
 

Jampion

Code Reviewer
Level 15
Joined
Mar 25, 2016
Messages
1,327
I think this should not be that hard. I was just thinking how it is possible for the caster to be selectable only by the owing team.
For the corpse I would create a new unit and kill it immediatly. The unit has the same model as the casting unit.

Alternatively you can use the caster and play his death animation and then spawn a corpse.
 
But a corpe cannot perform actions. The unit should be able to take orders. If any order is given the effect cancels.

EDIT: Hey I made it!

  • Untitled Trigger 001
    • Events
      • Unit - A unit Finishes casting an ability
    • Conditions
      • (Ability being cast) Equal to Feign Death (Hunter)
    • Actions
      • Animation - Play (Triggering unit)'s Decay Flesh animation
      • Animation - Change (Triggering unit)'s animation speed to 0.00% of its original speed
      • Unit - Make (Triggering unit) Invulnerable
Now I have to amek a trigger when the unit isg tgiven any orer to cancel this.
 
Last edited:

Jampion

Code Reviewer
Level 15
Joined
Mar 25, 2016
Messages
1,327
Here is a map using the burrow method. Press Esc to cause the enemy unit to burrow/unburrow.

Problem is the unit cannot take orders in that time (you need to unburrow), but please take a look at the map anyways. I think this will make clearer what I meant with the corpse.
I think the animation looks also very realisticly. You cannot see that the unit is not really dead (well you could see that the unit died without taking damage before, but that's kind of what feint death is all about).


In response to your edit here is my edit:

People will still see the shadow of the unit and the hp bar and if they hover with the mouse over the unit they will also see that there is an enemy unit.
I don't know how important it is to you that the unit really looks dead though.

You can cancel by detecting if the unit recieves an order.
You can also make the ability a channeled ability with infinite duration and the effect only lasts as long as channeled.

Problem is though in both your method and my burrow method, that the caster does not stop to auto acquire enemy units. So I would recommend using a channeled base ability, so the unit does not automatically do something else.
 

Attachments

  • Burrow.w3x
    17.2 KB · Views: 51
Last edited:

Jampion

Code Reviewer
Level 15
Joined
Mar 25, 2016
Messages
1,327
Yeah looks cool.

Is this what you wanted?
Because I thought you wanted a version that would not trick the unit, but the player.
I mean that it really looks for a human player that the unit is dead.
 
Level 11
Joined
May 16, 2016
Messages
730
So I was wonderign how to make Feign Death spell: the untis feigns death tricking enemy units to ignore it. Any action taken will cancel the effect.
I want the unit to play its death animation and stay dead corpse with invulnerability for the duration of the spell.
This template tricks both unit and player.
After feing death engaged appeared the selectable dummy unit, but it can't be choosed by any players.
Order the dummy right click, move, patrol, and the random owned by the current player "feing death-ed" unit in 300 AoE from the point order will "revived".
If no more feing death units left owned by the current player, then the dummy unit will removed.
To select dummy you can press F8 or UP arrow button.
 

Attachments

  • FEING DEATH.w3x
    20.1 KB · Views: 45

Jampion

Code Reviewer
Level 15
Joined
Mar 25, 2016
Messages
1,327
I have encountered a few bugs with the dummy disappearing and not being able to select the unit anymore.

I have finished my Burrowed method. Feign Death can be canceled by ordering the unit any order.

However with invisbility detection the unit can be seen, because you cannot make true sight only reveal invisible and not burrowed units (Data Detection type invisibility will still reveal burrowed units).

Test map: press esc to order the enemy knights to use Feign Death.
 

Attachments

  • Burrow.w3x
    19.8 KB · Views: 44
Status
Not open for further replies.
Top