Zompy Posted January 14, 2009 Posted January 14, 2009 Hey, some of you might know wc3, warcraft 3, well i want to make a single play bot for that, but im wondering how i can make some kind of script for that, sometimes your at the place up, smetimes down, so always making a building at one coordinate doesnt work... Im completely noob I did make some little scripts though.
azure Posted January 14, 2009 Posted January 14, 2009 Hey, some of you might know wc3, warcraft 3, well i want to make a single play bot for that, but im wondering how i can make some kind of script for that, sometimes your at the place up, smetimes down, so always making a building at one coordinate doesnt work... Im completely noob I did make some little scripts though.Yeessh... good luck. I recommend doing some forum searches first. Gamebots aren't exactly easy, especially for a real time strategy game that manipulates resources and makes concious decisions about what needs to do what! Isn't there a product available out there for this already?
Zompy Posted January 14, 2009 Author Posted January 14, 2009 Well, i dont want a used program, maybe to learn from, but nothing more, ill search the forum, could you gie me some more info? Thanks for your help
L3G3NdKillEr Posted January 14, 2009 Posted January 14, 2009 Have a look On Valuater's Game Bot Builder.. http://www.autoitscript.com/forum/index.ph...;hl=Bot+Builder i'm very responsible, when ever something goes wrong they always say I'm responsible.Life is like an Adventure... BUT COOL GRAPHICS<====================----=LEGEND KILLER=----=========================>
Fend Posted January 14, 2009 Posted January 14, 2009 The first step to bot writing in Autoit ofcourse would be to have a general understanding of Autoit. Understand how variables are used, control structure like while loops, arrays. After this I would spend sometime writing a simple script using the pixel functions...like pixelsearch. Write a scrpit that does something, could be to make something move left or right if a certain pixel changes colors. After you have made a little working script, redesign, rewrite untill you have a good idea of the mechanics. From here you could scrap pixel searches and directly work with memory, nomadmemory.au3 is a wonderfull tool for botmakers. There are a lot of posts on this site devoted to memory manipulation. These are a few steps you could follow to start working on your bot. On a side note, I would think that botmaking for a strategy game would be more difficult that other types of games. I would spend a good amount of time working out what you want it to do and under what circumstances the bot should do this or that. I like cookies?
Zompy Posted January 15, 2009 Author Posted January 15, 2009 Im busy on another project, but i need your help guys, i cannot figure out how to insert a second thing, like when i type moz it will do something else, help! ; Prompt the user to run the script - use a Yes/No prompt (4 - see help file) $answer = MsgBox(4, "AutoIt Example (English Only)", "Opening the leader project. Run?") ; Check the user's answer to the prompt (see the help file for MsgBox return values) ; If "No" was clicked (7) then exit the script If $answer = 7 Then MsgBox(4096, "AutoIt", "OK. Bye!") Exit EndIf ; Loop around until the user gives a valid "autoit" answer $bLoop = 1 While $bLoop = 1 $text = InputBox("AutoIt Example", "Please enter the program you want to run") If @error = 1 Then MsgBox(4096, "Error", "You pressed 'Cancel' - try again!") Else ; They clicked OK, but did they type the right thing? If $text <> "TFTB" Then MsgBox(4096, "Error", "You typed in the wrong thing - try again!") Else Run the TFT script, removed due size $bLoop = 0 ; Exit the loop - ExitLoop would have been an alternative too :) EndIf EndIf WEnd ; Print the success message MsgBox(4096,"AutoIt Example", "You typed in the correct word! Congrats.") ; Finished!
azure Posted January 15, 2009 Posted January 15, 2009 Im busy on another project, but i need your help guys, i cannot figure out how to insert a second thing, like when i type moz it will do something else, help! ; Prompt the user to run the script - use a Yes/No prompt (4 - see help file) $answer = MsgBox(4, "AutoIt Example (English Only)", "Opening the leader project. Run?") ; Check the user's answer to the prompt (see the help file for MsgBox return values) ; If "No" was clicked (7) then exit the script If $answer = 7 Then MsgBox(4096, "AutoIt", "OK. Bye!") Exit EndIf ; Loop around until the user gives a valid "autoit" answer $bLoop = 1 While $bLoop = 1 $text = InputBox("AutoIt Example", "Please enter the program you want to run") If @error = 1 Then MsgBox(4096, "Error", "You pressed 'Cancel' - try again!") Else ; They clicked OK, but did they type the right thing? If $text <> "TFTB" Then MsgBox(4096, "Error", "You typed in the wrong thing - try again!") Else Run the TFT script, removed due size $bLoop = 0 ; Exit the loop - ExitLoop would have been an alternative too :) EndIf EndIf WEnd ; Print the success message MsgBox(4096,"AutoIt Example", "You typed in the correct word! Congrats.") ; Finished! Like this? ; Prompt the user to run the script - use a Yes/No prompt (4 - see help file) $answer = MsgBox(4, "AutoIt Example (English Only)", "Opening the leader project. Run?") ; Check the user's answer to the prompt (see the help file for MsgBox return values) ; If "No" was clicked (7) then exit the script If $answer = 7 Then MsgBox(4096, "AutoIt", "OK. Bye!") Exit EndIf ; Loop around until the user gives a valid "autoit" answer $bLoop = 1 While $bLoop = 1 $text = InputBox("AutoIt Example", "Please enter the program you want to run") If @error = 1 Then MsgBox(4096, "Error", "You pressed 'Cancel' - try again!") Else ; They clicked OK, but did they type the right thing? Select Case $text = "TFTB" ;Run the TFT Script, removed due to size $bLoop = 0 ; Exit the loop - ExitLoop would have been an alternative too :) Case $text = "MOZ" ;Do Something Else! $bLoop = 0 ; Exit the loop - ExitLoop would have been an alternative too :) Case Else MsgBox(4096, "Error", "You typed in the wrong thing - try again!") EndSelect EndIf WEnd ; Print the success message MsgBox(4096,"AutoIt Example", "You typed in the correct word! Congrats.") ; Finished!
Zompy Posted January 15, 2009 Author Posted January 15, 2009 Oh, i gonna test that out right now! ill post later!
Zompy Posted January 15, 2009 Author Posted January 15, 2009 (edited) It works! Thanks so much edit: how to mkae random delays? Edited January 15, 2009 by Zompy
azure Posted January 15, 2009 Posted January 15, 2009 It works! Thanks so much edit: how to mkae random delays? Please keep in the forum unless I ask you to PM me. Using the random function. Sleep(Random(10,100,1)*10)
Zompy Posted January 15, 2009 Author Posted January 15, 2009 Alright, im sorry, i don't understand that code, what is the delay in here? why the *10?
azure Posted January 15, 2009 Posted January 15, 2009 Alright, im sorry, i don't understand that code, what is the delay in here? why the *10?Use the help file please.
azure Posted January 15, 2009 Posted January 15, 2009 Cant find it...Can't find what? The help file?Start, Programs, AutoIt v3, autoIt Help FileOr "C:\Program Files\AutoIt3\AutoIt.chm"
Zompy Posted January 15, 2009 Author Posted January 15, 2009 I cant find it IN the help file, well, i figured out how it works now
azure Posted January 15, 2009 Posted January 15, 2009 I cant find it IN the help file, well, i figured out how it works now SciTE has context sensitive help.If you type Sleep(100) and put your mouse on the word "sleep" hit F1 and your help file should open with details on that command.
Zompy Posted January 16, 2009 Author Posted January 16, 2009 Ok thanks, ill focuz os somthing with pixels now, trying to find out how it works
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now