i and str - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: i and str (
/showthread.php?tid=218002)
i and str -
MEC - 29.01.2011
i'm getting the last couple errors out of my mysql login system. but there's some odd errors i dont know how to fix.
i'm thinking they might be some sort of include i dont have but i'm not familiar with them so. maybe you guys know.
Код:
if(GetPVarInt(playerid, "WrongPass") == 3)
{
SendClientMessage(playerid, 0xF60000AA, "Max password tries exceeded!!");
GetPlayerName(i, str, 24); <-----This Line
and this line=> format(str, 100, "**(AUTO KICK)** %s(%d) Failed to login - Registered Playername", str,i);
Kick(playerid);
}
Код:
Mec-New.pwn(193) : error 017: undefined symbol "i"
Mec-New.pwn(194) : error 017: undefined symbol "str"
Re: i and str -
Steven Paul - 29.01.2011
here you go
pawn Код:
if(GetPVarInt(playerid, "WrongPass") == 3)
{
for(new i=0; i<=MAX_PLAYERS; i++)
{
new str[128];
SendClientMessage(playerid, 0xF60000AA, "Max password tries exceeded!!");
GetPlayerName(i, str, 24);
format(str, 100, "**(AUTO KICK)** %s(%d) Failed to login - Registered Playername", str,i);
Kick(playerid);
}
}
Re: i and str -
MEC - 29.01.2011
thank you