power
New Member
- Reaction score
- 3
Hey,
I am working on an RPG and I don't want a unit to be able to hold to shields or to of the same class of item. Aka you can only have 1 charged item (Sword). I have a trigger that i was told works but it doesnt seem to. Can anyone either tell me why it isn't working or give me a trigger that does work.
The items are miscellaneous so I don't see what the problem would be.
Anyway, if anyone could help me, I would appreciate that and +rep.
I am working on an RPG and I don't want a unit to be able to hold to shields or to of the same class of item. Aka you can only have 1 charged item (Sword). I have a trigger that i was told works but it doesnt seem to. Can anyone either tell me why it isn't working or give me a trigger that does work.
Code:
Miscellaneous item
Events
Unit - A unit Acquires an item
Conditions
(Item-class of (Item being manipulated)) Equal to Miscellaneous
Actions
Unit - Order (Hero manipulating item) to move (Item being manipulated) to inventory slot 1
Wait 0.01 seconds
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
Or - Any (Conditions) are true
Conditions
(Item-class of (Item carried by (Hero manipulating item) in slot 2)) Equal to Miscellaneous
(Item-class of (Item carried by (Hero manipulating item) in slot 5)) Equal to Miscellaneous
(Item-class of (Item carried by (Hero manipulating item) in slot 3)) Equal to Miscellaneous
(Item-class of (Item carried by (Hero manipulating item) in slot 4)) Equal to Miscellaneous
(Item-class of (Item carried by (Hero manipulating item) in slot 6)) Equal to Miscellaneous
Then - Actions
Hero - Drop (Item being manipulated) from (Hero manipulating item)
Game - Display to (Player group((Owner of (Hero manipulating item)))) the text: You can only wield ...
Else - Actions
Do nothing
The items are miscellaneous so I don't see what the problem would be.
Anyway, if anyone could help me, I would appreciate that and +rep.