Jump to content

Recommended Posts

Posted

C:\Documents and Settings\admin\Desktop\D2 Infinity\D2 Insanity.au3(156,2) : ERROR: syntax error
    Func
    ^

Is the error i get.

This is my code

; -----------------------------------------------------------------------
; Start Diablo II
; -----------------------------------------------------------------------
    Func StartDiablo()

    If StringRight($D2Path, 1) = "\" Then
        $D2FullPath = $D2Path & $D2File & " -w -ns -skiptobnet -res800 " & $D2Params
    Else
        $D2FullPath = $D2Path & "\" & $D2File & " -w -ns -skiptobnet  -res800 " & $D2Params
    EndIf

    Run($D2FullPath, $D2Path)

    For $x1 = 0 To 29
        If WinExists("Diablo II") = 1 Then
            ExitLoop
        EndIf
        Sleep(1000)
    Next

    Sleep($StartDelay)

    WinMove("Diablo II", "", 0, 0)
    WinActivate("Diablo II")
    AdlibEnable("CheckD2")
    Login()
EndFunc

Everything there is declared. O.o PORQUEEEEE!!!!

Posted (edited)

Everything there looks fine... So the problem exists in the rest of your code, prior to the posted code.

Edited by exodius
Posted

Can you post the rest of the script? It's not sufficient enough to spot the syntax error.

By the way:

For $x1 = 0 To 29
        If WinExists("Diablo II") = 1 Then
            ExitLoop
        EndIf
        Sleep(1000)
NextoÝ÷ ÙÆ§mêÞ¸­µéí+0k'è­·­µêܡاËrèZn+Z¶W²Ø§*)x¨«­¢+Ù¥´ÀÌØí¥]¥Ñ±äôÌÀÀÀÀìÌÀͽ¹Ì¸M¼å½Ôݽ¸ÌäíÐÉÕ¸¥¹Ñ¼¸¥¹¥¹¥Ñ±½½À͸)¥´ÀÌØí¥%¹¥ÐôQ¥µÉ%¹¥Ð ¤()¼(%M±À ÈÀÀ¤)U¹Ñ¥°9½Ð]¥¹á¥ÍÑÌ ÅÕ½Ðí¥±¼%$ÅÕ½Ðì¤=ÈQ¥µÉ¥ ÀÌØí¥%¹¥Ð¤ÐìÀÌØí¥]¥Ñ±ä
Posted

Usually when I get a error that doesn't show the point in the line where the error occurred, its because of a missing EndFunc statement in a previous section of the script.

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