SA-MP Forums Archive
[Ajuda] commando Verip Bugado ;-; - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] commando Verip Bugado ;-; (/showthread.php?tid=562459)



commando Verip Bugado ;-; - VinnyScript - 09.02.2015

Код:
CMD:verip(playerid){
	new string[148];
	new cmdtext[256];
	new tmp[256];
	new	idx;
	if(PlayerInfo[playerid][Admin] >=1) return SendClientMessage(playerid, cinza, "{00FF00}[CBD] {FFFFFF}Somente Administrador Level 1 ou superior.");
	tmp = strtok(cmdtext, idx);
	new otherplayer = strval(tmp);
	if(!strlen(tmp)) return SendClientMessage(playerid, -1, "{00FF00}[CBD]{FFFFFF} /verip [playerid]");
	new IP[128];
	GetPlayerIp(otherplayer, IP, sizeof(IP));
	GetPlayerName(otherplayer, PlayerName, sizeof(PlayerName));
	format(string, sizeof(string), "{00FF00}[CBD]{FF0000}%s's {FFFFFF}IP: {FF0000}%s", PlayerName, IP);
	SendClientMessage(playerid, WHITE, string);
	return 1;
}
Sem funзao

eu achei esse cod aqui no forum em codigos uteis .;-


Re: commando Verip Bugado ;-; - zPain - 09.02.2015

PHP код:
CMD:verip(playeridparams[]) {
    new 
targetid;
    if(
sscanf(params"u"targetid)) {
        return 
1;
    }

    if(!
IsPlayerConnected(targetid)) {
        return 
1;
    }

    static 
string[64];
    
GetPlayerIp(playeridstringsizeof string);

    
format(stringsizeof string"ID: %d - IP: %s"targetidstring);
    
SendClientMessage(playerid, -1string);
    return 
1;