SHOW:
|
|
- or go back to the newest paste.
1 | - | //------------------------------------------------------------------------------ |
1 | + | |
2 | - | // Belépő üzenet by Patrick150 Betöltve! |
2 | + | |
3 | - | //------------------------------------------------------------------------------ |
3 | + | |
4 | #define COLOR_LIGHTBLUE 0x6DC5F3FF | |
5 | #define COLOR_SZIN 0xFF8C55FF | |
6 | #define COLOR_WHITE 0xFFFFFFAA | |
7 | ||
8 | new FALSE = false; | |
9 | ||
10 | #define SendFormatMessage(%1,%2,%3,%4) do{new sendfstring[128];format(sendfstring,256,(%3),%4);SendClientMessage(%1,(%2),sendfstring);}while(FALSE) | |
11 | #define SendFormatMessageToAll(%1,%2,%3) do{new sendfstring[128];format(sendfstring,256,(%2),%3);SendClientMessageToAll((%1),sendfstring);}while(FALSE) | |
12 | ||
13 | public OnFilterScriptInit() | |
14 | { | |
15 | return 1; | |
16 | } | |
17 | public OnFilterScriptExit() | |
18 | { | |
19 | return 1; | |
20 | } | |
21 | ||
22 | public OnPlayerConnect(playerid) | |
23 | { | |
24 | SendClientMessage(playerid, 0xFF8C55FF, "Üdvözöllek a szerveren!"); // ezt az ünetet küldi amikor valaki belép a szerverbe!!! oda be kell irni az üzeneteket!!! | |
25 | SendClientMessage(playerid, 0x6DC5F3FF, "Ha van valami gond syolj egy adminnak!"); | |
26 | ||
27 | SendFormatMessageToAll(0xFFFFFFAA,"%s csatlakozott a szerverhez.",GetPlayerNameEx(playerid)); | |
28 | return 1; | |
29 | } | |
30 | public OnPlayerDisconnect(playerid, reason) | |
31 | { | |
32 | new | |
33 | string[64] | |
34 | ; | |
35 | ||
36 | switch(reason) | |
37 | { | |
38 | case 0: format(string,sizeof string,"%s kifagyott.",GetPlayerNameEx(playerid));// ezt átirhatod másra is!!! | |
39 | case 1: format(string,sizeof string,"%s kilépett.",GetPlayerNameEx(playerid));// ezt is | |
40 | case 2: format(string,sizeof string,"%s bannolták/kickelték.",GetPlayerNameEx(playerid));// ezt is | |
41 | ||
42 | } | |
43 | SendClientMessageToAll(0xFFFFFFAA,string); | |
44 | return 1; | |
45 | } | |
46 | ||
47 | stock GetPlayerNameEx(playerid) | |
48 | { | |
49 | new string[120]; | |
50 | GetPlayerName(playerid,string,24); | |
51 | new str[24]; | |
52 | strmid(str,string,0,strlen(string),24); | |
53 | for(new i = 0; i < MAX_PLAYER_NAME; i++) | |
54 | { | |
55 | if (str[i] == '_') str[i] = ' '; | |
56 | } | |
57 | return str; | |
58 | } |