Set both +o and +a on first user join

If your UnrealIRCd is up and running but you have a question about it, then use this forum.
(NOT for installation or connecting issues! Use the other forum instead.)

Moderator: Supporters

Posts: 1
Joined: Sun Jul 08, 2018 2:44 am

Set both +o and +a on first user join

Post by exceptionall.null » Sun Jul 08, 2018 2:49 am

I would like to use the setting set::level-on-join "protect" but this causes an issue with anope services which requires a user to be a channel op to register.

Is there a way to set mode +oa on a user when they join rather than just +a?

Posts: 12
Joined: Sun Aug 05, 2018 2:51 pm

Re: Set both +o and +a on first user join

Post by Amiga00 » Thu Aug 09, 2018 9:54 am

Yes well I think maybe multiple options could be set in the level-on-join, such as say "owner,protect,op,halfop" for example, then it would set the modes specified on the user when they join, certainly would be a good addition.

So in this case, for example, you would type: level-on-join "protect,op";
Amiga600 @ #unreal-support

UnrealIRCd coder
Posts: 189
Joined: Fri Aug 19, 2016 5:26 pm
Location: NL

Re: Set both +o and +a on first user join

Post by Gottem » Sun Aug 12, 2018 10:13 pm

^ Lies. :D

Code: Select all

else if (!strcmp(cep->ce_varname, "level-on-join")) {
	char *p;
	CheckDuplicate(cep, level_on_join, "level-on-join");
	if (!channellevel_to_int(cep->ce_vardata))
		config_error("%s:%i: set::level-on-join: unknown value '%s', should be one of: none, voice, halfop, op, protect, owner",
			cep->ce_fileptr->cf_filename, cep->ce_varlinenum, cep->ce_vardata);
Notice the should be one of; channellevel_to_int() needs an exact match on either of those values (none, voice, etc). Should probably just ask Syzop to implement support for multiple flags. ;]
If you like my modules, pls consider donating (through PayPal) or use the custom job fee option in my shop if you want to donate with credit card or iDEAL ;];]