Guest User

Untitled

a guest
Oct 17th, 2017
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.86 KB | None | 0 0
  1. public OnPlayerText(playerid, text[])
  2. {
  3. new text2[256];
  4. new pnametext[MAX_PLAYER_NAME];
  5. GetPlayerName(playerid,pnametext,MAX_PLAYER_NAME);
  6. if(text[0] == ';')
  7. {
  8. for(new i, p = GetMaxPlayers(); i < p; i++)
  9. {
  10. if(!IsPlayerConnected(i)) continue;
  11. new Float:T,Float:V,Float:A;
  12. GetPlayerPos(playerid,T,V,A);
  13. if(!IsPlayerInRangeOfPoint(i, 20.0, T, V, A)) continue;
  14.  
  15. strdel(text, 0, 1);
  16. format(text2, 256,"%s [ID:%d]: %s", pnametext, playerid, text);
  17. SendClientMessage(i, aclaro, text2);
  18. SetPlayerChatBubble(playerid,text, COLOR_WHITE, 20, 10000);
  19. PlayerPlaySound(playerid, 1057, T+20, V+20, A+20);
  20. }
  21. return false;
  22. }
  23. //UpperToLower(text);
  24. new string[256];
  25. format(string,sizeof(string),"[ID:%d]: %s",playerid,text);
  26. SendPlayerMessageToAll(playerid,string);
  27. SetPlayerChatBubble(playerid,text, COLOR_WHITE, 100.0, 10000);
  28. return 0;
  29. }
Add Comment
Please, Sign In to add comment