Sign in to follow this  
Followers 0
SYther

[Help]Making A Script

14 posts in this topic

ok, obvisoually I am new to this, and I want to start scripting / making bots.

what I want to try and make would be an Auto Trainer.

What I would like it to do is...

1. It would look at colours and pick the monster I want it too.

2. It would Right click on the monster and leave it for around 10 seconds, to finish fighting.

3. It would look at MP and HP and when it is BELOW 70- It would keypress Z or X ( Z - HP ) ( X - MP )

4. It would repeat this process, until stopped.

I would like it if you guys would help me MAKE my FIRST script. ! :)

I don't wanna seem like a begger, would just like the help, thank you..

Share this post


Link to post
Share on other sites



Because I cannot find the edit button... :)

what I would want to know is,

If I where to find my monster by Colour, how would I find this colour, what command/code would I write in to make sure it detects it. - what would I type in to make it Right click the monster and detect I have finished combat, -Ready to move on to my next target.

IF I where to find out my HP and MP, how would I go by doing this, how would I check to see if its below 70, how would I then Keystroke the Letter on the keyboard to restore this.?

my apologise if there is a edit button, I did not see it.

Share this post


Link to post
Share on other sites

You need to look up the following commands in the helpfile...

PixelGetColor

MouseClick

Send

and all types of loops (for, while, etc.)

when you've familiarized yourself with those you can move onto more advanced stuff like memory reading.


[font="Impact"] I always thought dogs laid eggs, and I learned something today. [/font]

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

(Pixel Get Colour)

( this is Ideal because on the game, the hp & mp bars are in the top Left =] )

; Find a pure red pixel or a red pixel within 10 shades variations of pure red

$coord = PixelSearch( 0, 0, 20, 300, 0xFF0000, 10 )

If Not @error Then

MsgBox(0, "X and Y are:", $coord[0] & "," & $coord[1])

EndIf

(MouseClick)

; Double click at 0,500

MouseClick("Right", 0, 500, 1

(Send)

Send("z")

Send("x")

(For...To...Step...Next)

For $i = 5 to 1 Step -1

MsgBox(0, "Count down!", $i)

Next

MsgBox(0,"", "Blast Off!")

Ok, I have read them through twice, and I choosed. For...To...Step...Next, for my Loop, tell me if this is correct loop?

which will worrys me I wont be able to make this script from scratch, due to I am beginner, thank you for your reply,

hope you reply back.

please tell me now what I have to do, in order to learn more :)

Edited by SYther

Share this post


Link to post
Share on other sites

Any chance I could recieve some help :) :)

Share this post


Link to post
Share on other sites

could anyone give me a site then, how I could learn the commands on learning them and scripting with AutoIt?

I know about the helpfile and yes I have used it, what I am looking for would be an example of the script that I am looking at, and how I will use it.

Thankyou.

Share this post


Link to post
Share on other sites

Do a search for Runescape, I know there have been many a bot made for that game.

It should give you some good ideas.

Also check out Autoit123 and the PDF in the following thread for learning more about Autoit

http://www.autoitscript.com/forum/index.ph...4&hl=script


[u]Helpful tips:[/u]If you want better answers to your questions, take the time to reproduce your issue in a small "stand alone" example script whenever possible. Also, make sure you tell us 1) what you tried, 2) what you expected to happen, and 3) what happened instead.[u]Useful links:[/u]BrettF's update to LxP's "How to AutoIt" pdfValuater's Autoit 1-2-3 Download page for the latest versions of Autoit and SciTE[quote]<glyph> For example - if you came in here asking "how do I use a jackhammer" we might ask "why do you need to use a jackhammer"<glyph> If the answer to the latter question is "to knock my grandmother's head off to let out the evil spirits that gave her cancer", then maybe the problem is actually unrelated to jackhammers[/quote]

Share this post


Link to post
Share on other sites

thank you for the reply,

would anyone like to help me over msn, because I type in this..

Run ( 'Thang Global' )

start it, and it errors... ALREADY that is my first lmao. if anyone would like to leave their msn or pm me it,

I would be very thankful =]

Share this post


Link to post
Share on other sites

any help than please?

Share this post


Link to post
Share on other sites

the problem is when you pixelsearch, it doesnt return the position of the pixel found, it will only tell you its found it

and if your planning to search and entire screen, that will take alot of cpu power.

What is the game.

Share this post


Link to post
Share on other sites

my first few lines was...

; This will run ThangOnline.

Run ( 'ThangOnline' )

and that didnt even work. :)

The game is... Thang Online - Site is. ; http://thang.ongameport.com/

thank you for your reply.

Share this post


Link to post
Share on other sites

I have to go to school now, so I will have to speak to you later, ill be back in around... 6 hours. later

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0