Feat: Coordinate obfuscation/censoring
Feature
I (someone else) would (should) like (must) to implement a feature (security utility) that...
Hides coordinates from everything when specific conditions are met. These should include:
- User wants to censor coordinates
- Automatically censoring coordinates if location changes (for instance getting teleported with coordinates on)
The coordinate obfuscation should apply to:
- Messages with coordinates printed in chat by the client
- Coordinates send to chat by the player by accident (might be out of scope)
- Coordinates displayed by HUD elements
- Debug messages
The obfuscation implementation could obfuscate by:
- Removing coordinate numbers
- Using relative coordinates to something
- Scrambling coordinates
- Hiding elements displaying coordinates
Tasks TODO:
- [ ] Implement utility to transform coordinates to Text
- [ ] Replace all coordinate printing in the codebase with common Text transformation utility
- [ ] Implement module to trigger coordinate obfuscation automatically
Pull Request
- [ ] I will be submitting a pull request
This seems overly complicated to implement without adding boilerplate everywhere
This seems overly complicated to implement without adding boilerplate everywhere
The idea is to add a common utility to translate coordinates to text. Then, you can hook into that to change if and how coordinates are displayed. People can still leak coords in public chat if they want, but for most common uses, modules should use the common utility to convert coordinates. Baritone has a similar utility that obfuscstes coordinates if enabled.
For reference https://github.com/cabaletta/baritone/blob/a9f40fb0e5f9d1b61bf4836e4d7eb53dc7965a8b/src/api/java/baritone/api/utils/SettingsUtil.java#L172