Template:Hit Point Market Value Inverse

From RimWorld Wiki
Jump to navigation Jump to search
Documentation icon Template documentation[view] [edit] [history] [purge]

This template calculates the minimum percentage hit points (0.0 to 1.0) at which an item would be worth n if its market value at full durability is m:

{{Hit Point Market Value Inverse|n|m}}

Returns never if n > m

Note that this ignores all sell price modifiers.

Relationship between hit points and value

Examples[edit]

{{Hit Point Market Value Inverse|64|64}}

Returns 0.9 because from 0.9 to 1.0 hit points, items have full market value.

{{Hit Point Market Value Inverse|5|50}}

Returns 0.5 because items have 10% of full market value when at 50% of hit points.

{{Hit Point Market Value Inverse|2|50}}

Returns 0.2 because items have 4% of full market value when at 20% of hit points.

{{Hit Point Market Value Inverse|80|75}}

Returns never because the target market value is greater than the maximum market value