Made passive scores show up for all skills with bonuses to passive score

closes #56
This commit is contained in:
Stefan Zermatten
2017-07-13 13:42:04 +02:00
parent 3227cd0934
commit 6a84c83644
5 changed files with 61 additions and 20 deletions

View File

@@ -38,4 +38,16 @@ Template.skillRow.helpers({
operation: "conditional",
}).count();
},
isPassiveShown: function(){
if (this.showPassive === "forced") return true;
if (this.showPassive === "ifNeeded"){
var charId = Template.parentData()._id;
return Effects.find({
charId,
stat: this.skill,
operation: "passiveAdd",
enabled: true,
}).count();
}
},
});