UOGamers Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

  • To obtain new Razor updates, please reinstall Razor from our new website.

Steam Tailoring Bod Sorter concept

Sevenz

Wanderer
Edited as code has been updated:

First - Thank you very much @MB! The code is much, much smaller now. Your comment was really helpful!

This is now sorting for the following: BRSK, HRSK, SRSK, CBD, and Footwear for 4, 5 and 6 part large and small bods. It should be pretty complete, I think. (I hope?)

What I could really use at this point is someone willing to test and provide some feedback.

I've added in some messages as you sort like 'FivePartBod 4 CBD' that let you know what it was trying if there is a failure.

Usage:
1. put your book to sort from in your backpack
2. open all the containers your bod books are in (be sure you're in range)
3. hit play
4. target them as required

Troubleshooting:

1. It isn't reading the bod correctly or piling up bods
If you stopped it in the middle or something went wrong, like lag:
  • Stop the macro
  • Click on the active objects button and remove "bod", "found", "moveto<something>" from the Aliases list if they're there. You will also need to remove the respective Aliases from that list if you change books or containers.
  • Save
  • Hit play

2. It isn't pulling any bods and just cycling over and over.
  • Check that the filter on your sort book is set to all.
3. Some of my BODS are in the wrong books
There may be things I've missed as this is still new. Please post a message with the following:
  • BOD Properties
  • Where it was sorted to
  • Where it should have been sorted to

In addition it would be helpful if you could do the following:
  • put just that bod in a book
  • clear the aliases
  • save
  • run the macro
  • post below with the message that shows up over your characters head when its sorting. That should help me find the issue in the code.

I hope this ends up helping someone with a tedious task.

Thanks!

Sevenz



Code:
// ---------------------------------------------
// Footwear
// ---------------------------------------------
if not @listexists "Footwear"
  createlist "Footwear"
  pushlist "Footwear" "Sandals" //Footwear Collection
  pushlist "Footwear" "Shoes" //Footwear Collection
  pushlist "Footwear" "Boots" //Footwear Collection
  pushlist "Footwear" "Thigh Boots" //Footwear Collection
endif
// ---------------------------------------------
// 4 Part outfits
// ---------------------------------------------
if not @listexists "FourPart"
  createlist "FourPart"
  pushlist "FourPart" "Bandana" //Gypsy
  pushlist "FourPart" "Shirt" //Gypsy
  pushlist "FourPart" "Skirt" //Gypsy
  pushlist "FourPart" "Skullcap" //Pirate
  pushlist "FourPart" "Doublet" //Pirate
  pushlist "FourPart" "Kilt" //Pirate
  pushlist "FourPart" "Jester Hat" //Jester
  pushlist "FourPart" "Jester Suit" //Jester
  pushlist "FourPart" "Cloak"  //Jester
  pushlist "FourPart" "Straw Hat" //Farmer
  pushlist "FourPart" "Tunic" //Farmer
  pushlist "FourPart" "Long Pants"  //Farmer
  pushlist "FourPart" "Wizards Hat" //Wizard
  pushlist "FourPart" "Body Sash" //Wizard
  pushlist "FourPart" "Robe" //Wizard
  pushlist "FourPart" "Floppy Hat" //Fishergirl
  pushlist "FourPart" "Full Apron" //Fishergirl
  pushlist "FourPart" "Plain Dress" //Fishergirl
  pushlist "FourPart" "Bonnet" //Lady
  pushlist "FourPart" "Half Apron" //Lady
  pushlist "FourPart" "Fancy Dress" //Lady
  pushlist "FourPart" "Tricorne Hat" //Hat Collection
  pushlist "FourPart" "Cap" //Hat Collection
  pushlist "FourPart" "Wide-Brim Hat" //Hat Collection
  pushlist "FourPart" "Tall Straw Hat" //Hat Collection
endif
// ---------------------------------------------
// 5 Part outfits
// ---------------------------------------------
if not @listexists "FivePart"
  createlist "FivePart"
  pushlist "FivePart" "studded gorget"
  pushlist "FivePart" "studded gloves"
  pushlist "FivePart" "studded sleeves"
  pushlist "FivePart" "studded leggings"
  pushlist "FivePart" "studded tunic"
  pushlist "FivePart" "bone helmet"
  pushlist "FivePart" "bone gloves"
  pushlist "FivePart" "bone arms"
  pushlist "FivePart" "bone leggings"
  pushlist "FivePart" "bone armor"
  pushlist "FivePart" "feathered hat"
  pushlist "FivePart" "surcoat"
  pushlist "FivePart" "fancy shirt"
  pushlist "FivePart" "short pants"
endif
// ---------------------------------------------
// 6 Part outfits
// ---------------------------------------------
if not @listexists "SixPart"
  createlist "SixPart"
  pushlist "SixPart" "leather gorget"
  pushlist "SixPart" "leather skirt"
  pushlist "SixPart" "leather cap"
  pushlist "SixPart" "leather gloves"
  pushlist "SixPart" "leather sleeves"
  pushlist "SixPart" "leather leggings"
  pushlist "SixPart" "leather tunic"
  pushlist "SixPart" "leather bustier"
  pushlist "SixPart" "leather shorts"
  pushlist "SixPart" "female leather armor"
  pushlist "SixPart" "studded bustier"
  pushlist "SixPart" "studded armor"
endif
// ---------------------------------------------
// Book we want to sort through
// ---------------------------------------------
if not @findobject "toSort"
  headmsg "Select BOD book to sort" "100"
  promptalias "toSort"
endif
// ---------------------------------------------
// Container that holds book of each type
// ---------------------------------------------
if not @findobject "BRSKcont"
  headmsg "Select container where BRSK book is" "100"
  promptalias "BRSKcont"
endif
if not @findobject "HRSKcont"
  headmsg "Select container where HRSK book is" "100"
  promptalias "HRSKcont"
endif
if not @findobject "SRSKcont"
  headmsg "Select container where SRSK book is" "100"
  promptalias "SRSKcont"
endif
if not @findobject "CBDcont"
  headmsg "Select container where CBD book is" "100"
  promptalias "CBDcont"
endif
//if not @findobject "TPScont"
//  headmsg "Select container where TPS book is" "100"
//  promptalias "TPScont"
//endif
if not @findobject "Footwearcont"
  headmsg "Select container where Footwear book is" "100"
  promptalias "Footwearcont"
endif
if not @findobject "TrashBODcont"
  headmsg "Select container where TrashBod book is" "100"
  promptalias "TrashBODcont"
endif
// ---------------------------------------------
// Book of each type reward
// ---------------------------------------------
if not @findobject "BRSK"
  headmsg "Select BRSK book" "100"
  promptalias "BRSK"
endif
if not @findobject "HRSK"
  headmsg "Select HRSK book" "100"
  promptalias "HRSK"
endif
if not @findobject "SRSK"
  headmsg "Select SRSK book" "100"
  promptalias "SRSK"
endif
if not @findobject "CBD"
  headmsg "Select CBD book" "100"
  promptalias "CBD"
endif
//if not @findobject "TPS"
//headmsg "Select TPS book" "100"
//promptalias "TPS"
//endif
if not @findobject "Footwear"
  headmsg "Select Footwear book" "100"
  promptalias "Footwear"
endif
if not @findobject "TrashBOD"
  headmsg "Select TrashBOD book" "100"
  promptalias "TrashBOD"
endif
// ---------------------------------------------
// Get first bod from Bulk Source
// ---------------------------------------------
while not @property 'Deeds In Book: 0' 'toSort'
  // If we have a tailoring bod in backpack
  // get its properties
  // otherwise get a new bod
  useobject "toSort"
  waitforgump 0x54f555df 2000
  replygump 0x54f555df 5
  pause 1000
  if @findtype 0x2258 1155 "backpack" "any"
    @setalias "bod" "found"
    waitforproperties "bod" 5000
  endif
  // ---------------------------------------------
  // Find the outfit this bod belongs to
  // ---------------------------------------------
  // if we don't have any sort flags set
  // find the outfit set this bod belongs to
  if not findalias "movetoSRSK" and not findalias "movetoCBD"
    if not findalias "movetoHRSK" and not findalias "movetoBRSK"
      // check fourpart first as we'll get most
      // of our bods here
      for 1 to FourPart
        //headmsg "Checking FourPartBod" "33"
        if @property FourPart[] "bod" and not @property "Leather Skirt" "bod"
          if not @property "Leather Cap" "bod" and not @property "Leather Tunic" "bod"
            if not @property "Fancy Shirt" "bod" and not @property "Studded Tunic" "bod"
              //headmsg "Found FourPartBod" "3"
              @setalias "FourPartBod" "bod"
              //headmsg "FourPartBod" "33"
              break
            endif
          endif
        endif
      endfor
      // if we found the outfit
      // stop checking otherwise check
      // five parts
      if not @findalias "FourPartBod"
        for 1 to FivePart
          //headmsg "Checking FivePartBod" "33"
          if @property FivePart[] "bod"
            //headmsg "Found FivePartBod" "33"
            @setalias "FivePartBod" "bod"
            //headmsg "FivePartBod" "33"
            break
          endif
        endfor
      endif
      // if we found the outfit
      // stop checking otherwise check
      // six parts
      if not @findalias "FourPartBod" and not @findalias "FivePartBod"
        for 1 to SixPart
          //headmsg "Checking SixPartBod" "33"
          if @property SixPart[] "bod"
            //headmsg "Found SixPartBod" "33"
            @setalias "SixPartBod" "bod"
            //headmsg "SixPartBod" "33"
            break
          endif
        endfor
      endif
      if not @findalias "FourPartBod" and not @findalias "FivePartBod"
        if not findalias "SixPartBod"
          for 1 to Footwear
            //headmsg "Checking FootwearBod" "33"
            if @property Footwear[] "bod"
              //headmsg "Found Footwear" "10"
              @setalias "FootwearBod" "bod"
              break
            endif
          endfor
        endif
      endif
    endif
  endif
  pause 1000
  // ---------------------------------------------
  // Start filtering for reward
  // ---------------------------------------------
  //check fourpart
  if @findalias "FourPartBod"
    //headmsg "Filtering FourPartBod" "33"
    if @property "Barbed" "bod" and @property "Exceptional" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FourPartBod 1 HRSK" "33"
      endif
    elseif @property "Barbed" "bod" and @property "Exceptional" "bod"
      if @property "Make: 10" "bod"
        @setalias "movetoCBD" "bod"
        headmsg "FourPartBod 2 CBD" "33"
      endif
    elseif @property "Horned" "bod" and @property "Exceptional" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoCBD" "bod"
        headmsg "FourPartBod 3 CBD" "33"
      endif
    elseif @property "Spined" "bod" and @property "Large" "bod"
      if not @property "Exceptional" "bod" and @property "Make: 10" "bod"
        @setalias "movetoSRSK" "bod"
        headmsg "FourPartBod 4 SRSK" "33"
      endif
    elseif @property "Spined" "bod" and @property "Large" "bod"
      if not @property "Exceptional" "bod" and @property "Make: 15" "bod"
        @setalias "movetoSRSK" "bod"
        headmsg "FourPartBod 5 SRSK" "33"
      endif
    elseif @property "Spined" "bod" and not @property "Large" "bod"
      if @property "Make: 10" "bod"
        @setalias "movetoSRSK" "bod"
        headmsg "FourPartBod 6 SRSK" "33"
      endif
    elseif @property "Spined" "bod" and not @property "Large" "bod"
      if @property "Make: 15" "bod"
        @setalias "movetoSRSK" "bod"
        headmsg "FourPartBod 7 SRSK" "33"
      endif
    elseif not @property "Spined" "bod" and not @property "Horned" "bod"
      if not @property "Barbed" "bod" and @property "Make: 20" "bod"
        if not @property "Exceptional" "bod" and @property "Large" "bod"
          @setalias "movetoSRSK" "bod"
          headmsg "FourPartBod 8 SRSK" "33"
        endif
      endif
    elseif not @property "Spined" "bod" and not @property "Horned" "bod"
      if not @property "Barbed" "bod" and @property "Make: 20" "bod"
        if @property "Small Bulk" "bod"
          @setalias "movetoSRSK" "bod"
          headmsg "FourPartBod 9 SRSK" "33"
        endif
      endif
    endif
  elseif @findalias "FivePartBod"
    //headmsg "Filtering FivePartBod" "33"
    if @property "Barbed" "bod" and @property "Exceptional" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoBRSK" "bod"
        headmsg "FivePartBod 1 BRSK" "33"
      endif
    elseif @property "Horned" "bod" and @property "Exceptional" "bod"
      if @property "Make: 10" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FivePartBod 2 HRSK" "33"
      endif
    elseif @property "Horned" "bod" and @property "Exceptional" "bod"
      if @property "Make: 15" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FivePartBod 3 HRSK" "33"
      endif
    elseif @property "Spined" "bod" and @property "Exceptional" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FivePartBod 4 HRSK" "33"
      endif
    elseif @property "Spined" "bod" and @property "Exceptional" "bod"
      if @property "Make: 10" "bod"
        @setalias "movetoCBD" "bod"
        headmsg "FivePartBod 5 CBD" "33"
      endif
    elseif @property "Exceptional" "bod" and @property "Make: 20" "bod"
      if not @property "Spined" "bod" and not @property "Horned" "bod"
        if not @property "Barbed" "bod"
          @setalias "movetoCBD" "bod"
          headmsg "FivePartBod 6 CBD" "33"
        endif
      endif
    elseif not @property "Exceptional" "bod" and @property "Make: 20" "bod"
      if @property "Barbed" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FivePartBod 7 HRSK" "33"
      endif
    elseif not @property "Exceptional" "bod" and @property "Make: 10" "bod"
      if @property "Barbed" "bod"
        @setalias "movetoCBD" "bod"
        headmsg "FivePartBod 8 CBD" "33"
      endif
    elseif not @property "Exceptional" "bod" and @property "Make: 20" "bod"
      if @property "Horned" "bod"
        @setalias "movetoCBD" "bod"
        headmsg "FivePartBod 9 CBD" "33"
      endif
    endif
  elseif @findalias "SixPartBod"
    //headmsg "Filtering SixPartBod" "200"
    if @property "Exceptional" "bod" and @property "Barbed" "bod"
      @setalias "movetoBRSK" "bod"
      headmsg "SixPartBod 1 BRSK" "33"
    elseif @property "Exceptional" "bod" and @property "Horned" "bod"
      @setalias "movetoBRSK" "bod"
      headmsg "SixPartBod 2 BRSK" "33"
    elseif @property "Exceptional" "bod" and @property "Spined" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoBRSK" "bod"
        headmsg "SixPartBod 3 BRSK" "33"
      endif
    elseif @property "Barbed" "bod" and not @property "Exceptional" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoBRSK" "bod"
        headmsg "SixPartBod 4 BRSK" "33"
      endif
    elseif @property "Exceptional" "bod" and @property "Make: 10" "bod"
      @setalias "movetoHRSK" "bod"
      headmsg "SixPartBod 5 HRSK" "33"
    elseif @property "Exceptional" "bod" and @property "Make: 15" "bod"
      @setalias "movetoHRSK" "bod"
      headmsg "SixPartBod 6 HRSK" "33"
    elseif @property "Horned" "bod" and not @property "Exceptional" "bod"
      if @property "Make: 10" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "SixPartBod 7 HRSK" "33"
      endif
    elseif @property "Horned" "bod" and not @property "Exceptional" "bod"
      if @property "Make: 15" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "SixPartBod 8 HRSK" "33"
      endif
    elseif @property "Spined" "bod" and not @property "Exceptional" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "SixPartBod 9 HRSK" "33"
      endif
    elseif @property "Spined" "bod" and not @property "Exceptional" "bod"
      if @property "Make: 10" "bod"
        @setalias "movetoCBD" "bod"
        headmsg "SixPartBod 10 CBD" "33"
      endif
    elseif @property "Make: 20" "bod" and not @property "Exceptional" "bod"
      if not @property "Spined" "bod" and not @property "Horned" "bod"
        if not @property "Barbed" "bod"
          @setalias "movetoCBD" "bod"
          headmsg "SixPartBod 11 CBD" "33"
        endif
      endif
    endif
  elseif @findalias "FootwearBOD"
    if @property "Large" "bod" and not @property "Exceptional" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoFootwear" "bod"
        headmsg "Footwear 1" "33"
      endif
    elseif @property "Small Bulk" "bod" and @property "Make: 20" "bod"
      @setalias "movetoFootwear" "bod"
      headmsg "Footwear 2" "33"
    endif
  endif
  pause 500
  // ---------------------------------------------
  // Move to correct book
  // ---------------------------------------------
  // World save pause
  if @injournal 'The world will save'
    clearjournal
    sysmsg 'Pausing macro for Server Save'
    waitforjournal 'World save complete' 20000 'system'
    sysmsg 'Resuming macro'
  endif
  // Too many items check
  if @injournal 'That container cannot hold'
    clearjournal
    headmsg "Can't hold anymore items" "33"
    stop
  endif
  // Weight check
  if weight > maxweight
    headmsg "Overweight" "33"
    stop
  endif
  if @findobject "movetoBRSK" 1155 "backpack"
    //find BRSK book
    if not @findobject "BRSK" 0 "backpack"
      @findobject "BRSK" 0 "ground" "any" 3
      @moveitem "BRSK" "backpack" 0 0 0 1
      pause 500
    endif
    @moveitem "movetoBRSK" "BRSK"
    pause 500
    @moveitem "BRSK" "BRSKcont" 0 0 0 1
    pause 500
  endif
  if @findobject "movetoHRSK" 1155 "backpack"
    //find HRSK book
    if not @findobject "HRSK" 0 "backpack"
      @findobject "HRSK" 0 "ground" "any" 3
      @moveitem "HRSK" "backpack" 0 0 0 1
      pause 500
    endif
    @moveitem "movetoHRSK" "HRSK"
    pause 500
    @moveitem "HRSK" "HRSKcont" 0 0 0 1
    pause 500
  endif
  if @findobject "movetoSRSK" 1155 "backpack"
    if not @findobject "SRSK" 0 "backpack"
      @findobject "SRSK" 0 "ground" "any" 3
      @moveitem "SRSK" "backpack" 0 0 0 1
      pause 500
    endif
    @moveitem "movetoSRSK" "SRSK"
    pause 500
    @moveitem "SRSK" "SRSKcont" 0 0 0 1
    pause 500
  endif
  if @findobject "movetoCBD" 1155 "backpack"
    //find CBD book
    if not @findobject "CBD" 0 "backpack"
      @findobject "CBD" 0 "ground" "any" 3
      @moveitem "CBD" "backpack" 0 0 0 1
      pause 500
    endif
    @moveitem "movetoCBD" "CBD"
    pause 500
    @moveitem "CBD" "CBDcont" 0 0 0 1
    pause 500
  endif
  if @findobject "movetoFootwear" 1155 "backpack"
    if not @findobject "Footwear" 0 "backpack"
      @findobject "Footwear" 0 "ground" "any" 3
      @moveitem "Footwear" "backpack" 0 0 0 1
      pause 500
    endif
    @moveitem "movetoFootwear" "Footwear"
    pause 500
    @moveitem "Footwear" "Footwearcont" 0 0 0 1
    pause 500
  endif
  // ---------------------------------------------
  // Trash if we didn't find any of our filters
  // ---------------------------------------------
  if not @findalias "movetoHRSK" and not @findalias "movetoBRSK"
    if not @findalias "movetoSRSK" and not @findalias "movetoCBD"
      if not @findalias "movetoFootwear"
        if not @findobject "TrashBOD" 0 "backpack"
          @findobject "TrashBOD" 0 "ground" "any" 3
          @moveitem "TrashBOD" "backpack" 0 0 0 1
          pause 500
        endif
        @moveitem "bod" "TrashBOD"
        headmsg "Item put in Trash book" "100"
        pause 500
        @moveitem "TrashBOD" "TrashBODcont" 0 0 0 1
        pause 500
      endif
    endif
  endif
  // ---------------------------------------------
  // Clean up
  // ---------------------------------------------
  @unsetalias "movetoSRSK"
  @unsetalias "movetoHRSK"
  @unsetalias "movetoBRSK"
  @unsetalias "movetoCBD"
  @unsetalias "movetoFootwear"
  @unsetalias "FourPartBod"
  @unsetalias "FivePartBod"
  @unsetalias "SixPartBod"
  @unsetalias "FootwearBod"
  @unsetalias "bod"
  @unsetalias "Found"
  pause 500
endwhile
@unsetalias "toSort"
 
Last edited:

MB

Knight
I've never done bods, but if each of those repeating sections for different clothing types are the same, you could do a list and a for loop around those replacing each variable each cycle. Look how the Fletcher scripts handles protection talismans. If they are all the same except for clothing type, do you even need to check for clothing type? If a lot are the same you could check the ones that are different and then do rest without clothing type stipulation. You could also use an existing EUO script, though I suspect a working UOS macro would be much faster.
 

kolbycrouch

Knight
I have a script that I made, that might do what you want, but I wanted it to be more specific and sort runic bods into seperate books for each sbod type, which got to be frustrating so I do it manually. I do this because I don't use a bod exporter on EUO, so you may not need it like that.
 

Sevenz

Wanderer
hi Kolby, hey thanks for that. It is always nice to see how someone else went about solving a problem, so if you care to share it, I'd like to look.

I made significant updates to it and reloaded the code to the first post if you have any feedback on it.
 
Hey Sevenz, I've been using your script a lot, it's been very helpful. I found just a few things with it I wanted to share with you.

I noticed that it wasn't counting short pants as 5 part and was not counting studded armor as 6 part. I also noticed it wasn't filtering some bods for rewards correctly. 10 ex spined 5 part and 15 ex horned 5 parts were going to trash.

For the filtering problem, I tracked it down to a logic bug in the filtering code. Consider this piece of code for filtering 5 part bods:

Code:
    elseif @property "Horned" "bod" and @property "Exceptional" "bod"
      if @property "Make: 10" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FivePartBod 2 HRSK" "33"
      endif
    elseif @property "Horned" "bod" and @property "Exceptional" "bod"
      if @property "Make: 15" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FivePartBod 3 HRSK" "33"
      endif

So in this case, the second else if will never be reached because it is the same condition as the one above it. If-elseif-elseif..etc are exclusive in that at most only one code block will ever be executed, and the first one that meets the condition will be executed.

To fix it, you would need to do something like this:

Code:
    elseif @property "Horned" "bod" and @property "Exceptional" "bod"
      if @property "Make: 10" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FivePartBod 2 HRSK" "33"
      elseif @property "Make: 15" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FivePartBod 3 HRSK" "33"
      endif

I think there were a few more spots like that.

The short pants and studded armor problems were a lot more mysterious to me. I'm not even sure if the problem is just me or not. When I uncommented out all the head msgs, I saw that those two pieces never got put on an outfit so they ended up always going to the trash. I cleared all my active objects and still no go. When I looked at my lists those items were in those outfit lists. They were both at the end of their respective lists so I tried changing the order around or removing some elements of the list but still not working. I'm sure it's something I've overlooked but I did come up with a workaround:

For the if statements around setting the 5 part and 6 part aliases change them to this:
if @property FivePart[] "bod" or @property "short pants" "bod"

if @property SixPart[] "bod" or @property "studded armor" "bod"

Again, I can't track this problem down to any code, it seems like it should work. I'm not sure if it's just me or my UOS or what but it is really strange to me.
 
I figured out why it was skipping the studded armor and the short pants. It was the lower bound of the for loop when checking the outfits. It was "for 1 to SixPart" but needs to be "for 0 to SixPart"

I'll go ahead and post my modified version with the fixes. When I was fixing the filtering section, I modified what it sorts for so I didn't end up with so much stuff that I don't want to fill.

-With 120 tailoring you can get normal LBODs but you cannot get normal smalls. You can of course fill the normal lbods with exceptional but in most cases it would be a waste. The only normals I decided to keep are the normal 20 4 pc cloth (if you want to do spined...) and normal 20 6pc plain leather for the CBD.

-I went ahead and added the TPS filter but just for 20 ex plain leather. Your 20 normal plain leather 6pc LBODs will go in the CBD book and the 20 exceptional plain leather 6pc smalls that you will fill the normal lbods with go in the TPS book. Then extra's you can fill for 120 PS if you want.

-I commented out the gypsy outfit because the thigh boots are better used for the town crier to get a CBD

-For doing spined I only sort the normal cloth 4pc lbods and the boots. I find that sorting the exceptional cloth smalls gives me way too much, so if I do spined I just pull the cloth smalls from the trash and the ones I don't use will be resets for me. If you do want to filter for the exceptional smalls for the spined then uncomment lines 239 and 240. If you don't want to do spined at all then comment out lines: 98,99,100,129,130,131,234,235 and it shouldn't bother you with any of the spined bods. I'm a little OCD so that's why I do the spined. You get 8k for turning in the lbod so it's not that bad for a little cloth and a little leather. I have no idea what I'm going to do with 100 spined kits :confused:

-The only other footwear bod worth anything is 20 exceptional barbed for the horned kit. You could do some for the CBD but you get so many CBD's just doing plain leather.

-Also it only goes for CBD's that you can get with plain leather and cloth (doesn't get bone for CBD either)

-I commented out the pauses at lines 228 and 315 since they didn't seem necessary and saves 1.5 seconds per bod. A few times I end up getting a bod that got missed but that would probably be the delay between pulling the bod out and doing the findtype on it(the pause at line 159 if you need to adjust). When it happens it never causes anything to get sorted incorrectly though so it's not a big deal.

I like to do all the cloth and plain leather that I can mostly because you can make a good profit by just turning in the completed lbods. The last round I did of 6 books, I used about 60k plain leather and not much cloth and I ended up with 1.6kk from just turning in the lbods.

Major thanks to @Sevenz for this script. It has been hugely helpful to me.

Code:
// ---------------------------------------------
// Footwear
// ---------------------------------------------
if not @listexists "Footwear"
  createlist "Footwear"
  pushlist "Footwear" "Sandals" //Footwear Collection
  pushlist "Footwear" "Shoes" //Footwear Collection
  pushlist "Footwear" "Boots" //Footwear Collection
  pushlist "Footwear" "Thigh Boots" //Footwear Collection
endif
// ---------------------------------------------
// 4 Part outfits
// ---------------------------------------------
if not @listexists "FourPart"
  createlist "FourPart"
  //pushlist "FourPart" "Bandana" //Gypsy
  //pushlist "FourPart" "Shirt" //Gypsy
  //pushlist "FourPart" "Skirt" //Gypsy
  pushlist "FourPart" "Skullcap" //Pirate
  pushlist "FourPart" "Doublet" //Pirate
  pushlist "FourPart" "Kilt" //Pirate
  pushlist "FourPart" "Jester Hat" //Jester
  pushlist "FourPart" "Jester Suit" //Jester
  pushlist "FourPart" "Cloak"  //Jester
  pushlist "FourPart" "Straw Hat" //Farmer
  pushlist "FourPart" "Tunic" //Farmer
  pushlist "FourPart" "Long Pants"  //Farmer
  pushlist "FourPart" "Wizards Hat" //Wizard
  pushlist "FourPart" "Body Sash" //Wizard
  pushlist "FourPart" "Robe" //Wizard
  pushlist "FourPart" "Floppy Hat" //Fishergirl
  pushlist "FourPart" "Full Apron" //Fishergirl
  pushlist "FourPart" "Plain Dress" //Fishergirl
  pushlist "FourPart" "Bonnet" //Lady
  pushlist "FourPart" "Half Apron" //Lady
  pushlist "FourPart" "Fancy Dress" //Lady
  pushlist "FourPart" "Tricorne Hat" //Hat Collection
  pushlist "FourPart" "Cap" //Hat Collection
  pushlist "FourPart" "Wide-Brim Hat" //Hat Collection
  pushlist "FourPart" "Tall Straw Hat" //Hat Collection
