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

[JASS] Ability Hotkeys

Status
Not open for further replies.
Level 9
Joined
May 25, 2008
Messages
148
Hey guys

In my game units pick up spells that they can cast once, when the spell it cast the ability is removed.

So since you can have any different combination of abilities i want to make a trigger that will set the hotkey of a spell based on the number of spells the unit already has.

So if the unit doesnt have a spell, it will make the new spell's hotkey Q if the unit has 2 spells it will make the new spell's hotkey E

In short : I need some script to change the hotkey of an ability only for a specific unit.

(+rep and have your name mentioned under 'special credits' in my map if you can give the solution)
 
Status
Not open for further replies.
Top