Results 1 to 6 of 6

Thread: Please Help

  1. #1
    Join Date
    Jan 2013
    Posts
    11
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Please Help

    Can I get some help with the following?

    [Hint] C:\Simba\Scripts\PowerChopper.simba(70:10): Variable 'Result' never used at line 69
    [Error] C:\Simba\Scripts\PowerChopper.simba(126:40): Type mismatch at line 125
    Compiling failed.

    Program PowerChopper;

    {$DEFINE SMART}
    {$i SRL\SRL.simba}

    Const
    SRLStats_Username = '';// Your SRL Stats Username
    SRLStats_Password = ''; // Your SRL Stats Password
    BreakEvery = 120; //How Many Minutes To Break After
    BreakFor = 5; //How Long To Break For
    Version = '1.0b';
    NumbOfPlayers= 1; //How many players are you using
    StartPlayer= 0; //Player to start autoing with! (0 means first char)



    Var
    TooLong:Integer;

    procedure DeclarePlayers;
    var i:integer;
    begin
    NumberOfPlayers(NumbOfPlayers);
    CurrentPlayer :=StartPlayer;
    for i := 0 to NumbOfPlayers-1 do
    Players[i].BoxRewards := ['mote', 'otsume', 'XP', 'Gem', 'ithril', 'oal', 'une', 'oins'];

    with Players[0] do
    begin
    Name := ''; //Player username.
    Pass := ''; //Player password.
    Active := True;
    Integers[1] := 4; //1=BrightCopper,2=DarkCopper,3=Tin,4=Iron.
    Integers[2] := 4; //Seconds to try mining rock before clicking another.
    end;




    end;

    Procedure StatsGuise(wat:String);
    Begin
    Status(wat);
    Disguise(wat);
    End;

    Procedure Antiban;
    Begin
    Case Random(250) Of
    0: Begin StatsGuise ('AntiBan') GameTab(tab_Stats) HoverSkill('Woodcutting', False) GameTab(28) End;
    1: Begin StatsGuise ('AntiBan') SleepAndMoveMouse (7000 + Random(500)); End;
    2: Begin StatsGuise ('AntiBan') GameTab(tab_Inv) ExamineInv; GameTab(28); End;
    3: Begin StatsGuise ('AntiBan') RandomAngle(1); End;
    4: Begin StatsGuise ('AntiBan') GameTab(Tab_Stats) Wait (3000 + Random(500)); GameTab(28); End;
    5: Begin StatsGuise ('AntiBan') GameTab(tab_Stats) HoverSkill('random', False); GameTab(28); End;
    End;
    End;

    Procedure FailSafe(Reason:String);
    Begin
    Players[CurrentPlayer].Loc:=Reason
    Logout;
    Stats_Commit;
    Writeln(Reason);
    TerminateScript;
    End;

    Function ChopDown:Boolean;
    Var
    seX, seY, PlusOne, TreeCounter: Integer;
    Begin
    MarkTime(TooLong);
    FindNormalRandoms;
    PlusOne:= InvCount +1;
    //If FindObjCustom(seX, seY, ['Chop', 'down', 'p d'], [1128488, 1984576, 2510920, 2701360], 10) Then
    Sex:=MSCX;
    Sey:=MSCY;
    If FindObjTPA(SeX, SeY, 2905438, 10, 1, 15, 60, 600, ['Cho']) Then
    Begin
    StatsGuise('Hooray, we found a tree!');
    GetMousePos(Sex, Sey);
    Case Random(2) Of
    0: Mouse(SeX, SeY, 5, 5, True);
    1: Begin
    Mouse(SeX, SeY, 5, 5, False);
    WaitOption('Chop', 500);
    End;
    End;

    Flag;
    MarkTime(TreeCounter);
    If (TimeFromMark(TooLong) > 30000) Then
    FailSafe('Could Not Find Tree');
    Repeat
    If (TimeFromMark(TooLong) > 30000) Then
    FailSafe('Could Not Find Tree');
    FindNormalRandoms;
    StatsGuise('AntiBan and Waiting');
    Antiban;
    Wait(1000);
    If InvCount=Plusone Then
    Writeln('We Got One!');
    Until (InvCount=Plusone) or (TimeFromMark(TreeCounter) > 5000)
    End;
    End;

    Procedure DropLogs;
    var
    SeX, SeY, LogDTM, I:Integer;
    SlotBox:TBox;
    LogPattern:TIntegerArray;

    Begin
    MarkTime(TooLong);
    LogDTM := DTMFromString('mbQAAAHicY2VgYFjNwsAwB4h3AvFWIF4IxB OZGBimA/FMIO4A4m4gtjHhB6pmRMH/GTABIxYMBgB4vwfV');
    LogPattern:=[1,5,9,13,17,21,25,2,6,10,14,18,22,26,3,7,11,15,19, 23,27,4,8,12,16,20,24,28];
    For I:=0 To 27 Do
    Begin
    FindNormalRandoms;
    StatsGuise('Dropping Log:' + IntToStr(I));
    SlotBox:=InvBox(LogPattern[I]);
    If FindDTm(LogDTM,SeX,SeY,SlotBox.X1,SlotBox.Y1, SlotBox.X2, SlotBox.Y2) Then
    Begin
    MouseItem (LogPattern[I],False);
    ChooseOption ('Drop');
    End;

    End;
    MarkTime(TooLong);
    End;


    begin
    SetupSRL;
    DeclarePlayers;
    Repeat
    ChopDown;
    If InvFull Then
    DropLogs;
    Until(false);

    end.

  2. #2
    Join Date
    Jan 2012
    Posts
    2,568
    Mentioned
    35 Post(s)
    Quoted
    356 Post(s)

    Default

    Second parameter for MouseItem is an integer but you passed a Boolean to it. Use SRL integer constants: mouse_move, mouse_Left, move_Right.

  3. #3
    Join Date
    Jan 2013
    Posts
    11
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    They didn't work. :|
    Still getting the same issue.

  4. #4
    Join Date
    Jan 2012
    Posts
    2,568
    Mentioned
    35 Post(s)
    Quoted
    356 Post(s)

    Default

    What's the issue? Hint is not an error, it's simply because ur function result is unused.

  5. #5
    Join Date
    Feb 2006
    Location
    Tracy/Davis, California
    Posts
    12,631
    Mentioned
    135 Post(s)
    Quoted
    418 Post(s)

    Default

    This is the tutorial section, It's intended for Tutorials which help/teach users how to code.
    I've moved it to the scripting help section for you, please use that next time.
    Also it's also best to post all simba code in Simba tags when psoting so it's much easier to read.

    [.Simba]
    Program SimbaTags;
    Begin
    Writeln('Code goes in between these');
    End;[/simba]

    ^ Like that, but without the "." so

    Simba Code:
    Program SimbaTags;
    Begin
      Writeln('Code goes in between these');
    End;

  6. #6
    Join Date
    Sep 2012
    Location
    Australia.
    Posts
    839
    Mentioned
    16 Post(s)
    Quoted
    225 Post(s)

    Default

    Adding to what YoHoJo said, with the recent forum upgrade there is a new feature with the SIMBA tags!

    Use [simba=true][/simba]! It adds line numbers to your code so it's easier to get help. Example:

    Simba Code:
    1. program Oharroder;
    2. {i SRL/srl.simba}
    3.  
    4. procedure Errors;
    5. begin
    6.   RandomCode here; //Error starts here please help
    7. end;
    8.  
    9. begin
    10.   Writeln('Well... SIMBA tags are pro?');
    11.   Errors;
    12. end.

    You get the point.

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
  •