[HELP] Saving/Restoring location
#4

pawn Код:
stock LoadStats(playerid)
{
    new pName[24],Query[80];
    GetPlayerName(playerid,pName,24);
    format(Query, sizeof(Query), "SELECT * FROM `Users` WHERE `Username` = '%s';", pName);
    mysql_query(Query);
    mysql_store_result();
    mysql_fetch_row_format(Query, "|");
    sscanf(Query, "e<p<|>s[24]s[23]i>", PInfo[playerid]);
    mysql_free_result();
    GivePlayerMoney(playerid,PInfo[playerid][Money]);
    SetSpawnInfo(playerid, 0, 297, UserStats[playerid][X], UserStats[playerid][Y], UserStats[playerid][Z], 10, 0,0,0,0,0,0);
    SpawnPlayer(playerid);
    return 1;
}
Try this.
Reply


Messages In This Thread
[HELP] Saving/Restoring location - by simon92922 - 09.06.2012, 15:04
Re: [HELP] Saving/Restoring location - by JhnzRep - 09.06.2012, 15:05
Re: [HELP] Saving/Restoring location - by simon92922 - 09.06.2012, 15:08
Re: [HELP] Saving/Restoring location - by JhnzRep - 09.06.2012, 15:12
Re: [HELP] Saving/Restoring location - by simon92922 - 09.06.2012, 15:28
Re: [HELP] Saving/Restoring location - by JhnzRep - 09.06.2012, 15:33
Re: [HELP] Saving/Restoring location - by simon92922 - 09.06.2012, 15:37
Re: [HELP] Saving/Restoring location - by simon92922 - 09.06.2012, 16:07
Re: [HELP] Saving/Restoring location - by simon92922 - 09.06.2012, 16:21
Re: [HELP] Saving/Restoring location - by simon92922 - 09.06.2012, 16:40

Forum Jump:


Users browsing this thread: 2 Guest(s)