20.09.2012, 19:16
ae gente meu gm ta sem o comando /f chat local aquem tem os codes para ativalo fico grato!
if(!strcmp(cmd, "/f", true))
{
new tmp[128];
strmid(tmp, cmdtext, 3, strlen(cmdtext), 128);
if(!strlen(tmp)) return SendClientMessage(playerid, COLOR_RED, "/f [texto]");
new Float:diegox,Float:diegoy,Float:diegoz;
format(tmp, sizeof(tmp), "|»»| Chat Prуximo |««| %s: %s", PlayerName(playerid), tmp);
GetPlayerPos(playerid, diegox, diegoy, diegoz);
for(new diego; diego < MAX_PLAYERS; diego++)
{
if(IsPlayerInRangeOfPoint(diego, 10.0, diegox, diegoy, diegoz))
{
SendClientMessage(diego, COLOR_RED, tmp);
}
}
return 1;
}
if(!strcmp(cmdtext, "/f", true))
{
strdel(cmdtext,0,3);
if(!strlen(cmdtext)) return SendClientMessage(playerid, -1, "/f [texto]");
static Float:x,Float:y,Float:z,i;
i = 0;
GetPlayerPos(playerid, x, y, z);
format(cmdtext, 128 , "|Chat local %s: %s",pegarnome(playerid),cmdtext);
for(; i < MAX_PLAYERS; ++i)
{
if(!IsPlayerInRangeOfPoint(i, 50.0, x, y, z)) continue;
SendClientMessage(i, -1, cmdtext);
}
return 1;
}
pegarnome(p)
{
static nome[24];
GetPlayerName(p,nome,sizeof nome);
return nome;
}
if(!strfind(cmdtext, "/f", true))
{
if(cmdtext[2] == 0 || cmdtext[2] == 32)
{
if(cmdtext[2] != 32 || (cmdtext[3] == 0 && cmdtext[2] == 32)) return SendClientMessage(playerid, 0xFFFFFFAA, "Digite: /f [texto]");
new Float:P_Pos[3];
new NickName[25];
GetPlayerPos(playerid, P_Pos[0], P_Pos[1], P_Pos[2]);
GetPlayerName(playerid, NickName, 25);
format(cmdtext, 129, "[Local] %s diz: %s", NickName, cmdtext[3]);
for(new x = 0, y = GetMaxPlayers(); x != y; x++)
{
if(!IsPlayerInRangeOfPoint(x, 10.0, P_Pos[0], P_Pos[1], P_Pos[2])) continue;
SendClientMessage(x, 0xFFFFFFAA, cmdtext);
}
return true;
}
}
C:\DOCUME~1\Vitor\Desktop\SERVID~1\GAMEMO~1\EXPRPG.pwn(29311) : warning 219: local variable "anim" shadows a variable at a preceding level C:\DOCUME~1\Vitor\Desktop\SERVID~1\GAMEMO~1\EXPRPG.pwn(29317) : warning 219: local variable "anim" shadows a variable at a preceding level C:\DOCUME~1\Vitor\Desktop\SERVID~1\GAMEMO~1\EXPRPG.pwn(30501) : error 010: invalid function or declaration C:\DOCUME~1\Vitor\Desktop\SERVID~1\GAMEMO~1\EXPRPG.pwn(30503) : error 010: invalid function or declaration C:\DOCUME~1\Vitor\Desktop\SERVID~1\GAMEMO~1\EXPRPG.pwn(30505) : error 010: invalid function or declaration C:\DOCUME~1\Vitor\Desktop\SERVID~1\GAMEMO~1\EXPRPG.pwn(30508) : error 021: symbol already defined: "GetPlayerPos" C:\DOCUME~1\Vitor\Desktop\SERVID~1\GAMEMO~1\EXPRPG.pwn(30511) : error 010: invalid function or declaration C:\DOCUME~1\Vitor\Desktop\SERVID~1\GAMEMO~1\EXPRPG.pwn(30513) : error 010: invalid function or declaration C:\DOCUME~1\Vitor\Desktop\SERVID~1\GAMEMO~1\EXPRPG.pwn(30516) : error 010: invalid function or declaration C:\DOCUME~1\Vitor\Desktop\SERVID~1\GAMEMO~1\EXPRPG.pwn(30519) : warning 203: symbol is never used: "NickName" C:\DOCUME~1\Vitor\Desktop\SERVID~1\GAMEMO~1\EXPRPG.pwn(30519) : warning 203: symbol is never used: "P_Pos" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 7 Errors.