Jump to content

Help Me If You Don't Mind :p


Recommended Posts

ok in a game I play I want to be able tell the script the game is running, and I want to bind space bar to

alt-f4 so when I tap on the spacebar I quickly log out, so It would look something like this please

running("game")

and if game is not running message box pops up saying ("game not found")

bind/space_pressed = alt-f4

this will help in my game alot because I don't want to die and lose gold.

Thanks in advance

Thanks in advance
Link to comment
Share on other sites

Hi,

try this :

; When it is a browser game then check for the window instead of the game.exe or take the broswer.exe

If ProcessExists("game.exe") Then
    HotKeySet("{Space}", "close")
Else
    MsgBox(64, "Info", "The game isn´t running!")
    Exit(0)
EndIf

Func Close()
    Send("!{F4}")
EndFunc

While 1
    Sleep(100)
WEnd

So long,

Mega

Edited by th.meger

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Link to comment
Share on other sites

Hi,

try this :

; When it is a browser game then check for the window instead of the game.exe or take the broswer.exe

If ProcessExists("game.exe") Then
    HotKeySet("{Space}", "close")
Else
    MsgBox(64, "Info", "The game isn´t running!")
    Exit(0)
EndIf

Func Close()
    Send("!{F4}")
EndFunc

While 1
    Sleep(100)
WEnd

So long,

Mega

wow I love how you got it set up, but when Im in the game I hit the script and It says im not in the game, and I gave it the right location to. Ill keep screwing with it for now. :) hmm im still new but I wonder if I used WinExists instead of ProcessExists would it make a differents, because WinExists Checks to see if a specified window exists. Well ProcessExists Checks to see if a specified process exists, It doesn't sound like it would make a differents but ill try. HOLY SHIT lol I was correct thanks Mega you have gave me a great start. hehe I don't lose gold now Thanks again.

Edited by Evil_Has_Survived
Thanks in advance
Link to comment
Share on other sites

wow I love how you got it set up, but when Im in the game I hit the script and It says im not in the game, and I gave it the right location to. Ill keep screwing with it for now. :) hmm im still new but I wonder if I used WinExists instead of ProcessExists would it make a differents, because WinExists Checks to see if a specified window exists. Well ProcessExists Checks to see if a specified process exists, It doesn't sound like it would make a differents but ill try. HOLY SHIT lol I was correct thanks Mega you have gave me a great start. hehe I don't lose gold now Thanks again.

HI,

there is a difference. WinExists is for windows and ProcessExists for processes. What is it for a game? Browser or has it got a exe that you can see in the taskmanager?

For getting the correct WindowsTitle take the " Autoit Window Info "and have a look at Opt("WinTitleMatchMode", X)

So long,

Mega

Edited by th.meger

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Link to comment
Share on other sites

HI,

there is a difference. WinExists is for windows and ProcessExists for processes. What is it for a game? Browser or has it got a exe that you can see in the taskmanager?

For getting the correct WindowsTitle take the " Autoit Window Info "and have a look at Opt("WinTitleMatchMode", X)

So long,

Mega

Thanks I got it working it was a WinExists

Thanks in advance
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...