* Squashed commit of the following:

commit 0bfa224dae
Author: Byroks <byroks@gmail.com>
Date:   Mon Nov 27 19:56:05 2023 +0100

    V1.3.1 (#6)

    * v1.3.1

    * v1.3.1

    * update .gitingore

commit 35a6b0fae9
Author: Byroks <byroks@gmail.com>
Date:   Mon Nov 27 19:48:56 2023 +0100

    v1.3.1

commit db21ca93b0
Author: Byroks <byroks@gmail.com>
Date:   Sun Nov 26 13:13:13 2023 +0100

    subtract ap when casting spell

    Changes:
     + subtract AP when casting a spell

* Dev Kampfkünste Items & Integration (#7)

Changes:
 + add kampfkuenste template
 + add kampfkuenste tab
 + make kampfkuenste rollable
 + update localization

* v2.0.0
This commit is contained in:
2023-11-28 19:50:56 +01:00
committed by GitHub
parent 0bfa224dae
commit 16df142d45
16 changed files with 374 additions and 16 deletions
+21
View File
@@ -245,6 +245,27 @@ export class M5Roll {
return new M5Roll(rollData, actor, (game as Game).i18n.localize("midgard5.resistanceMind"));
}
static async initativeRoll(actor: any) {
let newInitiative; // the initiative value for the combatant
// ...
// The intnitiative value is calculated here
// ...
let combatant = game["combat"].getCombatantByActor(actor._id);
if (!combatant) {
await game["combat"].createEmbeddedDocuments("Combatant", [{ actorId: actor._id }]);
combatant = game["combat"].getCombatantByActor(actor._id);
}
const initiatives = {
_id: combatant._id,
initiative: actor.system.calc.attributes.gw.value,
};
await game["combat"].updateEmbeddedDocuments("Combatant", [initiatives]);
}
static resistanceBody(actor: any) {
const rollData = actor.getRollData() as M5RollData;
rollData.i = {