Advertisement
Chip7

[FS] Texto Cores Chat [Simples]

Apr 30th, 2012
409
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 4.44 KB | None | 0 0
  1. /*
  2. ______________|FilterScript|______________
  3. - Criador: @Riichard
  4. - Designer: @Riichard
  5. - Cores Retiradas de : www.mxstudio.com.br/Conteudos/Dreamweaver/Cores.htm
  6. - 7 Tipos de Cores Basicas.(Amarelo,Vermelho,Azul,Verde,Cinza,Rosa,Branco)
  7. - Não retire os créditos.
  8. - Equipe [SDS] Style Drift Show [SDS]
  9. - Site/Blog : equipe-sds.blogspot.com
  10. - Servidor : 69.162.102.12:7773
  11. - VISITE NOSSO SITE: http://www.sampknd.com/
  12. - SAMP KND MELHOR BLOG DE SAMP DO BRASIL
  13. ______________|FilterScript|______________
  14. */
  15.  
  16. #include <a_samp>
  17.  
  18. // Variaveis & Defines :
  19. #define Textos 200 // Cuidado com os conflitos.
  20. new Texto1[MAX_PLAYERS];
  21. new Nick[MAX_PLAYER_NAME];
  22. new String[128];
  23.  
  24. // == Outros == //
  25. public OnFilterScriptInit()
  26. {
  27.     print("\n*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*");
  28.     print("        [FilterScript] Texto Cores Chat");
  29.     print("*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*\n");
  30.     return 1;
  31. }
  32. // Comando
  33. public OnPlayerCommandText(playerid, cmdtext[])
  34. {
  35.     if(strcmp(cmdtext,"/Textos", true) == 0)
  36.     {
  37.     ShowPlayerDialog(playerid,Textos,DIALOG_STYLE_LIST,"Escolha Sua Cor Preferida","Texto 1 > {FFFF00}Amarelo\nTexto 2 > {FF0000}Vermelho\nTexto 3 > {00BFFF}Azul\nTexto 4 > {00FF00}Verde\nTexto 5 > {696969}Cinza\nTexto 6 > {FF00FF}Rosa\nTexto 7 > Branco","Selecionar","Cancelar");
  38.     GetPlayerName(playerid, Nick, MAX_PLAYER_NAME);
  39.     format(String, sizeof(String), "%s » Está vendo modificações em seu texto. {FFFFFF}/Textos", Nick);
  40.     SendClientMessageToAll(0x6C7B8BFF, String);
  41.     return 1;
  42.     }
  43.     return 0;
  44.     }
  45. // Chat Com as Cores Prontas.
  46. public OnPlayerText(playerid, text[])
  47. {
  48. if(strlen(text)> 48)
  49. {
  50. SendClientMessage(playerid,-1,"Texto Muito Grande » Maximo Permitido : 48 !");
  51. return 0;
  52. }
  53. // Amarelo
  54. if(Texto1[playerid] == 1)
  55. {
  56. format(String, sizeof(String), "{FFFF00}%s",text[0]);
  57. SendPlayerMessageToAll(playerid, String);
  58. return 0;
  59. }
  60. // Vermelho
  61. if(Texto1[playerid] == 2)
  62. {
  63. format(String, sizeof(String), "{FF0000}%s",text[0]);
  64. SendPlayerMessageToAll(playerid, String);
  65. return 0;
  66. }
  67. // Azul
  68. if(Texto1[playerid] == 3)
  69. {
  70. format(String, sizeof(String), "{00BFFF}%s",text[0]);
  71. SendPlayerMessageToAll(playerid, String);
  72. return 0;
  73. }
  74. // Verde
  75. if(Texto1[playerid] == 4)
  76. {
  77. format(String, sizeof(String), "{00FF00}%s",text[0]);
  78. SendPlayerMessageToAll(playerid, String);
  79. return 0;
  80. }
  81. // Cinza
  82. if(Texto1[playerid] == 5)
  83. {
  84. format(String, sizeof(String), "{696969}%s",text[0]);
  85. SendPlayerMessageToAll(playerid, String);
  86. return 0;
  87. }
  88. // Rosa
  89. if(Texto1[playerid] == 6)
  90. {
  91. format(String, sizeof(String), "{FF00FF}%s",text[0]);
  92. SendPlayerMessageToAll(playerid, String);
  93. return 0;
  94. }
  95. // Branco
  96. if(Texto1[playerid] == 7)
  97. {
  98. format(String, sizeof(String), "{FFFFFF}%s",text[0]);
  99. SendPlayerMessageToAll(playerid, String);
  100. return 0;
  101. }
  102. return 0;
  103. }
  104. // Response Dialog
  105. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  106. {
  107.             if(dialogid == Textos)
  108.             {
  109.             if(response)
  110.             {
  111.             if(listitem == 0)// Amarelo
  112.             {
  113.             Texto1[playerid] = 1;
  114.             SendClientMessage(playerid,-1,"» Você Mudou Sua Cor de Texto para > {FFFF00}Amarelo");
  115.             }
  116.             if(listitem == 1)// Vermelho
  117.             {
  118.             Texto1[playerid] = 2;
  119.             SendClientMessage(playerid,-1,"» Você Mudou Sua Cor de Texto para > {FF0000}Vermelho");
  120.             }
  121.             if(listitem == 2)// Azul
  122.             {
  123.             Texto1[playerid] = 3;
  124.             SendClientMessage(playerid,-1,"» Você Mudou Sua Cor de Texto para > {00BFFF}Azul");
  125.             }
  126.             if(listitem == 3)// Verde
  127.             {
  128.             Texto1[playerid] = 4;
  129.             SendClientMessage(playerid,-1,"» Você Mudou Sua Cor de Texto para > {00FF00}Verde");
  130.             }
  131.             if(listitem == 4)// Cinza
  132.             {
  133.             Texto1[playerid] = 5;
  134.             SendClientMessage(playerid,-1,"» Você Mudou Sua Cor de Texto para > {696969}Cinza");
  135.             }
  136.             if(listitem == 5)// Rosa
  137.             {
  138.             Texto1[playerid] = 6;
  139.             SendClientMessage(playerid,-1,"» Você Mudou Sua Cor de Texto para > {FF00FF}Rosa");
  140.             }
  141.             if(listitem == 6)// Branco
  142.             {
  143.             Texto1[playerid] = 7;
  144.             SendClientMessage(playerid,-1,"» Você Mudou Sua Cor de Texto para > {FFFFFF}Branco");
  145.             }
  146.             }
  147.             }
  148.             return 0;
  149.             }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement