diff --git a/rpg-docs/Model/Character/Characters.js b/rpg-docs/Model/Character/Characters.js
index efee22a4..65295462 100644
--- a/rpg-docs/Model/Character/Characters.js
+++ b/rpg-docs/Model/Character/Characters.js
@@ -345,8 +345,8 @@ Characters.calculate = {
var value;
var add = 0;
var mul = 1;
- var min = Math.NEGATIVE_INFINITY;
- var max = Math.POSITIVE_INFINITY;
+ var min = Number.NEGATIVE_INFINITY;
+ var max = Number.POSITIVE_INFINITY;
Effects.find({
charId: charId,
diff --git a/rpg-docs/Model/Character/Spells.js b/rpg-docs/Model/Character/Spells.js
index 5234b321..f4759512 100644
--- a/rpg-docs/Model/Character/Spells.js
+++ b/rpg-docs/Model/Character/Spells.js
@@ -62,6 +62,7 @@ Spells.attachSchema(Schemas.Spell);
Spells.attachBehaviour("softRemovable");
makeChild(Spells); //children of spell lists
+makeParent(Spells, ["name", "enabled"]); //parents of attacks
Spells.allow(CHARACTER_SUBSCHEMA_ALLOW);
Spells.deny(CHARACTER_SUBSCHEMA_DENY);
diff --git a/rpg-docs/Routes/Routes.js b/rpg-docs/Routes/Routes.js
index 7a26c2cc..3eff3ff3 100644
--- a/rpg-docs/Routes/Routes.js
+++ b/rpg-docs/Routes/Routes.js
@@ -27,7 +27,7 @@ Router.map(function() {
},
data: {
characters: function(){
- return Characters.find({}, {fields: {_id: 1}});
+ return Characters.find({}, {fields: {_id: 1}, sort: {name: 1}});
}
},
onAfterAction: function() {
diff --git a/rpg-docs/client/views/character/attacks/attackEdit/attackEdit.html b/rpg-docs/client/views/character/attacks/attackEdit/attackEdit.html
index d742378d..a5cd8e03 100644
--- a/rpg-docs/client/views/character/attacks/attackEdit/attackEdit.html
+++ b/rpg-docs/client/views/character/attacks/attackEdit/attackEdit.html
@@ -3,26 +3,26 @@
-
+
\ No newline at end of file
diff --git a/rpg-docs/client/views/character/attacks/attackEdit/attackEdit.js b/rpg-docs/client/views/character/attacks/attackEdit/attackEdit.js
index dd5fb174..295f0311 100644
--- a/rpg-docs/client/views/character/attacks/attackEdit/attackEdit.js
+++ b/rpg-docs/client/views/character/attacks/attackEdit/attackEdit.js
@@ -15,23 +15,23 @@ var damageTypes = [
];
Template.attackEdit.events({
- "tap #deleteAttack": function(event, instance) {
+ "tap .deleteAttack": function(event, instance) {
Attacks.softRemoveNode(this._id);
GlobalUI.deletedToast(this._id, "Attacks", "Attack");
},
- "change #attackBonusInput": function(event) {
+ "change .attackBonusInput": function(event) {
var value = event.currentTarget.value;
Attacks.update(this._id, {$set: {attackBonus: value}});
},
- "change #damageInput": function(event) {
+ "change .damageInput": function(event) {
var value = event.currentTarget.value;
Attacks.update(this._id, {$set: {damage: value}});
},
- "change #detailInput": function(event) {
+ "change .detailInput": function(event) {
var value = event.currentTarget.value;
Attacks.update(this._id, {$set: {details: value}});
},
- "core-select #damageTypeDropdown": function(event) {
+ "core-select .damageTypeDropdown": function(event) {
var detail = event.originalEvent.detail;
if (!detail.isSelected) return;
var value = detail.item.getAttribute("name");
diff --git a/rpg-docs/client/views/character/features/features.js b/rpg-docs/client/views/character/features/features.js
index 5a9fa705..3f68a6af 100644
--- a/rpg-docs/client/views/character/features/features.js
+++ b/rpg-docs/client/views/character/features/features.js
@@ -107,7 +107,8 @@ Template.resource.helpers({
return !valuePositive;
},
getColor: function(){
- if (this.char.attributeValue(this.name) > 0){
+ var value = Characters.calculate.attributeValue(this.char._id, this.name);
+ if (value > 0){
return this.color;
} else {
return "grey";
diff --git a/rpg-docs/client/views/character/stats/hitDice/hitDice.html b/rpg-docs/client/views/character/stats/hitDice/hitDice.html
index ac1b2af3..0cbfbab8 100644
--- a/rpg-docs/client/views/character/stats/hitDice/hitDice.html
+++ b/rpg-docs/client/views/character/stats/hitDice/hitDice.html
@@ -21,7 +21,7 @@
{{characterCalculate "attributeValue" ../_id name}}
- d{{diceNum}} {{characterCalculate "abilityMod" ../_id "constitution"}}
+ d{{diceNum}} {{conMod}}
diff --git a/rpg-docs/client/views/character/stats/hitDice/hitDice.js b/rpg-docs/client/views/character/stats/hitDice/hitDice.js
index e6cd38e5..7399309d 100644
--- a/rpg-docs/client/views/character/stats/hitDice/hitDice.js
+++ b/rpg-docs/client/views/character/stats/hitDice/hitDice.js
@@ -8,6 +8,11 @@ Template.hitDice.helpers({
var value = Characters.calculate.attributeValue(this.char._id, this.name);
return value <= 0;
},
+ conMod: function(){
+ return signedString(
+ Characters.calculate.abilityMod(this.char._id, "constitution")
+ );
+ },
});
Template.hitDice.events({
diff --git a/rpg-docs/client/views/characterList/characterSideList.js b/rpg-docs/client/views/characterList/characterSideList.js
index 956698cd..9bc9637a 100644
--- a/rpg-docs/client/views/characterList/characterSideList.js
+++ b/rpg-docs/client/views/characterList/characterSideList.js
@@ -13,7 +13,10 @@ Template.characterSideList.helpers({
{owner: userId},
]
},
- {fields: {name: 1}}
+ {
+ fields: {name: 1},
+ sort: {name: 1},
+ }
);
}
});
diff --git a/rpg-docs/private/changeLogs/changeLogs.js b/rpg-docs/private/changeLogs/changeLogs.js
index a4346a1b..fddfd7d3 100644
--- a/rpg-docs/private/changeLogs/changeLogs.js
+++ b/rpg-docs/private/changeLogs/changeLogs.js
@@ -208,3 +208,14 @@ ChangeLogs.insert({
"Made dependency loops return NaN immediately, rather than looping indefinitely until a page refresh. Adding an effect that adds \"strength\" to Strength, won't cause Strength to constantly increase or freeze the browser, Strength just becomes NaN",
],
});
+
+ChangeLogs.insert({
+ version: "0.6.4",
+ changes: [
+ "Hit dice now has a \"+\" between the dice and the constitution modifier",
+ "Items with multiple attacks should have the damage type editable on all attacks now",
+ "Spell attacks should now correctly inherit changes to their spell's name",
+ "Character lists should now be ordered alphabetically",
+ "Skills should have correct min and max effects applied again",
+ ],
+});