Need help. 1 error 2 lines. (argument 2) - 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: Need help. 1 error 2 lines. (argument 2) (
/showthread.php?tid=309851)
Need help. 1 error 2 lines. (argument 2) -
Request - 09.01.2012
Код:
public SendAdminMessage(color, string[])
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))//this line
{//this line
if(PlayerInfo[i][pAdmin] >= 1)
{
SendClientMessage(i, color, string);
}
}
}
}
error 035: argument type mismatch (argument 2)
Thx for helping me
Re: Need help. 1 error 2 lines. (argument 2) -
Konstantinos - 09.01.2012
I am sure, you mean stock, right?
pawn Код:
stock SendAdminMessage(color, string[])
{
for(new i = 0; i < MAX_PLAYERS; i++) {
if(IsPlayerConnected(i) && PlayerInfo[i][pAdmin] > 0) {
SendClientMessage(i, color, string);
}
}
return 1;
}
Re: Need help. 1 error 2 lines. (argument 2) -
Request - 09.01.2012
The same error in this 2 lines now....
Quote:
else if(strcmp(line, "Owner=", false, 6) == 0) strcpy(VehicleOwner[i], sizeof(VehicleOwner[]), line[6]);
else if(strcmp(line, "NumberPlate=", false, 12) == 0) strcpy(VehicleNumberPlate[i], sizeof(VehicleNumberPlate[]), line[12]);
|
Re: Need help. 1 error 2 lines. (argument 2) -
Request - 09.01.2012
Please help me out with this...
Re: Need help. 1 error 2 lines. (argument 2) -
Request - 09.01.2012
PLS Someone help me out
Re: Need help. 1 error 2 lines. (argument 2) -
[BG]Gamer - 09.01.2012
Put this some where in the script :
pawn Код:
forward SendClientMessageToAdmins(color, string[], alevel);
pawn Код:
public SendClientMessageToAdmins(color, string[], alevel)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if (PlayertInfo[i][pAdmin] >= alevel || IsPlayerAdmin(i))
{
SendClientMessage(i, color, string);
}
}
printf("%s", string);
return 1;
}
color - message color
string[] - the string wich will show
alevel - the level from wich level will show to admins
Re: Need help. 1 error 2 lines. (argument 2) -
Request - 09.01.2012
Didnt work that out...