pieater112 Posted June 17, 2008 Share Posted June 17, 2008 ok so i play this game called Twelve Sky and i cant play to much so im trying to write out this simple looting and grinding bot... so here's the script that i came up with so far WinWaitActive ("12Sky"); While 1 = 1 $i = 0 While $1 <= 10 $move= Random(1, 100, 1) If $Move < 50 Send ("{RIGHT down}") Sleep (500) Send ("0x17") Sleep (500) Send ("e") Sleep (1000) Send ("{RIGHT up}") Else Send ("{LEFT down}") Sleep (500) Send ("0x17") Sleep (500) Send ("e") Sleep (1000) Send ("{LEFT up}") EndIf $i = $i + 1 WEnd Send ("{HOME}") the problem is when i try run it in game an error comes up saying that "the If command (the 5th line) must have a Then after it." So i add Then infront of the If command but then it says that "Else cannot function without an If command" any help improving this script will be appreciated my other question is that i use ASCII as my scripting and the problem is that Twelve Sky uses F1-8 as your primary attack and buffering skills and as i look through the ASCII charts i cant find any sort of code for F1-8.... so are 0x17-28 the code for F1-12? Time to Ride or Die Eye for Eye Link to comment Share on other sites More sharing options...
Levenson Posted June 17, 2008 Share Posted June 17, 2008 (edited) Look into the manual at the Statement Reference IfConditionally run statements. If <expression> Then statements ... [ElseIf expression-n Then [elseif statements ... ]] ... [Else [else statements] ... EndIf2: Send("{F1}"); Send("{F2}"); Edited June 17, 2008 by Levenson Link to comment Share on other sites More sharing options...
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