Jump to content
Eliminator

Making a bot for the online game

Recommended Posts

Eliminator

Hi! I tried Auto-IT 3 to make a bot for one online game that collects EXP points (Basic rules - your character walks and encountering the random battles, battle is turn based, then you get EXP for winning the encounter).

First, i used Visual Basic 6 but i dont know how to simulate pressing arrow buttons...

I used the ScriptWriter but it executes all comands too fast and character is failing to encounter enemies.

Its possible to make AutoIT know if the screen already changed to battle screen?

Share this post


Link to post
Share on other sites
Eliminator

OK i have another problem.

1)Game client often crashes. How do i know if it was happen to relogin?

2)Sometimes there appears a blue screen that allows to add a new moves. How to tell my script to click the "proceed" button?

thanks for advice.

Share this post


Link to post
Share on other sites
TerarinK

ahhh, a new person who needs help.

For number one, using a Adlib will guarntee that it will check that status or else you could implement another autoit script that just checks on that and when it crashes send data to halt everything and relogin. However most games don't play like that and it is simple check for one things that the window has and if not there continue, easiest way of them all.

Number two would check the proceed button on a check on pixels, else slep for about 10 - 250 mmsec.

Just one thing what game is it, where is it, can we all play it?


0x576520616C6C206469652C206C697665206C69666520617320696620796F75207765726520696E20746865206C617374207365636F6E642E

Share this post


Link to post
Share on other sites
Andreik

What game is it?


When the words fail... music speaks

Share this post


Link to post
Share on other sites
myxomatosii

How about playing the game as it was intended?

Oh thats no fun! Haha, for those of us with the time and fortitude, we ARE playing. We just accelerate our response time through way of advanced interfacing. :P

Part (sometimes all) of the game for me is just creating a tool to master it. :unsure:

Edited by myxomatosii

Share this post


Link to post
Share on other sites
Eliminator

Im intresting not so much to play this game so making a bot for it.

At this moment my bot :

Launches a game

Enters username and password stored in ini file

Do a login to game

Walk around

Kill monsters (i check if game is in the battle mode by checking 2 pixels of battle window :P )

BUT

i have one problem...

I dont know how to realise without GOTOs this events:

If game crashed then we wait for 10 seconds and run it again, enter login password and pressing enter to login.

If nothing happens for 1 minute (server is full or other error) then turn game client off and run it again.

Share this post


Link to post
Share on other sites
BrianCJ

Ive found that with writing bots for games, you can do a TON with pixelsearch

$pos = PixelSearch(70,58,165,76,0x00CD00, 10, 2)
    if @error then
    ; do whatever action if the color isnt found
        sleep (10000); wait 10 seconds
        LogIn()
    Else
    ; whatever you want to do if the color is found 
    EndIf

Func LogIn()
; Enter LogIn information
; Press the enter button

; look for some color that is only on the log-in screen
While $x < 10
$pos = PixelSearch(70,58,165,76,0x00CD00, 10, 2)
    if @error then
    ; do whatever action if the color isnt found, wait 1 miniute
        sleep (6000)
        $x = $x+1
    Else
        PlayGame() 
    EndIf
Wend
Restart()
EndFunc


func PlayGame()
; this is where you put in what you want the game to do
endfunc

func Restart()
; this is where you put the code to restart the game
endfunc

Share this post


Link to post
Share on other sites
Bert

Oh thats no fun! Haha, for those of us with the time and fortitude, we ARE playing. We just accelerate our response time through way of advanced interfacing. :P

Part (sometimes all) of the game for me is just creating a tool to master it. :unsure:

In other word, you cheat.

Share this post


Link to post
Share on other sites
Gondus

In other word, you cheat.

So your saying, in ALL the time you have scripted in autoit you have NEVER made a bot for a game...

If this was the truth i would be VERY amazed.


-----------Current Programming Language Status:Beginner: J#, Ruby Intermediate: Autoit, Java, C#, C++Advanced: Basic, Visual Basic, Fortran

Share this post


Link to post
Share on other sites
Inverted

So your saying, in ALL the time you have scripted in autoit you have NEVER made a bot for a game...

If this was the truth i would be VERY amazed.

You know, some people program serious stuff and not button-clicking shit for online gridfests.

It may seem strange to you, I know, but take my word for it.

Now act amazed :P

Edited by Inverted

Share this post


Link to post
Share on other sites
Eliminator

BrianCJ Hey i dont knew that we can use functions! So i can make logging in and battle mode as a function! :P

Yep this is a cheating. But cheating is fun sometimes.

Share this post


Link to post
Share on other sites
DeSwa

You cant make bot on Autoit. you must use vb.net or C++

Share this post


Link to post
Share on other sites
Eliminator

DeSwa but it works. Bot written on autoit script. language. Now i planning to add a log to it :P

Share this post


Link to post
Share on other sites
JLogan3o13

@Moaz did you not notice this thread is over 7 years old? It is also against the forum rules. Please familiarize yourself with those rules before you post again, and please do not resurrect old threads.


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

×