Warcraft III resources & community, 2003–2006 · archived

Grouping Items Together

3 posts
#1

Grouping Items Together

Hey, me again, does anybody know how to make items group together? like I buy 6 potions of healing, they all group together to get 6 potions of healing with 5 inventory slots remaining
Please help
#2

Re: Grouping Items Together

Rao Dao Zao said:
Item stacking is a nasty business.

The IncredibleItemStackingSystemOfDoom http://www.wc3sear.ch/viewtopic.php?t=15018provides an excellent solution.
The map includes a custom script:
set udg_Item_TempPotionCount = CountItemsOnUnit('I00M',GetManipulatingUnit()).
In order to get the trigger to work properly on my map I had to replace it with:
For each (Integer A) 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 (Hero manipulating item) in slot (Integer A))) Equal to Potion of Healing
Then - Actions
Set Item_TempPotionCount = (Item_TempPotionCount + 1)
Else - Actions
as specified in the tutorial.
Thanks RDZ! That thing rocks!
http://img131.imageshack.us/img131/3599/tmnp1.gif
#3
yes, ty, that will be VERY useful