Results 1 to 3 of 3

Thread: Right but wrong?

  1. #1
    Join Date
    Mar 2012
    Posts
    74
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default Right but wrong?

    Hello im currently working on an astral runner and im doing it step by step

    so far i made the walking code from bank to altar but it doesnt seem to work when i run it could anyone have a look and see whats wrong?
    Code:
    program lunarislandwalkaltar;
    
     {$DEFINE SMART}
    
      {$i SRL/srl.simba}
      {$i SPS/sps.simba}
    
      procedure DeclarePlayers;
    begin
      HowManyPlayers := 1;
      NumberOfPlayers(HowManyPlayers);
      CurrentPlayer := 0;
    
      with Players[0] do
      begin
        Name := ''; // Username
        Pass := ''; // Password
        Active := True; // Set to true if you want to use Player 0
      end;
    end;
    
    
    
    Var
    myPath:TPointArray;
    begin
    SetupSRL;
    SPS_Setup(RUNESCAPE_SURFACE, ['0_2', '0_3', '1_2']);
    myPath := [Point(209, 966), Point(209, 974), Point(223, 974),
      Point(233, 974), Point(245, 972), Point(257, 976), Point(259, 984),
      Point(259, 994), Point(261, 1002), Point(261, 1008), Point(261, 1018),
      Point(261, 1026), Point(259, 1034), Point(261, 1044), Point(261, 1056),
      Point(261, 1062), Point(261, 1070), Point(261, 1078), Point(269, 1084),
      Point(275, 1090), Point(285, 1098), Point(289, 1108), Point(297, 1110),
      Point(303, 1120), Point(309, 1124), Point(321, 1128), Point(327, 1130),
      Point(333, 1128), Point(341, 1132), Point(341, 1136), Point(343, 1144),
      Point(345, 1154), Point(345, 1162), Point(349, 1172), Point(347, 1182),
      Point(347, 1196), Point(355, 1192), Point(365, 1188), Point(373, 1186),
      Point(383, 1180), Point(395, 1176), Point(405, 1178), Point(417, 1178),
      Point(427, 1176), Point(427, 1176), Point(435, 1172), Point(435, 1172)];
    
    end.
    
    procedure MainLoop;
    begin
    SPS_WalkPath(mypath)
    end;
    
    begin
      {$IFDEF SMART}
        Smart_Server := 0;
        Smart_Members := True;
        Smart_Signed := True;
        Smart_SuperDetail := False;
      {$ENDIF}
      SetupSRL();
      ClearDebug();
      DeclarePlayers();
      LoginPlayer();
      MainLoop();
    end.
    Thanks in advance

  2. #2
    Join Date
    Dec 2011
    Location
    Kosovo
    Posts
    831
    Mentioned
    0 Post(s)
    Quoted
    6 Post(s)

    Default

    lol, this should be a procedure like this:

    Simba Code:
    Procedure WalkThere;


    Var
    myPath:TPointArray;
    begin
    SetupSRL;
    SPS_Setup(RUNESCAPE_SURFACE, ['0_2', '0_3', '1_2']);
    myPath := [Point(209, 966), Point(209, 974), Point(223, 974),
      Point(233, 974), Point(245, 972), Point(257, 976), Point(259, 984),
      Point(259, 994), Point(261, 1002), Point(261, 1008), Point(261, 1018),
      Point(261, 1026), Point(259, 1034), Point(261, 1044), Point(261, 1056),
      Point(261, 1062), Point(261, 1070), Point(261, 1078), Point(269, 1084),
      Point(275, 1090), Point(285, 1098), Point(289, 1108), Point(297, 1110),
      Point(303, 1120), Point(309, 1124), Point(321, 1128), Point(327, 1130),
      Point(333, 1128), Point(341, 1132), Point(341, 1136), Point(343, 1144),
      Point(345, 1154), Point(345, 1162), Point(349, 1172), Point(347, 1182),
      Point(347, 1196), Point(355, 1192), Point(365, 1188), Point(373, 1186),
      Point(383, 1180), Point(395, 1176), Point(405, 1178), Point(417, 1178),
      Point(427, 1176), Point(427, 1176), Point(435, 1172), Point(435, 1172)];

    end;
    Goals:
    Understanding TPAs
    Making Proggy for fighting
    Getting on SRL members
    Get 500 posts

  3. #3
    Join Date
    Oct 2011
    Location
    UK
    Posts
    1,322
    Mentioned
    2 Post(s)
    Quoted
    1 Post(s)

    Default

    Simba Code:
    program lunarislandwalkaltar;

     {$DEFINE SMART}

      {.include SRL/srl.simba}
      {.include SPS/sps.simba}

    procedure DeclarePlayers;
    begin
      HowManyPlayers := 1;
      NumberOfPlayers(HowManyPlayers);
      CurrentPlayer := 0;

      with Players[0] do
      begin
        Name := ''; // Username
        Pass := ''; // Password
        Pin := '';
        Active := True; // Set to true if you want to use Player 0
      end;
    end;
             //Everything up to this point is perfect

    Function WalkThePath : Boolean;    //This is the start of your function, if you don't know what one is check the tutorial section
    Var
      myPath : TPointArray;
    begin

      SPS_Setup(RUNESCAPE_SURFACE, ['0_2', '0_3', '1_2']);
      myPath := [Point(209, 966), Point(209, 974), Point(223, 974),
                 Point(233, 974), Point(245, 972), Point(257, 976), Point(259, 984),
                 Point(259, 994), Point(261, 1002), Point(261, 1008), Point(261, 1018),
                 Point(261, 1026), Point(259, 1034), Point(261, 1044), Point(261, 1056),
                 Point(261, 1062), Point(261, 1070), Point(261, 1078), Point(269, 1084),
                 Point(275, 1090), Point(285, 1098), Point(289, 1108), Point(297, 1110),
                 Point(303, 1120), Point(309, 1124), Point(321, 1128), Point(327, 1130),
                 Point(333, 1128), Point(341, 1132), Point(341, 1136), Point(343, 1144),
                 Point(345, 1154), Point(345, 1162), Point(349, 1172), Point(347, 1182),
                 Point(347, 1196), Point(355, 1192), Point(365, 1188), Point(373, 1186),
                 Point(383, 1180), Point(395, 1176), Point(405, 1178), Point(417, 1178),
                 Point(427, 1176), Point(427, 1176), Point(435, 1172), Point(435, 1172)];

      Result := SPS_WalkPath(MyPath);

    end;

    begin
      {$IFDEF SMART}
        Smart_Server := 0;
        Smart_Members := True;
        Smart_Signed := True;
        Smart_SuperDetail := False;
      {$ENDIF}
      SetupSRL();
      ClearDebug();
      DeclarePlayers();
      LoginPlayer();
      WalkThePath;   //This makes it do your path walking...
    end.

Thread Information

Users Browsing this Thread

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

Posting Permissions

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