Jump to content

Need some bot help!


Recommended Posts

Hello,

Im trying to create a bot, but the _Red() func wont work.

I need this:

If INSERT is pressed _All() should be activted. _All() Will activate _Red() _Blue() _Purple() and _Green() (Will come). But if I press INSERT, and _Red() is activated, it wont stop giving the MsgBox().

Can someone test it, and tell me whats wrong?

#include <GUIConstants.au3>

Opt("GUICloseOnEsc", 1)
Opt("PixelCoordMode", 2)

Global $Red = 0, $Blue = 0, $Purple = 0, $Green = 0

HotKeySet("{INSERT}", "_All")
HotKeySet("{HOME}", "_Off")

$oGame = ObjCreate("ShockwaveFlash.ShockwaveFlash.1")
$GUI = GUICreate("Super Crazy Guitar Maniac Dexuxe 3", 734 + 20, 414 + 20, -1, -1)
$GUIObj = GUICtrlCreateObj($oGame, 10, 10, 734, 414)

With $oGame
    .bgcolor = 0x000000
    .Movie = "http://www.notdoppler.com/files/supercrazyguitarmaniacdeluxe3.swf"
    .Loop = True
    .wmode = "Opaque"
EndWith

GUISetState()
While 1
    $nMsg = GUIGetMsg()
    Select
    Case $nMsg = $GUI_EVENT_CLOSE ; -3
        Exit
    EndSelect
WEnd

Func _All()
    MsgBox(64, "Status", "Status: On")
    _Red()
EndFunc

Func _Red()
    While 2
        If PixelSearch(345, 234, 377, 272, 0x990000) = True Then
            MsgBox(0, "Test", "Test")
        EndIf
    WEnd
EndFunc

Func _Off()
    Global $Red = 0, $Blue = 0, $Purple = 0, $Green = 0
EndFunc

-AlmarM-

Minesweeper

A minesweeper game created in autoit, source available.

_Mouse_UDF

An UDF for registering functions to mouse events, made in pure autoit.

2D Hitbox Editor

A 2D hitbox editor for quick creation of 2D sphere and rectangle hitboxes.

Link to comment
Share on other sites

Well when you get in your function _Red() then it will never end this function and return because it got stucked in your while loop.

It just checking the pixelsearch over and over again and if it's true then it shows a message box.

You need to create something like if it's true then ... else exitloop..

Regards

Link to comment
Share on other sites

So like this?

#include <GUIConstants.au3>

Opt("GUICloseOnEsc", 1)
Opt("PixelCoordMode", 2)

Global $Red = 0, $Blue = 0, $Purple = 0, $Green = 0

HotKeySet("{INSERT}", "_All")
HotKeySet("{HOME}", "_Off")

$oGame = ObjCreate("ShockwaveFlash.ShockwaveFlash.1")
$GUI = GUICreate("Super Crazy Guitar Maniac Dexuxe 3", 734 + 20, 414 + 20, -1, -1)
$GUIObj = GUICtrlCreateObj($oGame, 10, 10, 734, 414)

With $oGame
    .bgcolor = 0x000000
    .Movie = "http://www.notdoppler.com/files/supercrazyguitarmaniacdeluxe3.swf"
    .Loop = True
    .wmode = "Opaque"
EndWith

GUISetState()
While 1
    $nMsg = GUIGetMsg()
    Select
    Case $nMsg = $GUI_EVENT_CLOSE ; -3
        Exit
    EndSelect
WEnd

Func _All()
    MsgBox(64, "Status", "Status: On")
    _Red()
EndFunc

Func _Red()
    While 2
        If PixelSearch(345, 234, 377, 272, 0x990000) = True Then
            MsgBox(0, "Test", "Test")
        Else
            ExitLoop
        EndIf 
    WEnd
EndFunc

Func _Off()
    Global $Red = 0, $Blue = 0, $Purple = 0, $Green = 0
EndFunc

Minesweeper

A minesweeper game created in autoit, source available.

_Mouse_UDF

An UDF for registering functions to mouse events, made in pure autoit.

2D Hitbox Editor

A 2D hitbox editor for quick creation of 2D sphere and rectangle hitboxes.

Link to comment
Share on other sites

Just try the script with Scite, itt will create a flash game. And when the RED arrows will come into the place where it need to be, the script need to Send UP arrow.

-AlmarM-

Minesweeper

