diff --git a/source/module/actors/M5Character.ts b/source/module/actors/M5Character.ts index a186773..46f2263 100644 --- a/source/module/actors/M5Character.ts +++ b/source/module/actors/M5Character.ts @@ -461,58 +461,55 @@ export class M5Character extends Actor { }; }); - if (!skip?.encumbrance) { - const item = context.items.filter((x) => x.name === "Belastung"); - if (ret.stats.encumbrance > ret.stats.heavyLoad) { - if (item.length === 0) { - this.createEffect("Belastung", [{ id: "movement", operation: M5ModOperation.DIVISION, type: M5ModType.STAT, value: 2 }]); - } else if (item.length === 1) { - item[0].update({ - data: { - equipped: true, - }, - }); - } else if (item.length === 2) { - item[1]?.delete(); - } - } else if (ret.stats.encumbrance <= ret.stats.heavyLoad) { - if (item.length === 1) { - item[0].update({ - data: { - equipped: false, - }, - }); - } - } - } + // if (!skip?.encumbrance) { + // const item = context.items.filter((x) => x.name === "Belastung"); + // if (ret.stats.encumbrance > ret.stats.heavyLoad) { + // if (item.length === 0) { + // this.createEffect("Belastung", [{ id: "movement", operation: M5ModOperation.DIVISION, type: M5ModType.STAT, value: 2 }]); + // } else if (item.length === 1) { + // item[0].update({ + // data: { + // equipped: true, + // }, + // }); + // } else if (item.length === 2) { + // item[1]?.delete(); + // } + // } else if (ret.stats.encumbrance <= ret.stats.heavyLoad) { + // if (item.length === 1) { + // item[0]?.update({ + // data: { + // equipped: false, + // }, + // }); + // } + // } + // } - if (!skip?.encumbrance) { - const item = context.items.filter((x) => x.name === "Höchstlast"); - if (ret.stats.encumbrance > ret.stats.loadMax) { - if (item.length === 0) { - let messageContent = `Höchstlast wurde überschritten: 1 AP Schaden durch Belastung alle 10 Minuten abziehen!`; - let chatData = { - speaker: ChatMessage.getSpeaker({ actor: Actor.name }), - content: messageContent, - }; - ChatMessage.create(chatData, {}); - ui.notifications.warn(messageContent); - this.createEffect("Höchstlast", [{ id: "ap", operation: M5ModOperation.SUBTRACT, type: M5ModType.STAT, value: 1 }]); - } else if (item.length === 2) { - item[1]?.delete(); - } else if (item.length === 1) { - item[0].update({ - data: { - equipped: true, - }, - }); - } - } else if (ret.stats.encumbrance < ret.stats.loadMax) { - if (item.length === 1) { - item[0]?.delete(); - } - } - } + // if (!skip?.encumbrance) { + // const item = context.items.filter((x) => x.name === "Höchstlast"); + // if (ret.stats.encumbrance > ret.stats.loadMax) { + // if (item.length === 0) { + // this.createEffect("Höchstlast", [{ id: "ap", operation: M5ModOperation.SUBTRACT, type: M5ModType.STAT, value: 1 }]); + // } else if (item.length === 1) { + // item[0].update({ + // data: { + // equipped: true, + // }, + // }); + // } else if (item.length === 2) { + // item[1]?.delete(); + // } + // } else if (ret.stats.encumbrance <= ret.stats.loadMax) { + // if (item.length === 1) { + // item[0]?.update({ + // data: { + // equipped: false, + // }, + // }); + // } + // } + // } } if (!skip?.effects) { @@ -551,11 +548,11 @@ export class M5Character extends Actor { pp: item.system.pp, calc: item.system.calc, } as M5SkillCalculated; - + // Adjust attribute Aussehen based on Athletik skill if (item.name === "Athletik") { ret.attributes.au.value += Math.floor(item.system.fw / 3); - }; + } // Adjust stat Bewegungsweite based on Laufen skill if (item.name === "Laufen") { diff --git a/templates/sheets/character/gear.hbs b/templates/sheets/character/gear.hbs index a31181e..4a5158a 100644 --- a/templates/sheets/character/gear.hbs +++ b/templates/sheets/character/gear.hbs @@ -18,7 +18,7 @@ - + @@ -47,11 +47,11 @@ - - - - - + + + + +