NaturesFlame Posted September 16, 2007 Share Posted September 16, 2007 all in all, I'm not a huge fan of scripting games, but each person is free to do as they wish that being said however, I've been playing a game called Sword of the New World , and one of the most wonderful things about this game is that you can just set it up, put your characters in a certain place, and they'll pretty much level themselves. However, they won't pick up the loots. Looting is simple enough, you hold control and shift, click, and your characters (you can control up to 3 at a time) will go to where you click, picking up all the loot as they go along. I wrote up a script to do exactly that, and it works perfectly fine outside the game while its running, however, when I bring the game up it immediately stops working. If I alt-tab out the script starts working perfectly fine again. I was wondering if anyone had a solution to this dilemma, because while I am leveling up quite nicely, I'm quite poor from the lack of loot pick up. Just for reference, I'll post the script: expandcollapse popupHotKeySet("{ESC}", "Terminate") Sleep(5000) Loot() Func Terminate() Exit 0 EndFunc Func Loot() While 1 MouseMove(747, 327, 0) Send("{CTRLDOWN}") Send("{SHIFTDOWN}") MouseClick("left") Send("{SHIFTUP}") Send("{CTRLUP}") Sleep(5000) MouseMove(24, 433, 0) Send("{CTRLDOWN}") Send("{SHIFTDOWN}") MouseClick("left") Send("{SHIFTUP}") Send("{CTRLUP}") Sleep(5000) MouseMove(474, 519, 0) Send("{CTRLDOWN}") Send("{SHIFTDOWN}") MouseClick("left") Send("{SHIFTUP}") Send("{CTRLUP}") Sleep(30000) WEnd EndFunc Link to comment Share on other sites More sharing options...
NaturesFlame Posted September 16, 2007 Author Share Posted September 16, 2007 I forgot to mention, it uses X-Trap Game Security, if that helps Link to comment Share on other sites More sharing options...
aslani Posted September 17, 2007 Share Posted September 17, 2007 You need to specify the window where you want to run your script on. Ref. WinActive() and WinActivate() [font="Georgia"]Chances are, I'm wrong.[/font]HotKey trouble?Stringregexp GuideAutoIT Current Version 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