A minesweeper game created in autoit, source available.

_Mouse_UDF

An UDF for registering functions to mouse events, made in pure autoit.

2D Hitbox Editor

A 2D hitbox editor for quick creation of 2D sphere and rectangle hitboxes.

Link to comment
Share on other sites

Just try the script with Scite, itt will create a flash game. And when the RED arrows will come into the place where it need to be, the script need to Send UP arrow.

-AlmarM-

Hello

I think this is what you need: :)

#include <GUIConstants.au3>

Opt("GUICloseOnEsc", 1)
Opt("PixelCoordMode", 0)

Global $red = 0x990000, $blue = 0x003366, $purple = 0x663366, $green = 0x006600, $black = 0x000000

HotKeySet("{F6}", "_On")
HotKeySet("{F7}", "_Off")
HotKeySet("{ESC}", "terminate")

$oGame = ObjCreate("ShockwaveFlash.ShockwaveFlash.1")
$GUI = GUICreate("Super Crazy Guitar Maniac Dexuxe 3", 734 + 20, 414 + 20, -1, -1)
$GUIObj = GUICtrlCreateObj($oGame, 10, 10, 734, 414)

With $oGame
    .bgcolor = 0x000000
    .Movie = "http://www.notdoppler.com/files/supercrazyguitarmaniacdeluxe3.swf"
    .Loop = True
    .wmode = "Opaque"
EndWith

GUISetState()
_Off()

Func _Off()

TrayTip("","",0)

While 1
    $nMsg = GUIGetMsg()
    Select
    Case $nMsg = $GUI_EVENT_CLOSE ; -3
        Exit
    EndSelect
WEnd

EndFunc ; _Off()


Func _On()
    
    TrayTip("Guitar Bot","The bot is working",25)
    
    While 1
        
        Select
                
            ; looking for up arrow (red)
            Case PixelGetColor(84,100) == $red
                While (PixelGetColor(84,100) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{UP down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{UP up}")
            ; looking for number 4
            Case PixelGetColor(84,100) <> $black And PixelSearch(64,98,102,102,$red) == 1
                While (PixelGetColor(84,100) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{4 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{4 up}")
            
            ; looking for right arrow (blue)
            Case PixelGetColor(84,151) == $blue
                While (PixelGetColor(84,151) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{RIGHT down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{RIGHT up}")
            ; looking for number 3
            Case PixelGetColor(84,151) <> $black And PixelSearch(64,149,102,153,$blue) == 1
                While (PixelGetColor(84,151) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{3 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{3 up}")
                
            ; looking for left arrow (purple)
            Case PixelGetColor(84,206) == $purple
                While (PixelGetColor(84,206) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{LEFT down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{LEFT up}")
            ; looking for number 2
            Case PixelGetColor(84,206) <> $black And PixelSearch(64,204,102,208,$purple) == 1
                While (PixelGetColor(84,206) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{2 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{2 up}")
                
            ; looking for down arrow (green)
            Case PixelGetColor(84,258) == $green
                While (PixelGetColor(84,258) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{DOWN down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{DOWN up}")
            ; looking for number 1
            Case PixelGetColor(84,258) <> $black And PixelSearch(64,256,102,260,$green) == 1
                While (PixelGetColor(84,258) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{1 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{1 up}")

        EndSelect
            
    WEnd
    
EndFunc ; _On()

Func terminate()
    Exit
EndFunc ; terminate()

I have only tested it on the first to songs, but there is works perfect.. Hope you enjoy it. and you're welcome to test it in the other songs also and please tell me if there is a bug.

Regards

EDIT: added a picture

post-24573-1213908026_thumb.gif

Edited by newbiescripter
Link to comment
Share on other sites

Hello

I think this is what you need: :)

#include <GUIConstants.au3>

Opt("GUICloseOnEsc", 1)
Opt("PixelCoordMode", 0)

Global $red = 0x990000, $blue = 0x003366, $purple = 0x663366, $green = 0x006600, $black = 0x000000

HotKeySet("{F6}", "_On")
HotKeySet("{F7}", "_Off")
HotKeySet("{ESC}", "terminate")

$oGame = ObjCreate("ShockwaveFlash.ShockwaveFlash.1")
$GUI = GUICreate("Super Crazy Guitar Maniac Dexuxe 3", 734 + 20, 414 + 20, -1, -1)
$GUIObj = GUICtrlCreateObj($oGame, 10, 10, 734, 414)

With $oGame
    .bgcolor = 0x000000
    .Movie = "http://www.notdoppler.com/files/supercrazyguitarmaniacdeluxe3.swf"
    .Loop = True
    .wmode = "Opaque"
EndWith

GUISetState()
_Off()

Func _Off()

TrayTip("","",0)

While 1
    $nMsg = GUIGetMsg()
    Select
    Case $nMsg = $GUI_EVENT_CLOSE ; -3
        Exit
    EndSelect
WEnd

EndFunc ; _Off()


Func _On()
    
    TrayTip("Guitar Bot","The bot is working",25)
    
    While 1
        
        Select
                
            ; looking for up arrow (red)
            Case PixelGetColor(84,100) == $red
                While (PixelGetColor(84,100) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{UP down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{UP up}")
            ; looking for number 4
            Case PixelGetColor(84,100) <> $black And PixelSearch(64,98,102,102,$red) == 1
                While (PixelGetColor(84,100) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{4 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{4 up}")
            
            ; looking for right arrow (blue)
            Case PixelGetColor(84,151) == $blue
                While (PixelGetColor(84,151) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{RIGHT down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{RIGHT up}")
            ; looking for number 3
            Case PixelGetColor(84,151) <> $black And PixelSearch(64,149,102,153,$blue) == 1
                While (PixelGetColor(84,151) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{3 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{3 up}")
                
            ; looking for left arrow (purple)
            Case PixelGetColor(84,206) == $purple
                While (PixelGetColor(84,206) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{LEFT down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{LEFT up}")
            ; looking for number 2
            Case PixelGetColor(84,206) <> $black And PixelSearch(64,204,102,208,$purple) == 1
                While (PixelGetColor(84,206) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{2 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{2 up}")
                
            ; looking for down arrow (green)
            Case PixelGetColor(84,258) == $green
                While (PixelGetColor(84,258) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{DOWN down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{DOWN up}")
            ; looking for number 1
            Case PixelGetColor(84,258) <> $black And PixelSearch(64,256,102,260,$green) == 1
                While (PixelGetColor(84,258) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{1 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{1 up}")

        EndSelect
            
    WEnd
    
EndFunc ; _On()

Func terminate()
    Exit
EndFunc ; terminate()

I have only tested it on the first to songs, but there is works perfect.. Hope you enjoy it. and you're welcome to test it in the other songs also and please tell me if there is a bug.

Regards

EDIT: added a picture

With your bot, for me, it missed every single note, this may be because I have a black windows XP theme. I will try with the original later.

EDIT: With the regular Windows XP theme, it still misses ever note.

Edited by JasonB
Link to comment
Share on other sites

With your bot, for me, it missed every single note, this may be because I have a black windows XP theme. I will try with the original later.

EDIT: With the regular Windows XP theme, it still misses ever note.

Maybe your computer is too slow or maybe it's because of the colors.. try to check the colors and see if there is the same on yours.

I'm running it on a 2.4ghz dual core.

Regards

EDIT: question: does it makes mistakes or doesn't it react at all?

Edited by newbiescripter
Link to comment
Share on other sites

Maybe your computer is too slow or maybe it's because of the colors.. try to check the colors and see if there is the same on yours.

I'm running it on a 2.4ghz dual core.

Regards

EDIT: question: does it makes mistakes or doesn't it react at all?

Edit1:colors are ok

Edit2:what rezolution you use...i use 1024 and bot don't do nothing...maybe the rezolution it's the answare:D

Edited by Kyme
Link to comment
Share on other sites

Edit1:colors are ok

Edit2:what rezolution you use...i use 1024 and bot don't do nothing...maybe the rezolution it's the answare:D

I use 1400x900 as my resolution.

But i'm not sure that is that since the coordinates I use is for the active window and not for the absolute screen.

Regards

Edited by newbiescripter
Link to comment
Share on other sites

I use 1400x900 as my resolution.

But i'm not sure that is that since the coordinates I use is for the active window and not for the absolute screen.

Regards

My resolution = 1280 x 1024

What would be the cordinats for that?

Minesweeper

A minesweeper game created in autoit, source available.

_Mouse_UDF

An UDF for registering functions to mouse events, made in pure autoit.

2D Hitbox Editor

A 2D hitbox editor for quick creation of 2D sphere and rectangle hitboxes.

Link to comment
Share on other sites

Maybe your computer is too slow or maybe it's because of the colors.. try to check the colors and see if there is the same on yours.

I'm running it on a 2.4ghz dual core.

Regards

EDIT: question: does it makes mistakes or doesn't it react at all?

In my post above ull see my Resolution, but for me it doenst react at all!

-AlmarM-

Minesweeper

A minesweeper game created in autoit, source available.

_Mouse_UDF

An UDF for registering functions to mouse events, made in pure autoit.

2D Hitbox Editor

A 2D hitbox editor for quick creation of 2D sphere and rectangle hitboxes.

Link to comment
Share on other sites

In my post above ull see my Resolution, but for me it doenst react at all!

-AlmarM-

It isn't because of the resolution I've now tested in in all almost all resolutions. maybe your CPU isn't fast enough or the colors on your com is a bit different?

try playing around with it.

and if someone knows why it doesn't work on others computer than mine, then please post the solutions or a surgestion to it.

regards

Link to comment
Share on other sites

It isn't because of the resolution I've now tested in in all almost all resolutions. maybe your CPU isn't fast enough or the colors on your com is a bit different?

try playing around with it.

and if someone knows why it doesn't work on others computer than mine, then please post the solutions or a surgestion to it.

regards

for me colors are ok....i check it out...i can set my monitor to 1400/900 only 1440/900:|

i think the problem it's rezolution...or other what can be???

cpu fast???....yeah....can be but low probability...i will test it on 2.55 duo core2 if it work but i don't believe to be that the way...see soon

Link to comment
Share on other sites

for me colors are ok....i check it out...i can set my monitor to 1400/900 only 1440/900:|

i think the problem it's rezolution...or other what can be???

cpu fast???....yeah....can be but low probability...i will test it on 2.55 duo core2 if it work but i don't believe to be that the way...see soon

My resolution is also 1440/900. 1400/900 was a typo.

I think it's maybe the sendcontrol command that makes the troubles since I had a little trouble by making the game detect it.

Try this and see if you get a traytip telling you what should be done.

then we find out if it detects the colors but doesn't send the message afterwoods.

#include <GUIConstants.au3>

Opt("GUICloseOnEsc", 1)
Opt("PixelCoordMode", 0)

Global $red = 0x990000, $blue = 0x003366, $purple = 0x663366, $green = 0x006600, $black = 0x000000

HotKeySet("{F6}", "_On")
HotKeySet("{F7}", "_Off")
HotKeySet("{ESC}", "terminate")

$oGame = ObjCreate("ShockwaveFlash.ShockwaveFlash.1")
$GUI = GUICreate("Super Crazy Guitar Maniac Dexuxe 3", 734 + 20, 414 + 20, -1, -1)
$GUIObj = GUICtrlCreateObj($oGame, 10, 10, 734, 414)

With $oGame
    .bgcolor = 0x000000
    .Movie = "http://www.notdoppler.com/files/supercrazyguitarmaniacdeluxe3.swf"
    .Loop = True
    .wmode = "Opaque"
EndWith

GUISetState()
_Off()

Func _Off()

TrayTip("","",0)

While 1
    $nMsg = GUIGetMsg()
    Select
    Case $nMsg = $GUI_EVENT_CLOSE ; -3
        Exit
    EndSelect
WEnd

EndFunc ; _Off()


Func _On()
    
    TrayTip("Guitar Bot","The bot is working",25)
    
    While 1
                
        Select
                
            ; looking for up arrow (red)
            Case PixelGetColor(84,100) == $red
                While (PixelGetColor(84,100) <> $black)
                    TrayTip("TEST","Press up arrow",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{UP down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{UP up}")
            ; looking for number 4
            Case PixelGetColor(84,100) <> $black And PixelSearch(64,98,102,102,$red) == 1
                While (PixelGetColor(84,100) <> $black)
                    TrayTip("TEST","Hold number 4 down",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{4 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{4 up}")
            
            ; looking for right arrow (blue)
            Case PixelGetColor(84,151) == $blue
                While (PixelGetColor(84,151) <> $black)
                    TrayTip("TEST","Press right arrow",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{RIGHT down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{RIGHT up}")
            ; looking for number 3
            Case PixelGetColor(84,151) <> $black And PixelSearch(64,149,102,153,$blue) == 1
                While (PixelGetColor(84,151) <> $black)
                    TrayTip("TEST","Hold number 3 down",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{3 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{3 up}")
                
            ; looking for left arrow (purple)
            Case PixelGetColor(84,206) == $purple
                While (PixelGetColor(84,206) <> $black)
                    TrayTip("TEST","Press left arrow",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{LEFT down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{LEFT up}")
            ; looking for number 2
            Case PixelGetColor(84,206) <> $black And PixelSearch(64,204,102,208,$purple) == 1
                While (PixelGetColor(84,206) <> $black)
                    TrayTip("TEST","Hold number 2 down",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{2 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{2 up}")
                
            ; looking for down arrow (green)
            Case PixelGetColor(84,258) == $green
                While (PixelGetColor(84,258) <> $black)
                    TrayTip("TEST","Press down arrow",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{DOWN down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{DOWN up}")
            ; looking for number 1
            Case PixelGetColor(84,258) <> $black And PixelSearch(64,256,102,260,$green) == 1
                While (PixelGetColor(84,258) <> $black)
                    TrayTip("TEST","Hold number 1 down",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{1 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{1 up}")

        EndSelect
        
    WEnd
    
EndFunc ; _On()

Func terminate()
    Exit
EndFunc ; terminate()
Link to comment
Share on other sites

My resolution is also 1440/900. 1400/900 was a typo.

I think it's maybe the sendcontrol command that makes the troubles since I had a little trouble by making the game detect it.

Try this and see if you get a traytip telling you what should be done.

then we find out if it detects the colors but doesn't send the message afterwoods.

#include <GUIConstants.au3>

Opt("GUICloseOnEsc", 1)
Opt("PixelCoordMode", 0)

Global $red = 0x990000, $blue = 0x003366, $purple = 0x663366, $green = 0x006600, $black = 0x000000

HotKeySet("{F6}", "_On")
HotKeySet("{F7}", "_Off")
HotKeySet("{ESC}", "terminate")

$oGame = ObjCreate("ShockwaveFlash.ShockwaveFlash.1")
$GUI = GUICreate("Super Crazy Guitar Maniac Dexuxe 3", 734 + 20, 414 + 20, -1, -1)
$GUIObj = GUICtrlCreateObj($oGame, 10, 10, 734, 414)

With $oGame
    .bgcolor = 0x000000
    .Movie = "http://www.notdoppler.com/files/supercrazyguitarmaniacdeluxe3.swf"
    .Loop = True
    .wmode = "Opaque"
EndWith

GUISetState()
_Off()

Func _Off()

TrayTip("","",0)

While 1
    $nMsg = GUIGetMsg()
    Select
    Case $nMsg = $GUI_EVENT_CLOSE ; -3
        Exit
    EndSelect
WEnd

EndFunc ; _Off()


Func _On()
    
    TrayTip("Guitar Bot","The bot is working",25)
    
    While 1
                
        Select
                
            ; looking for up arrow (red)
            Case PixelGetColor(84,100) == $red
                While (PixelGetColor(84,100) <> $black)
                    TrayTip("TEST","Press up arrow",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{UP down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{UP up}")
            ; looking for number 4
            Case PixelGetColor(84,100) <> $black And PixelSearch(64,98,102,102,$red) == 1
                While (PixelGetColor(84,100) <> $black)
                    TrayTip("TEST","Hold number 4 down",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{4 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{4 up}")
            
            ; looking for right arrow (blue)
            Case PixelGetColor(84,151) == $blue
                While (PixelGetColor(84,151) <> $black)
                    TrayTip("TEST","Press right arrow",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{RIGHT down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{RIGHT up}")
            ; looking for number 3
            Case PixelGetColor(84,151) <> $black And PixelSearch(64,149,102,153,$blue) == 1
                While (PixelGetColor(84,151) <> $black)
                    TrayTip("TEST","Hold number 3 down",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{3 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{3 up}")
                
            ; looking for left arrow (purple)
            Case PixelGetColor(84,206) == $purple
                While (PixelGetColor(84,206) <> $black)
                    TrayTip("TEST","Press left arrow",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{LEFT down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{LEFT up}")
            ; looking for number 2
            Case PixelGetColor(84,206) <> $black And PixelSearch(64,204,102,208,$purple) == 1
                While (PixelGetColor(84,206) <> $black)
                    TrayTip("TEST","Hold number 2 down",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{2 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{2 up}")
                
            ; looking for down arrow (green)
            Case PixelGetColor(84,258) == $green
                While (PixelGetColor(84,258) <> $black)
                    TrayTip("TEST","Press down arrow",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{DOWN down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{DOWN up}")
            ; looking for number 1
            Case PixelGetColor(84,258) <> $black And PixelSearch(64,256,102,260,$green) == 1
                While (PixelGetColor(84,258) <> $black)
                    TrayTip("TEST","Hold number 1 down",25)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{1 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",25370736,"{1 up}")

        EndSelect
        
    WEnd
    
EndFunc ; _On()

Func terminate()
    Exit
EndFunc ; terminate()
Ill try it now. Ill tell u soon!

Minesweeper

A minesweeper game created in autoit, source available.

_Mouse_UDF

An UDF for registering functions to mouse events, made in pure autoit.

2D Hitbox Editor

A 2D hitbox editor for quick creation of 2D sphere and rectangle hitboxes.

Link to comment
Share on other sites

It keeps saying: Hold 4 Down.

I think its because the black string?

EDIT: Sorry for the dubble post, when the red arrows passes, it will popup the traytip, but wont end the UP arrow!

-AlmarM-

Edited by AlmarM

Minesweeper

A minesweeper game created in autoit, source available.

_Mouse_UDF

An UDF for registering functions to mouse events, made in pure autoit.

2D Hitbox Editor

A 2D hitbox editor for quick creation of 2D sphere and rectangle hitboxes.

Link to comment
Share on other sites

Hi

Once I installed the newest version of autoit and the beta is didn't work for me either so I look it through and find out that it was the controlID that has changed..

Try the new one out and see if it works for you now. It only make perfect in the 3 first songs and then a silver in the 4th. put I will try optimize it when I got time for it.

#include <GUIConstants.au3>

Opt("GUICloseOnEsc", 1)
Opt("PixelCoordMode", 0)

Global $red = 0x990000, $blue = 0x003366, $purple = 0x663366, $green = 0x006600, $black = 0x000000

HotKeySet("{F6}", "_On")
HotKeySet("{F7}", "_Off")
HotKeySet("{ESC}", "terminate")

$oGame = ObjCreate("ShockwaveFlash.ShockwaveFlash.1")
$GUI = GUICreate("Super Crazy Guitar Maniac Dexuxe 3", 734 + 20, 414 + 20, -1, -1)
$GUIObj = GUICtrlCreateObj($oGame, 10, 10, 734, 414)

With $oGame
    .bgcolor = 0x000000
    .Movie = "http://www.notdoppler.com/files/supercrazyguitarmaniacdeluxe3.swf"
    .Loop = True
    .wmode = "Opaque"
EndWith

GUISetState()
_Off()

Func _Off()

TrayTip("","",0)

While 1
    $nMsg = GUIGetMsg()
    Select
    Case $nMsg = $GUI_EVENT_CLOSE ; -3
        Exit
    EndSelect
WEnd

EndFunc ; _Off()


Func _On()
    
    TrayTip("Guitar Bot","The bot is working",25)
    
    While 1
                
        Select
                
            ; looking for up arrow (red)
            Case PixelGetColor(84,100) == $red
                While (PixelGetColor(84,100) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{UP down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{UP up}")
            ; looking for number 4
            Case PixelGetColor(84,100) <> $black And PixelSearch(64,98,102,102,$red) == 1
                While (PixelGetColor(84,100) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{4 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{4 up}")
            
            ; looking for right arrow (blue)
            Case PixelGetColor(84,151) == $blue
                While (PixelGetColor(84,151) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{RIGHT down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{RIGHT up}")
            ; looking for number 3
            Case PixelGetColor(84,151) <> $black And PixelSearch(64,149,102,153,$blue) == 1
                While (PixelGetColor(84,151) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{3 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{3 up}")
                
            ; looking for left arrow (purple)
            Case PixelGetColor(84,206) == $purple
                While (PixelGetColor(84,206) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{LEFT down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{LEFT up}")
            ; looking for number 2
            Case PixelGetColor(84,206) <> $black And PixelSearch(64,204,102,208,$purple) == 1
                While (PixelGetColor(84,206) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{2 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{2 up}")
                
            ; looking for down arrow (green)
            Case PixelGetColor(84,258) == $green
                While (PixelGetColor(84,258) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{DOWN down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{DOWN up}")
            ; looking for number 1
            Case PixelGetColor(84,258) <> $black And PixelSearch(64,256,102,260,$green) == 1
                While (PixelGetColor(84,258) <> $black)
                    ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{1 down}")
                WEnd
                ControlSend("Super Crazy Guitar Maniac Dexuxe 3","",28516464,"{1 up}")

        EndSelect
        
    WEnd
    
EndFunc ; _On()

Func terminate()
    Exit
EndFunc ; terminate()

Hope it works for you now..

Regards :)

Link to comment
Share on other sites

I tried to "speed" it up a little

took out every other pixelsearch()

used key send options

#include <GUIConstants.au3>

Opt("GUIOnEventMode", 1) 
Opt("GUICloseOnEsc", 1)
Opt("PixelCoordMode", 0)

Opt("SendKeyDelay", 2) ;5 milliseconds
Opt("SendKeyDownDelay", 1) ;1 millisecond


Global $red = 0x990000, $blue = 0x003366, $purple = 0x663366, $green = 0x006600, $black = 0x000000
Global $Runner, $title = "Super Crazy Guitar Maniac Dexuxe 3", $step = 4

HotKeySet("{F5}", "_On_Off")
HotKeySet("{ESC}", "terminate")

$oGame = ObjCreate("ShockwaveFlash.ShockwaveFlash.1")
$GUI = GUICreate($title, 734 + 20, 414 + 20, -1, -1)
GUISetOnEvent($GUI_EVENT_CLOSE, "terminate")
$GUIObj = GUICtrlCreateObj($oGame, 10, 10, 734, 414)

With $oGame
    .bgcolor = 0x000000
    .Movie = "http://www.notdoppler.com/files/supercrazyguitarmaniacdeluxe3.swf"
    .Loop = True
    .wmode = "Opaque"
EndWith

GUISetState()

While 1
    Sleep(10)
WEnd

Func _On_Off()
    $Runner = Not $Runner
    ToolTip("The bot is working", 25, 25, "Guitar Bot", 1)

    While $Runner

        $UpArrow = PixelGetColor(84, 100)
        
        If $UpArrow == $red Then ; looking for up arrow (red)
            While (PixelGetColor(84, 100) <> $black)
                Send("{UP down}")
            WEnd
            Send("{UP up}")
        ElseIf $UpArrow <> $black And PixelSearch(64, 98, 102, 102, $red, 10, $step) == 1 Then; looking for number 4
            While (PixelGetColor(84, 100) <> $black)
                Send("{4 down}")
            WEnd
            Send("{4 up}")
        EndIf
        
        $RightArrow = PixelGetColor(84, 151)
        
        If $RightArrow == $blue Then; looking for right arrow (blue)
            While (PixelGetColor(84, 151) <> $black)
                Send("{RIGHT down}")
            WEnd
            Send("{RIGHT up}")
        ElseIf $RightArrow <> $black And PixelSearch(64, 149, 102, 153, $blue, 10, $step) == 1 Then; looking for number 3
            While (PixelGetColor(84, 151) <> $black)
                Send("{3 down}")
            WEnd
            Send("{3 up}")
        EndIf
        
        $LeftArrow = PixelGetColor(84, 206)
        
        If $LeftArrow == $purple Then ; looking for left arrow (purple)
            While (PixelGetColor(84, 206) <> $black)
                Send("{LEFT down}")
            WEnd
            Send("{LEFT up}")
        ElseIf $LeftArrow <> $black And PixelSearch(64, 204, 102, 208, $purple, 10, $step) == 1 Then; looking for number 2
            While (PixelGetColor(84, 206) <> $black)
                Send("{2 down}")
            WEnd
            Send("{2 up}")
        EndIf
        
        $DownArrow = PixelGetColor(84, 258)
        
        If $DownArrow == $green Then ; looking for down arrow (green)
            While (PixelGetColor(84, 258) <> $black)
                Send("{DOWN down}")
            WEnd
            Send("{DOWN up}")
        ElseIf $DownArrow <> $black And PixelSearch(64, 256, 102, 260, $green, 10, $step) == 1 Then; looking for number 1
            While (PixelGetColor(84, 258) <> $black)
                Send("{1 down}")
            WEnd
            Send("{1 up}")
        EndIf
        
    WEnd
    ToolTip("")
EndFunc   ;==>_On_Off

Func terminate()
    Exit
EndFunc   ;==>terminate

8)

NEWHeader1.png

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...