BunnymodXT icon indicating copy to clipboard operation
BunnymodXT copied to clipboard

restructuring: windows: find cmd functions from linked list instead of using patterns

Open SmileyAG opened this issue 2 years ago • 0 comments

To hook cmd functions such as changelevel2 or record it is not necessary to create patterns at all There is cmd_function_t* cmd_functions global variable in the engine code in which all commands is stored

cmd_function_t structure:

typedef void (*xcommand_t) (void);
typedef struct cmd_function_s
{
	struct cmd_function_s	*next;
	char					*name;
	xcommand_t				function;
	int						flags;
} cmd_function_t;

SmileyAG avatar Jan 07 '24 20:01 SmileyAG