Adds Split Personality path connector coloring and an option menu toggle to disable it.#9504
Open
Devlin1991 wants to merge 1 commit intoPathOfBuildingCommunity:devfrom
Open
Conversation
…gle to disable it. Signed-off-by: Andrew Devlin <devlin1991@googlemail.com>
35d4f25 to
54a43e5
Compare
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.
Description of the problem being solved:
When a "Split Personality, Crimson Jewel" is socketed into the passive skill tree the node connectors are not rendered differently to identity the shortest path from class starting node like the game does.
Steps taken to verify a working solution:
PassiveSpecClass:GetShortestPathToClassStart(rootId)to calculate which nodes are on the path between a given node and the class start. The existingfunction PassiveSpecClass:SetNodeDistanceToClassStart(root)which is used to calculate the Split Personality multiplier only returns the distance so was not applicable here.function PassiveTreeViewClass:Draw(build, viewPort, inputEvents)which checks for nodes which contain Split Personality jewels by looking for thejewelIncEffectFromClassStartvariable on them, then feeds those nodes intoGetShortestPathToClassStartand creates a table containing the superset of nodes on those paths calledsplitPersonalityPathSPLITPERSONALITYwith the color chosen by picking the middle tone from the PoE in-game split personality connector texture. It's a more complex texture and I wanted to avoid adding an entirely new set of connector textures for this commit, I may add it as a follow-up PR.function renderConnector(connector)which checks if both nodes are in the splitPersonalityPath and if so changes the default connector color from white tocolorCodes.SPLITPERSONALITY, this does not affect anything that previously overrode the default white color such as the compare mode or hover disconnection.function PassiveTreeViewClass:Draw(build, viewPort, inputEvents)which checks if a node is in the splitPersonalityPath and if so changes the default node color from white tocolorCodes.SPLITPERSONALITY, this does not affect anything that previously overrode the default white color such as the compare mode or hover disconnection.showSplitPersonalityPathit defaults to true but can be disabled in the options menu under the "build-related options" submenu.Link to a build that showcases this PR:
https://pobb.in/zZ8X9L54cb2b
Before screenshot:
After screenshot: