Try to ask someone to optimize this
- SpecificConfig
- Events
- Map initialization
- Conditions
- Actions
- Set SpecItems[1] = Claws of Attack +15
- Set SpecItems[2] = Crown of Kings +5
- Set SpecItemsTotal = 2
Attached test-map just in case
- SpecificPrevent
- Events
- Unit - A unit Acquires an item
- Conditions
- Actions
- For each (Integer A) from 1 to SpecItemsTotal, do (Actions)
- Loop - Actions
- Set SpecTempInt = 0
- For each (Integer B) from 1 to 6, 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 B))) Equal to SpecItems[(Integer A)]
- Then - Actions
- Set SpecTempInt = (SpecTempInt + 1)
- Else - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- SpecTempInt Greater than 1
- Then - Actions
- Hero - Drop (Item being manipulated) from (Triggering unit)
- Game - Display to (Player group((Triggering player))) the text: Can't pick up item
- Else - Actions