]>
jfr.im git - irc/quakenet/newserv.git/blob - helpmod2/huser.h
1 /* new H user, a little more than N's user */
11 #include "helpmod_entries.h"
13 #define H_USRFLAGS_DEFAULT 0
15 typedef struct huser_struct
17 /* the real N user, channel information etc. can be gotten from this */
22 helpmod_entry state
; /* for old H */
26 /* for the lamer control, global -> can detect lame amsg's */
28 int last_line_repeats
;
34 /* end lamer control */
36 helpmod_editor
*editor
;
38 struct huser_channel_struct
*hchannels
;
40 struct huser_struct
*next
;
46 HCUMODE_VOICE
= 1 << 1,
48 H_IDLE_WARNING
= 1 << 3
51 typedef struct huser_channel_struct
54 struct hchannel_struct
*hchan
;
57 /* for queue, tells us who was the oper for this user */
58 huser
*responsible_oper
;
60 struct huser_channel_struct
*next
;
66 huser
*huser_add(nick
*);
67 void huser_del(huser
*);
69 huser
*huser_get(nick
*);
71 /* indicates that the user did something, channel is optional */
72 void huser_activity(huser
*, hchannel
*);
74 void huser_clear_inactives(void);
75 int huser_count(void);
76 void huser_reset_states(void);
78 hlevel
huser_get_level(huser
*);
79 int huser_get_account_flags(huser
*);
81 const char *huser_get_nick(huser
*);
82 const char *huser_get_ident(huser
*);
83 const char *huser_get_host(huser
*);
84 const char *huser_get_auth(huser
*);
85 const char *huser_get_realname(huser
*);
87 /* defines the "being on queue" and being on desk (getting service) */
88 int on_queue(huser
*, huser_channel
*);
89 int on_desk(huser
*, huser_channel
*);
92 int huser_is_trojan(huser
*);
94 huser_channel
*huser_add_channel(huser
*, struct hchannel_struct
*);
95 void huser_del_channel(huser
*, struct hchannel_struct
*);
96 /* returns 0 if the user is not on the channel, non-zero otherwise */
97 huser_channel
*huser_on_channel(huser
*, struct hchannel_struct
*);
99 /* returns non-zero if the given huser pointer is valid */
100 int huser_valid(huser
*);