27-06-2008, 02:07 PM
stackable items
|
27-06-2008, 02:23 PM
Just add more item type checks to the check for currency.
Atm all it does is check if you already have the item, and if you do set the value to +1, else it sets a new slot. I recently made all items stack in my bank. It's easy as hell. Quote:Robin:
27-06-2008, 02:30 PM
In mine, each item can be stackable and given a max stack amount. This allows for a lot of customization of the items.
The biggest headache i had was that if you have stacks of the items in your inventory already, you had to be able to add to those first before starting a new stack. Then if you don't have enough space in your inventory it drops any that won't fit. Then there was taking away the items in multiple stacks. Everyone was pretty easy, just took awhile to get it to where i liked it.
27-06-2008, 02:41 PM
Give Item:
for i = 1 to max_inv if getplayerinvitemnum(i).name = item(itemnum).name then setplayerinvitemval(i, getplayerinvitemval(i) + 1) end if next Take Item: For i = 1 to max_inv if getplayerinvitemnum(i).name = item(itemnum).name then If getplayerinvitemval(i) - ItemAmount >= 0 then setplayerinvitemnum(i, 0) else setplayerinvitemval(i, getplayerinvitemval(i) - ItemAmount) end if next Quote:Robin: |
« Next Oldest | Next Newest »
|
Users browsing this thread: 1 Guest(s)