CPP: Fix Classic Inscription skill progression and skill-up notifications - #271
Closed
CDBrodie wants to merge 1 commit into
Closed
CPP: Fix Classic Inscription skill progression and skill-up notifications#271CDBrodie wants to merge 1 commit into
CDBrodie wants to merge 1 commit into
Conversation
Contributor
Author
|
Closing until I fix a little error I found. |
Owner
Alright |
Contributor
Author
|
This has been Superseded by PR #272 . 271 (This PR) Can be ignored/deleted |
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.
Changes Proposed:
This PR fixes Classic Inscription skill progression and restores the missing native skill-up chat notification.
Testing showed that Inscription is learned correctly from trainers and displays correctly in the Professions window using the parent profession skill:
However, some Classic Inscription recipes reference the expansion-specific child skill in their DB2
SkillupSkillLineID:The player does not normally store Classic Inscription progression on skill
2514. BecausePlayer::UpdateCraftSkill()usedSkillupSkillLineIDdirectly, these recipes attempted to increase a skill the character did not possess and therefore awarded no profession skill.For example, Classic Inscription recipe spell
52843reported:The fix resolves
SKILL_INSCRIPTION_2toSKILL_INSCRIPTIONbefore checking and increasing the player's crafting skill.This preserves the correct BFA profession representation while allowing Classic Inscription recipes to increase the player's actual Inscription skill.
This PR also restores the missing client skill-up notification from
Player::UpdateSkillPro().Previously,
UpdateSkillPro()successfully changed the player's skill rank but did not send a corresponding skill chat message. Profession skill therefore increased internally and in the profession window without displaying the normal blue skill-up notification.After a successful skill increase, the core now sends the message using the native
CHAT_MSG_SKILLchat type and the localized skill name.Example:
Milling was also tested during investigation. The existing Milling implementation already progresses
SKILL_INSCRIPTIONcorrectly and therefore does not require modification.This PR proposes changes to:
Issues Addressed:
SKILL_INSCRIPTION_2do not increase the player's actual Inscription skill.Player::UpdateCraftSkill()attempts to progress skill2514even though the player normally stores Inscription progression on skill773.Player::UpdateSkillPro()do not display the normal client skill-up message.2514is not required and can interfere with the profession displayed by the BFA client.SOURCE:
The changes have been validated through:
The behavior was validated directly against the current BFA-HavenCore implementation and its DB2 skill-line data during in-game testing.
Observed Classic Inscription recipe data before resolving the skill line:
After resolving the recipe skill line to the player's stored Inscription skill:
Milling was also verified independently to increase the stored Inscription skill:
No
2514skill entry was required on the player.Tests Performed:
This PR has been:
Testing was performed on Windows using a locally compiled RelWithDebInfo build.
The following scenarios were tested:
773.SkillupSkillLineID = 2514now increase skill773.2514does not need to exist incharacter_skills.CHAT_MSG_SKILLnotification.SkillLineEntry.How to Test the Changes:
Create or use a character that does not currently know Inscription.
Learn Inscription normally from a profession trainer.
Open the Professions window and confirm Inscription appears normally and Milling is available.
If desired, save and log out and verify the stored skill:
The expected profession skill is
773.Skill
2514should not need to be manually created on the character.Recipe spell
52843was used during testing.Craft the recipe.
Confirm that the Inscription profession skill increases.
Confirm the client displays a blue skill-up message similar to:
Mill a low-level herb that can grant Inscription skill.
Confirm Milling also increases the same Inscription profession skill.
Confirm the Milling skill increase also displays the normal blue skill-up message.
Save and log out, then verify the persisted value:
The expected result is progression on skill
773without requiring a2514skill entry.Player::UpdateSkillPro()is a generic skill progression function, regression testing should also be performed on other skills that use this path.Recommended professions to verify include:
Confirm that normal skill progression still works and that successful skill increases display the native
CHAT_MSG_SKILLnotification.Known Issues and TODO List:
SkillupSkillLineID = 0in DB2 data. These recipes cannot award profession skill throughUpdateCraftSkill()and are separate data issues from the Inscription progression problem addressed by this PR.UpdateSkillPro()is a generic skill progression path.How to Test BFA-HavenCore PRs
When a PR is ready to be tested, it will be marked as [WAITING TO BE TESTED].
You can help by testing PRs and writing your feedback here on the PR's page on GitHub.
REMEMBER: when testing a PR that changes something generic (i.e. a part of code that handles more than one specific thing), the tester should not only check that the PR does its job (e.g. fixing spell XXX) but especially check that the PR does not cause any regression (i.e. introducing new bugs).
For example: if a PR fixes spell X by changing a part of code that handles spells X, Y, and Z, we should not only test X, but we should test Y and Z as well.