MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 1 | // MorgenGrauen MUDlib |
| 2 | // |
| 3 | // player/comm.h -- communication module properties |
| 4 | // |
| 5 | // $Id: comm.h,v 3.3 2000/02/09 15:56:25 Padreic Exp $ |
| 6 | |
| 7 | #ifndef __PLAYER_COMM_H__ |
| 8 | #define __PLAYER_COMM_H__ |
| 9 | |
| 10 | // living/comm.h brauchen wir auch. |
| 11 | #include <living/comm.h> |
| 12 | |
| 13 | // properties |
| 14 | |
| 15 | #define P_INTERMUD "intermud" // Does she listen to it ? |
| 16 | #define P_BUFFER "buffer" // ignore-, tell-buffer |
| 17 | #define P_DEAF "deaf" // Taubheit |
| 18 | #define P_PERM_STRING "perm_string" // Fuer Sprachflueche |
| 19 | #define P_MESSAGE_BEEP "message_beep" // wenn gesetzt |
| 20 | // Anzahl der Sekunden dazwischen |
| 21 | #define P_MESSAGE_PREPEND "message_prepend" |
| 22 | // Will der Magier MT_DEBUG sehen? |
| 23 | #define P_WIZ_DEBUG "std_p_wizdebug" |
| 24 | |
| 25 | #define MESSAGE_BEEP "\007" |
| 26 | |
Bugfix | 3afcb79 | 2022-01-21 22:32:42 +0100 | [diff] [blame] | 27 | // Definitionen fuer Alerts |
| 28 | // Eigentlich waere hier "p_lib_alert" als Inhalt des Defines vorgesehen, da |
| 29 | // "visualbell" in den Savefiles steht, ist eine Migrations hier jedoch |
| 30 | // aufwaendig und auf unbestimmte Zeit verschoben. |
| 31 | #define P_ALERT "visualbell" |
| 32 | #define AL_NO_SOUND 1 |
| 33 | // Bis 1024 (2^10) reserviert fuer allg. Einstellungen |
Zesstra | 1cc6cf3 | 2022-02-09 11:49:31 +0100 | [diff] [blame] | 34 | // Aktionsfilter: |
Bugfix | 60f5bc6 | 2022-01-21 11:09:56 +0100 | [diff] [blame] | 35 | #define MB_TELL 2048 |
| 36 | #define MB_SAY 4096 |
| 37 | #define MB_CHANNEL 8192 |
| 38 | #define MB_SHOUT 16384 |
Zesstra | 3a261e5 | 2022-02-10 14:00:31 +0100 | [diff] [blame] | 39 | #define MB_MENTION 0x8000 |
Zesstra | 1cc6cf3 | 2022-02-09 11:49:31 +0100 | [diff] [blame] | 40 | #define MB_MISC 0x10000 // alle anderen Aktionen ohne eigenen Filter |
Bugfix | 60f5bc6 | 2022-01-21 11:09:56 +0100 | [diff] [blame] | 41 | // Flags < 1048576 (2^20) reserviert fuer Flags |
Zesstra | 3a261e5 | 2022-02-10 14:00:31 +0100 | [diff] [blame] | 42 | #define MB_ALL (MB_SAY | MB_TELL | MB_CHANNEL | MB_SHOUT | MB_MENTION | MB_MISC) |
Bugfix | 3afcb79 | 2022-01-21 22:32:42 +0100 | [diff] [blame] | 43 | |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 44 | // definitions for Message() |
| 45 | |
| 46 | #define MSGFLAG_CHANNEL 0x0001 // messages from channeld.c |
| 47 | #define MSGFLAG_CHIST 0x0002 |
| 48 | #define MSGFLAG_SOUL 0x0004 // messages from soul.c |
| 49 | #define MSGFLAG_REMOTE 0x0008 // remote emotes |
| 50 | #define MSGFLAG_SHOUT 0x0010 // communication commands |
| 51 | #define MSGFLAG_TELL 0x0020 |
| 52 | #define MSGFLAG_SAY 0x0040 |
| 53 | #define MSGFLAG_WHISPER 0x0080 |
| 54 | #define MSGFLAG_MECHO 0x0100 |
| 55 | #define MSGFLAG_RTELL 0x0200 // tell from other mud |
| 56 | |
| 57 | #define MAX_SAVED_MESSAGES 50 |
| 58 | #define MAX_SAVED_CHATS 20 |
| 59 | |
| 60 | // Was geht in den Kobold? |
| 61 | #define MSGFLAG_CACHE (MSGFLAG_TELL | MSGFLAG_REMOTE | MSGFLAG_WHISPER | MSGFLAG_RTELL) |
| 62 | |
| 63 | #define MSGFLAG_DEAFCHK (MSGFLAG_SHOUT | MSGFLAG_TELL | MSGFLAG_SAY | MSGFLAG_WHISPER | MSGFLAG_CHANNEL | MSGFLAG_RTELL) |
| 64 | |
| 65 | // Rueckgabewerte von Message() |
| 66 | #define MESSAGE_OK 1 // alles klar |
| 67 | #define MESSAGE_CACHE 0 // Meldung steht im Kobold |
| 68 | #define MESSAGE_IGNORE_YOU -1 // Meldung/Sender wird ignoriert |
| 69 | #define MESSAGE_IGNORE_VERB -2 |
| 70 | #define MESSAGE_IGNORE_MUD -3 |
| 71 | #define MESSAGE_DEAF -4 // Empfaenger hoert nicht zu |
| 72 | #define MESSAGE_CACHE_FULL -5 // Kobold kann nichts mehr merken |
| 73 | |
| 74 | // Flags fuer Statusreports |
| 75 | #define DO_REPORT_HP 0x1 |
| 76 | #define DO_REPORT_SP 0x2 |
| 77 | #define DO_REPORT_POISON 0x4 |
| 78 | #define DO_REPORT_WIMPY 0x8 |
| 79 | #define DO_REPORT_WIMPY_DIR 0x10 |
| 80 | |
| 81 | #endif // __PLAYER_COMM_H__ |
| 82 | |
| 83 | #ifdef NEED_PROTOTYPES |
| 84 | |
| 85 | #ifndef __PLAYER_COMM_H_PROTO__ |
| 86 | #define __PLAYER_COMM_H_PROTO__ |
| 87 | |
| 88 | // prototypes |
| 89 | |
| 90 | protected varargs int _recv(object ob, string message, |
| 91 | int flag, string indent); |
| 92 | |
| 93 | varargs int Message(string msg, int flag, string indent, |
| 94 | string cname, mixed sender); |
| 95 | |
| 96 | protected void status_report(int type, mixed val); |
| 97 | protected void _notify(string msg, string action); |
bugfix | 1b04afb | 2020-04-15 14:52:24 +0200 | [diff] [blame] | 98 | static void modify_prompt(); |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 99 | |
| 100 | #endif // __PLAYER_COMM_H_PROTO__ |
| 101 | |
| 102 | #endif // NEED_PROTOYPES |
| 103 | |