Skip to content

Conversation

@EmmittJ
Copy link
Member

@EmmittJ EmmittJ commented Mar 14, 2020

This provides all the models and necessary converters in order to parse the Passive Skill Tree JSON data. This is fully backwards compatible with all of the old JSON formats. It also provides a basic url encoder/decoder which correctly supports version 3 and 4.

This is a fairly large pull request, but I wanted to get it all in one go. I can add more tests to areas we think need them as well.

…tions JSON

Added Json classes for both the base passive tree as well as the options that go along with it.
Fixed a build issue
Commented out generic deserialization test for Passive Tree
Addd a Convert method to PassiveTreeDefinition that takes in the JsonPassiveTree class
Addd a Convert method to PassiveNodeDefinition that takes in the JsonPassiveNode class
Fixed the last commit not compiling
Adding Tests for Calculated Properties for PassiveTree.Base classes
Added JsonPassiveTreePosition class to consolidate position calculation and properties
Fixed an issue with how JsonPassiveNode was calculating Position
Added MaxImageZoomLevel and associated tests
Added a position reset when the ZoomLevel changes on JsonPassiveTreePosition
Added BasePassiveTreeURI to JsonPassiveTree
Added PassiveTreeBuildUrlData class with Encode/Decode capabilities for web-safe official urls
Added a ClearPositionCache to JsonPassiveTreePosition in order to accommodate for nodes that change position (Ascendancy Class Groups specifically)
Added tests for ClearPositionCache
Added some tests for JsonPassiveNode Convert to NodeDefinition
Removed ability to set on most collections in on JsonPassive objects
Fixed a parsing issue with JsonPassiveTreeOptions not parsing a list of JsonJewelHighlight
Added Tests for calculated properties in GameModel.PassiveTree.Options (JsonJewelHighlight, JsonAscendancyClassOption)
Updated property names in JsonJewelHighlight to better reflect what is actually being done
Fixed an issue with colour parsing in JsonAscendancyClassOption.FlavourTextColour
@brather1ng
Copy link
Member

I've skimmed over everything and it looks fine in general. Will give it a more detailed look tomorrow. I like the route you went with PassiveTree/NodeDefinition and the deserialization. Means that the current usage can stay as lightweight as it is, while the app itself can use the same deserialization output.

With the new format, the "Opts" of the old format will be obsolete, right? Just a JsonPassiveTree that contains everything.

One thing GGG didn't include in the data released before the patch is the "jewelSlots" array (see the source of https://www.pathofexile.com/passive-skill-tree). That'll be required for importing jewels, so it should also be in JsonPassiveTree.

@EmmittJ
Copy link
Member Author

EmmittJ commented Mar 14, 2020

Yeah, the Opts file will be obsolete. We can keep the loading if we want to load the ascendancy classes and move them into the new format. Would be fairly easy (they are nearly identical). The jewelSlots thing I will look into. I didn't realize that was added. Should be really easy to support.

@brather1ng brather1ng merged commit 822e067 into master Mar 16, 2020
@brather1ng brather1ng deleted the passive-skill-tree branch March 16, 2020 17:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants