-
Notifications
You must be signed in to change notification settings - Fork 426
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
[Rules] Update logic checks everywhere for FVNoDropFlag. #2179
Conversation
FVNoDropFlag == 0 is disabled FVNoDropFlag == 1 is enabled for everyone FVNoDropFlag == 2 is enabled for Admin() >= Character:MinStatusForNoDropExemptions
I noticed some inconsistency in the FVNoDropFlag logic so I made some corrections. I have not had a chance to test these yet as I do not have my full dev environment setup yet, but the logic was simple enough that I wanted to get a pull request up. |
Have you had time to set up an environment to test this? |
I haven't had a chance to run this PR locally yet, will get to it today or this weekend. |
…or FVNoDropFlag checks
Tested World:FVNoDropFlag == 0, 1, 2 and Character:MinStatusForNoDropExemptions <, ==, > Admin() |
Beautiful, I'll let some other eyes peek at this, but looks good to me. Thanks for the contribution. 👍 |
Accidentally closed, I reopened it. |
I ran these changes on my personal server for over a month. I noticed that attuned items still were not tradable, but this fixed NO DROP items from being tradeable like it should. I'll put a separate PR up to fix being able to trade attuned items later. |
Another note on readability, these checks could benefit from client helpers to make the code a bit more readable beyond the constants themselves - function helper(s) that describe the intent of what's being checked for |
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.
Bumping for constant changes before merge
@Quintinon we plan on getting this one sorted? |
…/EQEmuServer into fix_FVNoDropFlag_logic
…and make an enum for the possible values. Added console warning if setting is outside of allowed values.
* Update logic checks everywhere for FVNoDropFlag. FVNoDropFlag == 0 is disabled FVNoDropFlag == 1 is enabled for everyone FVNoDropFlag == 2 is enabled for Admin() >= Character:MinStatusForNoDropExemptions * Adding extra parenthesis to reduce ambiquity of order of operations for FVNoDropFlag checks * Move FVNoDropFlag checks into a helper function in emu_constants.cpp and make an enum for the possible values. Added console warning if setting is outside of allowed values. * Move to client scoped helper method Co-authored-by: Akkadius <akkadius1@gmail.com>
* Update logic checks everywhere for FVNoDropFlag. FVNoDropFlag == 0 is disabled FVNoDropFlag == 1 is enabled for everyone FVNoDropFlag == 2 is enabled for Admin() >= Character:MinStatusForNoDropExemptions * Adding extra parenthesis to reduce ambiquity of order of operations for FVNoDropFlag checks * Move FVNoDropFlag checks into a helper function in emu_constants.cpp and make an enum for the possible values. Added console warning if setting is outside of allowed values. * Move to client scoped helper method Co-authored-by: Akkadius <akkadius1@gmail.com>
FVNoDropFlag == 0 is disabled
FVNoDropFlag == 1 is enabled for everyone
FVNoDropFlag == 2 is enabled for Admin() >= Character:MinStatusForNoDropExemptions