fix(monsters.json): updating to make the count property datatype consistent.#524
Open
jfmcdonald wants to merge 1 commit into5e-bits:mainfrom
Open
fix(monsters.json): updating to make the count property datatype consistent.#524jfmcdonald wants to merge 1 commit into5e-bits:mainfrom
jfmcdonald wants to merge 1 commit into5e-bits:mainfrom
Conversation
bagelbits
approved these changes
Jan 18, 2023
Collaborator
bagelbits
left a comment
There was a problem hiding this comment.
Good catch. Violet fungus and Hydra kind of mess everything up.
I think we'll also need to update the types in the API as well.
Collaborator
|
The data types are documented in a few different places in https://github.com/5e-bits/5e-srd-api |
Collaborator
|
I can own updating the API side. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this do?
take 2 on the right repo this time.
This change updates the Monsters.json source file to set the multiattack count properties to a consistent datatype. In 99% of cases the count is an integer. There are however 2(?) instances where the count is a string. This is a pain when parsing with statically typed languages and brakes unmarshaling of the data. I couldn't think of a good way to convert the hydra for instance to a consistent integer so I went and retyped the property throughout. I'm open to better ideas.
How was it tested?
lots of grep statements.
Is there a Github issue this is resolving?
No, I probably should have created an issue, Sorry.
Did you update the docs in the API? Please link an associated PR if applicable.
No, I don't think the datatypes are documented anywhere?
Here's a fun image for your troubles