Results 1 to 8 of 8

Thread: Soulsplit Alcher

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

    Default Soulsplit Alcher

    Soulsplit Gem cutter



    Instructions

    - Brightness on Max
    - Default Graphics (oldschool)
    - Make sure you have the RSPS include http://villavu.com/forum/showthread.php?t=107271
    - Put the item you want to alch in the same slot were the alcher button is (slot 16)

    Features

    - Knows the item that you are alching

    Credits

    -Jani - Explode box
    Attached Files Attached Files

  2. #2
    Join Date
    Jun 2013
    Posts
    147
    Mentioned
    2 Post(s)
    Quoted
    41 Post(s)

    Default

    Damn, looks like a pretty advanced alcher from the looks of it xD Just curious though... what's an Explode Box?

  3. #3
    Join Date
    Dec 2011
    Posts
    273
    Mentioned
    0 Post(s)
    Quoted
    39 Post(s)

    Default

    Quote Originally Posted by koryperson View Post
    Damn, looks like a pretty advanced alcher from the looks of it xD Just curious though... what's an Explode Box?
    ExplodeBox is a way without smart, to detect the parameters of a given box, or target..

    Example : ExplodeBox(IntToBox(200, 40, 300, 80);
    Would set the search function if called, in between those given points.. sort of like a mousebox, but this draws a search around the particular "ExplodeBox".. I'm sorry I'm no advanced simba user, to put this into advanced terms
    "What can't hurt you, try it. What can kill you, do it!"

    Scripts Completed: 3
    Amount Released : 2

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

    Default

    Quote Originally Posted by VillaVuFTW View Post
    ExplodeBox is a way without smart, to detect the parameters of a given box, or target..

    Example : ExplodeBox(IntToBox(200, 40, 300, 80);
    Would set the search function if called, in between those given points.. sort of like a mousebox, but this draws a search around the particular "ExplodeBox".. I'm sorry I'm no advanced simba user, to put this into advanced terms
    No..

    @koryperson

    Consider this square



    Explode box will pretty much take this square and explode it into a lot of tiny boxes like this:



    (except the boxes would be equel)

    Each of the tiny boxes would be like a inventory slot

  5. #5
    Join Date
    Feb 2006
    Location
    Helsinki, Finland
    Posts
    1,395
    Mentioned
    30 Post(s)
    Quoted
    107 Post(s)

    Default

    Quote Originally Posted by VillaVuFTW View Post
    ExplodeBox is a way without smart, to detect the parameters of a given box, or target..

    Example : ExplodeBox(IntToBox(200, 40, 300, 80);
    Would set the search function if called, in between those given points.. sort of like a mousebox, but this draws a search around the particular "ExplodeBox".. I'm sorry I'm no advanced simba user, to put this into advanced terms
    Below is something for you guys!

    Small (basic) snippet for "Box Explosion" - exploding box to TBoxArray (by rows and columns):

    Code:
    const
      BITMAP_WIDTH = 500;
      BITMAP_HEIGHT = 500;
    
      MAIN_BOX_X1 = 100;
      MAIN_BOX_Y1 = 200;
      MAIN_BOX_X2 = 400;
      MAIN_BOX_Y2 = 300;
    
      EXPLOSION_ROWS = 10;
      EXPLOSION_COLUMNS = 30;
    
      RANDOM_COLORS = True;
    
    function ExplodeBox(bx: TBox; rows, columns: integer): TBoxArray;
    var
      r, c, w, h, ew, eh, ow, oh, i, x, y: integer;
    begin
      if ((rows > 0) and (columns > 0) and (bx.X1 <= bx.X2) and (bx.Y1 <= bx.Y2)) then
      begin
        w := ((bx.X2 - bx.X1) + 1);
        h := ((bx.Y2 - bx.Y1) + 1);
        if (rows > h) then
          rows := h;
        if (columns > w) then
          columns := w;
        w := (w div columns);
        h := (h div rows);
        ew := (((bx.X2 - bx.X1) + 1) - (w * columns));
        eh := (((bx.Y2 - bx.Y1) + 1) - (h * rows));
        SetLength(Result, (rows * columns));
        y := bx.Y1;
        for r := 0 to (rows - 1) do
        begin
          x := bx.X1;
          if ((eh > 0) and (r < eh)) then
            oh := 1
          else
            oh := 0;
          for c := 0 to (columns - 1) do
          begin
            if ((ew > 0) and (c < ew)) then
              ow := 1
            else
              ow := 0;
            i := ((r * columns) + c);
            Result[i].X1 := x;
            Result[i].X2 := (x + (w - 1) + ow);
            Result[i].Y1 := y;
            Result[i].Y2 := (y + (h - 1) + oh);
            x := (Result[i].X2 + 1);
          end;
          y := (Result[i].Y2 + 1);
        end;
      end else
        SetLength(Result, 0);
    end;
    
    var
      b: TBoxArray;
      h, i, m, bmp: integer;
      p, e: TPointArray;
    
    begin
      bmp := CreateBitmap(BITMAP_WIDTH, BITMAP_HEIGHT);
      DisplayDebugImgWindow(BITMAP_WIDTH, BITMAP_HEIGHT);
      DrawBitmapDebugImg(bmp);
      b := ExplodeBox(IntToBox(MAIN_BOX_X1, MAIN_BOX_Y1, MAIN_BOX_X2, MAIN_BOX_Y2), EXPLOSION_ROWS, EXPLOSION_COLUMNS);
      h := High(b);
      if RANDOM_COLORS then
        m := 1;
      case m of
        0:
        for i := 0 to h do
        begin
          p := TPAFromBox(b[i]);
          FindTPAEdgesWrap(p, e);
          DrawTPABitmap(bmp, e, 255);
          SetLength(e, 0);
        end;
        1:
        for i := 0 to h do
        begin
          p := TPAFromBox(b[i]);
          FindTPAEdgesWrap(p, e);
          DrawTPABitmap(bmp, e, Random(16777216));
          SetLength(e, 0);
        end;
      end;
      DrawBitmapDebugImg(bmp);
    end.
    Made small update for ExplodeBox too, as it had couple unneeded checks (for rows < 1 and columns < 1) that I forgot to remove in past..

    Sorry about offtopic :3

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

    Default

    can u update this

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

    Default

    Quote Originally Posted by kippper View Post
    can u update this
    Instructions on how to get the include are located at http://villavu.com/forum/showthread.php?t=107271
    Attached Files Attached Files

  8. #8
    Join Date
    Jul 2014
    Posts
    13
    Mentioned
    0 Post(s)
    Quoted
    5 Post(s)

    Default

    Clear instructions thanks

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
  •