Jump to content

Recommended Posts

Posted

hi guys,

I have this:

Func _Bank()
        Mouseclickdrag ("left", $LocScrollDown1, $LocScrollDown2, $LocScrollDown3, $LocScrollDown4)
    Mouseclickdrag ("left", $LocDragGeld1, $LocDragGeld2, $LocDragGeld3, $LocDragGeld4)
    Send ("^c")
    Run ("Notepad.exe")
    sleep (5000)
    Send ("^v")
    Send ("{LEFT}{LEFT}{LEFT}{BS}{LEFT}{LEFT}{LEFT}{BS}{LEFT}{LEFT}{LEFT}{BS}{LEFT}{BS}{BS}{BS}{BS}{BS}{BS}


{BS}{BS}{BS}{BS}{BS}")
    Send ("^a")
    Send ("^c")
    $Money = ClipGet()
        If $Money >= 200000000 Then
            ProcessClose("notepad.exe")
            WinActivate ("Mobstar mafia game - Microsoft Internet Explorer", "")
            Mouseclick ("left", $LocBank1, $LocBank2, 1)
        ;_WaitForWebPage()
            Sleep (5000)
            Mouseclick ("left", $LocStort1, $LocStort2, 1)
            Send ($Bankmoney)
            Mouseclick ("left", $Stortbedrag1, $Stortbedrag2, 1)
        ;_WaitForWebPage()
            Sleep (5000)
        Else
            $LowMoney = $Money - 200000
            ProcessClose("notepad.exe")
            WinActivate ("Mobstar mafia game - Microsoft Internet Explorer", "")
            Mouseclick ("left", $LocBank1, $LocBank2, 1)
        ;_WaitForWebPage()
            Sleep (5000)
            Mouseclick ("left", $LocStort1, $LocStort2, 1)
            Send ($LowMoney)
            Mouseclick ("left", $Stortbedrag1, $Stortbedrag2, 1)
        ;_WaitForWebPage()
            Sleep (5000)
        EndIf
EndFunc

The point is that the amount that is being copied on line 10 will be "scanned" and when the amount is higher than 200000000, 200 mill will be put in at Send ($Bankmoney). Though for some reason the script always takes the Else command and then puts in -200000 when the amount is higher than 200000000. When the amount is lower then 200000000 is does do the job correctly.

Could any of you explain the problem i'm having?

Berend Jan

Posted

try putting the following right after the line clipget and see what your return is

$Money = ClipGet()
     ConsoleWrite($Money & @LF)

in testing it seems to work here if i have the number in the clip.

<{POST_SNAPBACK}>

This gives me a error as respons: unknown function name :(
Posted

ConsoleWrite() is an included function in version 3.1.1 of Autoit. This is the latest public release version.

Though, the editor used, needs to support it, for it's use.

:(

Posted

oops, used to using beta version

replace the ConsoleWrite($Money & @LF)

with

MsgBox(0,"test",$Money)

<{POST_SNAPBACK}>

it does copy the right amount. It shows in the msgbox. don't understand why it puts in -200000 then. does anyone of you do?

Berend Jan

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
×
×
  • Create New...