Page 68 of 117 FirstFirst ... 1858666768697078 ... LastLast
Results 1,676 to 1,700 of 2916

Thread: [AeroLib] HoodzFighter

  1. #1676
    Join Date
    May 2007
    Location
    baltimore, md
    Posts
    836
    Mentioned
    0 Post(s)
    Quoted
    8 Post(s)

    Default

    Edit again: Fixed everything, the great and powerful google is your friend everyone. Great script man.

  2. #1677
    Join Date
    Jun 2013
    Posts
    79
    Mentioned
    1 Post(s)
    Quoted
    62 Post(s)

    Default

    slayer oldschool or rs3?

  3. #1678
    Join Date
    Sep 2012
    Location
    Netherlands
    Posts
    2,752
    Mentioned
    193 Post(s)
    Quoted
    1468 Post(s)

    Default

    Quote Originally Posted by leeds4eva View Post
    slayer oldschool or rs3?
    Oldschool

  4. #1679
    Join Date
    Sep 2012
    Location
    Netherlands
    Posts
    2,752
    Mentioned
    193 Post(s)
    Quoted
    1468 Post(s)

    Default

    currently rewriting the color version of the script.

    edit: just made PERFECT combat detection in color, really fast + stable!

  5. #1680
    Join Date
    Feb 2014
    Posts
    2
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Great script although i'm a pure and it won't attack anything higher level than me that I can not one click. Can you possibly make a pure script to add in?

  6. #1681
    Join Date
    Feb 2013
    Location
    Narnia
    Posts
    615
    Mentioned
    8 Post(s)
    Quoted
    252 Post(s)

    Default

    just saw you had over 70k views on this! gratz man

    View my OSR Script Repository!


    Botted to max
    Guides: How to Report Bugs to the Scripter
    ~~~~ Moved to Java. Currently Lurking ~~~~

  7. #1682
    Join Date
    Mar 2013
    Posts
    2
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    HoodzFighter version 2,5
    Error: Exception: Mask is invalid. Width/Height: (9,6). WhiteHi/BlackHi: (-1,53) at line 778
    The following DTMs were not freed: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, SRL - Lamp bitmap, SRL - Book of Knowledge, 23, 24, 25, 26, 27, 28, 29, 30]
    The following bitmaps were not freed: [SRL - Mod bitmap, SRL - Admin bitmap, SRL - Minimap Mask bitmap, 3]
    Keeps happening after every few minutes...anyone wanna save me?

    Pops over the antirandoms tab when it does as well^ if that helps lol
    Last edited by zurius1; 02-12-2014 at 10:10 PM.

  8. #1683
    Join Date
    Feb 2014
    Posts
    16
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    Hey ive been having trouble starting this and I believe its because my OSRS-SLR folder is wack. Can some one that can at least get this working post their entire OSRS-SLR folder for me so I can try to figure out whats wrong?

  9. #1684
    Join Date
    Feb 2013
    Location
    Narnia
    Posts
    615
    Mentioned
    8 Post(s)
    Quoted
    252 Post(s)

    Default

    Quote Originally Posted by DangerDan View Post
    Hey ive been having trouble starting this and I believe its because my OSRS-SLR folder is wack. Can some one that can at least get this working post their entire OSRS-SLR folder for me so I can try to figure out whats wrong?
    by your numerous posts, inability to get it to work, and constant statement of OSRS-SLR im assuming you renamed the folder OSRS-SLR when infact it should be named SRL-OSR. if this isnt the case then delete your folder and reinstal the SRL-OSR master zip and extract it correctly

    SRL not SLR

    View my OSR Script Repository!


    Botted to max
    Guides: How to Report Bugs to the Scripter
    ~~~~ Moved to Java. Currently Lurking ~~~~

  10. #1685
    Join Date
    Feb 2014
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    4 Post(s)

    Default

    @Hoodz Hey so first off very nice script! I haven't ran it but I remember when this first came out and it was pretty much flawless then.
    A few posts before I read that it might be outdated, is this still true?
    Because when I compile it doesn't load "MiniReflection.simba" because I dont have that file, because I updated everything to work with @Elfyyy's PC script.
    So my reflection is at: "C:\Simba\Includes\SRL-OSR\SRL\reflection" and the same thing with the antirandoms, instead of "C_AntiRandoms.simba" I have "C:\Simba\Includes\SRL-OSR\SRL\core\antirandoms\antirandoms.simba"
    Last edited by Veni Vidi Vici; 02-13-2014 at 04:59 AM.

  11. #1686
    Join Date
    Sep 2012
    Location
    Netherlands
    Posts
    2,752
    Mentioned
    193 Post(s)
    Quoted
    1468 Post(s)

    Default

    Quote Originally Posted by Sk1nyNerd View Post
    just saw you had over 70k views on this! gratz man
    thanks!
    Quote Originally Posted by DangerDan View Post
    Hey ive been having trouble starting this and I believe its because my OSRS-SLR folder is wack. Can some one that can at least get this working post their entire OSRS-SLR folder for me so I can try to figure out whats wrong?
    enter the constants correctly
    Quote Originally Posted by Veni Vidi Vici View Post
    @Hoodz Hey so first off very nice script! I haven't ran it but I remember when this first came out and it was pretty much flawless then.
    A few posts before I read that it might be outdated, is this still true?
    Because when I compile it doesn't load "MiniReflection.simba" because I dont have that file, because I updated everything to work with @Elfyyy's PC script.
    So my reflection is at: "C:\Simba\Includes\SRL-OSR\SRL\reflection" and the same thing with the antirandoms, instead of "C_AntiRandoms.simba" I have "C:\Simba\Includes\SRL-OSR\SRL\core\antirandoms\antirandoms.simba"
    currrently revamping this script, but you can find a working version here:
    Simba Code:
    program HoodFighter;
    {$DEFINE SMART8}
    {$I SRL-OSR/SRL.Simba}
    {$I SRL-OSR/SRL/misc/al_functions.simba}
    {$I SRL-OSR/SRL/Reflection/Reflection.simba}

    var
      x, y, hp, fooddtm, startcount, startxpskill, startxphp, gainedxpskill, gainedxphp, gainedxphourskill, gainedxphourhp: integer;
      Hue, Sat: TExtendedArray;
      MonsterColor, tol: TIntegerarray;

    const

       {player info}
      NICKNAME = '';
      USERNAME = '';
      PASSWORD = '';

      {hp/food info}
      {salmon, shark, lobster, trout}
      foodname = 'lobster';

      {monster/npc info} {use ACA} {current setup: yaks}
      {1}
      monstercolor1 = 3225412;
      hue1 = 0.16;
      sat1 = 0.44;
      tol1 = 14;

      {second monster, NOTE: if you want to use the same monster just copy the numbers from (1)}
      {2}
      monstercolor2 = 3225412;
      hue2 = 0.16;
      sat2 = 0.44;
      tol2 = 14;

      {other}

      {NEW 1.6}
      ADDWAIT = 100; {increase with 100 until you get it fast + stable, decrease if you want it to attack faster {1000 = 1 sec}
      {-------}

      TRAININGMODE = 2;
      ANTIBANTRAININGMODE = skill_range;   {Combat skill you are training: skill_defence, skill_attack, skill_strength, skill_range, skill_magic}
      WORLD = 1;
      RIGHTCLICKONLY = false;
      VERSION = '8';

    procedure DeclarePlayers;
    begin
      HowManyPlayers := 1;
      NumberOfPlayers(HowManyPlayers);
      CurrentPlayer := 0;
      with Players[0] do
      begin
        Name := USERNAME;
        Pass := PASSWORD;
        nick := NICKNAME;
        Active := True;
      end;
    end;

    procedure foodsetup;
    begin
      MonsterColor := [MonsterColor1, MonsterColor2];
      Hue := [Hue1, Hue2];
      Sat := [Sat1, Sat2];
      Tol := [Tol1, Tol2];
      case FoodName of
        'lobster':
          begin
            FoodDTM := DTMFromString('m6wAAAHic42ZgYHBhYmDwgmJPIHYEYhsgNodiOyB2BWIfIA5gZGCIAeIoIPYD4lAoDoPyfYDYC4idgHhHshjQdEaisAaQJBYTZyIEIwEA/ycJgA==');
          end;
        'salmon':
          begin
            FoodDTM := DTMFromString('mggAAAHicY2NgYOCGYhDgA2IJIBYGYi4gFgJifiBmhMqDxA44SkBFUDErAyZgxaoSYR4DAwCTLQG6');
          end;
        'trout':
          begin
            FoodDTM := DTMFromString('mggAAAHicY2NgYOAGYmEglgBiPgYIAIlxQTEIMAIxPxALAXF5UhxUBBWzAklWBkyAqRKCIQAAnDwB2A==');
          end;
        'shark':
          begin
            FOODDTM := DTMFromString('mlwAAAHicY2dgYOACYkYgZgViESCWYoAALiiWgfKZoXK8QCwMxDnBtlCdmJidATfArgOCoQAAsEwBww==');
          end;
      end;
    end;

    procedure SetupUpdater;
    var
      NewFile: integer;
      OnlineVersion, NewScript, NewFileName: string;
    begin
      writeln('Checking for script updates...');
      OnlineVersion := GetPage('http://pastebin.com/raw.php?i=dfiXPdg4');
      if (trim(OnlineVersion) > Version) then
      begin
        writeLn('Script update available!');
        writeLn('Updating script to v' + OnlineVersion);
        NewScript := GetPage('http://pastebin.com/raw.php?i=8unVMMBc');
        NewFileName := 'C:\Simba\Scripts\' + 'HoodzFighter.simba';
        NewFile := Rewritefile(NewFileName, true);
        try
          WriteFileString(NewFile, NewScript);
        except
          begin
            writeLn('Fatal error writing to ' + NewFileName + '!!');
            terminatescript;
          end;
        end;
        CloseFile(NewFile);
        writeLn('New script downloaded to ' + NewFileName + '. Please restart Simba.');
        TerminateScript;
      end
      else
        writeLn('You have the latest version of the script!');
    end;

    procedure TheStatus;
    begin
      FindNonInventoryRandoms;
      ClearDebug;
      GainedXpSkill := Round(R_GetSkillExp(ANTIBANTRAININGMODE) - StartXpSkill);
      GainedXpHp := Round(R_GetSkillExp(Skill_Hitpoints) - StartXpHp);
      GainedXpHourSkill := Round((GainedXpSkill) / (GetTimeRunning / 3600000.0));
      GainedXpHourHp := Round((GainedXpHp) / (GetTimeRunning / 3600000.0));
      Writeln('cb xp: ' + IntToStr(GainedXpSkill));
      Writeln('cb xp/hour: ' + IntToStr(GainedXpHourSkill));
      Writeln('hp xp: ' + IntToStr(GainedXpHp));
      Writeln('hp xp/hour: ' + IntToStr(GainedXpHourHp));
      Writeln('time running: ' + MsToTime(GetTimeRunning, 3));
      Writeln('Hp random eat: ' + IntToStr(HP));
      Writeln('Hp: ' + IntToStr(R_GetSkillLevel(Skill_Hitpoints)));
      Writeln('your level = ' + IntToStr(R_getMaxSkillLevel(antibantrainingmode)));
    end;

    procedure AntiBan;
    begin
      case Random(1000) of
        0..1:
          begin
            Al_HoverSkill(ANTIBANTRAININGMODE, False);
            Sleep(800 + Random(500));
          end;
        2..3:
          begin
            Al_HoverSkill(Skill_Hitpoints, False);
            Sleep(800 + Random(500));
          end;
        4..10:
          begin
            MakeCompass(RandomRange(0, 360));
            Sleep(800 + Random(500));
          end;
        11..26:
          begin
            AL_HumanRandomMouse;
            Sleep(800 + Random(500));
          end;
        18:
          begin
            AdjustMouseSpeed(2, 10, 20);
            Sleep(800 + Random(500));
          end;
        19:
          begin
            RandomRClick;
            Sleep(800 + Random(500));
          end;
        20:
          begin
            HoverMovingObject;
            Sleep(800 + Random(500));
          end;
        21:
          begin
            MMouseOffClient('top');
            Sleep(800 + Random(500));
          end;
        22:
          begin
            MMouseOffClient('left');
            Sleep(800 + Random(500));
          end;
        23:
          begin
            MMouseOffClient('right');
            Sleep(800 + Random(500));
          end;
        24:
          begin
            MMouseOffClient('bottom');
            Sleep(800 + Random(500));
          end;
        25..26:
          begin
            if IsRunOn(False) then
            begin
              SetRun(True);
            end
          end;
        29..31:
          begin
            RandomTab(False);
            Sleep(1000 + Random(500));
            AL_GameTab(Tab_Inv);
          end;
      end;
    end;

    procedure Attackmonster;
    var
      TPAA: T2DPointArray;
      TPA: TPointArray;
      CTS, I, Retry, x, y, t, R1, R2: Integer;
      MP: Tpoint;
      Box, pbox2, pbox: Tbox;
    begin
      if (not LoggedIn) then
      begin
        Exit;
      end
      else
      begin
        pbox2 := IntToBox(188, 23, 379, 64);
        PBox := IntToBox(223, 127, 295, 196);
        CTS := GetColorToleranceSpeed;
        ColorToleranceSpeed(2);
        MarkTime(T);
        for R1 := 0 to high(Hue) do
        begin
          CTS := GetColorToleranceSpeed;
          ColorToleranceSpeed(2);
          SetColorSpeed2Modifiers(Hue[R1], Sat[R1]);
          FindColorsSpiralTolerance(mscx, mscy, TPA, Monstercolor[R1], msx1, msy1, msx2, msy2, tol[R1]);
          ColorToleranceSpeed(CTS);
          TPAA := TPAToATPAEx(TPA, 20, 20);
          SortATPASize(TPAA, True);
          for I := 0 to High(TPAA) do
            if GetArraylength(TPAA[R2]) > 50 then
            begin
              Inc(Retry);
              MiddleTPAEx(TPAA[R2], x, y);
              MP := MiddleTPA(TPAA[R2]);
              Box := IntToBox(MP.x - 20, MP.y - 17, MP.x + 20, MP.y + 17);
              if (not (FindColor(X, Y, 255, mp.x - 20, mp.y - 25, mp.x + 20, mp.y + 15) or FindColor(X, Y, 65280, mp.x - 20, mp.y - 25, mp.x + 20, mp.y + 25))) then
              begin
                Al_MissMouse(Point(x, y), 5, 5);
                Sleep(10 + Random(10));
                if (RIGHTCLICKONLY) then
                begin
                  Wait(200 + random(100));
                  AL_ChooseOptionMulti(['tta']);
                  Flag;
                  Wait(2500 + Random(500));
                  Exit;
                end
                else
                begin
                  case Random(6) of
                    0..4:
                      begin
                        Al_fastclick(Mouse_Left);
                        Flag;
                        Exit;
                      end;
                    5:
                      begin
                        AL_fastclick(Mouse_Right);
                        Wait(200 + Random(100));
                        AL_ChooseOptionMulti(['tta']);
                        Flag;
                        Exit;
                      end;
                  end;
                end;
              end
              else
              begin
                case Random(8) of
                  1:
                    begin
                      Sleep(1000 + Random(230));
                      MakeCompass(RandomRange(0, 360));
                    end;
                end;
                Sleep(1000 + Random(230));
                FindNonInventoryRandoms();
                AttackMonster;
                Exit;
              end;
            end
          else
          begin
            MakeCompass(RandomRange(0, 360));
            Sleep(1000 + Random(230));
            FindNonInventoryRandoms();
            AttackMonster;
            Exit;
          end;
        end;
      end;
    end;

    procedure GenerateHP;
    var
      HP1, HP2: Integer;
    begin
      HP1 := Round(R_GetSkillLevel(Skill_Hitpoints) / 2) + Round(R_GetSkillLevel(Skill_Hitpoints) / 6);
      HP2 := Round(R_GetSkillLevel(Skill_Hitpoints) / 2) + Round(R_GetSkillLevel(Skill_Hitpoints) / 4);
      HP := RandomRange(HP1, HP2);
    end;

    procedure Eating_Food;
    begin
      if (R_GetSkillLevel(Skill_Hitpoints) > HP) then
      begin
        Wait(700 + Random(200));
        FindNonInventoryRandoms;
        Antiban;
      end
      else
      begin
        AL_gametab(Tab_Inv);
        Wait(120 + Random(200));
        if (Gametab(Tab_Inv)) then
        begin
          if (FindDtm(FoodDTM, x, y, MIX1, MIY1, MIX2, MIY2)) then
          begin
            Al_MissMouse(Point(x, y), 5, 5);
            Sleep(150 + Random(100));
            AL_FastClick(Mouse_Left);
            FindNormalRandoms();
            Sleep(1000 + Random(1000));
            AL_GameTab(Tab_Inv);
            GenerateHP;
            FindNonInventoryRandoms;
          end
          else
          begin
            Sleep(30000);
            LogOut;
          end;
        end;
      end;
    end;

    function IsInCombat: Boolean;
    begin
      if (R_WaitForAnimation(950 + ADDWAIT)) then
      begin
        FindNonInventoryRandoms;
        result := true
      end;
    end;

    procedure Skill_FailSafe;
    begin
      if FindColor(X, Y, 8042720, 485, 11, 515, 32) then
      begin
        MMouse(x, y, 3, 3);
        Clickmouse2(Mouse_Left);
        Wait(400 + Random(300))
      end
      else
      begin
        FindNonInventoryRandoms;
        AttackMonster;
      end;
    end;

    procedure ClearTheDTM;
    begin
      FreeDTM(FoodDTM);
      AddOnTerminate('clearthedtm');
    end;

    begin
      DeclarePlayers;
      FoodSetup;
      Smart_World := WORLD;
      SetupReflection;
      SetupUpdater;
      SetupSRL();
      Disguise('HoodzFighter Reflection v1,3');
      SRL_CombatRandoms := False;
      ActivateClient;
      ClearDebug;
      Writeln('HoodzFighter Reflection version 1,3');
      GenerateHP;
      repeat
        if (not LoggedIn) then
        begin
          if (StartCount = 0) then
          begin
            Inc(StartCount);
            LogInPlayer;
            SetAngle(0);
            Setrun(true);
            Setfightmode(trainingmode);
            AL_Gametab(tab_stats);
            StartXpSkill := Round(R_getskillexp(ANTIBANTRAININGMODE));
            StartXpHp := Round(R_GetSkillExp(Skill_Hitpoints));
            Writeln('start xp cb = ' + IntToStr(StartXpSkill));
            Writeln('start xp hp = ' + IntToStr(StartXpHp));
            GenerateHp;
          end
          else
          begin
            LogInPlayer;
            SetAngle(0);
            SetRun(True);
            Setfightmode(TrainingMode);
            AL_GameTab(Tab_Stats);
          end;
        end;
        if (LoggedIn) then
        begin
          if StartCount = 0 then
          begin
            GenerateHP;
            Inc(StartCount);
            ClearDebug;
            StartXpSkill := Round(R_getSkillExp(ANTIBANTRAININGMODE));
            StartXpHp := Round(R_GetSkillExp(Skill_Hitpoints));
            writeln('start xp cb = ' + IntToStr(StartXpSkill));
            writeln('start xp hp = ' + IntToStr(StartXpHp));
            if (IsInCombat) then
            begin
              Eating_Food;
            end
            else
            begin
              Skill_FailSafe;
            end;
          end
          else
          begin
            if (IsIncombat) then
            begin
              Eating_Food;
              TheStatus;
            end
            else
            begin
              Skill_FailSafe;
              FindNonInventoryRandoms();
            end;
          end;
        end;
      until (false);
    end.

  12. #1687
    Join Date
    Feb 2014
    Posts
    16
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    That was it thanks

  13. #1688
    Join Date
    Feb 2012
    Location
    US
    Posts
    83
    Mentioned
    0 Post(s)
    Quoted
    17 Post(s)

    Default

    just a coding question (and I haven't looked at your code lines 1:1 to see the exact differences, if any), but why do you have attackmonster1-6 rewritten 6 times? you could reduce your code by at least 500 lines just by some variable swaps; that's fully 1/3 of your code.
    Zaros

  14. #1689
    Join Date
    Sep 2012
    Location
    Netherlands
    Posts
    2,752
    Mentioned
    193 Post(s)
    Quoted
    1468 Post(s)

    Default

    Quote Originally Posted by Zaros View Post
    just a coding question (and I haven't looked at your code lines 1:1 to see the exact differences, if any), but why do you have attackmonster1-6 rewritten 6 times? you could reduce your code by at least 500 lines just by some variable swaps; that's fully 1/3 of your code.
    that version is months old, thats why im rewriting the script!

  15. #1690
    Join Date
    Feb 2012
    Location
    US
    Posts
    83
    Mentioned
    0 Post(s)
    Quoted
    17 Post(s)

    Default

    oh... haha yeah I haven't been here in like a year. just thought i'd check out the popular osrs scripts, and obviously yours is one of them. Is the reflection one newer?
    Zaros

  16. #1691
    Join Date
    Sep 2012
    Location
    Netherlands
    Posts
    2,752
    Mentioned
    193 Post(s)
    Quoted
    1468 Post(s)

    Default

    Quote Originally Posted by Zaros View Post
    oh... haha yeah I haven't been here in like a year. just thought i'd check out the popular osrs scripts, and obviously yours is one of them. Is the reflection one newer?
    Yes use the version i posted on post 1688.

  17. #1692
    Join Date
    Feb 2014
    Posts
    1
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Can you recommend me a monster which is different color like ground, barbarians are unuseable, but giant rets at edgeville dungeon are good (grey on brown) . Im looking for higher cb monter than rats, 10-13 lvl. can you help me please? thank you for your replay

  18. #1693
    Join Date
    Feb 2012
    Location
    US
    Posts
    83
    Mentioned
    0 Post(s)
    Quoted
    17 Post(s)

    Default

    Quote Originally Posted by hoodz View Post
    Yes use the version i posted on post 1688.
    I do have it working quite nicely, thank you! Just another quick question.. why is it so "clicky"? Like.. It doesn't detect if you're in combat, and this looks especially suspicious if you're in single-way. Also, there's no up-text checking in this version? I've spent a bit of time clicking on non-killable NPCs lol.
    Zaros

  19. #1694
    Join Date
    Feb 2014
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    4 Post(s)

    Default

    Thanks for giving me a alternate script to use! It works good, but one suggestion is to change how it detects the HP and to eat. It likes to risk it and eat a 6 hp and then ends up dying.

  20. #1695
    Join Date
    Feb 2012
    Location
    US
    Posts
    83
    Mentioned
    0 Post(s)
    Quoted
    17 Post(s)

    Default

    Quote Originally Posted by Veni Vidi Vici View Post
    Thanks for giving me a alternate script to use! It works good, but one suggestion is to change how it detects the HP and to eat. It likes to risk it and eat a 6 hp and then ends up dying.

    You can change the generate hp function to be more generous with health. Also if you read the OP it says you need a teletab or it goes to death without one.
    Zaros

  21. #1696
    Join Date
    Apr 2013
    Posts
    56
    Mentioned
    0 Post(s)
    Quoted
    22 Post(s)

    Default

    Not working

  22. #1697
    Join Date
    Sep 2012
    Location
    Netherlands
    Posts
    2,752
    Mentioned
    193 Post(s)
    Quoted
    1468 Post(s)

    Default

    Quote Originally Posted by Bearzs View Post
    Not working
    now i know what the problem is and can fix it!

    currently revamping the script so you have to wait..

  23. #1698
    Join Date
    Feb 2014
    Posts
    16
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    I have this working, I've made a couple changes and added prayer support to version hoodz posted above although its a little buggy. Not sure if people were still having problems but here it is:

    PS: its set to kill black demons using prayer atm

    Simba Code:
    program HoodFighter;
    {$DEFINE SMART8}
    {$I SRL-OSR/SRL.Simba}
    {$I SRL-OSR/SRL/misc/al_functions.simba}
    {$I SRL-OSR/SRL/Reflection/Reflection.simba}

    var
      x, y, hp, fooddtm, startcount, startxpskill, startxphp, gainedxpskill, gainedxphp, gainedxphourskill, gainedxphourhp: integer;
      Hue, Sat: TExtendedArray;
      MonsterColor, tol: TIntegerarray;

      DrinkPray, IP, DrinkPray1, DrinkPray2: integer;
      Pray1, Pray2, Pray3, Pray4: integer;
      Pray: TIntegerarray;

    const

      {player info}
      NICKNAME = '';
      USERNAME = '';
      PASSWORD = '';

      {hp/food info}
      {salmon, shark, lobster, trout}
      foodname = 'lobster';

      {monster/npc info} {use ACA} {current setup: yaks}
      {1}
      monstercolor1 = 2105380;
      hue1 = 0.00;
      sat1 = 0.53;
      tol1 = 7;

      {potion info} {note, you must manually turn on prayer}
      UsePrayer = true;  {set to true if you want to use prayer}

      {other}
      ADDWAIT = 700; {increase with 100 until you get it fast + stable, decrease if you want it to attack faster {1000 = 1 sec}
      TRAININGMODE = 1;
      ANTIBANTRAININGMODE = skill_slayer;  {Combat skill you are training: skill_defence, skill_attack, skill_strength, skill_range, skill_magic}
      WORLD = 30;
      RIGHTCLICKONLY = true;  {true if you want to right click the monster}
      VERSION = '8';

    function IsInCombat: Boolean;
    begin
      if (R_WaitForAnimation(950 + ADDWAIT)) then
      begin
        FindNonInventoryRandoms;
        result := true
      end;
    end;

    procedure DeclarePlayers;
    begin
      HowManyPlayers := 1;
      NumberOfPlayers(HowManyPlayers);
      CurrentPlayer := 0;
      with Players[0] do
      begin
        Name := USERNAME;
        Pass := PASSWORD;
        nick := NICKNAME;
        Active := True;
      end;
    end;

    procedure foodsetup;
    begin
      MonsterColor := [MonsterColor1];
      Hue := [Hue1];
      Sat := [Sat1];
      Tol := [Tol1];
      case FoodName of
        'lobster':
          begin
            FoodDTM := DTMFromString('m6wAAAHic42ZgYHBhYmDwgmJPIHYEYhsgNodiOyB2BWIfIA5gZGCIAeIoIPYD4lAoDoPyfYDYC4idgHhHshjQdEaisAaQJBYTZyIEIwEA/ycJgA==');
          end;
        'salmon':
          begin
            FoodDTM := DTMFromString('mggAAAHicY2NgYOCGYhDgA2IJIBYGYi4gFgJifiBmhMqDxA44SkBFUDErAyZgxaoSYR4DAwCTLQG6');
          end;
        'trout':
          begin
            FoodDTM := DTMFromString('mggAAAHicY2NgYOAGYmEglgBiPgYIAIlxQTEIMAIxPxALAXF5UhxUBBWzAklWBkyAqRKCIQAAnDwB2A==');
          end;
        'shark':
          begin
            FOODDTM := DTMFromString('mlwAAAHicY2dgYOACYkYgZgViESCWYoAALiiWgfKZoXK8QCwMxDnBtlCdmJidATfArgOCoQAAsEwBww==');
          end;
      end;
    end;

    procedure OnEnd;
    begin
      FreeDTM(Pray1);
      FreeDTM(Pray2);
      FreeDTM(Pray3);
      FreeDTM(Pray4);
    end;

    procedure ArraySetup;
    begin

      Pray1 := DTMFromString('mWAAAAHicY2FgYLjLxMDwFIivAfF9INZgZGBQg2IDEN7eBVTFCMdsDKiAEQ2DAACFtgWq'); {1 dose}
      Pray2 := DTMFromString('mWAAAAHicY2FgYGBjYmDgAmJ+IGYAYg1GBgYTINaCYvnKGKAEIxxzMaACRjQMAgBrxQHl');
      Pray3 := DTMFromString('mWAAAAHicY2FgYGhlYmBoB+JGIO4DYg1GBgYzRgitB8QWl+YDVTHCMTsDKmBEwyAAACq5BJc=');
      Pray4 := DTMFromString('mWAAAAHicY2FgYIhmYmCIAuIUIA4FYjVGBgYzINYFYi0gTr26BqiKEY65GFABIxoGAQACtAQp'); {4 dose}

      Pray := [Pray1, Pray2, Pray3, Pray4];

      AddOnTerminate('OnEnd');
    end;

    procedure RandomPot;
    begin
      DrinkPray1 := R_GetMaxSkillLevel(Skill_Prayer) / 3;
      DrinkPray2 := R_GetMaxSkillLevel(Skill_Prayer) / 2;
      DrinkPray := Randomrange(DrinkPray1, DrinkPray2);
      Writeln('Generated drink pot at: ' + IntToStr(DrinkPray));
    end;

    procedure SetupUpdater;
    var
      NewFile: integer;
      OnlineVersion, NewScript, NewFileName: string;
    begin
      writeln('Checking for script updates...');
      OnlineVersion := GetPage('http://pastebin.com/raw.php?i=dfiXPdg4');
      if (trim(OnlineVersion) < Version) then
      begin
        writeLn('Script update available!');
        writeLn('Updating script to v' + OnlineVersion);
        NewScript := GetPage('http://pastebin.com/raw.php?i=8unVMMBc');
        NewFileName := 'C:\Simba\Scripts\' + 'HoodzFighter.simba';
        NewFile := Rewritefile(NewFileName, true);
        try
          WriteFileString(NewFile, NewScript);
        except
          begin
            writeLn('Fatal error writing to ' + NewFileName + '!!');
            terminatescript;
          end;
        end;
        CloseFile(NewFile);
        writeLn('New script downloaded to ' + NewFileName + '. Please restart Simba.');
        TerminateScript;
      end
      else
        writeLn('You have the latest version of the script!');
    end;

    procedure PrayerProcedure;
    begin
      if (R_GetSkillLevel(Skill_Prayer) < DrinkPray) then
      begin
        AL_gametab(Tab_Inv);
        for IP := 0 to High(Pray) do
        begin
          if (FindDTM(Pray[IP], x, y, MIX1, MIY1, MIX2, MIY2)) then
          begin
            Al_MissMouse(point(x, y), randomrange(-5, 5), randomrange(-5, 5));
            Sleep(150 + random(50));
            Al_FastClick(Mouse_Left);
            RandomPot;
            Exit;
          end
          else
          begin
            Writeln('out of pray pots');
          end;
        end;
      end
    end;

    procedure TheStatus;
    begin
      FindNonInventoryRandoms;
      ClearDebug;
      GainedXpSkill := Round(R_GetSkillExp(ANTIBANTRAININGMODE) - StartXpSkill);
      GainedXpHp := Round(R_GetSkillExp(Skill_Hitpoints) - StartXpHp);
      GainedXpHourSkill := Round((GainedXpSkill) / (GetTimeRunning / 3600000.0));
      GainedXpHourHp := Round((GainedXpHp) / (GetTimeRunning / 3600000.0));
      Writeln('time running: ' + MsToTime(GetTimeRunning, 3));
      Writeln('cb xp: ' + IntToStr(GainedXpSkill));
      Writeln('cb xp/hour: ' + IntToStr(GainedXpHourSkill));
      Writeln('hp xp: ' + IntToStr(GainedXpHp));
      Writeln('hp xp/hour: ' + IntToStr(GainedXpHourHp));
      Writeln('Hp random eat: ' + IntToStr(HP));
      if (UsePrayer) then
      begin
      Writeln('Prayer random pot: ' + IntToStr(DrinkPray));
      end;
      Writeln('level = ' + IntToStr(R_getMaxSkillLevel(antibantrainingmode)));
    end;

    procedure AntiBan;
    begin
      case Random(1000) of
        0..1:
          begin
            Al_HoverSkill(ANTIBANTRAININGMODE, False);
            Sleep(800 + Random(500));
          end;
        2..3:
          begin
            Al_HoverSkill(Skill_Hitpoints, False);
            Sleep(800 + Random(500));
          end;
        4..10:
          begin
            MakeCompass(RandomRange(0, 360));
            Sleep(800 + Random(500));
          end;
        11..26:
          begin
            AL_HumanRandomMouse;
            Sleep(800 + Random(500));
          end;
        18:
          begin
            AdjustMouseSpeed(2, 10, 20);
            Sleep(800 + Random(500));
          end;
        19:
          begin
            RandomRClick;
            Sleep(800 + Random(500));
          end;
        20:
          begin
            HoverMovingObject;
            Sleep(800 + Random(500));
          end;
        21:
          begin
            MMouseOffClient('top');
            Sleep(800 + Random(500));
          end;
        22:
          begin
            MMouseOffClient('left');
            Sleep(800 + Random(500));
          end;
        23:
          begin
            MMouseOffClient('right');
            Sleep(800 + Random(500));
          end;
        24:
          begin
            MMouseOffClient('bottom');
            Sleep(800 + Random(500));
          end;
        25..26:
          begin
            if IsRunOn(False) then
            begin
              SetRun(True);
            end
          end;
        29..31:
          begin
            RandomTab(False);
            Sleep(1000 + Random(500));
            AL_GameTab(Tab_Inv);
          end;
      end;
    end;

    procedure Attackmonster;
    var
      TPAA: T2DPointArray;
      TPA: TPointArray;
      CTS, I, Retry, x, y, t, R1, R2: Integer;
      MP: Tpoint;
      Box, pbox2, pbox: Tbox;
    begin
      if (not LoggedIn) then
      begin
        Exit;
      end
      else
      begin
        pbox2 := IntToBox(188, 23, 379, 64);
        PBox := IntToBox(223, 127, 295, 196);
        CTS := GetColorToleranceSpeed;
        ColorToleranceSpeed(2);
        MarkTime(T);
        for R1 := 0 to high(Hue) do
        begin
          CTS := GetColorToleranceSpeed;
          ColorToleranceSpeed(2);
          SetColorSpeed2Modifiers(Hue[R1], Sat[R1]);
          FindColorsSpiralTolerance(mscx, mscy, TPA, Monstercolor[R1], msx1, msy1, msx2, msy2, tol[R1]);
          ColorToleranceSpeed(CTS);
          TPAA := TPAToATPAEx(TPA, 20, 20);
          SortATPASize(TPAA, True);
          for I := 0 to High(TPAA) do
            if GetArraylength(TPAA[R2]) > 50 then
            begin
              Inc(Retry);
              MiddleTPAEx(TPAA[R2], x, y);
              MP := MiddleTPA(TPAA[R2]);
              Box := IntToBox(MP.x - 20, MP.y - 17, MP.x + 20, MP.y + 17);
              if (not (FindColor(X, Y, 255, mp.x - 20, mp.y - 25, mp.x + 20, mp.y + 15) or FindColor(X, Y, 65280, mp.x - 20, mp.y - 25, mp.x + 20, mp.y + 25))) then
              begin
                Al_MissMouse(Point(x, y), 5, 5);
                Sleep(10 + Random(10));
                if (RIGHTCLICKONLY) then
                begin
                  AL_fastclick(Mouse_Right);
                  Wait(200 + Random(100));
                  AL_ChooseOptionMulti(['tta']);
                  Flag;
                  Exit;
                end
                else
                begin
                  case Random(6) of
                    0..4:
                      begin
                        Al_fastclick(Mouse_Left);
                        Flag;
                        Exit;
                      end;
                    5:
                      begin
                        AL_fastclick(Mouse_Right);
                        Wait(200 + Random(100));
                        AL_ChooseOptionMulti(['tta']);
                        Flag;
                        Exit;
                      end;
                  end;
                end;
              end
              else
              begin
                case Random(8) of
                  1:
                    begin
                      Sleep(1000 + Random(230));
                      MakeCompass(RandomRange(0, 360));
                    end;
                end;
                Sleep(1000 + Random(230));
                FindNonInventoryRandoms();
                AttackMonster;
                Exit;
              end;
            end
          else
          begin
            MakeCompass(RandomRange(0, 360));
            Sleep(1000 + Random(230));
            FindNonInventoryRandoms();
            AttackMonster;
            Exit;
          end;
        end;
      end;
    end;

    procedure GenerateHP;
    var
      HP1, HP2: Integer;
    begin
      HP1 := Round(R_GetSkillLevel(Skill_Hitpoints) / 2) + Round(R_GetSkillLevel(Skill_Hitpoints) / 6);
      HP2 := Round(R_GetSkillLevel(Skill_Hitpoints) / 2) + Round(R_GetSkillLevel(Skill_Hitpoints) / 4);
      HP := RandomRange(HP1, HP2);
    end;

    procedure Eating_Food;
    begin
      if (R_GetSkillLevel(Skill_Hitpoints) > HP) then
      begin
        Wait(700 + Random(200));
        FindNonInventoryRandoms;
        Antiban;
      end
      else
      begin
        AL_gametab(Tab_Inv);
        Wait(120 + Random(200));
        if (Gametab(Tab_Inv)) then
        begin
          if (FindDtm(FoodDTM, x, y, MIX1, MIY1, MIX2, MIY2)) then
          begin
            Al_MissMouse(Point(x, y), 5, 5);
            Sleep(150 + Random(100));
            AL_FastClick(Mouse_Left);
            FindNormalRandoms();
            Sleep(1000 + Random(1000));
            AL_GameTab(Tab_Inv);
            GenerateHP;
            FindNonInventoryRandoms;
          end
          else
          begin
            Sleep(30000);
            LogOut;
          end;
        end;
      end;
    end;

    procedure Skill_FailSafe;
    begin
      if FindColor(X, Y, 8042720, 485, 11, 515, 32) then
      begin
        MMouse(x, y, 3, 3);
        Clickmouse2(Mouse_Left);
        Wait(400 + Random(300))
      end
      else
      begin
        FindNonInventoryRandoms;
        AttackMonster;
      end;
    end;

    procedure ClearTheDTM;
    begin
      FreeDTM(FoodDTM);
      AddOnTerminate('clearthedtm');
    end;

    begin
      DeclarePlayers;
      FoodSetup;
      Smart_World := WORLD;
      SetupSRL();
      SetupReflection;
      SetupUpdater;
      Disguise('HoodzFighter Reflection v1,3');
      SRL_CombatRandoms := False;
      ActivateClient;
      ClearDebug;
      Writeln('HoodzFighter Reflection version 1,3');
      GenerateHP;
      repeat
        if (not LoggedIn) then
        begin
          if (StartCount = 0) then
          begin
            Inc(StartCount);
            LogInPlayer;
            SetAngle(0);
            Setrun(true);
            Setfightmode(trainingmode);
            AL_Gametab(tab_stats);
            StartXpSkill := Round(R_getskillexp(ANTIBANTRAININGMODE));
            StartXpHp := Round(R_GetSkillExp(Skill_Hitpoints));
            Writeln('start xp cb = ' + IntToStr(StartXpSkill));
            Writeln('start xp hp = ' + IntToStr(StartXpHp));
            GenerateHp;
          end
          else
          begin
            LogInPlayer;
            SetAngle(0);
            SetRun(True);
            Setfightmode(TrainingMode);
            AL_GameTab(Tab_Stats);
          end;
        end;
        if (LoggedIn) then
        begin
          if StartCount = 0 then
          begin
            GenerateHP;
            Inc(StartCount);
            ClearDebug;
            StartXpSkill := Round(R_getSkillExp(ANTIBANTRAININGMODE));
            StartXpHp := Round(R_GetSkillExp(Skill_Hitpoints));
            writeln('start xp cb = ' + IntToStr(StartXpSkill));
            writeln('start xp hp = ' + IntToStr(StartXpHp));
            ArraySetup;
            RandomPot;
            if (IsInCombat) then
            begin
              Eating_Food;
            end
            else
            begin
              Skill_FailSafe;
            end;
          end
          else
          begin
            if (UsePrayer) then
            PrayerProcedure;
            if (IsIncombat) then
            begin
              Eating_Food;
              TheStatus;
            end
            else
            begin
              Skill_FailSafe;
              FindNonInventoryRandoms();
            end;
          end;
        end;
      until (false);
    end.

  24. #1699
    Join Date
    Sep 2012
    Location
    Netherlands
    Posts
    2,752
    Mentioned
    193 Post(s)
    Quoted
    1468 Post(s)

    Default

    almost done with the reflection version. looting/fighting 90% done, pots 100%. also need to add a failsafe to isInCombat function and i need to add some random finders.

  25. #1700
    Join Date
    Feb 2013
    Location
    Narnia
    Posts
    615
    Mentioned
    8 Post(s)
    Quoted
    252 Post(s)

    Default

    Quote Originally Posted by hoodz View Post
    almost done with the reflection version. looting/fighting 90% done, pots 100%. also need to add a failsafe to isInCombat function and i need to add some random finders.
    heres a loot items thing i made a couple weeks ago. LootListIDs is the array of ids we are looking for and LootListName is the corresponding name to that id. idk if this helps or not
    Simba Code:
    function LootItems: Boolean;
    var
      i, j, k: integer;
      LootLocation: Tpoint;
      AvailableLoots: TGroundItemArray;
    begin
      Result := False;

      AvailableLoots := R_GetGroundItemsDistance(10);

      for i := 0 to High(AvailableLoots) do
      begin
        for j := 0 to High(LootListIDs) do
        begin
          if (AvailableLoots[i].ID = LootListIDs[j]) then
          begin
            for k := 0 to High(LootListNames) do
            begin
              LootLocation := R_TileToMS(AvailableLoots[i].Tile);
              MMouse(LootLocation.x, LootLocation.y, 2, 2);
              HumanWait;
              if (R_IsUpText(LootListNames[k])) then
              begin
                ClickMouse2(mouse_left);
                Result := True;
              end else
              begin
                ClickMouse2(mouse_right);
                R_WaitChooseOption('Take ' + LootListNames[k], 350);
                R_ChooseOption('Take ' + LootListNames[k]);
                Result := True;
              end;
            end;
          end else
            Exit;
        end;
      end;

    end;

    View my OSR Script Repository!


    Botted to max
    Guides: How to Report Bugs to the Scripter
    ~~~~ Moved to Java. Currently Lurking ~~~~

Page 68 of 117 FirstFirst ... 1858666768697078 ... LastLast

Thread Information

Users Browsing this Thread

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

Tags for this Thread

Posting Permissions

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