blob: b9e64988ec5c88ed1fac00d8040f5a8c603ae36f [file] [log] [blame]
MG Mud User88f12472016-06-24 23:31:02 +02001// 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
Zesstra7459f252022-02-23 22:47:26 +010015#define P_BUFFER "buffer" // Kobold konfigurieren
MG Mud User88f12472016-06-24 23:31:02 +020016#define P_DEAF "deaf" // Taubheit
17#define P_PERM_STRING "perm_string" // Fuer Sprachflueche
18#define P_MESSAGE_BEEP "message_beep" // wenn gesetzt
19 // Anzahl der Sekunden dazwischen
20#define P_MESSAGE_PREPEND "message_prepend"
21// Will der Magier MT_DEBUG sehen?
22#define P_WIZ_DEBUG "std_p_wizdebug"
23
24#define MESSAGE_BEEP "\007"
25
Zesstra7459f252022-02-23 22:47:26 +010026// Konstanten fuer P_BUFFER
27#define KOBOLD_ONLINE 0x1 // bei Anwesenheit speichern
28#define KOBOLD_OFFLINE 0x2 // bei Abwesenheit speichern
29
Bugfix3afcb792022-01-21 22:32:42 +010030// Definitionen fuer Alerts
31// Eigentlich waere hier "p_lib_alert" als Inhalt des Defines vorgesehen, da
32// "visualbell" in den Savefiles steht, ist eine Migrations hier jedoch
33// aufwaendig und auf unbestimmte Zeit verschoben.
34#define P_ALERT "visualbell"
35#define AL_NO_SOUND 1
36// Bis 1024 (2^10) reserviert fuer allg. Einstellungen
Zesstra1cc6cf32022-02-09 11:49:31 +010037// Aktionsfilter:
Bugfix60f5bc62022-01-21 11:09:56 +010038#define MB_TELL 2048
39#define MB_SAY 4096
40#define MB_CHANNEL 8192
41#define MB_SHOUT 16384
Zesstra3a261e52022-02-10 14:00:31 +010042#define MB_MENTION 0x8000
Zesstra1cc6cf32022-02-09 11:49:31 +010043#define MB_MISC 0x10000 // alle anderen Aktionen ohne eigenen Filter
Bugfix60f5bc62022-01-21 11:09:56 +010044// Flags < 1048576 (2^20) reserviert fuer Flags
Zesstra3a261e52022-02-10 14:00:31 +010045#define MB_ALL (MB_SAY | MB_TELL | MB_CHANNEL | MB_SHOUT | MB_MENTION | MB_MISC)
Bugfix3afcb792022-01-21 22:32:42 +010046
MG Mud User88f12472016-06-24 23:31:02 +020047// definitions for Message()
48
49#define MSGFLAG_CHANNEL 0x0001 // messages from channeld.c
50#define MSGFLAG_CHIST 0x0002
51#define MSGFLAG_SOUL 0x0004 // messages from soul.c
52#define MSGFLAG_REMOTE 0x0008 // remote emotes
53#define MSGFLAG_SHOUT 0x0010 // communication commands
54#define MSGFLAG_TELL 0x0020
55#define MSGFLAG_SAY 0x0040
56#define MSGFLAG_WHISPER 0x0080
57#define MSGFLAG_MECHO 0x0100
58#define MSGFLAG_RTELL 0x0200 // tell from other mud
59
60#define MAX_SAVED_MESSAGES 50
61#define MAX_SAVED_CHATS 20
62
63// Was geht in den Kobold?
64#define MSGFLAG_CACHE (MSGFLAG_TELL | MSGFLAG_REMOTE | MSGFLAG_WHISPER | MSGFLAG_RTELL)
65
66#define MSGFLAG_DEAFCHK (MSGFLAG_SHOUT | MSGFLAG_TELL | MSGFLAG_SAY | MSGFLAG_WHISPER | MSGFLAG_CHANNEL | MSGFLAG_RTELL)
67
68// Rueckgabewerte von Message()
69#define MESSAGE_OK 1 // alles klar
70#define MESSAGE_CACHE 0 // Meldung steht im Kobold
71#define MESSAGE_IGNORE_YOU -1 // Meldung/Sender wird ignoriert
72#define MESSAGE_IGNORE_VERB -2
73#define MESSAGE_IGNORE_MUD -3
74#define MESSAGE_DEAF -4 // Empfaenger hoert nicht zu
75#define MESSAGE_CACHE_FULL -5 // Kobold kann nichts mehr merken
76
77// Flags fuer Statusreports
78#define DO_REPORT_HP 0x1
79#define DO_REPORT_SP 0x2
80#define DO_REPORT_POISON 0x4
81#define DO_REPORT_WIMPY 0x8
82#define DO_REPORT_WIMPY_DIR 0x10
83
Zesstra8b5320e2022-02-18 21:10:26 +010084// Pfad zum (Offline-) Kobold
85#define KOBOLD "/secure/kobold"
86
MG Mud User88f12472016-06-24 23:31:02 +020087#endif // __PLAYER_COMM_H__
88
89#ifdef NEED_PROTOTYPES
90
91#ifndef __PLAYER_COMM_H_PROTO__
92#define __PLAYER_COMM_H_PROTO__
93
Zesstra8b5320e2022-02-18 21:10:26 +010094#define MAX_KOBOLD_LIMIT 256
95
MG Mud User88f12472016-06-24 23:31:02 +020096// prototypes
97
98protected varargs int _recv(object ob, string message,
99 int flag, string indent);
100
101varargs int Message(string msg, int flag, string indent,
102 string cname, mixed sender);
103
104protected void status_report(int type, mixed val);
105protected void _notify(string msg, string action);
bugfix1b04afb2020-04-15 14:52:24 +0200106static void modify_prompt();
MG Mud User88f12472016-06-24 23:31:02 +0200107
108#endif // __PLAYER_COMM_H_PROTO__
109
110#endif // NEED_PROTOYPES
111