Como desativa chat global -
victor_h666 - 31.12.2010
Alguйm sabe? aquele que fica a cor do manolo e vai pra todomundo yeah.
This forum requires that you wait 60 seconds between posts. Please try again in 18 seconds.
This forum requires that you wait 60 seconds between posts. Please try again in 3 seconds.
Re: Como desativa chat global -
Macintosh - 31.12.2010
pawn Код:
SetPlayerColor(playerid,COR);
Pхe isso no OnPlayerConnect...
Se desejar que as cores sejam randфmicas basta adicionar estб public
Topo GM
pawn Код:
#define COR1 0xFF0000AA
#define COR2 0x000080AA
#define COR3 0x8080FFAA
#define COR4 0x80FF00AA
forward RandomColor();
new cores[] = {
COR1,
COR2,
COR3,
COR4
};
Final GM
pawn Код:
public RandomColor()
{
SetPlayerColor(playerid, cores);
return 1;
}
Re: Como desativa chat global -
Black Sσldiєя - 31.12.2010
Isso vocк muda na
public OnPlayerText(playerid, text[]).
Vocк quer que a mensagem seja enviada sу pra quem tб perto?
Re: Como desativa chat global -
Macintosh - 31.12.2010
eu acho que sу precisa por 8.0 ou algo do tipo...
Assim
pawn Код:
#define COR1 0xFF0000AA
#define COR2 0x000080AA
#define COR3 0x8080FFAA
#define COR4 0x80FF00AA
#define COR5 0x0F00A0AA
new PlayerLogado[MAX_PLAYERS];
new chatreal = 1;
Pхe isso no OnPlayerText ^^
pawn Код:
if(chatreal)
{
if(PlayerLogadoplayerid] == 0)
{
return 0;
}
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "%s Diz: %s", sendername, text);
ProxDetector(20.0, playerid, string,COR1,COR2,COR3,COR4,COR4;// o 20.0 й a distвncia em que o outro player irб ver o texto digitado. Pode mudб-lo para 10.0 ,12.0 etc...
if(strlen(text) < 145)
{
new chatstring[MAX_CHATBUBBLE_LENGTH+1];
format(chatstring,MAX_CHATBUBBLE_LENGTH,"%s",text);
SetPlayerChatBubble(playerid,chatstring,COR5,100.0,10000);
}
return 0;
}
return 1;
}
OBS.: Desculpa a demora tinha saнdo *-*
Re: Como desativa chat global -
Black Sσldiєя - 31.12.2010
Final do GM:
pawn Код:
public ProxDetector(Float:radi, playerid, string[],col1,col2,col3,col4,col5)
{
if(IsPlayerConnected(playerid))
{
new Float:posx, Float:posy, Float:posz;
new Float:oldposx, Float:oldposy, Float:oldposz;
new Float:tempposx, Float:tempposy, Float:tempposz;
GetPlayerPos(playerid, oldposx, oldposy, oldposz);
//radi = 2.0; //Trigger Radius
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(!BigEar[i])
{
GetPlayerPos(i, posx, posy, posz);
tempposx = (oldposx -posx);
tempposy = (oldposy -posy);
tempposz = (oldposz -posz);
//printf("DEBUG: X:%f Y:%f Z:%f",posx,posy,posz);
if (((tempposx < radi/16) && (tempposx > -radi/16)) && ((tempposy < radi/16) && (tempposy > -radi/16)) && ((tempposz < radi/16) && (tempposz > -radi/16)))
{
SendClientMessage(i, col1, string);
}
else if (((tempposx < radi/8) && (tempposx > -radi/8)) && ((tempposy < radi/8) && (tempposy > -radi/8)) && ((tempposz < radi/8) && (tempposz > -radi/8)))
{
SendClientMessage(i, col2, string);
}
else if (((tempposx < radi/4) && (tempposx > -radi/4)) && ((tempposy < radi/4) && (tempposy > -radi/4)) && ((tempposz < radi/4) && (tempposz > -radi/4)))
{
SendClientMessage(i, col3, string);
}
else if (((tempposx < radi/2) && (tempposx > -radi/2)) && ((tempposy < radi/2) && (tempposy > -radi/2)) && ((tempposz < radi/2) && (tempposz > -radi/2)))
{
SendClientMessage(i, col4, string);
}
else if (((tempposx < radi) && (tempposx > -radi)) && ((tempposy < radi) && (tempposy > -radi)) && ((tempposz < radi) && (tempposz > -radi)))
{
SendClientMessage(i, col5, string);
}
}
else
{
SendClientMessage(i, col1, string);
}
}
}
}//not connected
return 1;
}
Re: Como desativa chat global -
Macintosh - 31.12.2010
TOPO GM
pawn Код:
forward ProxDetector(Float:radi, playerid, string[],col1,col2,col3,col4,col5);
Re: Como desativa chat global -
victor_h666 - 31.12.2010
Blablabla Isso eu jб fiz por mim mesmo ы.ы.
Pra desativar o chat global й sу retornar 0 no onplayertext.
Re: Como desativa chat global -
Black Sσldiєя - 31.12.2010
Se fez isso porque vem pedir ajuda? Й foda, agente ajuda e ainda reclama.
Bla bla bla, veja um noob acima que acha que й experiente.
Re: Como desativa chat global -
Shelby - 31.12.2010
https://sampwiki.blast.hk/wiki/LimitGlobalChatRadius
Re: Como desativa chat global -
Macintosh - 31.12.2010
Aff dps que o cara esculhamba um efкdepк desse vem reclamar dizendo que й novo no fуrum.
Ficam que nem putas (Obs.: Nгo sгo todos os novatos.)
Por isso conheзo muita gente que nгo loga aqui por que jб virou zona de noob.