Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: cumulative weight of a container  (Read 1845 times)

HungThir

  • Bay Watcher
    • View Profile
cumulative weight of a container
« on: September 09, 2019, 06:29:44 pm »

is there a way to see the cumulative weight of a container in adventure mode (i.e the container and its contents)? i have dfhack

if i look at the container i can see its own item weight, and if i look at each item in it i can see its own item weight, and for containers of big objects i could just pull out a calculator and add it up...

but items that weigh less than 1 urist are only shown as "<1", whether they weigh 0.99 or 0.01, so a bag with 100 "<1" items might weigh over 100 (bag weight + 100*0.99) or it might weigh less than 10 (bag weight + 100*.01)... is there any way to know?
Logged

HmH

  • Bay Watcher
  • Cage Trap Personified
    • View Profile
Re: cumulative weight of a container
« Reply #1 on: September 25, 2019, 12:36:24 am »

Take a freshly minted stack of 500 coins.
Throw one coin away. You now have a stack of 499 coins.
Drop another coin. You are left with stack of 498 coins.
Sell a coin to someone else. What remains is a stack of 497 coins...

...er, what I meant was, split the stack into several stacks, watch how their weight changes depending on the stack size.
But I'm pretty sure the mass of individual objects is simply summed up when they're in a stack or a container.

HungThir

  • Bay Watcher
    • View Profile
Re: cumulative weight of a container
« Reply #2 on: September 26, 2019, 01:45:42 am »

the displayed weight of a stack of items is the sum of the weights of the individual items in the stack, that’s already easy enough to see — if the stack weighs over one it can just be accounted for like any other single heavy item

but imagine a bag full of crafts made from the bones of your conquests... they don’t stack, but they also don’t weigh enough to show a real weight (just “<1”). if there’s 100 of em, they could be weighing you down by 10, or 99, or anywhere in between...

anyway, it’s sounding like there isn’t an in-ui way to see this, so i’m probably gonna just script it in dfhack sometime. will post up the snippet here if/when i do
Logged