mardi 17 février 2015

Mask Code Saving

I have made a mask system that when the player type /mask, it will give the player something like this

"Stranger 55555" the problem is when I take off the mask and put it back, the mask name will be changed to another number. Any idea to save the mask name? I did save the "MaskName" , but it's not saving the mask name.



OnPlayerLogin


Code:



if(strcmp(key , "MaskName" , true) == 0) { val = Ini_Value(Data); strmid(PlayerInfo[playerid][pMaskName], val, 0, strlen(val)-1, 255); }


OnPlayerRegister


Code:



format(var, 32, "MaskName=%d\n",PlayerInfo[playerid][pMaskName]);fwrite(hFile, var);


OnPlayerConnect


Code:



strmid(PlayerInfo[playerid][pMaskName], "None", 0, strlen("None"), 255);


StatsUpdate


Code:



format(var, 32, "MaskName=%d\n",PlayerInfo[playerid][pMaskName]);fwrite(hFile, var);






Aucun commentaire:

Enregistrer un commentaire