How would i do this on here...
#1

Ok, I have just followed Compton Easy E's Tutorial on dudb/dini,
Done it all, Compiled Successfully, Works fine!
But how do i get it to save cash and admin level,
Because i registered, But when i logged in,
It reset my cash, But i want it to save my cash,
Rather than reset it, So how would i get it to save my cash,
And adminlevel, And whatever else i add, Or does anyone have a tutorial, A Good one
Reply
#2

Did you add something like, GivePlayerMoney(playerid,PlayerInfo[playerid][Money]);
Add this under onplayerlogin.
Reply
#3

I have this:

pawn Код:
SetPlayerMoney(playerid, dini_Int(file, "Cash"));
Thats called when player uses /login and logs in successfully,
The problem is, That i dont have anything that saves cash or adminlevel to the file,
How would i do that
Reply
#4

Well. To write it use,
dUserSetINT(PlayerName2(playerid)).("Cash",GetPlay erMoney(playerid));

stock PlayerName2(playerid) {
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof(name));
return name;
}
You have to make a saveplayer public.
And put this in it. And other things.
And put OnPlayerSave(playerid); under onplayerdisconnect.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)