Sign in to follow this  
Followers 0
Dead_Man

need help with GUI

4 posts in this topic

#1 ·  Posted (edited)

first of all I'm making this for wow, its a basic bot to move you around that i gave a GUI to, my problem is when i try and make the window count down until the next function is performed, the script doesnt work ( my progress is commented out ) this is what i have so far.

Problems i have from the progress I've made so far

1) most of the time the timer doesn't show ( ~80%)

2) if it does show, it doesn't count down

; use F1 to turn on and off

#include <GUIConstants.au3>
GUICreate("Bot Status",250,100,"","","",$WS_EX_STATICEDGE)
$font="Comic Sans MS"
GUISetFont(10,"","",$font)
GUISetState (@SW_SHOW)
GUICtrlCreateLabel("The Bot is Idle.                                       ","","")
WinSetOnTop("Bot Status","",1)
HotKeySet("{F1}", "moveon")
HotKeySet("{F2}", "Spamheal")
HotKeySet("{F3}", "Vanishdown")

While 1
    $msg = GUIGetMsg()
    If $msg = $GUI_EVENT_CLOSE Then ExitLoop
    if not ProcessExists("wow.exe") Then ExitLoop
WEnd



func moveon()
    GUICtrlCreateLabel("The Bot is Moving Around.","","")
    HotKeySet("{F1}", "rest")
    While 1
        $rand = Random(1,5,1) ; 1 = up, 2 = left, 3 = right, 4 = down, 5 = jump
        $timer = Random(30000,120000,1) ; 30 seconds to 2min
        if $rand = 1 Then
            ControlSend("World of Warcraft", "","","{up down}")
            sleep(200)
            ControlSend("World of Warcraft", "","","{up up}")
            Sleep($timer)
            ;for $timer = $timer to 1 step -1
            ;   GUICtrlCreateLabel("Time Until Next Action: " & Round($timer/1000,0) & " seconds.",0,+30)
            ;Next
            ;ExitLoop
        Elseif $rand = 2 Then
            ControlSend("World of Warcraft", "","","{left down}")
            sleep(200)
            ControlSend("World of Warcraft", "","","{left up}")
            sleep($timer)
        ElseIf $rand = 3 Then
            ControlSend("World of Warcraft", "","","{Right down}")
            sleep(200)
            ControlSend("World of Warcraft", "","","{right up}")
            sleep($timer)
        ElseIf $rand = 4 then
            ControlSend("World of Warcraft", "","","{down down}")
            sleep(200)
            ControlSend("World of Warcraft", "","","{down up}")
            Sleep($timer)
        Elseif $rand = 5 Then
            ControlSend("World of Warcraft", "","","{space}")
            Sleep($timer)
        EndIf
    WEnd
EndFunc

func Spamheal()
    GUICtrlCreateLabel("The Bot is Spamming Heal.                         ","","")
    HotKeySet("{F2}", "rest")
    while 1
        $rand3 = random(1,20,1)
        $rand2 = Random(1,20,$rand3)
        $sleep = Random(100,200,$rand2)
        ControlSend("World of Warcraft", "","","{1}")
        sleep($sleep)
        MouseClick("left")
        sleep($sleep)
    WEnd
EndFunc

func rest()
GUICtrlCreateLabel("The Bot is Idle.                    ","","")
GUICtrlCreateLabel("                                                     ",0,+20)
HotKeySet("{F1}", "moveon")
HotKeySet("{F2}", "Spamheal")
    while 1
        sleep(100)
    WEnd
EndFunc

func vanishdown()
    HotKeySet("{F3}","vanishup")
    for $stealth = 255 to 0 step -2
        WinSetTrans("Bot Status","",$stealth)
    Next
EndFunc

func vanishup()
    HotKeySet("{F3}","vanishdown")
    for $stealth = 0 to 255 step +2
        WinSetTrans("Bot Status","",$stealth)
    Next
EndFunc
Edited by Dead_Man

Share this post


Link to post
Share on other sites



Add Me On Msn [Maxell225@Hotmail.Com] And I Will Help You :]


Latest Projects :- New & Improved TCP Chat

Share this post


Link to post
Share on other sites

Add Me On Msn [Maxell225@Hotmail.Com] And I Will Help You :]

Isn't this what the forums are for?

Share this post


Link to post
Share on other sites

Good Point... But I Just Work A Lot Better While Chatting To The Person :/


Latest Projects :- New & Improved TCP Chat

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