-
-
Notifications
You must be signed in to change notification settings - Fork 417
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
NoPortalOverlay #827
base: master
Are you sure you want to change the base?
NoPortalOverlay #827
Conversation
This pull request has been open for a while with no recent activity. If you're still working on this or waiting for a review, please add a comment or commit within the next 7 days to keep it open. Otherwise, the pull request will be automatically closed to free up time for other tasks. Pull requests should be closed if:
|
Still relevant, although with this PR and NoBlockOverlay (#728), we would have a lot of different NoXOverlay hacks. It might be better to combine them all into one. |
WalkthroughWalkthroughThe changes encompass the addition of a feature in the Wurst Minecraft client mod that enables players to disable the portal overlay effect. This enhancement includes introducing a new hack ( Changes
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
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.
Review Status
Actionable comments generated: 0
Configuration used: CodeRabbit UI
Files ignored due to filter (1)
- src/main/resources/assets/wurst/lang/en_us.json
Files selected for processing (3)
- src/main/java/net/wurstclient/hack/HackList.java (1 hunks)
- src/main/java/net/wurstclient/hacks/NoPortalOverlayHack.java (1 hunks)
- src/main/java/net/wurstclient/mixin/IngameHudMixin.java (1 hunks)
Additional comments: 3
src/main/java/net/wurstclient/hacks/NoPortalOverlayHack.java (1)
- 1-24: The class
NoPortalOverlayHack
is well-structured and follows Java conventions. The constructor sets the hack's name and category appropriately.src/main/java/net/wurstclient/mixin/IngameHudMixin.java (1)
- 59-70: Verify that the
WurstClient.INSTANCE
is reliably instantiated before theonRenderPortalOverlay
method is called to prevent potential null pointer exceptions.src/main/java/net/wurstclient/hack/HackList.java (1)
- 138-145: The addition of
NoPortalOverlayHack
toHackList
follows the established pattern and is correctly instantiated.
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.
Review Status
Actionable comments generated: 0
Configuration used: CodeRabbit UI
Files selected for processing (1)
- src/main/java/net/wurstclient/hacks/NoPortalOverlayHack.java (1 hunks)
Files skipped from review as they are similar to previous changes (1)
- src/main/java/net/wurstclient/hacks/NoPortalOverlayHack.java
This pull request has been open for a while with no recent activity. If you're still working on this or waiting for a review, please add a comment or commit within the next 7 days to keep it open. Otherwise, the pull request will be automatically closed to free up time for other tasks. Pull requests should be closed if:
|
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.
Actionable comments posted: 0
Review Details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files ignored due to path filters (1)
src/main/resources/assets/wurst/lang/en_us.json
is excluded by!**/*.json
Files selected for processing (1)
- src/main/java/net/wurstclient/mixin/IngameHudMixin.java (1 hunks)
Additional comments not posted (2)
src/main/java/net/wurstclient/mixin/IngameHudMixin.java (2)
65-68
: Check the use ofWurstClient.INSTANCE
for potential thread-safety issues.Verification successful
The
WurstClient
class is defined as an enum, which inherently provides thread-safety guarantees for its instances. Enums in Java are thread-safe and provide a singleton guarantee, ensuring that the instance is created in a thread-safe manner.Given this information, the use of
WurstClient.INSTANCE
does not pose any thread-safety issues.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Description: Verify the thread-safety of `WurstClient.INSTANCE`. # Test: Search for usage of `WurstClient.INSTANCE` across the project. Expect: Proper synchronization or single-threaded access. rg --type java 'WurstClient.INSTANCE' --files-with-matchesLength of output: 6418
Script:
#!/bin/bash # Description: Verify the thread-safety of `WurstClient.INSTANCE`. # Step 1: Find the definition and initialization of `WurstClient.INSTANCE`. rg --type java 'class WurstClient' --files-with-matches rg --type java 'INSTANCE' --files-with-matches # Step 2: Check for synchronization mechanisms around its usage. rg --type java 'synchronized' --files-with-matchesLength of output: 7379
Script:
#!/bin/bash # Description: Verify the thread-safety of `WurstClient.INSTANCE`. # Step 1: Examine the definition and initialization of `WurstClient.INSTANCE` in `WurstClient.java`. rg --type java 'public static final WurstClient INSTANCE' src/main/java/net/wurstclient/WurstClient.java # Step 2: Check if `WurstClient.INSTANCE` is thread-safe by design. rg --type java 'WurstClient' src/main/java/net/wurstclient/WurstClient.javaLength of output: 206
59-69
: Ensure proper integration ofonRenderPortalOverlay
with other methods inIngameHudMixin
.
Gets rid of the portal overlay when standing in a portal in survival.
Summary by CodeRabbit