AutoHotkey Community

It is currently May 26th, 2012, 9:17 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Interacting with Flash
PostPosted: July 19th, 2008, 8:33 pm 
Hi, I'm having problems with my .ahk files. I've been messing around with automating flash games, and so far it's been working wonderfully! However, I've only been using SendInput clicks and things like that.

Now, I want to be able to input Up and Right. The typical 'SendInput {Up}' doesn't work on the Flash game where I want it to get received, and clicks are also pointless.

If I could figure this out, my program will actually look wonderfully simple. Something like this is what I have so far, and it's just painful to think I can't have it just loop up and right for me:

[list]
F1::
MsgBox Bot started
Loop
{
if GetKeyState("F2", "1")
{
MsgBox, 0, Paused, Bot paused.
break
}
SendInput {Up} ;these are the ones refusing to work in Flash.
SentInput {Right}

}
return


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: July 19th, 2008, 8:35 pm 
Sorry for the typos too lol

Thanks :D


Report this post
Top
  
Reply with quote  
PostPosted: July 19th, 2008, 9:19 pm 
ScionOfWar wrote:
The typical 'SendInput {Up}'...

...SendInput is not "typical"...it's a faster/more optimized way to send, after everything's already working...when trying to get a Flash game to respond to keys I would use Send 1st & if that works change it to SendInput, then if that don't work, go back to Send...also you need to make sure the Flash game has focus 1st (click it) or nothing will work...manually click the Flash game, then try both of these...

Code:
F1::
Send, {Up}
Send, {Right}
return

F2::
s=319
Send, {Up down}
Sleep, %s%
Send, {Up up}
Send, {Right down}
Sleep, %s%
Send, {Right up}
return

...lower 319 until it don't work (try 219, 119, 19), then raise it again...


Report this post
Top
  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: BrandonHotkey, fusion1920, MSN [Bot], poserpro, tomoe_uehara, Yahoo [Bot] and 63 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group