endif
// ---------------------------------------------
// 5 Part outfits
// ---------------------------------------------
if not @listexists "FivePart"
  createlist "FivePart"
  pushlist "FivePart" "studded gorget"
  pushlist "FivePart" "studded gloves"
  pushlist "FivePart" "studded sleeves"
  pushlist "FivePart" "studded leggings"
  pushlist "FivePart" "studded tunic"
  pushlist "FivePart" "bone helmet"
  pushlist "FivePart" "bone gloves"
  pushlist "FivePart" "bone arms"
  pushlist "FivePart" "bone leggings"
  pushlist "FivePart" "bone armor"
  pushlist "FivePart" "feathered hat"
  pushlist "FivePart" "surcoat"
  pushlist "FivePart" "fancy shirt"
  pushlist "FivePart" "short pants"
endif
// ---------------------------------------------
// 6 Part outfits
// ---------------------------------------------
if not @listexists "SixPart"
  createlist "SixPart"
  pushlist "SixPart" "leather gorget"
  pushlist "SixPart" "leather skirt"
  pushlist "SixPart" "leather cap"
  pushlist "SixPart" "leather gloves"
  pushlist "SixPart" "leather sleeves"
  pushlist "SixPart" "leather leggings"
  pushlist "SixPart" "leather tunic"
  pushlist "SixPart" "leather bustier"
  pushlist "SixPart" "leather shorts"
  pushlist "SixPart" "female leather armor"
  pushlist "SixPart" "studded bustier"
  pushlist "SixPart" "studded armor"
