Results 1 to 7 of 7

Thread: BankBox!

  1. #1
    Join Date
    Nov 2007
    Location
    Nowhereville
    Posts
    1,155
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default BankBox!

    I put together a function because I haven't been very active scripting. I noticed there was no function called bankbox anymore, it was called BankIndexToMSBox or something like that. Any ways, I decided to put this function together so you can get a TBox of a bank index and have the option whether or not to fix the bank. Nevertheless, here it is.

    SCAR Code:
    function BankBox(BankIndex: integer; FixTheBank: boolean): TBox;
    begin
      if FixTheBank then FixBank;
      if BankIndex div 8 > 5 then Exit;
      Result.x1 := 79 * (BankIndex div 5);
      Result.y1 := 62 * (BankIndex div 8);
      Result.x2 := 118 * (BankIndex div 5);
      Result.y2 := 96 * (BankIndex div 8);
    end;

    Thanks,
    ~ Cut em2 it
    Formerly known as Cut em2 it

  2. #2
    Join Date
    Jun 2007
    Posts
    785
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    nice math this function might will be usefull

    [22:20] <[-jesus-]> freddy, go uninstall yourself

  3. #3
    Join Date
    Nov 2007
    Location
    Nowhereville
    Posts
    1,155
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    Thanks Dumpin. I hope that this will be used in peoples' scripts .

    Cut em2 it
    Formerly known as Cut em2 it

  4. #4
    Join Date
    Sep 2007
    Location
    Michigan
    Posts
    3,862
    Mentioned
    2 Post(s)
    Quoted
    1 Post(s)

    Default

    Whats the size of the box(s)? Just curious
    (Scripts outdated until I update for new SRL changes)
    AK Smelter & Crafter [SRL-Stats] - Fast Fighter [TUT] [SRL-Stats]
    If you PM me with a stupid question or one listed in FAQ I will NOT respond. -Narcle
    Summer = me busy, won't be around much.

  5. #5
    Join Date
    Nov 2007
    Location
    Nowhereville
    Posts
    1,155
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    Size? Like how many pixles? I'm not sure. The area? It's not a perfect box btw, if I remember right, it was one pixel off :|

    Cut em2 it
    Formerly known as Cut em2 it

  6. #6
    Join Date
    Dec 2006
    Location
    .̿̂̔͋͗̎̆ͥ̍̒ͤ͂̾̌̀̅
    Posts
    3,012
    Mentioned
    1 Post(s)
    Quoted
    3 Post(s)

    Default

    Did you base this on something you found from some old script or just made it yourself?

    Well, still good job I suppose.. Simple and useful

  7. #7
    Join Date
    Nov 2007
    Location
    Nowhereville
    Posts
    1,155
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    I made it myself Thanks

    Cut em2 it
    Formerly known as Cut em2 it

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
  •