This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Invite to a private channel

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
B
BigToe
Halfop
Posts: 99
Joined: Thu Dec 30, 2010 4:49 pm

Invite to a private channel

Post by BigToe »

hi, looking for a script that when you publicly type in a channel !invite <nickname>

The script will run the following commands:

1. /msg Q chanlev #channel nickname +aok
2. invite the nickname to #channel via an Invite command
3. /msg nickname Hi nickname, you were invited to join #channel by inviting-nickname.


Thank you in advance
User avatar
caesar
Mint Rubber
Posts: 3778
Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory

Post by caesar »

Code: Select all

bind pub o|o !invite chan:invite

proc chan:invite {nick uhosh hand chan text} {
	if {[scan $text {%s} member] != 1} {
		puthelp "NOTICE $nick :Error, syntax is: !invite <member>"
		return
	}
	puthelp "PRIVMSG Q :chanlev #channel $member +aok"
	puthelp "INVITE #channel $member"
	puthelp "PRIVMSG $member :Hi $member, you were invited to join #channel by $nick."
}
Be sure to change the flags that can use the command to whatever suits your needs and put in the actual channel instead of #channel.
Once the game is over, the king and the pawn go back in the same box.
B
BigToe
Halfop
Posts: 99
Joined: Thu Dec 30, 2010 4:49 pm

Post by BigToe »

Thanks, the script works great!
Post Reply