Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Mhh thanks for the fast response. Do you have a suggestion for a trigger, that could solve this? Was looking around, but sadly can't find any kind of trigger that influences cooldown.In the Object Editor? Not possible. Unless you trigger it or use some sort of metamorphosis to convert the unit whenever she cast that ability.
Events :
A unit is issued an order with no target
Conditions :
Issued order Equal to Order(defend)
Actions :
Set mana of Triggering unit to (Mana of Triggering unit - "Insert the value here")
As for the cooldown you may use a countdown timer, like when the unit cast the ability start a countdown timer as a one shot... and when the timer expire disable the ability.
How exactly do you want the cooldown to work?
1) Toggle Defend On -> Go on Cooldown and disable the ability entirely (can't toggle it off/on until the cooldown expires)
2) Toggle Defend On -> Go on Cooldown but allow you to still toggle Defend off (in this case the cooldown can be running in the background OR the cooldown can start once you toggle Defend off)
Luckily I need this spell only for one unit, so that's that.If you have multiple units with this ability then it won't be simple to create, unfortunately. Not that it would be hard to do, in fact I could probably whip it up in 30 minutes or so.
Have you learned how to use a Unit Indexer yet? I saw that you said that you were new to coding and that's why you're looking for simple solutions. A Unit Indexer and indexing in general is probably the best thing you can possibly learn how to use when starting out. It's really not all that complicated either. You can probably get by without fully understanding how it works, and simply understand how to use it.
I could whip up an example of the spell if you'd like.
Luckily I need this spell only for one unit, so that's that.
And yeah sure, if you would like to do that I would greatly appreciate it. Iam always interested in improving and learning something new! Thanks man.
Hey Uncle, I just came home and will have a look at your map. Thanks a lot!I'm not sure if edits show up in your notifications (I feel bad if they do, I edit a lot LOL) but I uploaded the latest working version of the spell. Defend Cooldown 3 SHOULD be 100% working.
If you have any questions, please let me know. Sorry if it ended up being a bit complicated, I tried to keep it as simple as possible but with like most things in Warcraft 3 there ended up being a ton of weird issues that I never expected.
