27.07.2014, 11:50
I made my own /acheck command which shows the admin the players IP, ping, sampversion, location, vw, int etc etc..
But upon compiling I have four errors, here is my command:
Here is the errors:
Lines 588 - 589:
Thanks in advance.
But upon compiling I have four errors, here is my command:
Код:
CMD:acheck(playerid,params[])
{
if(PlayerInfo[playerid][pAdmin] < 3) return SendClientMessage(playerid,-1,"{AA3333}ERROR:{FFFFFF} Only administrators may use this command.");
{
new player, playerip, playerping, playerversion, playerint, playervw, Float:playerX, Float:playerY, Float:playerZ, string[128], string2[128];
if (sscanf(params,"u",player)) return SendClientMessage(playerid,-1,"{AA3333}USAGE:{FFFFFF} /acheck (id)");
if (player == INVALID_PLAYER_ID) return SendClientMessage(playerid,-1,"{AA3333}ERROR:{FFFFFF} Player does not exist or is offline.");
GetPlayerIp(player,playerip,sizeof(playerip));
GetPlayerVersion(player,playerversion,sizeof(playerversion);
GetPlayerPos(player,playerX,playerY,playerZ);
playerping = GetPlayerPing(player);
playerint = GetPlayerInterior(player);
playervw = GetPlayerVirtualWorld(player);
format (string,128,"{32CD32}Player:{FFFFFF} %s {32CD32}IP:{FFFFFF} %i {32CD32}Ping:{FFFFFF} %i {32CD32}SAMP Version:{FFFFFF} %i",RemoveUnderScore(player),playerip,playerping,playerversion);
SendClientMessage(playerid,-1,string);
format (string2,128,"{32CD32}Interior:{FFFFFF} %i {32CD32}Virtual World:{FFFFFF} %i {32CD32}X:{FFFFFF} %i {32CD32}Y:{FFFFFF} %i {32CD32}Z:{FFFFFF} %i",playerint,playervw,playerX,playerY,playerZ);
SendClientMessage(playerid,-1,string2);
}
return 1;
}
Код:
C:\Users\Jack\Desktop\Vinewood Roleplay\gamemodes\vrp.pwn(588) : error 035: argument type mismatch (argument 2) C:\Users\Jack\Desktop\Vinewood Roleplay\gamemodes\vrp.pwn(588) : error 035: argument type mismatch (argument 2) C:\Users\Jack\Desktop\Vinewood Roleplay\gamemodes\vrp.pwn(589) : error 035: argument type mismatch (argument 2) C:\Users\Jack\Desktop\Vinewood Roleplay\gamemodes\vrp.pwn(589) : error 035: argument type mismatch (argument 2) Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors.
Код:
GetPlayerIp(player,playerip,sizeof(playerip)); GetPlayerVersion(player,playerversion,sizeof(playerversion));

