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

Ending a Unit Morph?

Status
Not open for further replies.
I'm not sure it is possible in GUI, but in JASS, I think you can use something like this, but I can't guarentee it will work:
Code:
    call CasterCastAbility(GetOwningPlayer(GetTriggerUnit()),<Abil Stop Code>,"cast",GetTriggerUnit(),true)
The native is:
Code:
native CasterCastAbility takes player owner, integer abilid, string order, widget target, boolean instant returns unit
I think that should work, you just need to have a "morph back" ability and have the unit cast that. If you don't want it to appear, put it in a spellbook and disable it like that. :grin:

EDIT: JASS tags were messed up, so I had to use code tags.

EDIT Again: This is part of the CS (caster system) so I don't know if there is another way to do the ability.
 
Last edited:
Status
Not open for further replies.
Top