Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
You are using an out of date browser. It may not display this or other websites correctly. You should upgrade or use an alternative browser.
Triggers
Makwo-Charges-System.w3x
Variables
Initialization
Info
Random Initialization
Binding Items
Enter map-specific custom script code below. This text will be included in the map script after variables are declared and before any trigger code.
Name
Type
is_array
initial_value
The only problem I have found, is that you can't add charged items when your inventory is full. You souldn't have to add anything to the trigger, I don't know, I'm not a doctor. Feel free to yoink and make better. I'm just wondering if anyone will ever read this.
Random Initialization
Events
Map initialization
Conditions
Actions
Visibility - Disable fog of war
Visibility - Disable black mask
Game - Set the time of day to 12
Game - Turn the day/night cycle Off
Binding Items
Events
Unit - A unit Acquires an item
Conditions
Actions
For each (Integer A) from 1 to (Size of inventory for (Triggering unit)) , do (Actions)
Loop - Actions
For each (Integer B) from 1 to (Size of inventory for (Triggering unit)) , do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Item-type of (Item carried by (Triggering unit) in slot (Integer A))) Equal to (Item-type of (Item carried by (Triggering unit) in slot (Integer B)))
(Charges remaining in (Item carried by (Triggering unit) in slot (Integer A))) Greater than 0
(Integer A) Not equal to (Integer B)
Then - Actions
Item - Set charges remaining in (Item carried by (Triggering unit) in slot (Integer A)) to ((Charges remaining in (Item carried by (Triggering unit) in slot (Integer A))) + (Charges remaining in (Item carried by (Triggering unit) in slot (Integer B))))
Item - Remove (Item carried by (Triggering unit) in slot (Integer B))
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.