SA-MP Forums Archive
[Ajuda] Coomand . - 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] Coomand . (/showthread.php?tid=603981)



Coomand . - DaRoma - 30.03.2016

PHP код:
dcmd_trazertodos(playerid, params[])
{
#pragma unused params
if(Player[playerid][pAdmin] >= 5 || Player[playerid][pFrente] >= 1)
{
new 
Float:X,Float:Y,Float:Z;
GetPlayerPos(playerid,X,Y,Z);
for(new 
i = 0; i < MAX_PLAYERS; i ++)
{
    if(
IsPlayerConnected(i) && GetPlayerTeam(i) == GetPlayerTeam(playerid))
    {
        
SetPlayerPos(i, X+1, Y+1, Z);
        new 
String[2500];
          
format(String,128, "** INFO ** O Player %s puxou todos da Facзгo.", getPName(playerid));
        
SendClientMessage(playerid,COR_NEGATIVO, String);
    }
}
}
else
{
SCM(playerid, COR_ERRO, "** ERROR ** Vocк Nгo Tem Permissгo!");
}
return 
1;
} 
estou tentando da /trazertodos ai funfa. so que nao puxa todos da minha facзгo .


Re: Coomand . - F1N4L - 30.03.2016

Se funfa n sei, tenta...

PHP код:
dcmd_trazertodos(playerid, params[]) 
{ 
    
#pragma unused params 
    
if(Player[playerid][pAdmin] >= 5 || Player[playerid][pFrente] >= 1) 
    { 
        new 
Float:X,Float:Y,Float:Z; 
        
GetPlayerPos(playerid,X,Y,Z); 
        
        for(new 
i = 0; i < MAX_PLAYERS; i ++) 
        { 
            if(
GetPlayerTeam(i) != GetPlayerTeam(i)) continue;
            
            
SetPlayerPos(i, X+1, Y+1, Z); 
            new 
String[2500]; 
            
format(String,128, "** INFO ** O Player %s puxou todos da Facзгo.", getPName(playerid)); 
            
SendClientMessage(i,COR_NEGATIVO, String); 
            
        } 
    } 
    else 
    { 
        
SCM(playerid, COR_ERRO, "** ERROR ** Vocк Nгo Tem Permissгo!"); 
    } 
    return 
1; 
} 



Re: Coomand . - DaRoma - 30.03.2016

Fuunfoo obgd peela ajudaa tmj