What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » Code

Code
Author: Message:
Jonte135
Junior Member
**


Posts: 57
– / – / Flag
Joined: Aug 2007
O.P. Code
Earlier I posted a thread about the same thing and got help, but it was going a little off-topic and if I would continue on that thread it would be like: "Okay done with code." "Could you add..." etc.

Basically what I need is a code that I easily can copy-paste to repeat the same thing over and over. It's a bot script, so I want to be able to do so I can add different types of things it should react on...

Explanation: I will have X amounts of files (2 mostly). One file should be the file that the code should react on that includes 1 or more words separated with enter. If one of the words in the file is "Hello" and I tell the code to react on "Hello" it should answer randomly from another file. So in the "answering file" it could be, separated with enter, these words: "Hey", "Hi", "Hello", "How are you" etc etc. But it should not be case sensitive or what's it's called, so it could be like "hEllo" or even in a sentence: "I would like to say hello to you" or "Hello how are you?" Also, I would want the code to be made so I can that it should react on 2 or more files. Like this: "if (file [bunch of code /me noob] = "hello" ||/&& if (another file [code...] = "you" then [more code]. It should be this when it replies too please :P (So like if ([code.] = "hello") then [reply with [...] ||/&& I hope you understand.

As I said earlier I should be able to just copy-paste this code so I can jsut edit the files and have the same "function" over and over. I'm sorry if this is a "do it for me" code but I am a noob when it comes to scripting and the fun part for me is just to edit code...

Thanks a ton! :)

This post was edited on 11-29-2008 at 04:58 PM by Jonte135.
11-29-2008 04:53 PM
Profile E-Mail PM Find Quote Report
ArkaneArkade
Full Member
***

Avatar
The One and Only

Posts: 193
Reputation: 5
38 / Male / Flag
Joined: Mar 2007
RE: Code
quote:
Originally posted by Jonte135
I am a noob when it comes to scripting and the fun part for me is just to edit code...
The fun part should be learning.
Anyway, to be a bit more serious, I'm not entirely sure what it is you're meaning.  Could be just me, but would you be able to give a small example of the [code...] in these files (feel free to pm if theres a lot).
I'll do what I can, but I'll make no promises, since I'm not the fountain of knowledge on this.
[Image: adsig.jpg]
11-29-2008 05:39 PM
Profile E-Mail PM Web Find Quote Report
Jonte135
Junior Member
**


Posts: 57
– / – / Flag
Joined: Aug 2007
O.P. RE: RE: Code
quote:
Originally posted by Leroux
quote:
Originally posted by Jonte135
I am a noob when it comes to scripting and the fun part for me is just to edit code...
The fun part should be learning.
Anyway, to be a bit more serious, I'm not entirely sure what it is you're meaning.  Could be just me, but would you be able to give a small example of the [code...] in these files (feel free to pm if theres a lot).
I'll do what I can, but I'll make no promises, since I'm not the fountain of knowledge on this.
The thing is that that there is no code :P It's just an example of what I was meaning. See it like this:

First there is the if statement, and [code. (dot else function on forum)] is just code that opens the file, reads it, gets the word and close the file. And ye the fun part is to learn too, but I like to learn by editing if you understand.
11-29-2008 05:45 PM
Profile E-Mail PM Find Quote Report
matty
Scripting Guru
*****


Posts: 8336
Reputation: 109
39 / Male / Flag
Joined: Dec 2002
Status: Away
RE: Code
Why not take previous scripts and try and adapt them to what you want. You wont learn if someone just gives you the code.
11-29-2008 06:03 PM
Profile E-Mail PM Find Quote Report
Jonte135
Junior Member
**


Posts: 57
– / – / Flag
Joined: Aug 2007
O.P. RE: RE: Code
quote:
Originally posted by matty
Why not take previous scripts and try and adapt them to what you want. You wont learn if someone just gives you the code.
Because I'm a noob :(

EDIT: And ye basically because I'm not experienced enough and I already tried doing that a little, it didn't work :P

This post was edited on 11-29-2008 at 09:51 PM by Jonte135.
11-29-2008 06:43 PM
Profile E-Mail PM Find Quote Report
ArkaneArkade
Full Member
***

Avatar
The One and Only

Posts: 193
Reputation: 5
38 / Male / Flag
Joined: Mar 2007
RE: Code
Ok, I'm still a little unclear on what you mean.  I kinda agree with matty on editing other scripts... but in fairness I'm still new enough to know what you mean.

Are you talking about a simple bit of [code...].
eg
If someone says "Hey mate", you want to use "Hey", and search in a file for possibilities, eg readfile hey.txt which will give you a reply, such as "hello, yo, whassup", and then the "mate" which will check a second file to get a reply of "man, dude, pal", then stick them together, or are you looking for something more complicated?
[Image: adsig.jpg]
11-29-2008 11:03 PM
Profile E-Mail PM Web Find Quote Report
Jonte135
Junior Member
**


Posts: 57
– / – / Flag
Joined: Aug 2007
O.P. RE: RE: Code
quote:
Originally posted by Leroux
Ok, I'm still a little unclear on what you mean.  I kinda agree with matty on editing other scripts... but in fairness I'm still new enough to know what you mean.

Are you talking about a simple bit of [code...].
eg
If someone says "Hey mate", you want to use "Hey", and search in a file for possibilities, eg readfile hey.txt which will give you a reply, such as "hello, yo, whassup", and then the "mate" which will check a second file to get a reply of "man, dude, pal", then stick them together, or are you looking for something more complicated?
Kinda yes, but it should look for "Hey" in "Hey mate" from a file so "you" say anything else like hello it should react too. And I should be able to do like if "you" say hi AND something else it will react. And the AND or OR (||) thing should be easy to add or remove. Also it should be like this when I reply so it will reply "hello" + "pal" like you said etc.
11-30-2008 01:10 PM
Profile E-Mail PM Find Quote Report
« Next Oldest Return to Top Next Newest »


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On