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.

Request script for private commands

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
Z
ZzozZ
Voice
Posts: 10
Joined: Sat Nov 13, 2010 6:42 pm

Request script for private commands

Post by ZzozZ »

Can any write script for private commands.
I mean weh i write msg to my bot !op <user>, then my bot give @ on that user.

i dont want all users see ho control the bot.
T
Torrevado
Op
Posts: 101
Joined: Wed Aug 02, 2006 6:29 pm

Post by Torrevado »

Some tcl scripts already do that. Search on TCL Archive

Example: this one can do it both pub or msg.
Z
ZzozZ
Voice
Posts: 10
Joined: Sat Nov 13, 2010 6:42 pm

Post by ZzozZ »

thanx, but i need code. i want to edit and write my commands, not only op, deop and etc.

i need just one ecxample how can i do that
User avatar
TCL_no_TK
Owner
Posts: 509
Joined: Fri Aug 25, 2006 7:05 pm
Location: England, Yorkshire

Post by TCL_no_TK »

@ZzozZ: would this be a set channel? if someone is sending /msg <YourBot> !op <nickname> we would be able to op the <nickname> all of eggdrop's channel that <nickname> is on. but if you want to do it to a specific channel that would be little easyer. or have them provide a channel.
w
willyw
Revered One
Posts: 1205
Joined: Thu Jan 15, 2009 12:55 am

Re: Request script for private commands

Post by willyw »

ZzozZ wrote: ...

i dont want all users see ho control the bot.
The easiest, simplest way to do this, is to log into your bot via either DCC or telnet, and issue the command(s) there... in the partyline.

http://www.egghelp.org/commands/irc.htm#op
w
willyw
Revered One
Posts: 1205
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

ZzozZ wrote:thanx, but i need code. i want to edit and write my commands, not only op, deop and etc.

i need just one ecxample how can i do that
Here is an example.

It does not include anything extra. Typically, one might like to check to be sure the bot itself is op'd, ... that the user nick submitted to be op'd is even on the channel, etc.

This script works on only one channel, and you set that channel in the script.

The command is:
/msg botnick !op <nick>
and as it is written below, will only work for bot owner(s).

Code: Select all


#set your channel here
set mychan "#channelname"

bind msg n "!op" give_op


proc give_op {nick uhost handle text} {
global mychan

set nick_to_op "[lindex [split $text] 0]"

pushmode $mychan +o $nick_to_op

}


Some excellent reference to read and bookmark:

http://www.eggheads.org/support/egghtml ... mands.html

http://suninet.the-demon.de/

http://www.tcl.tk/man/tcl8.5/TclCmd/contents.htm

I hope this helps.


Suggestion: Give it a try. :) write some TCL scripts, .. experiment and have fun with them. You can post them here (in the Scripting Help section) , if and when you need help with them.
Post Reply