AutoIt - How to go back to the start of a script? menu

User Tag List

Results 1 to 2 of 2
  1. #1
    krims0nknite's Avatar Member
    Reputation
    2
    Join Date
    Jun 2012
    Posts
    50
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    AutoIt - How to go back to the start of a script?

    I'm having some trouble with a script,

    Basically I want the script to keep track of the number of runs, and if that hits a specific number then to goto town.

    What happens is this:

    It'll check the number of runs, goto town if it needs to, exit the game,
    And then resume the script without checking the number of runs again
    I want it to check the runs (start at the beginning) again

    While $go
    if($Run) Then
    $Pixel1 = PixelSearch
    If Not @error Then
    While(Teleport())
    WEnd
    Repair()
    Sleep(200);
    ResumeGame()
    Else

    If $runMade >= 5 Then
    Town()
    Exit/ResumeGame()

    Else
    RunToCellarArea()
    if (StatusCheck()) Then
    While(Teleport())
    ; idle until teleport is over
    WEnd
    Town()
    Exit/ResumeGame()

    EndIf
    EndIf
    EndIf
    EndIf
    Wend
    Last edited by krims0nknite; 08-23-2012 at 07:02 AM.

    AutoIt - How to go back to the start of a script?
  2. #2
    Jaerin's Avatar Former Staff
    Reputation
    641
    Join Date
    Sep 2008
    Posts
    1,290
    Thanks G/R
    29/126
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Turn your script into functions so that you can easily create a main loop that will control the overall flow of your script.

    You have basically just a down and dirty linear script that is designed to only run once. Not a bad start, but next step is to learn how to start segmenting your scripts into functions and expanding from there.

Similar Threads

  1. How to change the starting areas!
    By metehan in forum WoW EMU Guides & Tutorials
    Replies: 16
    Last Post: 06-05-2008, 09:56 AM
  2. How to get Warglaives on the back
    By blurkan in forum WoW ME Questions and Requests
    Replies: 2
    Last Post: 04-23-2008, 01:46 PM
  3. [Question] How to put BG's and places such as Programmer Isle back into the game?
    By sonnyd666 in forum World of Warcraft Emulator Servers
    Replies: 7
    Last Post: 03-14-2008, 03:41 PM
  4. How can i modify the starting place for each race ?
    By Wheeze201 in forum World of Warcraft Emulator Servers
    Replies: 2
    Last Post: 01-04-2008, 09:39 PM
  5. [Guide] How to: Change the starting stats of a new character
    By Cursed in forum WoW EMU Guides & Tutorials
    Replies: 7
    Last Post: 12-30-2007, 10:11 PM
All times are GMT -5. The time now is 09:44 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search