Sign in to follow this  
Followers 0
AntiBNI

Having trouble on Closing an active window.

3 posts in this topic

ok heres my code

Case $PM = 6
If PixelGetColor (122,591)=305140 Then
WinClose ("Nomad of Silver Spirit - Nostale")
EndIf
EndSelect
Select
    Case $talk = 6
If PixelGetColor (122,591)=16382457 Then
WinClose ("Nomad of Silver Spirit - Nostale","")
EndIf
EndSelect

well its just the part that dosent work.

aniways the thing is that i want the Bot to when some one Whispers me (Private Messege) the bot Closes the Game in this case Nomad of Silver Spirit - Nostale.

It aint closing the window,i dont know why but its not closing it. :P

Thanks in Advice.

Cheers,

Anti

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

ok heres my code

Case $PM = 6
 If PixelGetColor (122,591)=305140 Then
 WinClose ("Nomad of Silver Spirit - Nostale")
 EndIf
 EndSelect
 Select
     Case $talk = 6
 If PixelGetColor (122,591)=16382457 Then
 WinClose ("Nomad of Silver Spirit - Nostale","")
 EndIf
 EndSelect

well its just the part that dosent work.

aniways the thing is that i want the Bot to when some one Whispers me (Private Messege) the bot Closes the Game in this case Nomad of Silver Spirit - Nostale.

It aint closing the window,i dont know why but its not closing it. :P

Thanks in Advice.

Cheers,

Anti

try using Opt in ur code.

Opt("WinTitleMatchMode", 2)

Just a guess though. Also u can try using AutoItInfo.exe to see what info it shows for your window. Another debuging trick that I use is to put a message box in the part of the code that you think doesn't work and see what it shows you. Like set up message box to show u a return error for WinClose and see why it doesn't close.

Edited by sheckandar

Live and Learn, 'cause Knowledge is Super Power.

Share this post


Link to post
Share on other sites

Also, some games are not closing easily. ProcessClose is another option.

Share this post


Link to post
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
Sign in to follow this  
Followers 0