MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 1 | SYNOPSIS |
Zesstra | 715ec20 | 2025-07-09 22:18:31 +0200 | [diff] [blame^] | 2 | int binary_message(int *|bytes message, int flags) |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 3 | |
Zesstra | 715ec20 | 2025-07-09 22:18:31 +0200 | [diff] [blame^] | 4 | DESCRIPTION |
| 5 | Flush output and send output directly with write WITHOUT IAC QUOTING. |
| 6 | The message may contain zeroes if given as int *. |
| 7 | The messages goes to this_object(), but only if interactive. |
| 8 | return value: number of characters actually written. |
| 9 | Any 'allowed charset' setting is ignored. |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 10 | |
Zesstra | 715ec20 | 2025-07-09 22:18:31 +0200 | [diff] [blame^] | 11 | Flag settings are interpreted bitwise and may be ored |
| 12 | together (only for clients not using MCCP compression): |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 13 | |
Zesstra | 715ec20 | 2025-07-09 22:18:31 +0200 | [diff] [blame^] | 14 | Bit 0 (value 1): when set, add_message() is used instead of |
| 15 | write(). Thus no previous flushing of the buffer is |
| 16 | needed, but the output is not immediate, nor can the |
| 17 | number of bytes actually sent be determined - the return |
| 18 | value is undefined. |
| 19 | Bit 1 (value 2): The buffer is flushed _after_ adding the |
| 20 | message. Useful only in conjunction with Bit 0. |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 21 | |
Zesstra | 715ec20 | 2025-07-09 22:18:31 +0200 | [diff] [blame^] | 22 | The idea behind the flag settings is that sending command |
| 23 | codes for colours and other things needs to bypass the allowed |
| 24 | charset filters, but isn't important enough to waste bandwith |
| 25 | on a synchronous transmission. |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 26 | |
Zesstra | 715ec20 | 2025-07-09 22:18:31 +0200 | [diff] [blame^] | 27 | HISTORY |
| 28 | Introduced in 3.2.1@40. |
| 29 | Argument 'flags' introduced in 3.2.1@60. |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 30 | |
Zesstra | 715ec20 | 2025-07-09 22:18:31 +0200 | [diff] [blame^] | 31 | SEE ALSO |
MG Mud User | 88f1247 | 2016-06-24 23:31:02 +0200 | [diff] [blame] | 32 | set_connection_charset(E) |