Mod elejére #define 5000 dialog neve..
public OnPlayerText(playerid, text[]){ new TickCount = GetTickCount( ); SetPlayerChatBubble(playerid, text, 0x99FF00AA, 100.0, 10000);if( gPlayerSpamTick[ playerid ] > ( TickCount - ( SPAM_TIME * 800 ) ) ){ SendClientMessage( playerid, 0xEB000FFF, \"Ne spamolj várj {FB0000}2 {FF0000}másodpercet!\" );gPlayerSpamTick[ playerid ] = GetTickCount( );return 0;} new iNums; for( new x = 0; x < strlen( text ); ++x ) { if( text[ x ] < \'0\' || text[ x ] > \'9\' ) continue; ++iNums; } if( iNums > 9 ) { SendClientMessage( playerid, COLOR_RED, \"Ne hirdess te fogyatékos buzi gyerek!\" ); return 0; } gPlayerSpamTick[ playerid ] = GetTickCount( );#pragma unused text new e[200]; format( e, 200, \"{FFFFFF}(%i)%s\", playerid, text ); SendPlayerMessageToAll(playerid, e); return 0; }
SendClientMessage( playerid, COLOR_RED, \"Ne hirdess te fogyatékos buzi gyerek!\" ); itt még nincs benne
SendClientMessage( playerid, COLOR_RED, \"Ne hirdess te fogyatékos buzi gyerek!\" );
new e[200]; format( e, 200, \"{FFFFFF}(%i)%s\", playerid, text ); SendPlayerMessageToAll(playerid, e);
new e[200];if(GetPVarInt(playerid, \"Kek\") == 1){ format( e, 200, \"{FFFFFF}(%i){375FFF}%s\", playerid, text );}if(GetPVarInt(playerid, \"Piros\") == 1){ format( e, 200, \"{FFFFFF}(%i){E60000}%s\", playerid, text );} SendPlayerMessageToAll(playerid, e);
nah itt az onplayetext ez nem jo te helyezd be plz! public OnPlayerText(playerid, text[]){ new TickCount = GetTickCount( ); SetPlayerChatBubble(playerid, text, 0x99FF00AA, 100.0, 10000);if( gPlayerSpamTick[ playerid ] > ( TickCount - ( SPAM_TIME * 800 ) ) ){ SendClientMessage( playerid, 0xEB000FFF, \"Ne spamolj várj {FB0000}2 {FF0000}másodpercet!\" );gPlayerSpamTick[ playerid ] = GetTickCount( );return 0;} new iNums; for( new x = 0; x < strlen( text ); ++x ) { if( text[ x ] < \'0\' || text[ x ] > \'9\' ) continue; ++iNums; } if( iNums > 9 ) { SendClientMessage( playerid, COLOR_RED, \"Ne hirdess te fogyatékos buzi gyerek!\" ); return 0; } gPlayerSpamTick[ playerid ] = GetTickCount( );#pragma unused textnew e[200];if(GetPVarInt(playerid, \"Kek\") == 1){ format( e, 200, \"{FFFFFF}(%i){375FFF}%s\", playerid, text );}if(GetPVarInt(playerid, \"Piros\") == 1){ format( e, 200, \"{FFFFFF}(%i){E60000}%s\", playerid, text );} SendPlayerMessageToAll(playerid, e); itt még nincs benne
public OnPlayerText(playerid, text[]){ new TickCount = GetTickCount( ); SetPlayerChatBubble(playerid, text, 0x99FF00AA, 100.0, 10000);if( gPlayerSpamTick[ playerid ] > ( TickCount - ( SPAM_TIME * 800 ) ) ){ SendClientMessage( playerid, 0xEB000FFF, \"Ne spamolj várj {FB0000}2 {FF0000}másodpercet!\" );gPlayerSpamTick[ playerid ] = GetTickCount( );return 0;} new iNums; for( new x = 0; x < strlen( text ); ++x ) { if( text[ x ] < \'0\' || text[ x ] > \'9\' ) continue; ++iNums; } if( iNums > 9 ) { SendClientMessage( playerid, COLOR_RED, \"Ne hirdess te fogyatékos buzi gyerek!\" ); return 0; } gPlayerSpamTick[ playerid ] = GetTickCount( );#pragma unused textnew e[200];if(GetPVarInt(playerid, \"Kek\") == 1){ format( e, 200, \"{FFFFFF}(%i){375FFF}%s\", playerid, text );}if(GetPVarInt(playerid, \"Piros\") == 1){ format( e, 200, \"{FFFFFF}(%i){E60000}%s\", playerid, text );} SendPlayerMessageToAll(playerid, e);
Két színben gyorsan összedobtam, de nem teszteltem! #include <a_samp>#include <zcmd>CMD:chatcolor(playerid){ShowPlayerDialog(playerid, 5000, DIALOG_STYLE_LIST, \"ChatColor change\", \"Kék\\nPiros\", \"Change!\", \"Mégse\");return 1;}public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]){if(dialogid == 5000){if(response){ if(listitem==0) { SetPVarInt(playerid, \"Kek\", 1); SetPVarInt(playerid, \"Piros\", 0); SendClientMessage(playerid, -1, \"Kék szövegszín kiválasztva!\"); } if(listitem==1) { SetPVarInt(playerid, \"Kek\", 0); SetPVarInt(playerid, \"Piros\", 1); SendClientMessage(playerid, -1, \"Piros szövegszín kiválasztva!\"); }}}return 1;}public OnPlayerText(playerid, text[]){ new string[512], Name[MAX_PLAYER_NAME];GetPlayerName(playerid, Name, MAX_PLAYER_NAME);if(GetPVarInt(playerid, \"Kek\") == 1){format(string, sizeof(string), \"%s {375FFF}%s\", Name, text);}if(GetPVarInt(playerid, \"Piros\") == 1){format(string, sizeof(string), \"%s {E60000}%s\", Name, text);}SendClientMessageToAll(GetPlayerColor(playerid), string);return 0;}
#include <a_samp>#include <zcmd>CMD:chatcolor(playerid){ShowPlayerDialog(playerid, 5000, DIALOG_STYLE_LIST, \"ChatColor change\", \"Kék\\nPiros\", \"Change!\", \"Mégse\");return 1;}public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]){if(dialogid == 5000){if(response){ if(listitem==0) { SetPVarInt(playerid, \"Kek\", 1); SetPVarInt(playerid, \"Piros\", 0); SendClientMessage(playerid, -1, \"Kék szövegszín kiválasztva!\"); } if(listitem==1) { SetPVarInt(playerid, \"Kek\", 0); SetPVarInt(playerid, \"Piros\", 1); SendClientMessage(playerid, -1, \"Piros szövegszín kiválasztva!\"); }}}return 1;}public OnPlayerText(playerid, text[]){ new string[512], Name[MAX_PLAYER_NAME];GetPlayerName(playerid, Name, MAX_PLAYER_NAME);if(GetPVarInt(playerid, \"Kek\") == 1){format(string, sizeof(string), \"%s {375FFF}%s\", Name, text);}if(GetPVarInt(playerid, \"Piros\") == 1){format(string, sizeof(string), \"%s {E60000}%s\", Name, text);}SendClientMessageToAll(GetPlayerColor(playerid), string);return 0;}
#include <a_samp> #include <zcmd> CMD:chatcolor(playerid) { ShowPlayerDialog(playerid, 5000, DIALOG_STYLE_LIST, \"ChatColor change\", \"Kék\\nPiros\", \"Change!\", \"Mégse\"); return 1; } public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { if(dialogid == 5000) { if(response) { if(listitem==0) { SetPVarInt(playerid, \"Kek\", 1); SetPVarInt(playerid, \"Piros\", 0); SendClientMessage(playerid, -1, \"Kék szövegszín kiválasztva!\"); } if(listitem==1) { SetPVarInt(playerid, \"Kek\", 0); SetPVarInt(playerid, \"Piros\", 1); SendClientMessage(playerid, -1, \"Piros szövegszín kiválasztva!\"); } } } return 1; } public OnPlayerText(playerid, text[]) { new e[200]; if(GetPVarInt(playerid, \"Kek\") == 1) { format( e, 200, \"{FFFFFF}(%i){375FFF}%s\", playerid, text ); } if(GetPVarInt(playerid, \"Piros\") == 1) { format( e, 200, \"{FFFFFF}(%i){E60000}%s\", playerid, text ); } SendPlayerMessageToAll(playerid, e); return 0; }
#include <a_samp>#include <zcmd>public OnPlayerConnect(playerid){SetPVarInt(playerid, \"Alap\", 1);return 1;}CMD:chatcolor(playerid){ShowPlayerDialog(playerid, 5000, DIALOG_STYLE_LIST, \"ChatColor change\", \"Kék\\nPiros\\nAlap\", \"Change!\", \"Mégse\");return 1;}public OnPlayerText(playerid, text[]){new e[200];if(GetPVarInt(playerid, \"Kek\") == 1){ format( e, 200, \"{FFFFFF}(%i){375FFF}%s\", playerid, text );}if(GetPVarInt(playerid, \"Piros\") == 1){ format( e, 200, \"{FFFFFF}(%i){E60000}%s\", playerid, text );}if(GetPVarInt(playerid, \"Alap\") == 1){ format( e, 200, \"{FFFFFF}(%i){FFFFFF}%s\", playerid, text );}SendPlayerMessageToAll(playerid, e);return 0;}public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]){ if(dialogid == 5000) { if(response) { if(listitem==0) { SetPVarInt(playerid, \"Kek\", 1); SetPVarInt(playerid, \"Piros\", 0); SetPVarInt(playerid, \"Alap\", 0); SendClientMessage(playerid, -1, \"Kék szövegszín kiválasztva!\"); } if(listitem==1) { SetPVarInt(playerid, \"Kek\", 0); SetPVarInt(playerid, \"Piros\", 1); SetPVarInt(playerid, \"Alap\", 0); SendClientMessage(playerid, -1, \"Piros szövegszín kiválasztva!\"); } if(listitem==2) { SetPVarInt(playerid, \"Kek\", 0); SetPVarInt(playerid, \"Piros\", 0); SetPVarInt(playerid, \"Alap\", 1); SendClientMessage(playerid, -1, \"Alap szövegszín (fehér) kiválasztva!\"); } } }return 1;}