Fix Bonus bei Wurf anzeige (#114)
Changes: + Situations Boni wird nicht mehr auf den Würfel gerechnet sondern seperat angezeigt wie andere Boni Reviewed-on: #114 Reviewed-by: Le-Frique <lefrique@live.de>
This commit is contained in:
parent
1852f2bf08
commit
38f1c90c09
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"TYPES.Actor.character": "Charakter",
|
"TYPES.Actor.character": "Charakter",
|
||||||
"ACTOR.TypeNpc": "Kreatur / Nichtspielerfigur",
|
"TYPES.Actor.npc": "Kreatur / Nichtspielerfigur",
|
||||||
"ACTOR.TypeVehicle": "Transportmittel / Pferd etc.",
|
"ACTOR.TypeVehicle": "Transportmittel / Pferd etc.",
|
||||||
|
|
||||||
"TYPES.Item.item": "Gegenstand",
|
"TYPES.Item.item": "Gegenstand",
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,12 @@ export class M5Roll {
|
||||||
public _total: number = 0;
|
public _total: number = 0;
|
||||||
public pool: PoolTerm = null;
|
public pool: PoolTerm = null;
|
||||||
|
|
||||||
constructor(public data: M5RollData, public actor: any, public label: string, public id?: string) {
|
constructor(
|
||||||
|
public data: M5RollData,
|
||||||
|
public actor: any,
|
||||||
|
public label: string,
|
||||||
|
public id?: string
|
||||||
|
) {
|
||||||
//super(null)
|
//super(null)
|
||||||
//this.data = rollData
|
//this.data = rollData
|
||||||
}
|
}
|
||||||
|
|
@ -26,7 +31,7 @@ export class M5Roll {
|
||||||
.map((rollName, index) => {
|
.map((rollName, index) => {
|
||||||
indexMap.set(index, rollName);
|
indexMap.set(index, rollName);
|
||||||
const formula = this.data.rolls[rollName];
|
const formula = this.data.rolls[rollName];
|
||||||
formula.formula = index === 0 && this.id !== "-1" ? formula.formula.replace(/(\d*d\d*)/, `{$1 + ${this.data.b.modifier}}`) : formula.formula;
|
formula.formula = index === 0 && this.id !== "-1" ? formula.formula + `+ ${this.data.b.modifier}` : formula.formula;
|
||||||
const roll = new Roll(formula.formula, this.data);
|
const roll = new Roll(formula.formula, this.data);
|
||||||
return roll;
|
return roll;
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue