-
Notifications
You must be signed in to change notification settings - Fork 761
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix copying own skills via RG_PLAGIARISM or SC_REPRODUCE causing the skill to be deleted and skills that required it eventually. #3298
Fix copying own skills via RG_PLAGIARISM or SC_REPRODUCE causing the skill to be deleted and skills that required it eventually. #3298
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there is some missing packet (at least for "newer" clients), on 2019-12-24 main, when a new skill is copied by Plagiarism (Rogue one) the old one stays in the tree as "unlearned":
In this example, I plagiarized Magnum Break and then Bash. Magnum Break stays there as disabled until I log out.
This does not happen in master, so I am guessing it is a bug.
Did you test this on a rogue / stalker and a character that doesn't own skills outside of his skill tree (such as GMs with all skills) Cause this new logic should not touch these skills that you copied unless you are using this artificial case o-o |
Hmm I did use My test was more or less like that:
then, on a pvp map, use another character to hit me with Magnum Break, which got copied. Then hit by Bash, which got copied but did not erase Magnum Break there. |
Please don't test stuff like this with If you can reproduce that way I'll try to research. |
…d them by accident
…lear_existing_cloneskill
…eskill and thus add support for SKILL_FLAG_REPLACED_LV_0
…ear_existing_reproduceskill
… them by accident
…ch SKILL_FLAG_PLAGIARIZED
…ety reasons as there's no clearly defined behavior for those
dfc86ba
to
8790b0b
Compare
Problem discovered, fixed and accordingly rebased the commits. Introducing a new function |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
working fine now; even with allskills
Pull Request Prelude
Changes Proposed
We address this by implementing logic to use SKILL_FLAG_REPLACED_LV_0 in SC_REPRODUCE and RG_PLAGIARISM.
We also reduced some code-duplication shared with pc_jobchange and skill_attack logic of those two skills.
SKILL_FLAG_PERM_GRANTED skills are no longer copyable as there's no clearly defined implementation for those when copied.
Note: A skill that one has the prerequisites for but one didn't level will appear as SKILL_FLAG_PERMANENT and have it's .id entry set in an
sd
's status.skill[] entry.Note: Well skills that you didn't learn, nor can learn, will also appear as SKILL_FLAG_PERMANENT, but can be distinguished via unset id.
Vaguely inspired by HeraclesHub/Heracles#14
Issues addressed: #3289
List of commits in my private-fork that this PR is based on: