Sponsored Links


Page 1 of 2 1 2 >
Topic Options
Rate This Topic
#2269 - 06/21/08 12:35 PM Make a bot respond to a command?
RyanBecker Online   content
newbie

Registered: 06/21/08
Posts: 27
Loc: South Carolina
I am new to WyldRyde and am still setting up my IRC channel. I do have one bot in my room, AMD. I was wondering, when someone sends a trigger like !rules, can i make a bot respond with an answer. Please excuse me if I sound like a n0ob.
_________________________
Tomorrow's Forecast:
Sunni In Places, Shi'ite In Others.

Click Here To Go To My Forum!

Top
Sponsored Links
Sponsored Links
Member
*****

Registered: 27/08/04
Posts: 10136
Loc: Mountain View, CA
Top
#2271 - 06/21/08 02:09 PM Re: Make a bot respond to a command? [Re: RyanBecker]
jwire4 Offline
newbie

Registered: 03/18/08
Posts: 41
Loc: Califotnia
Yes you can! And it is very simple! If AMD is on mirc then you are already halfway there! If not, download a program called mirc (IRC Client for windows) then all you have to do is go into the remote scripting (alt +r) and then you just input lines of codes (scripts) that your bot does. For example !rules might look like:

on :text:!rules:#chatroom: {
if (($calc(($ctime- %lastupdatetime)) >= 15) || (!%lastupdatetime)) {
set %lastupdatetime $ctime
/msg $chan Your Rules go here
}
}

Replace #chatroom with #yourchatroom.
The second line is talking about lastupdate time. It is set to 15 seconds. That means i f someone types !rules 2 times in 15 seconds it will only announce it one. SO after that you have a neutral time of 15 seconds. If someone types !rules before that 15 seconds is up it will not respond. Make sense? you can probably just set that to "0"
Replace "your rules here" to whatever you want the bot to repsond to when someone types !rules

From here it gets even more easy you can edit that script to do different triggers.

Hope this help's you. I myself was one a n00b and still I am to a lot of things.
When you master this type of script you can get more into !winner and !topic. If you have any questions feel free to wing by my room #rtvchatroom.
_________________________
<witty comment here>

Top
#2272 - 06/21/08 02:12 PM Re: Make a bot respond to a command? [Re: jwire4]
Karol Offline
newbie

Registered: 01/05/08
Posts: 27
Loc: Connecticut
What jwire4 said was right, but if you want the direct link of how to do it, please go here, which usrbingeek posted: http://www.wyldryde.org/forum/ubbthreads.php/topics/259/Triggers_like_rules.html#Post259 Good luck smile

Karol
_________________________
Join #karol ! Growing everyday!

Top
#2274 - 06/21/08 02:50 PM Re: Make a bot respond to a command? [Re: Karol]
RyanBecker Online   content
newbie

Registered: 06/21/08
Posts: 27
Loc: South Carolina
OK, I am having some troubles, or you didn't comprehend me right. The bot AMD is not a bot that I host. It is one provided by WyldRyde. Also, I do not have my own server. It is a WyldRyde server. It does not work. If you want to check it out, my channel is #ryanbecker. I should be there for a while. If this wont work on a WyldRyde bot, can you help me set up one? Also, I do have another script in my remotes file. Thanks.


Edited by RyanBecker (06/21/08 02:54 PM)
Edit Reason: Added some info to the end.
_________________________
Tomorrow's Forecast:
Sunni In Places, Shi'ite In Others.

Click Here To Go To My Forum!

Top
#2276 - 06/21/08 10:07 PM Re: Make a bot respond to a command? [Re: RyanBecker]
jwire4 Offline
newbie

Registered: 03/18/08
Posts: 41
Loc: Califotnia
OK, WyldRyde bots will not run triggers. WyldRyde bots primarily act like a big brother. They sit there and kick people for flooding,bad words,whatever you configure it to do. However they don not run triggers. To find a bot to run triggers, you need to install an IRC Client called "mIRC" There you can go into the remote tab, and enter the script I inputed earlier.
_________________________
<witty comment here>

Top
#2278 - 06/22/08 10:26 AM Re: Make a bot respond to a command? [Re: jwire4]
RyanBecker Online   content
newbie

Registered: 06/21/08
Posts: 27
Loc: South Carolina
Are you saying that I have to host a bot if I want the script to work? If I do, could someone help me set it up in my computer? Thanks.
_________________________
Tomorrow's Forecast:
Sunni In Places, Shi'ite In Others.

Click Here To Go To My Forum!

Top
#2279 - 06/22/08 10:54 AM Re: Make a bot respond to a command? [Re: RyanBecker]
boredcollegekid Offline
newbie

Registered: 12/19/07
Posts: 42
Loc: Tulsa, OK
to run a basic bot that will respond to commands you can simply run a second instance of mIRC on your current PC. Just download mIRC (www.mirc.com) install it, and when you have it running hit alt+r to bring up the scripts editor and put the code provided into the remotes tab (usually the one opened by default)
_________________________

Top
#2280 - 06/22/08 11:55 AM Re: Make a bot respond to a command? [Re: boredcollegekid]
jwire4 Offline
newbie

Registered: 03/18/08
Posts: 41
Loc: Califotnia
All you have to do is download mirc. Then follow these steps:

1.Open mirc
The first window you see os a window you will get every time input:Full name,email address,nickname (Whatever you want bot nick to be) alternative nick (nick available if bot nick pings out

2. Under "Connect" go to "servers" click the "ADD" button For Description put whatever (WyldRyde would be the best)

For IRC Server: Put your IRC server (you can find your IRC Server at http://www.wyldryde.org/servers , eg. IRC.WyldRyde.org)
Don't worry about group.If your nick is registered, put that password box.

click add

Now find WyldRyde or whatever you named the description on the IRC Servers list.
Click select

Now you have everything ready to go
Go back to connect and click connect

You will be logged into WyldRyde but, in no room (yet)
You need to type this in: /join #ryanbecker (or whatever chatroom)
You can do this command in anychatroom to join another. you want the bot to be in)

Now for scripts

Go up to the top of mirc where you see all these little icons. Click the one that is like a paper witha little green star by it click it (or wuicker while incide mirc hit alt +r) You are now in the mirc script editor. Make sure you are in the Remote Tab.

Here you can enter in any mirc script you want. This is how your rules would be

on :text:!rules:#ryanbecker: {
if (($calc(($ctime- %lastupdatetime)) >= 1) || (!%lastupdatetime)) {
set %lastupdatetime $ctime
/msg $chan Your Rules go here
}
}

Enter this in under the remote tab and edit Your rules go here to whatever you want them to be.
You can copy this script as many times as you want to make more. They will look like this:

on :text:!rules:#ryanbecker: {
if (($calc(($ctime- %lastupdatetime)) >= 1) || (!%lastupdatetime)) {
set %lastupdatetime $ctime
/msg $chan Your Rules go here
}
}
on :text:what is cam:#ryanbecker: {
if (($calc(($ctime- %lastupdatetime)) >= 1) || (!%lastupdatetime)) {
set %lastupdatetime $ctime
/msg $chan I am using a logitech webcam
}
}

It is very simple and as easy as copy past and edit. Now THIS COPY OF MIRC IS FOR YOUR BOT ONLY!

What this means is that the bot nick is just a nick sitting on an IRC server doing nothing. When you add scipts, it does something. It runs off of triggers. So this copy of mirc is just for the bot. If you want another mirc to use for you, download another copy. When you go into "your" copy of mirc. Make sure the remote tab in scripts editor is blank.

That is simply it! Basicly yes, you are hosting this bot. If you wanted to alk to someone about a diffrent kind of bot that runs triggers, a php bot, talk to Phil.

***Learning the mirc language is really easy! Study the scripts and then try making your own. You can be surprised how advanced this bot can become with the right scripts :)***

_________________________
<witty comment here>

Top
#2284 - 06/23/08 01:07 PM Re: Make a bot respond to a command? [Re: jwire4]
RyanBecker Online   content
newbie

Registered: 06/21/08
Posts: 27
Loc: South Carolina
Alright, still messed up. I had it working for a while, and then it crashed. It was not responding. It was logged in to the same room as it should be. However, this may be a problem. I want to be in the same copy of mIRC as my bot. I have the bot's nickname set as preferred, and mine set as alternate. When mIRC opens, the bot joins. If I want to join, I type this command "//server -m IRC.WyldRyde.org 6667" That opens a connection in a new windows. WyldRyde reports that the nickname CommandBot is in use, and mIRC switches to mine. I then connect to my room by doing a "/join #ryanbecker" I have been trying to do the triggers from my account, in the same copy of mIRC. Is that why it is not showing up? Also, I want to have a !help trigger, but my WyldRyde bot takes over. I have to use a different one. Any help would be great. I should be in my room, #ryanbecker, all day. Thanks!
_________________________
Tomorrow's Forecast:
Sunni In Places, Shi'ite In Others.

Click Here To Go To My Forum!

Top
#2286 - 06/23/08 01:17 PM Re: Make a bot respond to a command? [Re: RyanBecker]
jwire4 Offline
newbie

Registered: 03/18/08
Posts: 41
Loc: Califotnia
I see your problem. Unfortunately the way mirc runs bots runs now you have to have 1 dedicated copy of mirc just for your bot. This is because it will get the nicks screwed up as well. Also if you are running on the same copy as mirc as your bot and you type a command like !rules it will not respond because again, that copy of mirc is dedicated to a nick that runs on the server running off triggers. It won't respond to it's own question. Make sense? If you want to chat in mirc just download another copy of mirc for yourself. Shouldn't be any problems there smile As for the !help command I'm not sure. Try turning fantasy mode off. Ask in #help
_________________________
<witty comment here>

Top
#2305 - 06/24/08 10:58 PM Re: Make a bot respond to a command? [Re: jwire4]
RyanBecker Online   content
newbie

Registered: 06/21/08
Posts: 27
Loc: South Carolina
Ok, I have that all sorted out and am still working on programming everything. However, there is one command I would like to add that the current script will not do. When someone types !time, I want the bot to show my current time in the syntax "Ryan's Current Time Is <time>" where <time> is my current time. This is sort of like the !time feature that Pixie uses in #chris. If someone could help me, that would be great.

P.S., as for the !help command, I just use !chanhelp.
_________________________
Tomorrow's Forecast:
Sunni In Places, Shi'ite In Others.

Click Here To Go To My Forum!

Top
#2306 - 06/24/08 11:04 PM Re: Make a bot respond to a command? [Re: RyanBecker]
dave Offline
n00b

Registered: 04/07/08
Posts: 17
Loc: canada
ok so to do that the script will look like

on :text:!time:#chatroom: {
if (($calc(($ctime- %lastupdatetime)) >= 0) || (!%lastupdatetime)) {
set %lastupdatetime $ctime
/msg $chan Ryan's Current Time Is $time
}
}

change #chatroom to your chat room name
~easy_way
_________________________
O is for on the dark side, beacouse we have some fresh cookies. (COOKIES)
WOO!

Top
#2307 - 06/25/08 12:18 AM Re: Make a bot respond to a command? [Re: dave]
RyanBecker Online   content
newbie

Registered: 06/21/08
Posts: 27
Loc: South Carolina
Works great, thanks. I do have another script like that that makes my bot respond to a command. I wasn't sure what value you modify or what value to put in. Thanks again.
_________________________
Tomorrow's Forecast:
Sunni In Places, Shi'ite In Others.

Click Here To Go To My Forum!

Top
#2308 - 06/25/08 12:26 AM Re: Make a bot respond to a command? [Re: RyanBecker]
Scoobs8 Offline
n00b

Registered: 02/02/08
Posts: 1
Loc: Mobile, AL - USA
It depends on what the command is, and what you want it to do. But the basic script to make a bot message something to a channel when you type !command would be this:

on :text:!command:#yourchatroomnamegoeshere: {
msg $chan Command has been executed!
}

Let me know if you would like to be more specific.

I suggest you read the mIRC scripting help file by typing the following in mIRC:

/help on text
/help $chan

-Scoobs8
-WyldRyde Groupie

Top
#2309 - 06/25/08 12:49 AM Re: Make a bot respond to a command? [Re: Scoobs8]
RyanBecker Online   content
newbie

Registered: 06/21/08
Posts: 27
Loc: South Carolina
Scoobs8, I don't need you butting in right now. I get perfect help from jwire4 and the other people that have been helping me. I think you posted that because you just wanted to get a post. I already have a more complicated script that works better than your piece of junk. Besides, it has a complicated variable in it. Just lay off and don't post in this topic.
_________________________
Tomorrow's Forecast:
Sunni In Places, Shi'ite In Others.

Click Here To Go To My Forum!

Top
#2314 - 06/25/08 03:08 PM Re: Make a bot respond to a command? [Re: RyanBecker]
usrbingeek Administrator Offline
WyldRyde Staff

Registered: 07/31/06
Posts: 426
Loc: Burlington, VT
RyanBecker, there is no need to be rude. Scoobs is just trying to be helpful and his post might be of benefit to others even if it's not beneficial for you.
_________________________
WyldRyde IRC Network
Steve Mermelstein
Root Admin

#!/usr/bin/geek
My Amazon.com Wishlist

Please no PMs. Please post to a topic instead so your question(s) may benefit others.

Top
#2645 - 07/18/08 01:00 AM Re: Make a bot respond to a command? [Re: usrbingeek]
RyanBecker Online   content
newbie

Registered: 06/21/08
Posts: 27
Loc: South Carolina
Can someone lock this topic please? I don't need it open anymore. Thanks.
_________________________
Tomorrow's Forecast:
Sunni In Places, Shi'ite In Others.

Click Here To Go To My Forum!

Top
#2652 - 07/18/08 03:46 PM Re: Make a bot respond to a command? [Re: jwire4]
RyanBecker Online   content
newbie

Registered: 06/21/08
Posts: 27
Loc: South Carolina
How do you make it so that when a certain nick joins the channel, a bot says something?
_________________________
Tomorrow's Forecast:
Sunni In Places, Shi'ite In Others.

Click Here To Go To My Forum!

Top
#2653 - 07/18/08 05:10 PM Re: Make a bot respond to a command? [Re: RyanBecker]
iBook Offline
n00b

Registered: 06/01/08
Posts: 5
Loc: Kokomo,Indiana,USA
if you want it to happen in any channel, use this,
on *:JOIN:#:{if ($nick == <the-nick-goes-here>) { /msg $chan <text-to-say-when-owner-joins> | halt }}
if not use this,
on *:JOIN:#<channel-you-want-it-to-say-it-in>:{ if ($nick == <the-nick-goes-here>) { /msg #<channel-used-earlier> <text-to-say-when-owner-joins> | halt }}

Top
Page 1 of 2 1 2 >


Recent Posts
!add !edIT !del for a mIRC bot
by Jerry
Yesterday at 06:41 PM
Kat
by techman224
08/18/08 10:11 PM
Hello #turtles People....
by techman224
08/18/08 10:06 PM
Looking for Half-ops and Ops for #techman
by techman224
08/18/08 09:57 PM
New Advertising Channel #advertising.
by techman224
08/18/08 09:43 PM
Rules for Voiced (+v) users in #Chris
by Bloomedis
08/15/08 04:12 AM
Chris Thanks
by iPhone
08/15/08 03:52 AM
Who ownes Wyldryde?
by techman224
08/14/08 09:10 AM
Spamming and other general notes...
by Zetacon
08/14/08 01:48 AM
New game on Wyldryde.
by techman224
08/13/08 09:36 PM
Flash Chat and strange 'flashing' display
by techman224
08/13/08 06:51 PM
Unable to view user profiles?
by boredcollegekid
08/12/08 06:24 PM
Recent Pics
Old school IRC
How to use Google!
TIX
Who's Online
0 Registered (), 5 Guests and 12 Spiders online.
Key: Admin, Global Mod, Mod
Top Posters
usrbingeek 426
Kat 228
iPhone 86
Phil 86
Freekie 77
CCMike 63
Justin 59
wirelesspacket 51
KY_Wildcat 48
tengrrl 46
Terms Of Use
Use of this community signifies your agreement to the Terms Of Service and Conditions of Use.