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

Help with a skill

Status
Not open for further replies.
Level 15
Joined
Aug 20, 2014
Messages
263
I have a hero that gives some skills to units when he's in the unit's cargo only via triggers.
Now I have a unit that use "ethereal form" skill. The skill replace my unit with anotherone without the skills (it still has the hero in cargo) however, I need that the added skills being pass to the new ethereal unit and to the subsecuent replaced units when it turns corporeal again.
any ideas about how to deal with this?
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,511
You can use this to make the abilities permanent so that they don't get removed when morphing:
  • Custom script: call UnitMakeAbilityPermanent(unit, true, ability)
Example:
  • Set Variable MorphUnit = Transporting unit
  • Set Variable Ability1 = Acid Bomb
  • Unit - Add Ability1 to MorphUnit
  • Custom script: call UnitMakeAbilityPermanent(udg_MorphUnit, true, udg_Ability1)
 
Level 15
Joined
Aug 20, 2014
Messages
263
Ty buddy it works perfectly!
You can use this to make the abilities permanent so that they don't get removed when morphing:
  • Custom script: call UnitMakeAbilityPermanent(unit, true, ability)
Example:
  • Set Variable MorphUnit = Transporting unit
  • Set Variable Ability1 = Acid Bomb
  • Unit - Add Ability1 to MorphUnit
  • Custom script: call UnitMakeAbilityPermanent(udg_MorphUnit, true, udg_Ability1)
 
Status
Not open for further replies.
Top