toconnell / kdm-manager

An interactive campaign manager for the game "Monster", by Kingdom Death. Development blog and release notes at https://blog.kdm-manager.com This project has no affiliation with Kingdom Death and is a totally independent, fan-maintained project.
http://kdm-manager.com
Other
26 stars 11 forks source link

PotStars Survivor Sheet - Weapon Mastery box not detecting weapon mastery #513

Closed toconnell closed 5 years ago

toconnell commented 6 years ago

From email:

[5aa3284d8740d97b33de538b] has submitted an error report!

The report goes as follows: People of the Stars Campaign, one character reached Weapon Mastery - Shield, but the corresponding Dragon Trait on the grid is not being noted.

toconnell commented 5 years ago

Looks like this broke during the big type/subtype debacle of 2018.

We were checking for type, but 'weapon_mastery' had turned to the sub_type of A&I assets:

index bb20959..317ab2c 100644
--- a/v2/api.thewatcher.io/api/models/survivors.py
+++ b/v2/api.thewatcher.io/api/models/survivors.py
@@ -2483,7 +2483,7 @@ class Survivor(Models.UserAsset):
                 traits.append("%s ability" % a["name"])

         # check for any weapon mastery
-        AI.filter("type", ["weapon_mastery"], reverse=True)
+        AI.filter("sub_type", ["weapon_mastery"], reverse=True)
         for wm in AI.get_dicts():
             if wm["handle"] in self.survivor["abilities_and_impairments"]:
                 traits.append("Weapon Mastery")

This is resolved in the next release.