53 Commits

Author SHA1 Message Date
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
594d430ee4 More prefixchar stuff.
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-23 21:09:49 +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
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
0771566143 Explain what ModeParser does
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4907 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-12 01:19:25 +00:00
brain
66098d307c (Bigger than it looks, i did this with perl inplace edit) -- commands now 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-11 00:15:07 +00:00
brain
f9636a2eff So much stuff changed in this one, i forgot most of it.
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-10 22:40:57 +00:00
brain
e51a4b5c29 Move InsertMode into ModeParser
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4849 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-10 18:43:15 +00:00
brain
c6934754b0 Dynamically generate 004 numeric from the modehandler list
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4665 e03df62e-2008-0410-955e-edbf42e46eb7
2006-08-03 11:17:03 +00:00
brain
dc8f5d02f7 Add support for syntax of commands in place of the text 'Not enough 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-28 00:13:41 +00:00
brain
a1f073f66f Change std::pair<bool,std::string> to neater typedef "ModePair"
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4557 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-27 19:40:47 +00:00
brain
98a92e20f1 Mode merging during FJOIN with ourts==theirts. Only +k and +l have 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-27 17:59:20 +00:00
brain
feb7185050 commit remainder of new mode bouncing stuff for TS based modes
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4550 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-27 02:33:00 +00:00
brain
f4d202cdbb Add extra method to mode handler, ModeHandler::ModeSet().
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-26 21:54:36 +00:00
brain
0757a4a495 mass tidyup, change A LOT of stuff to const char** which was char** (such as 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-16 12:18:29 +00:00
brain
62b550f653 Inherit tons of stuff from classbase that should always have been
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4298 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-10 18:54:25 +00:00
brain
3dacf1edd2 Made a load more stuff Extensible which might be of use to someone
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4293 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-10 18:22:16 +00:00
brain
db75baa96d Added ModeParser::AddModeWatcher() and ModeParser::DelModeWatcher()
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4266 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-10 12:46:03 +00:00
brain
b4cbd36f1c Finally finished documenting new mode parser. Lots of comments.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4242 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-09 19:22:04 +00:00
brain
793d2364d9 Convert u_listmode and m_banexception to new api
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4189 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-08 20:57:24 +00:00
brain
5bbea4813d Added DisplayCurrentModes which will display the modes of a channel or nick
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4181 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-08 18:22:34 +00:00
brain
33ed72a1df Refactored user modes to work like the channel modes - core and module data 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-08 17:44:16 +00:00
brain
d40e1e5b0b Added usermodes +swi.
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-08 17:04:18 +00:00
brain
2f32d64790 Add cmode +o (op/deop) and in the process change a lot of char* to const char* to avoid unneccessary casts
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4165 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-08 15:05:33 +00:00
brain
fd411d067c ModeHandler documented
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4161 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-08 01:22:46 +00:00
brain
2fd5ed7aa9 Started work on ModeParser::CleanMask()
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4145 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07 21:03:00 +00:00
brain
53e8c67c58 Comments
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4144 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07 20:50:25 +00:00
brain
8f9d0a68cd Mode +b stuff, probably wont work yet
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4133 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07 17:37:20 +00:00
brain
7666e1ad84 Aaaand, correct all the obligitary typos
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4129 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07 15:29:42 +00:00
brain
a1af610ac1 Added masking stuff.
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-07 15:27:05 +00:00
brain
ace3781303 Mode parser WORKS! (for simple non-parameterized channel modes)
Tested with channel mode +s.


git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4126 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07 15:04:36 +00:00
brain
2d05d8bc33 Header for cmode_s.cpp
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4124 e03df62e-2008-0410-955e-edbf42e46eb7
2006-07-07 14:31:05 +00:00
brain
129416e519 Typedef an ugly iterator, dont send mode string if no modes were in the output sequence
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3867 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-10 20:43:03 +00:00
brain
3c272bcc1f More fixes
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3863 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-10 12:45:40 +00:00
brain
4dd8228ede Extra allowance for modes which have different number of params when being 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-10 12:11:00 +00:00
brain
b01e94da8f Start of new mode parser
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3857 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-10 11:50:48 +00:00
brain
87f5ef38db Om's way is better and lets watchers change mode parameters for the modes theyre watching
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3856 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-09 20:50:12 +00:00
brain
772d6f16c0 Start of mode parser refactoring
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3855 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-09 20:40:47 +00:00
om
c8cf429f7b Undo me screwing stuff up
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3797 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-02 18:25:11 +00:00
om
0a6ee7c4af Add amd64/linux to list of OS'es tested, but mainly CIA test :P
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3796 e03df62e-2008-0410-955e-edbf42e46eb7
2006-04-02 18:13:21 +00:00
brain
23101be0f2 UM_WALLOPS had value 3 which was a combination of UM_SERVERNOTICE and UM_INVISIBLE :/
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3591 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-09 14:18:33 +00:00
brain
c330b24501 Added userrec::modebits - fast way of checking if user has +swi rather than an icky strchr
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3588 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-09 13:21:35 +00:00
brain
02359de340 Tidied up give/take methods
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3482 e03df62e-2008-0410-955e-edbf42e46eb7
2006-03-06 01:51:11 +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
293df6a8b5 Split all commands into seperate files and redid command system to take classes, not function pointers (function pointers suck ass)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2534 e03df62e-2008-0410-955e-edbf42e46eb7
2005-12-16 18:10:38 +00:00
brain
3d433bc7b0 GROK!
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2521 e03df62e-2008-0410-955e-edbf42e46eb7
2005-12-16 11:32:57 +00:00
brain
ddb4ad9ce4 Moved mode stuff into modeparser
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2520 e03df62e-2008-0410-955e-edbf42e46eb7
2005-12-16 11:21:22 +00:00
brain
945466193b Tidied up inspircd.h
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2421 e03df62e-2008-0410-955e-edbf42e46eb7
2005-12-14 16:48:12 +00:00
brain
3eea190b73 Test change to verify security settings on brainbox allow me to commit to cvs
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@831 e03df62e-2008-0410-955e-edbf42e46eb7
2004-05-28 19:20:03 +00:00