Issue #8478 fix: Error loop when active skill disabled with Tawhoa's Chosen mirage skill#8480
Closed
umn-anon wants to merge 1 commit intoPathOfBuildingCommunity:devfrom
umn-anon:dev
Closed
Issue #8478 fix: Error loop when active skill disabled with Tawhoa's Chosen mirage skill#8480umn-anon wants to merge 1 commit intoPathOfBuildingCommunity:devfrom umn-anon:dev
umn-anon wants to merge 1 commit intoPathOfBuildingCommunity:devfrom
umn-anon:dev
Conversation
Contributor
|
This issues is caused by mainSkill being set to DefaultAttack when no active skill is found in a selected group. While the proposed solution works fine it also prevents mirages from being triggered by skills from items, tree or other sources not from gems. +++ b/src/Modules/CalcActiveSkill.lua
@@ -158,12 +158,18 @@ end
function calcs.copyActiveSkill(env, mode, skill)
local activeEffect = {
grantedEffect = skill.activeEffect.grantedEffect,
- level = skill.activeEffect.srcInstance.level,
- quality = skill.activeEffect.srcInstance.quality,
- qualityId = skill.activeEffect.srcInstance.qualityId,
- srcInstance = skill.activeEffect.srcInstance,
- gemData = skill.activeEffect.srcInstance.gemData,
+ level = skill.activeEffect.level,
+ quality = skill.activeEffect.quality
}
+
+ if skill.activeEffect.srcInstance then
+ activeEffect.level = skill.activeEffect.srcInstance.level
+ activeEffect.quality = skill.activeEffect.srcInstance.quality
+ activeEffect.qualityId = skill.activeEffect.srcInstance.qualityId
+ activeEffect.srcInstance = skill.activeEffect.srcInstance
+ activeEffect.gemData = skill.activeEffect.srcInstance.gemDat
+ end
+
local newSkill = calcs.createActiveSkill(activeEffect, skill.supportList, skill.actor, skill.socketGroup, skill.summonSkill)
local newEnv, _, _, _ = calcs.initEnv(env.build, mode, env.override)
calcs.buildActiveSkillModList(newEnv, newSkill)The above simply fixes the crash without changing what is supported and what is not. Note that because the DefaultAttack skill is only created when mainSkill is nil. Selecting tawhoa's chosen in the dropdown will still say that it's not finding a trigger source. |
Member
|
Implemented Paliak's fix in #8507 |
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.
Fixes # 8478
Description of the problem being solved:
see #8478
Steps taken to verify a working solution:
Link to a build that showcases this PR:
https://pobb.in/IjlXE2-NbvaG
Before screenshot:
After screenshot: