Petites améliorations

This commit is contained in:
2025-10-05 22:36:41 +02:00
parent 33dc58138c
commit 1bf9e330f4
18 changed files with 79 additions and 42 deletions

View File

@@ -1,10 +1,15 @@
import { DIFF, DIFFS, ROLL_TYPE_MEDITATION, ROLL_TYPE_OEUVRE, ROLL_TYPE_SORT, ROLL_TYPE_TACHE } from "./roll-constants.mjs";
import { DIFF, DIFFS, ROLL_TYPE_CUISINE, ROLL_TYPE_MEDITATION, ROLL_TYPE_OEUVRE, ROLL_TYPE_SORT, ROLL_TYPE_TACHE } from "./roll-constants.mjs";
import { ROLLDIALOG_SECTION, RollPart } from "./roll-part.mjs";
import { Misc } from "../misc.js";
export const PART_DIFF = "diff"
const EXCLUDED_ROLL_TYPES = [ROLL_TYPE_TACHE, ROLL_TYPE_MEDITATION, ROLL_TYPE_SORT, ROLL_TYPE_OEUVRE]
const EXCLUDED_ROLL_TYPES = [
ROLL_TYPE_TACHE,
ROLL_TYPE_MEDITATION,
ROLL_TYPE_SORT,
ROLL_TYPE_CUISINE,
ROLL_TYPE_OEUVRE]
export class RollPartDiff extends RollPart {
@@ -53,8 +58,8 @@ export class RollPartDiff extends RollPart {
setDiff(rollData, diff) {
const current = this.getCurrent(rollData)
current.value = diff.diff
current.type = diff.type
current.value = diff.diff ?? current.value
current.type = diff.type ?? current.type
}
getAjustements(rollData) {