-/* modcmd.h - NeonServ v5.2
- * Copyright (C) 2011 Philipp Kreil (pk910)
+/* modcmd.h - NeonServ v5.3
+ * Copyright (C) 2011-2012 Philipp Kreil (pk910)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
struct cmd_binding *next;
};
+#define BIND_FLAGS(BIND) (BIND->flags | BIND->func->flags)
+
struct trigger_cache {
int botid;
int clientid;
int register_command(int botid, char *name, cmd_bind_t *func, int paramcount, char *channel_access, int global_access, unsigned int flags);
int set_trigger_callback(int botid, trigger_callback_t *func);
+int flush_trigger_cache(int botid, int clientid);
+
#define changeChannelTrigger(BOTID,CHAN,NEW) changeBotwiseChannelTrigger(BOTID, 0, CHAN, NEW)
int changeBotwiseChannelTrigger(int botid, int clientid, struct ChanNode *chan, char *new_trigger);
#define bind_set_channel_access(BOTID,CMD,CACCESS) bind_botwise_set_channel_access(BOTID, 0, CMD, CACCESS)
void bind_botwise_set_channel_access(int botid, int clientid, char *cmd, char *chanaccess);
+#define bind_set_bind_flags(BOTID,CMD,FLAGS) bind_botwise_set_bind_flags(BOTID, 0, CMD, FLAGS)
+void bind_botwise_set_bind_flags(int botid, int clientid, char *cmd, unsigned int flags);
+
#define find_cmd_binding(BOTID,CMD) find_botwise_cmd_binding(BOTID, 0, CMD)
struct cmd_binding *find_botwise_cmd_binding(int botid, int clientid, char *cmd);