Is there something wrong in this line? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Is there something wrong in this line? (
/showthread.php?tid=619072)
Is there something wrong in this line? -
NealPeteros - 13.10.2016
Is there something wrong in this line?
Код HTML:
PlayerInfo[playerid][pLearn];
Says that the expression has no effect.
Re: Is there something wrong in this line? -
Runn3R - 13.10.2016
What are you trying to do? Give us the full code.
Re: Is there something wrong in this line? -
NealPeteros - 13.10.2016
Sorry for that.
PHP код:
case DIALOG_LOGIN:
{
if ( !response ) return Kick ( playerid );
if( response )
{
if(udb_hash(inputtext) == PlayerInfo[playerid][pPass])
{
INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
new tmp2[ 256 ], playername2[ MAX_PLAYER_NAME ];
GetPlayerName(playerid, playername2, sizeof(playername2));
format(tmp2, sizeof(tmp2), "~w~Welcome ~n~~g~%s", playername2);
GameTextForPlayer(playerid, tmp2, 5000, 1);
GivePlayerCash(playerid, PlayerInfo[playerid][pCash]);
PlayerInfo[playerid][pLearn];
SetSpawnInfo(playerid, PlayerInfo[playerid][pSpecial], PlayerInfo[playerid][pSkin], PlayerInfo[playerid][pPos_x], PlayerInfo[playerid][pPos_y], PlayerInfo[playerid][pPos_z], 1.0, -1, -1, -1, -1, -1, -1);
SpawnPlayer(playerid);
}
else
{
ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,"Login","You have entered an incorrect password.\nType your password below to login.","Login","Quit");
}
return 1;
}
}
}
return 1;
}
Re: Is there something wrong in this line? -
Runn3R - 13.10.2016
What are you trying to do with the PlayerInfo[playerid][pLearn];?
PlayerInfo[playerid][pLearn] = 1;?
Re: Is there something wrong in this line? -
NealPeteros - 13.10.2016
Sorry again. I'm trying to load it.
Re: Is there something wrong in this line? -
SyS - 13.10.2016
use the var to load data in LoadUser call back
Re: Is there something wrong in this line? -
Runn3R - 13.10.2016
Oh. Then you're doing it wrong, you need to place it on the "LoadUser_" callback.
Код:
INI_Int("pLearn", PlayerInfo[playerid][pLearn]);