endif
// ---------------------------------------------
// Book we want to sort through
// ---------------------------------------------
if not @findobject "toSort"
  headmsg "Select BOD book to sort" "100"
  promptalias "toSort"
endif
// ---------------------------------------------
// Container that holds book of each type
// ---------------------------------------------
if not @findobject "BRSKcont"
  headmsg "Select container where BRSK book is" "100"
  promptalias "BRSKcont"
endif
if not @findobject "HRSKcont"
  headmsg "Select container where HRSK book is" "100"
  promptalias "HRSKcont"
endif
if not @findobject "SRSKcont"
  headmsg "Select container where SRSK book is" "100"
  promptalias "SRSKcont"
endif
if not @findobject "CBDcont"
  headmsg "Select container where CBD book is" "100"
  promptalias "CBDcont"
endif
if not @findobject "TPScont"
  headmsg "Select container where TPS book is" "100"
  promptalias "TPScont"
endif
if not @findobject "Footwearcont"
  headmsg "Select container where Footwear book is" "100"
  promptalias "Footwearcont"
endif
if not @findobject "TrashBODcont"
  headmsg "Select container where TrashBod book is" "100"
  promptalias "TrashBODcont"
endif
// ---------------------------------------------
// Book of each type reward
// ---------------------------------------------
if not @findobject "BRSK"
  headmsg "Select BRSK book" "100"
  promptalias "BRSK"
endif
if not @findobject "HRSK"
  headmsg "Select HRSK book" "100"
  promptalias "HRSK"
endif
if not @findobject "SRSK"
  headmsg "Select SRSK book" "100"
  promptalias "SRSK"
endif
if not @findobject "CBD"
  headmsg "Select CBD book" "100"
  promptalias "CBD"
endif
if not @findobject "TPS"
  headmsg "Select TPS book" "100"
  promptalias "TPS"
endif
if not @findobject "Footwear"
  headmsg "Select Footwear book" "100"
  promptalias "Footwear"
endif
if not @findobject "TrashBOD"
  headmsg "Select TrashBOD book" "100"
  promptalias "TrashBOD"
endif
// ---------------------------------------------
// Get first bod from Bulk Source
// ---------------------------------------------
while not @property 'Deeds In Book: 0' 'toSort'
  // If we have a tailoring bod in backpack
  // get its properties
  // otherwise get a new bod
  useobject "toSort"
  waitforgump 0x54f555df 2000
  replygump 0x54f555df 5
  pause 1000
  if @findtype 0x2258 1155 "backpack" "any"
    @setalias "bod" "found"
    waitforproperties "bod" 5000
  endif
  // ---------------------------------------------
  // Find the outfit this bod belongs to
  // ---------------------------------------------
  // if we don't have any sort flags set
  // find the outfit set this bod belongs to
  if not findalias "movetoSRSK" and not findalias "movetoCBD"
    if not findalias "movetoHRSK" and not findalias "movetoBRSK"
      // check fourpart first as we'll get most
      // of our bods here
      for 0 to FourPart
        //headmsg "Checking FourPartBod" "33"
        if @property FourPart[] "bod" and not @property "Leather Skirt" "bod"
          if not @property "Leather Cap" "bod" and not @property "Leather Tunic" "bod"
            if not @property "Fancy Shirt" "bod" and not @property "Studded Tunic" "bod"
              //headmsg "Found FourPartBod" "3"
              @setalias "FourPartBod" "bod"
              //headmsg "FourPartBod" "33"
              break
            endif
          endif
        endif
      endfor
      // if we found the outfit
      // stop checking otherwise check
      // five parts
      if not @findalias "FourPartBod"
        for 0 to FivePart
          //headmsg "Checking FivePartBod" "33"
          if @property FivePart[] "bod"
            //headmsg "Found FivePartBod" "33"
            @setalias "FivePartBod" "bod"
            //headmsg "FivePartBod" "33"
            break
          endif
        endfor
      endif
      // if we found the outfit
      // stop checking otherwise check
      // six parts
      if not @findalias "FourPartBod" and not @findalias "FivePartBod"
        for 0 to SixPart
          //headmsg "Checking SixPartBod" "33"
          if @property SixPart[] "bod"
            //headmsg "Found SixPartBod" "33"
            @setalias "SixPartBod" "bod"
            //headmsg "SixPartBod" "33"
            break
          endif
        endfor
      endif
      if not @findalias "FourPartBod" and not @findalias "FivePartBod"
        if not findalias "SixPartBod"
          for 0 to Footwear
            //headmsg "Checking FootwearBod" "33"
            if @property Footwear[] "bod"
              //headmsg "Found Footwear" "10"
              @setalias "FootwearBod" "bod"
              break
            endif
          endfor
        endif
      endif
    endif
  endif
  //pause 1000
  // ---------------------------------------------
  // Start filtering for reward
  // ---------------------------------------------
  if @findalias "FourPartBod" and not @property "Exceptional" "bod"
    if @property "Make: 20" "bod"
      @setalias "movetoSRSK" "bod"
      headmsg "FourPartBod SRSK" "33"
    endif
  elseif @findalias "FourPartBod" and @property "Exceptional" "bod"
    if @property "Make: 20" "bod"
      //@setalias "movetoSRSK" "bod"
      //headmsg "FourPartBod SRSK" "33"
    endif
  elseif @findalias "FivePartBod" and @property "Exceptional" "bod"
    if @property "Spined" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FivePartBod HRSK" "33"
      endif
    elseif @property "Horned" "bod"
      if @property "Make: 10" "bod" or @property "Make: 15" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FivePartBod HRSK" "33"
      endif
    elseif @property "Barbed" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoBRSK" "bod"
        headmsg "FivePartBod BRSK" "33"
      endif
    elseif @property "Studded" "bod" //plain studded
      if @property "Make: 20" "bod"
        @setalias "movetoCBD" "bod"
        headmsg "FivePartBod 1 CBD" "33"
      endif
    elseif not @property "Bone" "bod" //town crier
      if @property "Make: 20" "bod" and not @property "Bone" "bod"
        @setalias "movetoCBD" "bod"
        headmsg "FivePartBod 2 CBD" "33"
      endif
    endif
  elseif @findalias "SixPartBod" and not @property "Exceptional" "bod"
    if @property "Barbed "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoBRSK" "bod"
        headmsg "SixPartBod BRSK" "33"
      endif
    elseif not @property "Horned" "bod" and not @property "Spined" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoCBD" "bod"
        headmsg "SixPartBod CBD" "33"
      endif
    endif
  elseif @findalias "SixPartBod" and @property "Exceptional" "bod"
    if @property "Spined" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoBRSK" "bod"
        headmsg "SixPartBod BRSK" "33"
      endif
    elseif @property "Horned" "bod"
      @setalias "movetoBRSK" "bod"
      headmsg "SixPartBod BRSK" "33"
    elseif @property "Barbed" "bod"
      @setalias "movetoBRSK" "bod"
      headmsg "SixPartBod BRSK" "33"
    else
      if @property "Make: 10" "bod" or @property "Make: 15" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "SixPartBod HRSK" "33"
      else
        @setalias "movetoTPS" "bod"
        headmsg "SixPartBod TPS" "33"
      endif
    endif
  elseif @findalias "FootwearBOD" and @property "Exceptional" "bod"
    if @property "Barbed" "bod"
      if @property "Make: 20" "bod"
        @setalias "movetoHRSK" "bod"
        headmsg "FootwearBOD HRSK" "33"
      endif
    elseif not @property "Horned" "bod" and not @property "Spined" "bod"
      if @property "Make: 20" "bod" and not @property "Large" "bod"
        @setalias "movetoFootwear" "bod"
        headmsg "Footwear" "33"
      endif
    endif
  endif
  //pause 500
  // ---------------------------------------------
  // Move to correct book
  // ---------------------------------------------
  // World save pause
  if @injournal 'The world will save'
    clearjournal
    sysmsg 'Pausing macro for Server Save'
    waitforjournal 'World save complete' 20000 'system'
    sysmsg 'Resuming macro'
  endif
  // Too many items check
  if @injournal 'That container cannot hold'
    clearjournal
    headmsg "Can't hold anymore items" "33"
    stop
  endif
  // Weight check
  if weight > maxweight
    headmsg "Overweight" "33"
    stop
  endif
  if @findobject "movetoBRSK" 1155 "backpack"
    //find BRSK book
    if not @findobject "BRSK" 0 "backpack"
      @findobject "BRSK" 0 "ground" "any" 3
      @moveitem "BRSK" "backpack" 0 0 0 1
      pause 500
    endif
    @moveitem "movetoBRSK" "BRSK"
    pause 500
    @moveitem "BRSK" "BRSKcont" 0 0 0 1
    pause 500
  endif
  if @findobject "movetoHRSK" 1155 "backpack"
    //find HRSK book
    if not @findobject "HRSK" 0 "backpack"
      @findobject "HRSK" 0 "ground" "any" 3
      @moveitem "HRSK" "backpack" 0 0 0 1
      pause 500
    endif
    @moveitem "movetoHRSK" "HRSK"
    pause 500
    @moveitem "HRSK" "HRSKcont" 0 0 0 1
    pause 500
  endif
  if @findobject "movetoSRSK" 1155 "backpack"
    if not @findobject "SRSK" 0 "backpack"
      @findobject "SRSK" 0 "ground" "any" 3
      @moveitem "SRSK" "backpack" 0 0 0 1
      pause 500
    endif
    @moveitem "movetoSRSK" "SRSK"
    pause 500
    @moveitem "SRSK" "SRSKcont" 0 0 0 1
    pause 500
  endif
  if @findobject "movetoCBD" 1155 "backpack"
    //find CBD book
    if not @findobject "CBD" 0 "backpack"
      @findobject "CBD" 0 "ground" "any" 3
      @moveitem "CBD" "backpack" 0 0 0 1
      pause 500
    endif
    @moveitem "movetoCBD" "CBD"
    pause 500
    @moveitem "CBD" "CBDcont" 0 0 0 1
    pause 500
  endif
  if @findobject "movetoFootwear" 1155 "backpack"
    if not @findobject "Footwear" 0 "backpack"
      @findobject "Footwear" 0 "ground" "any" 3
      @moveitem "Footwear" "backpack" 0 0 0 1
      pause 500
    endif
    @moveitem "movetoFootwear" "Footwear"
    pause 500
    @moveitem "Footwear" "Footwearcont" 0 0 0 1
    pause 500
  endif
  if @findobject "movetoTPS" 1155 "backpack"
    if not @findobject "TPS" 0 "backpack"
      @findobject "TPS" 0 "ground" "any" 3
      @moveitem "TPS" "backpack" 0 0 0 1
      pause 500
    endif
    @moveitem "movetoTPS" "TPS"
    pause 500
    @moveitem "TPS" "TPScont" 0 0 0 1
    pause 500
  endif
  // ---------------------------------------------
  // Trash if we didn't find any of our filters
  // ---------------------------------------------
  if not @findalias "movetoHRSK" and not @findalias "movetoBRSK"
    if not @findalias "movetoSRSK" and not @findalias "movetoCBD"
      if not @findalias "movetoFootwear" and not @findalias "movetoTPS"
        if not @findobject "TrashBOD" 0 "backpack"
          @findobject "TrashBOD" 0 "ground" "any" 3
          @moveitem "TrashBOD" "backpack" 0 0 0 1
          pause 500
        endif
        @moveitem "bod" "TrashBOD"
        headmsg "Item put in Trash book" "100"
        pause 500
        @moveitem "TrashBOD" "TrashBODcont" 0 0 0 1
        pause 500
      endif
    endif
  endif
  // ---------------------------------------------
  // Clean up
  // ---------------------------------------------
  @unsetalias "movetoSRSK"
  @unsetalias "movetoHRSK"
  @unsetalias "movetoBRSK"
  @unsetalias "movetoCBD"
  @unsetalias "movetoTPS"
  @unsetalias "movetoFootwear"
  @unsetalias "FourPartBod"
  @unsetalias "FivePartBod"
  @unsetalias "SixPartBod"
  @unsetalias "FootwearBod"
  @unsetalias "bod"
  @unsetalias "Found"
  pause 500
endwhile
@unsetalias "toSort"
 
Awesome script, I edited it to also sort blacksmith bods.

I am curious can you make it so at the beginning of the macro it puts all bod books in your bag then stores them afterwards, instead of moving back and forth for every bod?
 
Awesome script, I edited it to also sort blacksmith bods.

I am curious can you make it so at the beginning of the macro it puts all bod books in your bag then stores them afterwards, instead of moving back and forth for every bod?

If you want the books to always stay in your backpack then you could set all the book containers to your pack.
 
Is there a way I can have all bods in boxes and at beginning I set alias to a box to sort, then it dosnt ask me which box to sort until I stop and play again?
 

JlM

Wanderer
@Mechanical Turk Is there a reason there is a footwear bod book and it dosnt just put them into the srsk book, and put the garbage footwear bods in garbage book?

Also, I would like it to also instead of all bods that don't make a good reward, it will split flips from leather/bone bods/ and larges that don't make anything. Basically a flip book and a garbage book. How hard would that be?

Would it be easier to pull out the garbage at the end and put it in a book and rest would to to a flip book or the other way around?
 
Last edited:

JlM

Wanderer
@Mechanical Turk this is what I have so far. I made it so the bod books stay in my bag. Please help, its putting bods into the garbage book then it starts just taking them from unsorted bod book and leaving in bag.
Code:
////////////////////////////////
//Purpose: Sorter
////////////////////////////////
//Items needed in inventory:
//BOD books: (8)
//BRSK/HRSK/CBD/120
//Unfilled Flips//Garbage BODs/Unsorted BODs
////////////////////////////////
if not @findobject 'BRSK'
  headmsg "Select BRSK BOD Book" "100"
  headmsg "Select BRSK BOD Book" "100"
  headmsg "Select BRSK BOD Book" "100"
  promptalias 'BRSK'
endif
if not @findobject 'HRSK'
  headmsg "Select HRSK BOD Book" "100"
  headmsg "Select HRSK BOD Book" "100"
  headmsg "Select HRSK BOD Book" "100"
  promptalias 'HRSK'
endif
if not @findobject 'CBD'
  headmsg "Select CBD BOD Book" "100"
  headmsg "Select CBD BOD Book" "100"
  headmsg "Select CBD BOD Book" "100"
  promptalias 'CBD'
endif
if not @findobject '120'
  headmsg "Select 120 BOD Book" "100"
  headmsg "Select 120 BOD Book" "100"
  headmsg "Select 120 BOD Book" "100"
  promptalias '120'
endif
if not @findobject 'Unfilled Flips'
  headmsg "Select Unfilled Flips BOD Book" "100"
  headmsg "Select Unfilled Flips BOD Book" "100"
  headmsg "Select Unfilled Flips BOD Book" "100"
  promptalias 'Unfilled Flips'
endif
if not @findobject 'Unsorted BODs'
  headmsg "Select Unsorted BODs Book" "100"
  headmsg "Select Unsorted BODs Book" "100"
  headmsg "Select Unsorted BODs Book" "100"
  promptalias 'Unsorted BODs'
endif
if not @findobject 'Garbage BODs'
  headmsg "Select Garbage BODs Book" "100"
  headmsg "Select Garbage BODs Book" "100"
  headmsg "Select Garbage BODs Book" "100"
  promptalias 'Garbage BODs'
endif
////////////////////////////////
// Footwear
////////////////////////////////
if not @listexists "Footwear"
  createlist "Footwear"
  pushlist "Footwear" "Sandals" //Footwear Collection
  pushlist "Footwear" "Shoes" //Footwear Collection
  pushlist "Footwear" "Boots" //Footwear Collection
  pushlist "Footwear" "Thigh Boots" //Footwear Collection
endif
////////////////////////////////
// 4 Part outfits
////////////////////////////////
if not @listexists "FourPart"
  createlist "FourPart"
  //pushlist "FourPart" "Bandana" //Gypsy
  //pushlist "FourPart" "Shirt" //Gypsy
  //pushlist "FourPart" "Skirt" //Gypsy
  pushlist "FourPart" "Skullcap" //Pirate
  pushlist "FourPart" "Doublet" //Pirate
  pushlist "FourPart" "Kilt" //Pirate
  pushlist "FourPart" "Jester Hat" //Jester
  pushlist "FourPart" "Jester Suit" //Jester
  pushlist "FourPart" "Cloak" //Jester
  pushlist "FourPart" "Straw Hat" //Farmer
  pushlist "FourPart" "Tunic" //Farmer
  pushlist "FourPart" "Long Pants" //Farmer
  pushlist "FourPart" "Wizards Hat" //Wizard
  pushlist "FourPart" "Body Sash" //Wizard
  pushlist "FourPart" "Robe" //Wizard
  pushlist "FourPart" "Floppy Hat" //Fishergirl
  pushlist "FourPart" "Full Apron" //Fishergirl
  pushlist "FourPart" "Plain Dress" //Fishergirl
  pushlist "FourPart" "Bonnet" //Lady
  pushlist "FourPart" "Half Apron" //Lady
  pushlist "FourPart" "Fancy Dress" //Lady
  pushlist "FourPart" "Tricorne Hat" //Hat Collection
  pushlist "FourPart" "Cap" //Hat Collection
  pushlist "FourPart" "Wide-Brim Hat" //Hat Collection
  pushlist "FourPart" "Tall Straw Hat" //Hat Collection
endif
////////////////////////////////
// 5 Part outfits
////////////////////////////////
if not @listexists "FivePart"
  createlist "FivePart"
  pushlist "FivePart" "studded gorget"
  pushlist "FivePart" "studded gloves"
  pushlist "FivePart" "studded sleeves"
  pushlist "FivePart" "studded leggings"
  pushlist "FivePart" "studded tunic"
  pushlist "FivePart" "bone helmet"
  pushlist "FivePart" "bone gloves"
  pushlist "FivePart" "bone arms"
  pushlist "FivePart" "bone leggings"
  pushlist "FivePart" "bone armor"
  pushlist "FivePart" "feathered hat"
  pushlist "FivePart" "surcoat"
  pushlist "FivePart" "fancy shirt"
  pushlist "FivePart" "short pants"
endif
////////////////////////////////
// 6 Part outfits
////////////////////////////////
if not @listexists "SixPart"
  createlist "SixPart"
  pushlist "SixPart" "leather gorget"
  pushlist "SixPart" "leather skirt"
  pushlist "SixPart" "leather cap"
  pushlist "SixPart" "leather gloves"
  pushlist "SixPart" "leather sleeves"
  pushlist "SixPart" "leather leggings"
  pushlist "SixPart" "leather tunic"
  pushlist "SixPart" "leather bustier"
  pushlist "SixPart" "leather shorts"
  pushlist "SixPart" "female leather armor"
  pushlist "SixPart" "studded bustier"
  pushlist "SixPart" "studded armor"
endif
////////////////////////////////
// Get first bod from Bulk Source
////////////////////////////////
while not @property 'Deeds In Book: 0' 'Unsorted BODs'
  useobject "Unsorted BODs"
  waitforgump 0x54f555df 2000
  replygump 0x54f555df 5
  pause 1000
  if @findtype 0x2258 1155 "backpack" "any"
    @setalias "bod" "found"
    waitforproperties "bod" 5000
  endif
  ////////////////////////////////
  // Find the outfit this bod belongs to
  ////////////////////////////////
  if not findalias "movetoCBD"
    if not findalias "movetoUnfilledFlip" and not findalias "moveto120"
      if not findalias "movetoHRSK" and not findalias "movetoBRSK"
        for 0 to FourPart
          if @property FourPart[] "bod" and not @property "Leather Skirt" "bod"
            if not @property "Leather Cap" "bod" and not @property "Leather Tunic" "bod"
              if not @property "Fancy Shirt" "bod" and not @property "Studded Tunic" "bod"
                @setalias "FourPartBod" "bod"
                break
              endif
            endif
          endif
        endfor
        if not @findalias "FourPartBod"
          for 0 to FivePart
            if @property FivePart[] "bod"
              @setalias "FivePartBod" "bod"
              break
            endif
          endfor
        endif
        if not @findalias "FourPartBod" and not @findalias "FivePartBod"
          for 0 to SixPart
            if @property SixPart[] "bod"
              @setalias "SixPartBod" "bod"
              break
            endif
          endfor
        endif
        if not @findalias "FourPartBod" and not @findalias "FivePartBod"
          if not findalias "SixPartBod"
            for 0 to Footwear
              if @property Footwear[] "bod"
                @setalias "FootwearBod" "bod"
                break
              endif
            endfor
          endif
        endif
      endif
    endif
    //pause 1000
    ////////////////////////////////
    // Start filtering for reward
    ////////////////////////////////
    if @findalias "FourPartBod" and not @property "Exceptional" "bod"
      if @property "Make: 20" "bod"
        // @setalias "movetoSRSK" "bod"
        // headmsg "SRSK" "33"
      endif
    elseif @findalias "FourPartBod" and @property "Exceptional" "bod"
      if @property "Make: 20" "bod"
        //@setalias "movetoSRSK" "bod"
        //headmsg "SRSK" "33"
      endif
    elseif @findalias "FivePartBod" and @property "Exceptional" "bod"
      if @property "Spined" "bod"
        if @property "Make: 20" "bod"
          @setalias "movetoHRSK" "bod"
          headmsg "HRSK" "33"
        endif
      elseif @property "Horned" "bod"
        if @property "Make: 10" "bod" or @property "Make: 15" "bod"
          @setalias "movetoHRSK" "bod"
          headmsg "HRSK" "33"
        endif
      elseif @property "Barbed" "bod"
        if @property "Make: 20" "bod"
          @setalias "movetoBRSK" "bod"
          headmsg "BRSK" "33"
        endif
      elseif @property "Studded" "bod" //plain studded
        if @property "Make: 20" "bod"
          @setalias "movetoCBD" "bod"
          headmsg "CBD" "33"
        endif
      elseif not @property "Bone" "bod" //town crier
        if @property "Make: 20" "bod" and not @property "Bone" "bod"
          @setalias "movetoCBD" "bod"
          headmsg "CBD" "33"
        endif
      endif
    elseif @findalias "SixPartBod" and not @property "Exceptional" "bod"
      if @property "Barbed "bod"
        if @property "Make: 20" "bod"
          @setalias "movetoBRSK" "bod"
          headmsg "BRSK" "33"
        endif
      elseif not @property "Horned" "bod" and not @property "Spined" "bod"
        if @property "Make: 20" "bod"
          @setalias "movetoCBD" "bod"
          headmsg "CBD" "33"
        endif
      endif
    elseif @findalias "SixPartBod" and @property "Exceptional" "bod"
      if @property "Spined" "bod"
        if @property "Make: 20" "bod"
          @setalias "movetoBRSK" "bod"
          headmsg "BRSK" "33"
        endif
      elseif @property "Horned" "bod"
        @setalias "movetoBRSK" "bod"
        headmsg "BRSK" "33"
      elseif @property "Barbed" "bod"
        @setalias "movetoBRSK" "bod"
        headmsg "BRSK" "33"
      else
        if @property "Make: 10" "bod" or @property "Make: 15" "bod"
          @setalias "movetoHRSK" "bod"
          headmsg "HRSK" "33"
        else
          @setalias "moveto120" "bod"
          headmsg "120" "33"
        endif
      endif
    elseif @findalias "FootwearBOD" and @property "Exceptional" "bod"
      if @property "Barbed" "bod"
        if @property "Make: 20" "bod"
          @setalias "movetoHRSK" "bod"
          headmsg "HRSK" "33"
        endif
      elseif not @property "Horned" "bod" and not @property "Spined" "bod"
        if @property "Make: 20" "bod" and not @property "Large" "bod"
          @setalias "movetoGarbageBODs" "bod"
          headmsg "Footwear" "33"
        endif
      endif
    endif
    //pause 500
    ////////////////////////////////
    // Move to correct book
    ////////////////////////////////
    // World save pause
    if @injournal 'The world will save'
      clearjournal
      sysmsg 'Pausing macro for Server Save'
      waitforjournal 'World save complete' 20000 'system'
      sysmsg 'Resuming macro'
    endif
    // Too many items check
    if @injournal 'That container cannot hold'
      clearjournal
      headmsg "Can't hold anymore items" "33"
      stop
    endif
    // Weight check
    if weight > maxweight
      headmsg "Overweight" "33"
      stop
    endif
    if @findobject "movetoBRSK" 1155 "backpack"
      @moveitem "movetoBRSK" "BRSK"
      pause 500
    endif
    if @findobject "movetoHRSK" 1155 "backpack"
      @moveitem "movetoHRSK" "HRSK"
      pause 500
    endif
    if @findobject "movetoCBD" 1155 "backpack"
      @moveitem "movetoCBD" "CBD"
      pause 500
    endif
    if @findobject "movetoGarbageBODs" 1155 "backpack"
      @moveitem "movetoGarbageBODs" "Garbage BODs"
      pause 500
    endif
    if @findobject "moveto120" 1155 "backpack"
      @moveitem "moveto120" "120"
      pause 500
    endif
    ////////////////////////////////
    // Trash if we didn't find any of our filters
    ////////////////////////////////
    if not @findalias "movetoHRSK" and not @findalias "movetoBRSK"
      if not @findalias "moveto120" and not @findalias "movetoCBD"
        if not @findalias "movetoGarbageBODs" and not @findalias "moveto120"
          @moveitem "bod" "Garbage BODs"
          headmsg "Item put in Trash book" "100"
          pause 500
        endif
        //endif
        //endif
        ////////////////////////////////
        // Clean up
        ////////////////////////////////
        @unsetalias "movetoSRSK"
        @unsetalias "movetoHRSK"
        @unsetalias "movetoBRSK"
        @unsetalias "movetoCBD"
        @unsetalias "moveto120"
        @unsetalias "movetoGarbage"
        @unsetalias "FourPartBod"
        @unsetalias "FivePartBod"
        @unsetalias "SixPartBod"
        @unsetalias "FootwearBod"
        @unsetalias "bod"
        @unsetalias "Found"
        pause 500
      endwhile
 
Ok, I'll take a look at that sometime. I quit doing BODs so I might have to scrounge some up. Also on the sevenz script and my modified version, you can keep the bod books in your bag and when it asks for the container you just select the book and I think it has the same effect (it's like 2x faster when you do that).

On your problem, I did have a stray BOD stay in the pack from time to time, but you are saying it happens on every iteration?
 

JlM

Wanderer
Ok, I figured out a lot of my own questions. Still trying to improve, is there a way for when it drops a bod from book into bag, for it to have a timer or reset 'bod' or 'found' for the few times that I thinks it put it into a book or if you already have a bod in your bag. Some times It hangs on this.
 
Top