Overhauled how effects are edited

This commit is contained in:
Stefan Zermatten
2015-05-27 13:13:51 +02:00
parent 1323d8006c
commit 78b1d71b9d
4 changed files with 49 additions and 70 deletions

View File

@@ -156,7 +156,7 @@ Template.effectView.helpers({
if (this.operation === "conditional"){
return this.calculation || this.value;
}
if (stats[this.stat].group === "Weakness/Resistance"){
if (stats[this.stat] && stats[this.stat].group === "Weakness/Resistance"){
if (this.value === 0.5) return "Resistance";
if (this.value === 2) return "Vulnerability";
if (this.value === 0) return "Immunity";