diff --git a/plugins/include/amxconst.inc b/plugins/include/amxconst.inc index 138c1c06..4006c300 100755 --- a/plugins/include/amxconst.inc +++ b/plugins/include/amxconst.inc @@ -11,8 +11,6 @@ #endif #define _amxconst_included -#include - #define AMXX_VERSION 1.75 #define AMXX_VERSION_NUM 175 stock const AMXX_VERSION_STR[]="1.75" @@ -54,28 +52,6 @@ stock const AMXX_VERSION_STR[]="1.75" #define PLUGIN_HANDLED 1 /* stop other plugins */ #define PLUGIN_HANDLED_MAIN 2 /* to use in client_command(), continue all plugins but stop the command */ -/* Destination types for message_begin() */ -#define MSG_BROADCAST 0 /* unreliable to all */ -#define MSG_ONE 1 /* reliable to one (msg_entity) */ -#define MSG_ALL 2 /* reliable to all */ -#define MSG_INIT 3 /* write to the init string */ -#define MSG_PVS 4 /* Ents in PVS of org */ -#define MSG_PAS 5 /* Ents in PAS of org */ -#define MSG_PVS_R 6 /* Reliable to PVS */ -#define MSG_PAS_R 7 /* Reliable to PAS */ -#define MSG_ONE_UNRELIABLE 8 /* Send to one client, but don't put in reliable stream, put in unreliable datagram ( could be dropped ) */ -#define MSG_SPEC 9 /* Sends to all spectator proxies */ - -/* Message types for message_begin() */ -#define SVC_TEMPENTITY 23 -#define SVC_INTERMISSION 30 -#define SVC_CDTRACK 32 -#define SVC_WEAPONANIM 35 -#define SVC_ROOMTYPE 37 -#define SVC_ADDANGLE 38 /* [vec3] add this angle to the view angle */ -#define SVC_NEWUSERMSG 39 -#define SVC_HLTV 50 - /* Flags for register_cvar() */ #define FCVAR_ARCHIVE 1 /* set to cause it to be saved to vars.rc */ #define FCVAR_USERINFO 2 /* changes the client's info string */ diff --git a/plugins/include/amxmodx.inc b/plugins/include/amxmodx.inc index 55d92c51..247c2e86 100755 --- a/plugins/include/amxmodx.inc +++ b/plugins/include/amxmodx.inc @@ -474,21 +474,6 @@ native register_concmd(const cmd[],const function[],flags=-1, info[]=""); /* Registers function which will be called from server console. */ native register_srvcmd(const server_cmd[],const function[],flags=-1, info[]=""); -/* These functinos are used to generate client messages. -* You may generate menu, smoke, shockwaves, thunderlights, -* intermission and many many others messages. -* See HL SDK for more examples. */ -native message_begin( dest, msg_type, origin[3]={0,0,0},player=0); -native message_end(); -native write_byte( x ); -native write_char( x ); -native write_short( x ); -native write_long( x ); -native write_entity( x ); -native write_angle( x ); -native write_coord( x ); -native write_string( x[] ); - /* Gets info about client command. */ native get_clcmd(index, command[], len1, &flags, info[], len2, flag); diff --git a/plugins/include/message_const.inc b/plugins/include/message_const.inc index 756b256c..73854b39 100644 --- a/plugins/include/message_const.inc +++ b/plugins/include/message_const.inc @@ -11,6 +11,47 @@ #endif #define _message_const_included +/* Destination types for message_begin() */ +#define MSG_BROADCAST 0 // Unreliable to all +#define MSG_ONE 1 // Reliable to one (msg_entity) +#define MSG_ALL 2 // Reliable to all +#define MSG_INIT 3 // Write to the init string +#define MSG_PVS 4 // Ents in PVS of org +#define MSG_PAS 5 // Ents in PAS of org +#define MSG_PVS_R 6 // Reliable to PVS +#define MSG_PAS_R 7 // Reliable to PAS +#define MSG_ONE_UNRELIABLE 8 // Send to one client, but don't put in reliable stream, put in unreliable datagram (could be dropped) +#define MSG_SPEC 9 // Sends to all spectator proxies + +/* Message types for message_begin() */ +#define SVC_TEMPENTITY 23 +#define SVC_INTERMISSION 30 +#define SVC_CDTRACK 32 +#define SVC_WEAPONANIM 35 +#define SVC_ROOMTYPE 37 +#define SVC_ADDANGLE 38 // [vec3] add this angle to the view angle +#define SVC_NEWUSERMSG 39 +#define SVC_HLTV 50 + +/* Message flags for set_msg_block() */ +#define BLOCK_NOT 0 +#define BLOCK_ONCE 1 +#define BLOCK_SET 2 + +/* Used with get_msg_argtype() and set_msg_arg_* +enum +{ + ARG_BYTE = 1, /* int */ + ARG_CHAR, /* int */ + ARG_SHORT, /* int */ + ARG_LONG, /* int */ + ARG_ANGLE, /* float */ + ARG_COORD, /* float */ + ARG_STRING, /* string */ + ARG_ENTITY, /* int */ +} + +/* Temp entity message types for message_begin() */ #define TE_BEAMPOINTS 0 // Beam effect between two points // write_byte(TE_BEAMPOINTS) // write_coord(startposition.x) diff --git a/plugins/include/messages.inc b/plugins/include/messages.inc index 5e13c9b6..78d7a225 100644 --- a/plugins/include/messages.inc +++ b/plugins/include/messages.inc @@ -10,21 +10,22 @@ #endif #define _coremsg_included -#define BLOCK_NOT 0 -#define BLOCK_ONCE 1 -#define BLOCK_SET 2 +#include -enum -{ - ARG_BYTE = 1, /* int */ - ARG_CHAR, /* int */ - ARG_SHORT, /* int */ - ARG_LONG, /* int */ - ARG_ANGLE, /* float */ - ARG_COORD, /* float */ - ARG_STRING, /* string */ - ARG_ENTITY, /* int */ -} +/* These functinos are used to generate client messages. + * You may generate menu, smoke, shockwaves, thunderlights, + * intermission and many many others messages. + * See HL SDK for more examples. */ +native message_begin(dest, msg_type, origin[3] = {0,0,0}, player = 0); +native message_end(); +native write_byte(x); +native write_char(x); +native write_short(x); +native write_long(x); +native write_entity(x); +native write_angle(x); +native write_coord(x); +native write_string(x[]); /* Sets/Gets what engine messages are blocked. */ native set_msg_block(iMessage, iMessageFlags);