brain
be70931a50
Cache channel max bans value to save an O(n) loop of match() on every ban (etc) add
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6267 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-09 00:25:18 +00:00
w00t
696ee9ff66
And now, just to force you to recompile the *whole* ircd.. updated headers on the headers. :p
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5998 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-15 22:18:59 +00:00
brain
a78cecbeb9
Refactor userrec::chans.
...
Old way: A vector of ucrec, MAXCHANS in size by default populated by NULLS, so you have to scan the vector to find an empty slot when joining a user, parting a user etc
New way: std::map<chanrec*, char> (the char holds their basic core permissions on the channel [voice, halfop, op])
This increases speed a ton, and removes some wtf-age.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5986 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-14 17:46:47 +00:00
brain
0e8a718038
Update comments to reflect new API
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5807 e03df62e-2008-0410-955e-edbf42e46eb7
2006-11-26 18:12:50 +00:00
brain
2e52ff280d
Add extra parameter to OnUserPreNotice and OnUserPrePrivmsg, CUList &exempt_list, a list of users NOT to write to. By default it just contains the sender, you can add more.
...
This also bumps the module api version by one. added "CUList fixme" to peaveys module just so it builds, as this will be refactored to use the new feature that was just added :)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5806 e03df62e-2008-0410-955e-edbf42e46eb7
2006-11-26 18:04:47 +00:00
brain
990c308a95
Whoops, patch
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5324 e03df62e-2008-0410-955e-edbf42e46eb7
2006-09-25 17:43:28 +00:00
brain
2e2f1e98a6
Fix for bug noticed by dotslasher (?) where SAJOIN can desync
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5258 e03df62e-2008-0410-955e-edbf42e46eb7
2006-09-15 17:17:30 +00:00
brain
ea483e4972
Remove ExemptItem and InviteItem, these were never used
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5253 e03df62e-2008-0410-955e-edbf42e46eb7
2006-09-15 10:29:22 +00:00
brain
1a3297e974
* Fix ChanModes::ModeString to not try and set a key as a user mode ;)
...
* Tweak the way cyclehosts works, so that mode change is not echoed back to user who changes their host/ident
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5208 e03df62e-2008-0410-955e-edbf42e46eb7
2006-09-10 19:48:30 +00:00
brain
29fd51d6f7
Add chanrec::IsBanned() so that we dont have to keep walking the banlist in various modules and using match()
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5099 e03df62e-2008-0410-955e-edbf42e46eb7
2006-09-02 14:09:45 +00:00
brain
ceeb3afef3
Update comment
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5054 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-28 18:17:37 +00:00
brain
932f1a6bc5
Document ModeParser::FindPrefix() and chanrec::GetAllPrefixes()
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5006 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-23 22:03:05 +00:00
brain
ea3ba4bfd1
Multi-prefix FJOIN, and allowing module-defined prefixes across the network
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5002 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-23 21:34:04 +00:00
brain
1b87725fef
Document mode prefixes
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4999 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-23 20:50:20 +00:00
brain
b83765d756
Spotted problem: must clear out all prefixes attached to a user when they quit or leave a channel
...
Next thing to do, consider removing of opped_userlist, halfopped_userlist and voiced_userlist as this data is now in the prefixlist
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4998 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-23 20:29:09 +00:00
brain
8b864c8a82
Mode handlers handling listmodes where a listmode item is a nickname can now specify prefixes!!!!!!
...
This isnt documented yet.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4997 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-23 20:20:41 +00:00
brain
6557d7fa40
Documentation of new chanrec functions
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4894 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-11 19:17:31 +00:00
brain
dafc021be4
cmode(), cflags(), cstatus() -> chanrec::GetStatusChar(), chanrec::GetStatusFlags(), chanrec::GetStatus()
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4837 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-10 15:44:03 +00:00
brain
396c9ef9f7
FindNick, FindChan, ChanModes, UserList, CountInvisible, PurgeEmptyChannels, GetClass, WriteOpers, GetServerDescription -> into classes
...
ServerConfig takes InspIRCd pointer in its constructor
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4832 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-10 14:43:29 +00:00
brain
9bc04a3025
userrec and chanrec now have their own independent pointer back to their 'creator' InspIRCd* object, extern now longer required in channels.cpp or users.cpp
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4820 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-09 18:55:52 +00:00
brain
a7543c881b
Comment all the new stuff
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4797 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-08 16:47:14 +00:00
brain
6ab1d0dffb
WriteChannel* functions and ChanExceptSender* functions are now methods of chanrec. They probably should be renamed too eventually.
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4788 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-08 14:17:35 +00:00
brain
903ba4e2eb
add_channel -> chanrec::JoinUser()
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4787 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-08 13:22:30 +00:00
brain
6f1b8f50dd
Change to chanrec::PartUser. As with KickUser and ServerKickUser, returns the number of users left, if it returns 0, delete the chanrec
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4786 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-08 12:52:24 +00:00
brain
25f6cb0fe6
kick_channel -> chanrec::KickUser(), server_kick_channel -> chanrec::ServerKickUser()
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4782 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-08 12:20:45 +00:00
brain
49ef1162a5
Alter SetModeParam to take const char* to save on casts, notice a load of modules that arent setting the param or the mode inside the handler
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4231 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-09 16:40:58 +00:00
brain
f6fc729c72
Did some renaming so that the methods for modes in chanrec and userrec are identical.
...
bool IsModeSet(const unsigned char c);
void SetMode(const unsigned char c, bool value);
Fixed m_botmode for new api
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4194 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-08 21:37:16 +00:00
om
ecb76110fd
A few more typedefs defined and put into use.
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3866 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-10 20:38:26 +00:00
brain
572a7b503b
Commented a lot of stuff that hasnt been commented since 1.0.2
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3695 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-12 18:03:02 +00:00
brain
ced58c3be3
Renamed to chanrec::modes
...
Renamed IsCustomModeSet to IsModeSet
GetModeParameter will now return the channel limit (as a string) for a request for mode 'l' and the channel key for a request for mode 'k'.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3692 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-12 14:49:30 +00:00
brain
988568f3d1
*NEEDS TESTING* changed binarymodes to use the custom_modes entries
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3691 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-12 14:26:15 +00:00
brain
c738817483
Removed chanrec::binarymodes - insp wont compile atm do not use :p
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3690 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-12 13:38:16 +00:00
brain
c2a5839bcb
Probably wont compile yet - purge_empty_channels refactor
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3579 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-09 11:24:30 +00:00
brain
aaf5226111
Removed has_channel(userrec*,chanrec*), the new preferred way of doing it is channel->HasUser(userrec)
...
Yeah its the other way around to the old way, but somehow, seems less backwards to me (its also faster)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3560 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-08 23:16:18 +00:00
brain
21cf60233c
Got rid of all that ugly char* cast crap (todo: change docs to reflect change)
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3556 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-08 18:59:55 +00:00
brain
b2f5fc1e32
Fixed #defines to be enums (tidier)
...
Removed UCMODE_PROTECT/UCMODE_FOUNDER
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3555 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-08 18:25:51 +00:00
brain
bd155d5308
Actually, 64.
...
(256-64-128) = 64 chars printable alphabet (roughly)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3552 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-08 13:06:07 +00:00
brain
76174ede1d
chanrec::custom_modes only needs 96 values not 190
...
(256 - 32 - 128)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3551 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-08 13:05:07 +00:00
brain
6fef928da8
*TEST CODE* Faster custom mode set/unset
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3508 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-07 10:58:56 +00:00
brain
aa223a7d91
Sped up introduction of nicks using vector::resize() rather than the craq++ loop (wtf was i thinking doing it that way?)
...
Removed 'client connecting notices dont show locally during burst' -- this is silly as it doesnt work remotely and is pretty much pointless
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3460 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-05 00:08:48 +00:00
brain
d5d8a5987b
Moved custom_mode_params to per-channel
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3223 e03df62e-2008-0410-955e-edbf42e46eb7
2006-02-15 20:30:29 +00:00
brain
9ebbd138cc
This probably wont compile atm - add support for prefixed messages
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3046 e03df62e-2008-0410-955e-edbf42e46eb7
2006-02-03 17:20:40 +00:00
brain
93e3cda102
Added facility for servers to send KICK message (ew, i hate this crap)
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2830 e03df62e-2008-0410-955e-edbf42e46eb7
2006-01-22 19:23:20 +00:00
brain
1383dba43e
Updated copyrights in headers etc using perl inplace edit
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2795 e03df62e-2008-0410-955e-edbf42e46eb7
2006-01-15 15:59:11 +00:00
brain
8aa7f73bd7
Changed channel user lists from vector to map
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2780 e03df62e-2008-0410-955e-edbf42e46eb7
2006-01-12 20:14:43 +00:00
brain
fb99e9eaa2
Fixing move of *_channel functions to here
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2423 e03df62e-2008-0410-955e-edbf42e46eb7
2005-12-14 17:10:40 +00:00
brain
4aa2252476
Moved add_channel, del_channel, kick_channel to channels.cpp
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2422 e03df62e-2008-0410-955e-edbf42e46eb7
2005-12-14 17:07:47 +00:00
brain
4e9f3d1692
Added parameters
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@1522 e03df62e-2008-0410-955e-edbf42e46eb7
2005-05-25 22:01:10 +00:00
brain
55bd1494b0
Removed __single_client_alloc again because gcc devs were smoking crack and removed it
...
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@1406 e03df62e-2008-0410-955e-edbf42e46eb7
2005-05-16 11:31:58 +00:00
brain
ab01aaeeee
Changed to use __single_client_alloc, faster on most systems in a single thread
...
Specified namespace std in *all* files
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@1404 e03df62e-2008-0410-955e-edbf42e46eb7
2005-05-15 22:58:24 +00:00