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

Ability need resoruces?

Status
Not open for further replies.
Level 3
Joined
May 31, 2005
Messages
26
In my map a building has an ability which i want too use lumber too beable too cast it, at the minute ive got the triggers working for the ability (too fire missles at distaces if your wondering) but i want it too use 50 wood, how can i do this? also too make sure it checks too see if you have enough and if you dont an error comes saying you dont have enough resoruces..
 
Level 12
Joined
Apr 29, 2005
Messages
999
Building Ability
Events
Unit - A unit Begins casting an ability
Conditions
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(("some player") Current lumber) Equal to X
Then - Actions
Actions... Remember to reduce lumber for that player.
Else - Actions
Unit - Order (Casting unit) to Stop
Game - Display to (All players) for Y seconds the text: text

I think this would work.
 
Status
Not open for further replies.
Top