Page 6 of 7 FirstFirst ... 4567 LastLast
Results 126 to 150 of 169

Thread: Projectrs06 SRL Include

  1. #126
    Join Date
    May 2012
    Location
    Moscow, Russia
    Posts
    661
    Mentioned
    35 Post(s)
    Quoted
    102 Post(s)

    Default

    Support of the ProjectRS 06 include has been added to the my SPS Path maker.

    Example of the generated script:
    Simba Code:
    program Walker;
    //The code was generated with the path generator for SPS version 2.5.8 by Cynic
    //With Project RS 06 compabilty mode.
    {$i SRL/srl.simba}
    {$I P06Include/P06Include.Simba}
    {$i sps/p06sps.simba}

    var
    //place your variables here
     Status: string;

    procedure P06DeclarePlayers;
    begin
      P06_PlayerName:='';
      P06_PlayerPass:='';
    end;

    procedure toBank;
    var
      toBankVar: TPointArray;
    begin
      toBankVar:=[Point(332,366),Point(340,347),Point(346,335),Point(363,331),Point(361,305),Point(360,283),Point(358,259),Point(357,232),Point(357,208),Point(352,185),Point(344,159),Point(344,145),Point(341,121),Point(336,106),Point(314,103),Point(295,103),Point(269,103),Point(253,106),Point(228,106),Point(213,104),Point(201,105),Point(200,118),Point(198,131),Point(196,141)];
      if SPS_WalkPath(toBankVar) then
        Status := 'toBank'
      else begin
        Status :='Failed toBank';
        WriteLn(status + '#Time Running:' +TimeRunning);
        Logout;
        TerminateScript;
      end;
      WriteLn(status + '#Time Running:' +TimeRunning);
    end;

    procedure toMine;
    var
      toMineVar: TPointArray;
    begin
      toMineVar:=[Point(196,136),Point(196,120),Point(196,111),Point(201,103),Point(228,105),Point(245,105),Point(264,107),Point(278,102),Point(294,103),Point(324,109),Point(330,125),Point(337,140),Point(337,164),Point(347,183),Point(368,204),Point(357,222),Point(356,252),Point(356,272),Point(356,285),Point(356,311),Point(356,324),Point(339,337),Point(336,358),Point(331,369)];
      if SPS_WalkPath(toMineVar) then
        Status := 'toMine'
      else begin
        Status :='Failed toMine';
        WriteLn(status + '#Time Running:' +TimeRunning);
        Logout;
        TerminateScript;
      end;
      WriteLn(status + '#Time Running:' +TimeRunning);
    end;

    procedure SetupWalker;
    begin
      P06_DeclarePlayer;
      SetupP06Include;
      ActivateClient;
      Wait(2054+ Random(2318));
      If (Not P06_LoggedIn) Then
       P06LoginPlayer;
      Wait(857+ Random(353));
      P06_MakeCameraAngleHigh;
      P06_MakeCompassNorth;
      SPS_Setup(RUNESCAPE_OTHER,['varrokMiner']);
    end;

    begin
      SetupWalker;
      toBank;
      toMine;
    end.

    Cheers, Cynic.
    Per aspera ad Astra!
    ----------------------------------------
    Slow and steady wins the race.

  2. #127
    Join Date
    Nov 2012
    Posts
    2,351
    Mentioned
    55 Post(s)
    Quoted
    603 Post(s)

    Default

    Quote Originally Posted by CynicRus View Post
    Support of the ProjectRS 06 include has been added to the my SPS Path maker.

    Cheers, Cynic.
    Ahh amazing, thanks Cynic

    I'm sure alot of the SPS newcommers will find this really helpful and save them some time,

    EDIT - found your thread, added link to OP and added you to contributors list , thanks again, glad to see we are all becoming more accepting towards private servers
    Last edited by DannyRS; 02-18-2013 at 12:57 PM.


    Programming is like trying keep a wall of shifting sand up, you fix one thing but somewhere else starts crumbling

  3. #128
    Join Date
    Sep 2010
    Posts
    5,762
    Mentioned
    136 Post(s)
    Quoted
    2739 Post(s)

    Default

    How do I run the auto updater?

  4. #129
    Join Date
    Oct 2011
    Location
    Australia, Vic
    Posts
    1,517
    Mentioned
    2 Post(s)
    Quoted
    120 Post(s)

    Default

    Quote Originally Posted by rjj95 View Post
    How do I run the auto updater?
    From what I have seen, It runs itself.

  5. #130
    Join Date
    Sep 2010
    Posts
    5,762
    Mentioned
    136 Post(s)
    Quoted
    2739 Post(s)

    Default

    Project2006 Stat chars, not sure if the red is the correct color, also is this anywhere close to correct?

    Simba Code:
    Function P06_GetUpHpText: String;
    Var
      YellowT,FoundText: String;
    Begin
      YellowT:=GetTextAtExWrap(X1, Y1, X2, Y2, 0, 3, 1, 65535, 55, 'P06StatChars');
      FoundText:=YellowT + '';
      Result:=FoundText;
    End;


    Would I have to create a function like

    Simba Code:
    Function P06_Hp: Boolean;
    Var
      MyHP:Integer;
    Begin
    Procedure SetKill;
    Begin
      Case LowerCase(FoundText) Of
        '0': MyHP := 0;
        '1': MyHP := 1;
        '2': MyHP := 2;
        '3': MyHP := 3;
        '4': MyHP := 4;
        '5': MyHP := 5;
        '6': MyHP := 6;
        '7': MyHP := 7;
        '8': MyHP := 8;
        '9': MyHP := 9;
        '10': MyHP := 10;
      End;
    End;

    To get the HP?

    Btw i forgot 6,7,9

  6. #131
    Join Date
    Apr 2008
    Location
    Marquette, MI
    Posts
    15,252
    Mentioned
    138 Post(s)
    Quoted
    680 Post(s)

    Default

    rjj95, instead of returning a string in your getUpHpText, you can just do:
    Simba Code:
    result := strToInt(foundText);
    So there's no need for a conversion function. It can be done in one line.

  7. #132
    Join Date
    Sep 2010
    Posts
    5,762
    Mentioned
    136 Post(s)
    Quoted
    2739 Post(s)

    Default

    Quote Originally Posted by Coh3n View Post
    rjj95, instead of returning a string in your getUpHpText, you can just do:
    Simba Code:
    result := strToInt(foundText);
    So there's no need for a conversion function. It can be done in one line.
    ok thanks I'll have to test this but the server is offline ATM

  8. #133
    Join Date
    Nov 2012
    Posts
    141
    Mentioned
    0 Post(s)
    Quoted
    43 Post(s)

    Default

    Instead of using a case statement, you should use StrToInt.
    The reason behind this is that all the cases for each HP value would take up too many lines (~100 for all hp values).
    Code:
    function P06_GetStatsHP: Integer;
    var
      YellowT: string;
      ValueHP: Integer;
    begin
      YellowT := GetTextAtExWrap(X1, Y1, X2, Y2, 0, 3, 1, 65535, 55, 'P06StatChars');
      try
        ValueHP := StrToInt(YellowT);
      except
        ValueHP := -1;
      end;
      Result := ValueHP;
    end;
    The try, except needs to be there in case the value we read in isn't a valid integer (not that SRL can't read correctly ), it which case it will return -1. Otherwise you'd get an exception.
    So, 'asdf' would return -1, '123' would return 123 and so on.

    Edit: Wow, super late.

    Edit 2: StrToIntDef version (after Danny's post below):
    Code:
    function P06_GetStatsHP: Integer;
    var
      YellowT: string;
    begin
      YellowT := GetTextAtExWrap(X1, Y1, X2, Y2, 0, 3, 1, 65535, 55, 'P06StatChars');
      Result := StrToIntDef(YellowT, -1);
    end;
    Much shorter.
    Last edited by Neodymium; 02-21-2013 at 09:39 PM.

  9. #134
    Join Date
    Nov 2012
    Posts
    2,351
    Mentioned
    55 Post(s)
    Quoted
    603 Post(s)

    Default

    I believe StrToIntDef or something doesn't throw an exception? Whatever I used in my autozealer in "GetWinningTeam" or something

    Goodjob on the statchars Rjj, I'll add to OP later


    Programming is like trying keep a wall of shifting sand up, you fix one thing but somewhere else starts crumbling

  10. #135
    Join Date
    Jun 2012
    Posts
    20
    Mentioned
    0 Post(s)
    Quoted
    5 Post(s)

    Default

    can someone tell me whats wrong with this?

    [Error] C:\Simba\Includes\SRL/SRL/core/text.simba(791:13): Unknown identifier 'UpChars' at line 790

  11. #136
    Join Date
    Nov 2012
    Posts
    2,351
    Mentioned
    55 Post(s)
    Quoted
    603 Post(s)

    Default

    Quote Originally Posted by unregistered user View Post
    can someone tell me whats wrong with this?

    [Error] C:\Simba\Includes\SRL/SRL/core/text.simba(791:13): Unknown identifier 'UpChars' at line 790
    re-install simba


    Programming is like trying keep a wall of shifting sand up, you fix one thing but somewhere else starts crumbling

  12. #137
    Join Date
    Dec 2006
    Location
    Program TEXAS home of AUTOERS
    Posts
    7,934
    Mentioned
    26 Post(s)
    Quoted
    237 Post(s)

    Default

    Goodness... Though this was for 2007scape lol, its like 5-6 am here and had just written a script based off this include and had everything set up, fail. :X

  13. #138
    Join Date
    Nov 2012
    Posts
    2,351
    Mentioned
    55 Post(s)
    Quoted
    603 Post(s)

    Default

    Quote Originally Posted by P1nky View Post
    Goodness... Though this was for 2007scape lol, its like 5-6 am here and had just written a script based off this include and had everything set up, fail. :X
    I have an 07 version with the same P07_ prefix, if you want it,

    All function names are exactly the same other than the 7, and everything works, I just havent released it yet incase SRL was going to release an official one


    Programming is like trying keep a wall of shifting sand up, you fix one thing but somewhere else starts crumbling

  14. #139
    Join Date
    Jul 2012
    Posts
    15
    Mentioned
    0 Post(s)
    Quoted
    6 Post(s)

    Default

    Quote Originally Posted by DannyRS View Post
    Have you considered trying the SPS beta?
    Sorry for the late reply in the end i got it working, i just couldnt find the colour of the banker. Anyway since 2007 is out i'l play that

  15. #140
    Join Date
    Nov 2012
    Posts
    2,351
    Mentioned
    55 Post(s)
    Quoted
    603 Post(s)

    Default

    Quote Originally Posted by P1nky View Post
    Goodness... Though this was for 2007scape lol, its like 5-6 am here and had just written a script based off this include and had everything set up, fail. :X
    Here you go @P1nky: http://villavu.com/forum/showthread.php?t=96863


    Quote Originally Posted by imangry View Post
    Sorry for the late reply in the end i got it working, i just couldnt find the colour of the banker. Anyway since 2007 is out i'l play that
    Np, same here I think
    Last edited by DannyRS; 02-23-2013 at 03:09 PM.


    Programming is like trying keep a wall of shifting sand up, you fix one thing but somewhere else starts crumbling

  16. #141
    Join Date
    Feb 2013
    Posts
    5
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default

    Read your massegers danny!

  17. #142
    Join Date
    Feb 2013
    Posts
    1
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default



    I get this when I run it.

  18. #143
    Join Date
    Nov 2012
    Posts
    2,351
    Mentioned
    55 Post(s)
    Quoted
    603 Post(s)

    Default

    Quote Originally Posted by Betweenuandme View Post


    I get this when I run it.
    You are not supposed to run it...

    Is this private server officialy dead anyway?

    Quote Originally Posted by bdenizb View Post
    Read your massegers danny!
    Did I reply to you? My PM's is a sea of spam at the moment so going back to find any I missed is all but impossible


    Programming is like trying keep a wall of shifting sand up, you fix one thing but somewhere else starts crumbling

  19. #144
    Join Date
    Sep 2010
    Posts
    5,762
    Mentioned
    136 Post(s)
    Quoted
    2739 Post(s)

    Default

    Quote Originally Posted by DannyRS View Post
    You are not supposed to run it...

    Is this private server officialy dead anyway?



    Did I reply to you? My PM's is a sea of spam at the moment so going back to find any I missed is all but impossible
    Soulsplit 2006 will be coming out

  20. #145
    Join Date
    Nov 2012
    Posts
    2,351
    Mentioned
    55 Post(s)
    Quoted
    603 Post(s)

    Default

    Quote Originally Posted by rjj95 View Post
    Soulsplit 2006 will be coming out
    Meh this might still work, they use same client AFAIK


    Programming is like trying keep a wall of shifting sand up, you fix one thing but somewhere else starts crumbling

  21. #146
    Join Date
    Feb 2013
    Posts
    26
    Mentioned
    0 Post(s)
    Quoted
    5 Post(s)

    Default

    I keep getting Unknown identifier 'P06_MouseBox'???

  22. #147
    Join Date
    Nov 2012
    Posts
    2,351
    Mentioned
    55 Post(s)
    Quoted
    603 Post(s)

    Default

    Quote Originally Posted by kontempt View Post
    I keep getting Unknown identifier 'P06_MouseBox'???
    You didn't install the include right, PLEASE NOTE THIS IS A PRIVATE SERVER INCLUDE, NOT 07Scape, 07Scape here: http://villavu.com/forum/showthread.php?t=96863
    Last edited by DannyRS; 02-25-2013 at 09:47 PM.


    Programming is like trying keep a wall of shifting sand up, you fix one thing but somewhere else starts crumbling

  23. #148
    Join Date
    Feb 2013
    Posts
    26
    Mentioned
    0 Post(s)
    Quoted
    5 Post(s)

    Default

    Quote Originally Posted by DannyRS View Post
    You didn't install the include right, PLEASE NOTE THIS IS A PRIVATE SERVER INCLUDE, NOT 07Scape, 07Scape here: http://villavu.com/forum/showthread.php?t=96863
    Thank you i've updated that now, I'm also getting
    [Error] C:\Simba\Includes\P07Include.Simba(57:3): Unknown identifier 'MMouse' at line 56
    Compiling failed.
    ' MMouse(RandomRange(X1,X2),RandomRange(Y1,Y2),0,0); '

    I'm very new too this sorry

  24. #149
    Join Date
    Nov 2012
    Posts
    2,351
    Mentioned
    55 Post(s)
    Quoted
    603 Post(s)

    Default

    Quote Originally Posted by kontempt View Post
    Thank you i've updated that now, I'm also getting
    [Error] C:\Simba\Includes\P07Include.Simba(57:3): Unknown identifier 'MMouse' at line 56
    Compiling failed.
    ' MMouse(RandomRange(X1,X2),RandomRange(Y1,Y2),0,0); '

    I'm very new too this sorry
    you don't compile this include, you set it up like my example in a script,

    Simba Code:
    {$I srl/srl.simba}

    you need that in your script before you add this include


    Programming is like trying keep a wall of shifting sand up, you fix one thing but somewhere else starts crumbling

  25. #150
    Join Date
    Dec 2011
    Location
    U.S.A.
    Posts
    635
    Mentioned
    5 Post(s)
    Quoted
    249 Post(s)

    Default

    I have everything compiling but it doesn't seem to be able to find uptext.

Page 6 of 7 FirstFirst ... 4567 LastLast

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
  •