Results 1 to 3 of 3

Thread: It's me agian... being in the need for assistance...

  1. #1
    Join Date
    Sep 2007
    Posts
    41
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default It's me agian... being in the need for assistance...

    Okay, so here is my little problem, to describe it, I'll just show you what i would like the programm to do:
    SCAR Code:
    Programm Example;
    var
      x,y: Integer;
    Label
      DoItOver;

    Procedure SettingEverythingUp;
    begin
    {bla bla bla bla bla}
    end;

    Procedure FirstProcedure;
    begin
      {bla bal bla bla bla}
      Goto DoItOver;
      {bla bla bla bla bla}
    end;

    Procedure SecondProcedure;
    begin
      {bla bal bla bla bla}
    end;

    Procedure ThirdProcedure;
    begin
      {bla bal bla bla bla}
    end;
     
    begin
      SettingEverythingUp;
      repeat
        DoItOver:
        FirstProcedure;
        SecondProcedure;
        ThirdProcedure;
      Until Something;
    end;

    So, I want to have a goto a procedure, which gets put me in a certain point in the main loop, i would use this for situation like I just died and need to get to a certain point, and not have the script continue on.. Is the a function which can do that?
    BTW: the example one up there is obviously wrong.
    Thanks a lot
    http://www.fenjer.com/adnan/SRL/23/1...%20Chopper.png
    Well, it is finished, but it is too unsecure and it doesn't always work properly (1 out of 3 attempts fail), So I will stop scripting for a while, focusing on learning new functions and procedures to make this safer.

  2. #2
    Join Date
    Jun 2007
    Location
    Wednesday
    Posts
    2,446
    Mentioned
    3 Post(s)
    Quoted
    1 Post(s)

    Default

    A simple way to do it would be to make a boolean at the top called skipLoop or whatever you want to call it, then at the start of all the procedures put
    SCAR Code:
    if(skipLoop) then
      exit;
    and it would then skip the rest of the loop and you would just put a check in the procedure that you want to run when the boolean is true that exits if it is not true. You would then just have to write a short procedure that sees whether or not you are dead and if you are, it sets skipLoop to True.

  3. #3
    Join Date
    Sep 2007
    Posts
    41
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Wow, good idea, thanks a lot ^^
    http://www.fenjer.com/adnan/SRL/23/1...%20Chopper.png
    Well, it is finished, but it is too unsecure and it doesn't always work properly (1 out of 3 attempts fail), So I will stop scripting for a while, focusing on learning new functions and procedures to make this safer.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Need some assistance...
    By Da Der Der in forum OSR Help
    Replies: 2
    Last Post: 11-14-2007, 03:11 AM
  2. what was sumilions site agian?
    By wired16 in forum News and General
    Replies: 4
    Last Post: 05-19-2007, 08:02 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •