Inventory system - generic items
#2

Assuming you DO HAVE a PlayerInfo system,then add to your enum...
pawn Code:
enum
{
  iNumber//ITEM number
};
Then the command only looks like: /giveitem <playerid> <itemID>,but when the player receives the item,at the end of command:
pawn Code:
PlayerInfo[playerid][iNumber]++;//he now has one more item
Then you do:
pawn Code:
INI_WriteString(file, "GenericItem", PlayerInfo[playerid][iNumber]);
And now you don't have to mess up with memorizing numbers,etc.
Reply


Messages In This Thread
Inventory system - generic items - by Devix - 23.07.2012, 13:22
Re: Inventory system - generic items - by Cjgogo - 23.07.2012, 13:39
Re: Inventory system - generic items - by Vince - 23.07.2012, 13:41
Re: Inventory system - generic items - by Devix - 23.07.2012, 14:38

Forum Jump:


Users browsing this thread: 1 Guest(s)