Skip to content
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

oc_rlvsuite fix chat commands for restrictions #1015

Merged
merged 3 commits into from
Jul 28, 2024

Conversation

Medea-Destiny
Copy link
Collaborator

Chat command for applying restrictions had problems -- if the restriction itself is given rather than the button name, it would break. Added sanity check to ApplyCommand function, index of g_lRLVList is now checked to see if it gets an RLVCMD and if so converts to index of ButtonText, and returns if hit is CategoryIndex. Ensure the full command is fed to ApplyCommand, not just the first word -- ie (prefix) restriction add "TP Location" shouldn't attempt to add just "TP". NOTE: This fix will also allow presets with a space in the name to be accessed properly.

Changed filtering in UserCommand so that capitalization does not have to match (i.e it will accept "Preset" as well as "preset". Now also passes rlv as a synonym for setting restrictions which was coded but rejected before hit, but filters to only pass to ApplyCommand if there is a command following that is not "on" or "off" to avoid collision with RLV menu

Removed double menu for (prefix) restrictions

@Medea-Destiny Medea-Destiny added the Do Not Merge (yet) One reason or another for not merging label Nov 28, 2023
Copy link
Collaborator

@Pingout Pingout left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This tested as expected. RLV Restrictions now work properly with chat commands.
One note though, capitalization in using the Button Name is required. For example '[prefix] restriction add Blur View' will work but '[prefix] restriction add blur view' will not work.
'[prefix] restriction add setdebug_renderresolutiondivisor' works as expected.
The [prefix] restrictions chat command resulted in only one Restrictions Menu

@Medea-Destiny Medea-Destiny removed the Do Not Merge (yet) One reason or another for not merging label Jul 1, 2024
@Medea-Destiny
Copy link
Collaborator Author

Added fallback mode for case insensitivity to solve capitalization requirements.

@Medea-Destiny Medea-Destiny added the Needs testing This issue needs volunteers to try to duplicate the error or identify a caues label Jul 13, 2024
@Pingout
Copy link
Collaborator

Pingout commented Jul 18, 2024

Added fallback mode for case insensitivity to solve capitalization requirements.

Medea, can you check this please? I'm still having a problem with case sensitive, specifically '[prefix] restriction add blur view' will not work still

@Medea-Destiny Medea-Destiny added Ready to merge and removed Needs testing This issue needs volunteers to try to duplicate the error or identify a caues labels Jul 28, 2024
@SilkieSabra SilkieSabra merged commit d8b8ea8 into 8.3_Features-branch Jul 28, 2024
2 checks passed
@SilkieSabra SilkieSabra deleted the Medea-Destiny-rlvsuite_patch branch July 28, 2024 23:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants