v50 Steam/Premium information for editors
  • v50 information can now be added to pages in the main namespace. v0.47 information can still be found in the DF2014 namespace. See here for more details on the new versioning policy.
  • Use this page to report any issues related to the migration.
This notice may be cached—the current version can be found here.

Editing v0.34 Talk:Weight

Jump to navigation Jump to search

Warning: You are not logged in.
Your IP address will be recorded in this page's edit history.

You are editing a page for an older version of Dwarf Fortress ("Main" is the current version, not "v0.34"). Please make sure you intend to do this. If you are here by mistake, see the current page instead.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.

Latest revision Your text
Line 21: Line 21:
 
This calculation has been verified for several creature sizes and several worn clothing items.  
 
This calculation has been verified for several creature sizes and several worn clothing items.  
 
--[[User:UristDaVinci|UristDaVinci]] 07:40, 22 September 2012 (UTC)
 
--[[User:UristDaVinci|UristDaVinci]] 07:40, 22 September 2012 (UTC)
:I've just checked a disassembly and I came up with the following formula for volume: BASE_SIZE * COVERAGE/100 * LAYER_SIZE/100. BASE_SIZE is calculated from some undetermined values within the caste raws (chosen by whatever race made the armor) using the whatever STEP values are available (in DFHack, they're all in caste_raw.unknown2.unk26[...], currently defined as a single int32[33] array though it's actually divided into 6 sections, one per armor type), using the number 1000 if the "maker race" wasn't available. The notable exceptions to this formula are shields (no coverage or layer_size) and helms (no step factors). --[[User:Quietust|Quietust]] 15:07, 22 September 2012 (UTC)
+
:I've just checked a disassembly and I came up with the following formula : BASE_SIZE * COVERAGE/100 * LAYER_SIZE/100. BASE_SIZE is calculated from some undetermined values within the caste raws (chosen by whatever race made the armor) using the whatever STEP values are available (in DFHack, they're all in caste_raw.unknown2.unk26[...], currently defined as a single int32[33] array though it's actually divided into 6 seconds, one per armor type), using the number 1000 if the "maker race" wasn't available. The notable exceptions to this formula are shields (no coverage or layer_size) and helms (no step factors). --[[User:Quietust|Quietust]] 15:07, 22 September 2012 (UTC)
::So if we use the "volume to weight" formula from the topic page we can solve for your BASE_SIZE as follows using the definitions above:
 
 
 
::BASE_SIZE: [BODY_SIZE]/10*(percentage)*(step factor)
 
 
 
::I thought it was interesting that when I changed body part sizes during the testing, doing things like making the upper arms huge didn't make for huge mail shirts. The step factors don't appear to actually check the body parts they cover, but just change a multiplier to the volume calculated based on the body part the clothing is worn on. --[[User:UristDaVinci|UristDaVinci]] 17:32, 22 September 2012 (UTC)
 
 
 
== Volume ==
 
 
 
Is "volume" as given here ever used anywhere without "*10"? Because wouldn't it be easier to use SIZE / CAPACITY units consistently and don't have *10 and /10 all over?
 
- [[User:TBeholder|TBeholder]] 04:18, 23 October 2012 (UTC)
 
:The x10 factor is just a mathy way to say that the volume should be handled with 10 cm<sup>3</sup> (1 centiliter) precision (SIZE / 10 is an integer division, so by dividing and multiplying by 10 you just truncate last digit). However it's more convenient to think about volume in cm<sup>3</sup> than in centiliters. So you are right that in practice you can almost always ignore x10 factors when SIZE is used and simplify calculation (most of game object sizes are multiples of 10 anyway). It will not work for non-multiples of 10, though. --[[User:Njals|Njals]] ([[User talk:Njals|talk]]) 00:19, 8 May 2013 (UTC)
 

Please note that all contributions to Dwarf Fortress Wiki are considered to be released under the GFDL & MIT (see Dwarf Fortress Wiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

Please sign comments with ~~~~

To protect the wiki against automated edit spam, we kindly ask you to solve the following CAPTCHA:

Cancel Editing help (opens in new window)