PatchedSimba - Autoloot v123

Posts 1–10 of 10 · Page 1 of 1
Simba - Autoloot v123
mpgh hello world, I decided to post my personel autoloot
to start this is not me who made ​​the edit
I changed a bit the script and also change the photo that had the error
Is this not the best but it is well autoloot the job

ps: He has another single thing which I manage not to understand i drinks a potion from time to time -.-'

If somebody know the errors to want to correct me thank you plz!!!!

the original code it was full of error as
The following bitmaps were not freed: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52]
Error: Exception: "" is an invalid integer at line 62
[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83]
The following bitmaps were not freed: [0, 1, 2, 3]

or line 81 etc......

Tutorial
1- Download simba
2- Download Includes
3- Extract the files. You should see 1 folders, one called "Includes"
4- C:\Simba\Includes\ROTMG - *Includes*
5- Open the extracted "Includes" folder. You will see a folder called "ROTMG". Cut and Paste this into your Simba "Includes" folder.
6- Now open up Simba, go to File -> Open, and open up ROTMGAutoGrabber.simba. Select the game window using the crosshairs button, and press Run
7- F9
----------------------------------------------------------------------------------------------------------------------------------------

Code:
program ROTMGAutoGrabber;
  Type
    ROTMGItem = record
      Autograb, Image, Tier : Integer;
      Name: string;
    end;
  Type
    ROTMGSlot = record
    Image, Slot: Integer;
    end;
  Type
    ROTMGItemList = record
      List : Array[0..500] of ROTMGItem;
      Length : Integer;
    end;
  Type
    ROTMGSlotList = record
    List : Array[0..7] of ROTMGSlot;
    end;
  var
    ItemList : ROTMGItemList;
    SlotList : ROTMGSlotList;
    itemsGrabbed : Integer;
    itemsMissed : Integer;
    ii : Integer;
  procedure LoadSlots;
  var
    i : integer;
  begin
    for i := 1 to 8 do
    begin
       SlotList.List[i-1].Slot := i;
       SlotList.List[i-1].Image := LoadBitmap(IncludePath + 'ROTMG\Slots\' + 'slot' + inttostr(i) + '.png');
    end;
  end;

  procedure EnableMasks(image : Integer);
  var
    a, b, w, h : Integer;
  begin
    GetBitmapSize(image, w, h);
      for a := 0 to h-1 do
      begin
        if (a < 2) or (h - a - 1 < 2) then
        begin
          for b := 0 to w-1 do
          begin
          FastSetPixel(image,b,a, RGBtoColor(0,0,0));
        end;
      end else
      begin
        FastSetPixel(image,0,a,RGBtoColor(0,0,0));
        FastSetPixel(image,1,a,RGBtoColor(0,0,0));
        FastSetPixel(image,w-1,a,RGBtoColor(0,0,0));
        FastSetPixel(image,w-2,a,RGBtoColor(0,0,0));
      end;
    end;
  end;

  function LoadItem(fileName : string) : boolean;
  begin
      if Strtoint(ReadIni(fileName,'Autograb',IncludePath + 'ROTMG\Config.ini')) > 0 then
    begin
      ItemList.List[ItemList.Length].Image := LoadBitmap(IncludePath + 'ROTMG\Equipment\' + fileName);
      ItemList.List[ItemList.Length].Name := Readini(fileName,'Name',IncludePath + 'ROTMG\Config.ini');
      ItemList.List[ItemList.Length].Autograb := strtoint(Readini(fileName,'Autograb',IncludePath + 'ROTMG\Config.ini'));
      ItemList.List[ItemList.Length].Tier := strtoint(Readini(fileName,'Tier',IncludePath + 'ROTMG\Config.ini'));
      EnableMasks(ItemList.List[ItemList.Length].Image);
      result := true;
      exit;
    end;
    result := false;
  end;

  function LoadItems() : Integer;
  var
    x, itemCount, loaded : Integer;
    fileNames : TStringArray;
  begin
    fileNames:= GetFiles(IncludePath + 'ROTMG\Equipment\','png');
    itemCount:= length(fileNames);
    for x:= 0 to itemCount-1 do
    begin
      if LoadItem(fileNames[x]) then
      begin
          inc(loaded);
          inc(ItemList.Length);
      end;
    end;
    result := loaded;
  end;
  procedure GrabItem(item : ROTMGItem; x, y : Integer);
  var
    i,a,b,w,h,c,d,n,m : Integer;
  begin
    for i := 0 to 7 do
    begin
      if item.Autograb = 2 then
      begin
        GetMousePos(n,m);
        GetBitmapSize(item.Image,w,h);
        MoveMouse(x + w / 2, y + h / 2);
        KeyDown(16);
        ClickMouse(x + w / 2,y + h / 2,mouse_Left);
        Wait(0)
        Writeln('Items grabbed: (' + inttostr(itemsGrabbed) + ') Items Missed: (' + inttostr(itemsMissed) + ')');
        Writeln('Grabbed item "' + item.Name + '"');
        Wait(10);
        exit;
      end else
      if FindBitmapToleranceIn(SlotList.List[i].Image,a,b,610,400,800,600,25) then
      begin
        GetBitmapSize(SlotList.List[i].Image,c,d);
        GetBitmapSize(item.Image,w,h);
        GetMousePos(n,m);
        MoveMouse(x + w / 2, y + h / 2);
        ClickMouse(x + w / 2,y + h / 2,mouse_Left);
        Wait(10)
        ClickMouse(x + w / 2,y + h / 2,mouse_left);
        MoveMouse(n,m);
        inc(itemsGrabbed);
        Writeln('Items grabbed: (' + inttostr(itemsGrabbed) + ') Items Missed: (' + inttostr(itemsMissed) + ')');
        Writeln('Grabbed item "' + item.Name + '"');
        Wait(10);
        exit;
      end;
    end;
    inc(itemsMissed);
    Writeln('Items grabbed: (' + inttostr(itemsGrabbed) + ') Items Missed: (' + inttostr(itemsMissed) + ')');
    Writeln('Missed item "' + item.Name + '" (INVENTORY FULL)');
  end;

  procedure ScanItem (item : ROTMGItem);
  var
    x,y : integer;
  begin
    if FindBitmapToleranceIn(item.Image,x,y,610,500,800,600,30) then
      begin
        Writeln('found item:' +   item.Name    )
        GrabItem(item,x,y);
      end;
  end;
  procedure Initialize;
  begin
    ItemList.Length := 0;
    itemsGrabbed := 0;
    itemsMissed := 0;
    Writeln('Initializing autograbber');
    Writeln('Loading Items...');
    Writeln('Loaded ' + inttostr(LoadItems()) + ' items');
    Writeln('Loading slots...');
    LoadSlots();
    Writeln('Slots loaded');
    Writeln('Entering main loop...');
  end;
  begin
    Initialize();
    while true do
    begin
      for ii := 0 to ItemList.Length do
      begin
          ScanItem(ItemList.List[ii]);
      end;
    end;
  end.

@Imk0tter « Reply #9 on: November 05, 2010, 09:41:09 AM »
Also, make sure the client is running NORMAL SIZE.. No bigger, no smaller, otherwise it won't be able to find items/slots correctly.
(I assume you all realize that you have to drag the crosshair from Simba to the RoTMG window (The actual flash frame))
Edit: Not sure if this is important, but I wrote the script to work in 1280x1024, the bottom right corner of the RotMG window should be 800,600... Hope that helps!

Test Virus
http://virusscan.jotti.org/en-gb/sca...985ef3775ac2e5
https://www.virustotal.com/file/0f29...is/1348748637/

Please to not say stupid comment *Thanks everyone*



Thanks for sharing - Created by - Imk0tter
Includes_mpgh.net.zip150 KB · 148 downloads Clean
You need 2 virusscans and preferably a screenshot, but that is not needed.
Quote Originally Posted by Nachos View Post
You need 2 virusscans and preferably a screenshot, but that is not needed.
Wow I am really tired xD yes sorry nachos
Approved
Quote Originally Posted by crossfireglitcher View Post
Please don't leech pings.

Just don't.
Look on the forum and you see kept silent by autoloots not good it has only client for duped and tutorial - That it!!!!


Quote Originally Posted by Echo Phyber View Post
The following bitmaps were not freed: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132]

Did you say it has no errors?
yes yes it has error
where to put that code???+?
The following bitmaps were not freed: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132]

Did you say it has no errors?
Initializing autograbber
Loading Items...
Loaded 0 items
Loading slots...
Exception: Error while reading stream: File "C:\Simba\Includes\ROTMG\Slots\slot1.png" does not exist at line 33
=(
Quote Originally Posted by Hikyn View Post
Initializing autograbber
Loading Items...
Loaded 0 items
Loading slots...
Exception: Error while reading stream: File "C:\Simba\Includes\ROTMG\Slots\slot1.png" does not exist at line 33
=(
do you change the pic ? only work for format .png!
Posts 1–10 of 10 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Talk with us