• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

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