Quote:
Originally Posted by TaLhA XIV
I knew everything about this ,but I didn't knew that it was an advanced tutorial,sorry,I thought that you were trying to give this tutorial to newbies, anyways nice tutorial keep it up.This will help more people except newbies
One more thing that I wanted a explanation on this part,and how you edit this in the following codes.
pawn Код:
new cNum;//the variable to store the card number in INI:ABankNum[NextBNumber](name[], value[]) { INI_Int("CurrentCardNum",cNum);//the storage return 0; }
|
That's the way to work with an INI file that doesn't have any parametres that are player-related.Basically,I only want to store a number into that file,increment it when a player buys a card,and read the number from the file.I use the cNum variable to store the number that is readen FROM the file(ABankNum.ini),then I save it into the player's bank data(BankInfo[playerid][CardNumber]).After that I increment the number,because if the current player has the card number 1005,the next player will have the card number 1006.To load a SIMPLE INI file,you just need the function