MHWDB-API
MHWDB-API copied to clipboard
Inconsistent Skill Modifiers
Some of the skill modifiers (especially the elemental damage ones such as damageFire
, damageIce
and so on) have inconsistent types in the API (int
and String
).
This is due to some of the values being just integer numbers or something like 100+5%
. While this may technically be accurate information, it pain points while parsing.
I think it would make sense to add new fields to the SkillModifier
object to include percent damage modifiers. So you could have damageFire
and percentDamageFire
to account for new levels of elemental damage adding a flat base amount + an added % bonus.
Yeah, that's an ugly hold-over from when the data was being scraped from Kiranico / MH Wiki. I'm putting this in the backlog for either the next release or the release after next, since like you said, it makes parsing that field more difficult than it should be.
Sounds good!
What approach are you going to take to add that information? New fields in the SkillModifier
class?
I'm probably just gonna add percentDamageXYZ
fields, yeah. At some point, I'd like to completely refactor how the modifiers
field is stored and represented in the API, but I think that's gonna be a bit too much work to try and fit into this next release.
Ok sounds good to me 👍
Any updates on this? This is still a bit of a pain point.