H
HoboJoe_5
Guest
These triggers are supposed to work with each other to prevent a hero from owning more then one of a specific item. There is something wrong with one of them but i can't tell which one or what it is.
ItemsOwned
I have many triggers like this second trigger but i only need to put one it because they are all basically the same only for diferent items.
ItemsOwned
Code:
Events
Unit - A unit Acquires an item
Conditions
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Item-type of (Item being manipulated)) Equal to Camouflage Clothing
Then - Actions
Set ITEMsCamo[(Player number of (Owner of (Triggering unit)))] = (ITEMsCamo[(Player number of (Owner of (Triggering unit)))] + 1)
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Item-type of (Item being manipulated)) Equal to Protective Gear
Then - Actions
Set ITEMsPGear[(Player number of (Owner of (Triggering unit)))] = (ITEMsPGear[(Player number of (Owner of (Triggering unit)))] + 1)
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Item-type of (Item being manipulated)) Equal to Gripping Gloves
Then - Actions
Set ITEMsGrip[(Player number of (Owner of (Triggering unit)))] = (ITEMsGrip[(Player number of (Owner of (Triggering unit)))] + 1)
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Item-type of (Item being manipulated)) Equal to Helmet
Then - Actions
Set ITEMsHelm[(Player number of (Owner of (Triggering unit)))] = (ITEMsHelm[(Player number of (Owner of (Triggering unit)))] + 1)
Else - Actions
Do nothing
Code:
LimitPgear
Events
Unit - A unit Acquires an item
Conditions
ITEMsPGear[(Player number of (Owner of (Triggering unit)))] Greater than 1
(Item being manipulated) Equal to (Item carried by (Triggering unit) of type Protective Gear)
Actions
Item - Remove (Item being manipulated)


