summaryrefslogtreecommitdiff
path: root/include/mode.h
AgeCommit message (Collapse)Author
2007-01-03Fix lusers breakage introduced by latest set of optimizationsbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6219 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-29This doesnt need to be staticbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6164 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-29Add counter system for umodes to get rid of some O(n)brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6163 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-15And now, just to force you to recompile the *whole* ircd.. updated headers ↵w00t
on the headers. :p git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5998 e03df62e-2008-0410-955e-edbf42e46eb7
2006-09-09Make SAMODE oper output tidierbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5184 e03df62e-2008-0410-955e-edbf42e46eb7
2006-09-03Add /RELOAD and move cmd_mode into its own command.brain
/RELOAD is the only thing you cant reload (ahem) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5119 e03df62e-2008-0410-955e-edbf42e46eb7
2006-09-02Allow unloading of modules which implement modes!brain
The default implementation of the new system will remove simplemodes so any mode handler which is just a simple mode (no params and not a list mode) does not need to add much more than one line of code and remove its VF_STATIC flag. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5100 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-31*thwap* om for not fixing the bugs he finds :pbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5087 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-30Remove a ton of <typeinfo>, <iostream>, <sstream> etc that we usually never usebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5081 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-25Add <options:cyclehosts> which allows a user to appear to have quit when ↵brain
their host changes, so that clients/bots can stay synched properly. It is recommended this option always be on. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5017 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-23ModeParser::InsertMode is no longer required -- this is auto-generated by ↵brain
the ModeParser based on what modes are registered and wether or not they have certain attributes git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5007 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-23Document ModeParser::FindPrefix() and chanrec::GetAllPrefixes()brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5006 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-23Multi-prefix FJOIN, and allowing module-defined prefixes across the networkbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5002 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-23More prefixchar stuff.brain
WARNING: 005 numeric is broken in this commit. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5000 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-23Document mode prefixesbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4999 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-23Mode handlers handling listmodes where a listmode item is a nickname can now ↵brain
specify prefixes!!!!!! This isnt documented yet. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4997 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-12Explain what ModeParser doesbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4907 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-11(Bigger than it looks, i did this with perl inplace edit) -- commands now ↵brain
take an InspIRCd* param to their constructor, so that you can do stuff within them without an extern git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4862 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-10So much stuff changed in this one, i forgot most of it.brain
Oh yeah, main thing is ModeHandler and ModeWatcher classes now take an InspIRCd* to their constructor git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4858 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-10Move InsertMode into ModeParserbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4849 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-03Dynamically generate 004 numeric from the modehandler listbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4665 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-28Add support for syntax of commands in place of the text 'Not enough ↵brain
parameters' in numeric 461, where supported. To support this each derived class of command_t must set the value of command_t::syntax to a non-empty string. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4561 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-27Change std::pair<bool,std::string> to neater typedef "ModePair"brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4557 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-27Mode merging during FJOIN with ourts==theirts. Only +k and +l have ↵brain
CheckTimestamp methods atm, needs to be finished by me and TIDIED. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4556 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-27commit remainder of new mode bouncing stuff for TS based modesbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4550 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-26Add extra method to mode handler, ModeHandler::ModeSet().brain
Returns a std::pair<bool,string>. if the bool is true, the mode is set, and the second item in the pair is the parameter set on it, if any If the bool is false, the mode is not set, and the parameter given is returned as the second item of the pair To be used in mode bouncing, to build a safe set of bounced modes (dont ask yet) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4549 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-16mass tidyup, change A LOT of stuff to const char** which was char** (such as ↵brain
parameters to commands in handlers) which makes the new lineparser work neater with no casts. This also removes tons of casts from other locations (all in all, ive added 2 casts and removed almost a hundred) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4403 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-10Inherit tons of stuff from classbase that should always have beenbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4298 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-10Made a load more stuff Extensible which might be of use to someonebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4293 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-10Added ModeParser::AddModeWatcher() and ModeParser::DelModeWatcher()brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4266 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-09Finally finished documenting new mode parser. Lots of comments.brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4242 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-08Convert u_listmode and m_banexception to new apibrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4189 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-08Added DisplayCurrentModes which will display the modes of a channel or nickbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4181 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-08Refactored user modes to work like the channel modes - core and module data ↵brain
now the same storage format without ::modebits git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4175 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-08Added usermodes +swi.brain
Note the usermode system needs a bit of a refactor to combine module and core modes into the same storage neatly (as we did with channels) this is next on my todo. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4174 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-08Add cmode +o (op/deop) and in the process change a lot of char* to const ↵brain
char* to avoid unneccessary casts git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4165 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-08ModeHandler documentedbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4161 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07Started work on ModeParser::CleanMask()brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4145 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07Commentsbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4144 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07Mode +b stuff, probably wont work yetbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4133 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07Aaaand, correct all the obligitary typosbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4129 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07Added masking stuff.brain
Basically, so that we can hold user modes and channel modes in the same list, we use bitwise masking. We have a list of handlers, 256 in size 0 through 255, and to work out where a mode handler is dependent on WHAT it is, we use this simple hashing algorithm (no collisions can occur): (modeletter - 65) | mask Where mask is 128 (10000000b) if its a user mode, or 0 (00000000b, duh) if its a channel mode. Smart, and much faster than using a map of pairs. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4128 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07Mode parser WORKS! (for simple non-parameterized channel modes)brain
Tested with channel mode +s. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4126 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07Header for cmode_s.cppbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4124 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-10Typedef an ugly iterator, dont send mode string if no modes were in the ↵brain
output sequence git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3867 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-10More fixesbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3863 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-10Extra allowance for modes which have different number of params when being ↵brain
set to being unset (read as: jro smoking craq) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3858 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-10Start of new mode parserbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3857 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-09Om's way is better and lets watchers change mode parameters for the modes ↵brain
theyre watching git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3856 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-09Start of mode parser refactoringbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3855 e03df62e-2008-0410-955e-edbf42e46eb7