Various fixes for official release
This commit is contained in:
@@ -54,7 +54,7 @@ export default class MGNECharacter extends foundry.abstract.TypeDataModel {
|
||||
|
||||
// Compute current load per RAW:
|
||||
// Only items with a weight field count — features and creature-traits are excluded
|
||||
// trivial = 0, light = 10 per slot, normal = 1, heavy = fills remaining capacity (max 1)
|
||||
// trivial = 0, light = 10 per slot, normal = 1, heavy = 2
|
||||
let normalLoad = 0
|
||||
let lightCount = 0
|
||||
let heavyCount = 0
|
||||
@@ -71,15 +71,7 @@ export default class MGNECharacter extends foundry.abstract.TypeDataModel {
|
||||
this.lightItemCount = lightCount
|
||||
this.heavyItemCount = heavyCount
|
||||
|
||||
if (heavyCount >= 2) {
|
||||
// Can't carry two heavy items — automatically overloaded
|
||||
this.currentLoad = this.carryCapacity + (heavyCount - 1)
|
||||
} else if (heavyCount === 1) {
|
||||
// Heavy fills remaining capacity; other items fit alongside it
|
||||
this.currentLoad = Math.max(normalLoad, this.carryCapacity)
|
||||
} else {
|
||||
this.currentLoad = normalLoad
|
||||
}
|
||||
this.currentLoad = normalLoad + heavyCount * 2
|
||||
this.overloaded = this.currentLoad > this.carryCapacity
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user