-
-
Notifications
You must be signed in to change notification settings - Fork 429
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
Separate Hoglins from Passive Mob #959
Conversation
WalkthroughWalkthroughThis update primarily focuses on downgrading various components such as the Minecraft version, yarn mappings, fabric version, and mod version. It also adjusts method calls and logic across the codebase to align with these downgrades, improves authentication handling, streamlines rendering logic, and simplifies method signatures. The changes span across multiple areas including friend management, alt account management, command handling, hack functionalities, mixin adjustments, UI enhancements, and utility modifications. Changes
This table consolidates the changes into categories, summarizing the adjustments made across the codebase to accommodate version downgrades, improve authentication processes, and enhance UI consistency and code maintainability. 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 (
|
Bro, I just pr the wrong branch! I hate branches! |
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: 6
Configuration used: CodeRabbit UI
Files ignored due to path filters (3)
src/main/resources/assets/wurst/lang/en_us.json
is excluded by:!**/*.json
src/main/resources/fabric.mod.json
is excluded by:!**/*.json
src/main/resources/wurst.mixins.json
is excluded by:!**/*.json
Files selected for processing (69)
- gradle.properties (1 hunks)
- src/main/java/net/wurstclient/FriendsList.java (2 hunks)
- src/main/java/net/wurstclient/WurstClient.java (1 hunks)
- src/main/java/net/wurstclient/altmanager/AltRenderer.java (4 hunks)
- src/main/java/net/wurstclient/altmanager/LoginManager.java (1 hunks)
- src/main/java/net/wurstclient/altmanager/MicrosoftLoginManager.java (1 hunks)
- src/main/java/net/wurstclient/altmanager/MinecraftProfile.java (1 hunks)
- src/main/java/net/wurstclient/altmanager/MojangAlt.java (1 hunks)
- src/main/java/net/wurstclient/altmanager/screens/AltEditorScreen.java (4 hunks)
- src/main/java/net/wurstclient/altmanager/screens/AltManagerScreen.java (4 hunks)
- src/main/java/net/wurstclient/altmanager/screens/DirectLoginScreen.java (1 hunks)
- src/main/java/net/wurstclient/clickgui/screens/AddBookOfferScreen.java (4 hunks)
- src/main/java/net/wurstclient/clickgui/screens/ClickGuiScreen.java (2 hunks)
- src/main/java/net/wurstclient/clickgui/screens/EditBlockListScreen.java (6 hunks)
- src/main/java/net/wurstclient/clickgui/screens/EditBlockScreen.java (3 hunks)
- src/main/java/net/wurstclient/clickgui/screens/EditBookOfferScreen.java (3 hunks)
- src/main/java/net/wurstclient/clickgui/screens/EditBookOffersScreen.java (3 hunks)
- src/main/java/net/wurstclient/clickgui/screens/EditColorScreen.java (3 hunks)
- src/main/java/net/wurstclient/clickgui/screens/EditItemListScreen.java (5 hunks)
- src/main/java/net/wurstclient/clickgui/screens/EditSliderScreen.java (2 hunks)
- src/main/java/net/wurstclient/clickgui/screens/EditTextFieldScreen.java (2 hunks)
- src/main/java/net/wurstclient/clickgui/screens/SelectFileScreen.java (3 hunks)
- src/main/java/net/wurstclient/commands/AddAltCmd.java (1 hunks)
- src/main/java/net/wurstclient/commands/CopyItemCmd.java (1 hunks)
- src/main/java/net/wurstclient/commands/PotionCmd.java (4 hunks)
- src/main/java/net/wurstclient/hacks/AnchorAuraHack.java (1 hunks)
- src/main/java/net/wurstclient/hacks/AutoFarmHack.java (1 hunks)
- src/main/java/net/wurstclient/hacks/BonemealAuraHack.java (1 hunks)
- src/main/java/net/wurstclient/hacks/ChestEspHack.java (3 hunks)
- src/main/java/net/wurstclient/hacks/CrystalAuraHack.java (1 hunks)
- src/main/java/net/wurstclient/hacks/KillPotionHack.java (1 hunks)
- src/main/java/net/wurstclient/hacks/MassTpaHack.java (1 hunks)
- src/main/java/net/wurstclient/hacks/PlayerEspHack.java (2 hunks)
- src/main/java/net/wurstclient/hacks/TrollPotionHack.java (2 hunks)
- src/main/java/net/wurstclient/hacks/XRayHack.java (1 hunks)
- src/main/java/net/wurstclient/mixin/ClientPlayNetworkHandlerMixin.java (1 hunks)
- src/main/java/net/wurstclient/mixin/ControlsListWidgetMixin.java (1 hunks)
- src/main/java/net/wurstclient/mixin/CustomPayloadC2SPacketAccessor.java (1 hunks)
- src/main/java/net/wurstclient/mixin/DirectConnectScreenMixin.java (1 hunks)
- src/main/java/net/wurstclient/mixin/DisconnectedScreenMixin.java (3 hunks)
- src/main/java/net/wurstclient/mixin/IngameHudMixin.java (3 hunks)
- src/main/java/net/wurstclient/mixin/MinecraftClientMixin.java (4 hunks)
- src/main/java/net/wurstclient/mixin/PlayerSkinProviderMixin.java (2 hunks)
- src/main/java/net/wurstclient/mixin/ScreenMixin.java (1 hunks)
- src/main/java/net/wurstclient/mixin/TelemetryManagerMixin.java (1 hunks)
- src/main/java/net/wurstclient/mixin/TitleScreenMixin.java (2 hunks)
- src/main/java/net/wurstclient/mixinterface/IMinecraftClient.java (1 hunks)
- src/main/java/net/wurstclient/navigator/NavigatorMainScreen.java (1 hunks)
- src/main/java/net/wurstclient/navigator/NavigatorScreen.java (2 hunks)
- src/main/java/net/wurstclient/nochatreports/ForcedChatReportsScreen.java (4 hunks)
- src/main/java/net/wurstclient/nochatreports/NcrModRequiredScreen.java (3 hunks)
- src/main/java/net/wurstclient/options/EnterProfileNameScreen.java (2 hunks)
- src/main/java/net/wurstclient/options/KeybindEditorScreen.java (3 hunks)
- src/main/java/net/wurstclient/options/KeybindManagerScreen.java (3 hunks)
- src/main/java/net/wurstclient/options/KeybindProfilesScreen.java (3 hunks)
- src/main/java/net/wurstclient/options/PressAKeyScreen.java (2 hunks)
- src/main/java/net/wurstclient/options/WurstOptionsScreen.java (2 hunks)
- src/main/java/net/wurstclient/options/ZoomManagerScreen.java (2 hunks)
- src/main/java/net/wurstclient/other_features/VanillaSpoofOtf.java (2 hunks)
- src/main/java/net/wurstclient/serverfinder/CleanUpScreen.java (2 hunks)
- src/main/java/net/wurstclient/serverfinder/ServerFinderScreen.java (5 hunks)
- src/main/java/net/wurstclient/serverfinder/WurstServerPinger.java (2 hunks)
- src/main/java/net/wurstclient/settings/filterlists/EntityFilterList.java (1 hunks)
- src/main/java/net/wurstclient/settings/filters/FilterHoglinsSetting.java (1 hunks)
- src/main/java/net/wurstclient/settings/filters/FilterPassiveSetting.java (2 hunks)
- src/main/java/net/wurstclient/util/ChunkUtils.java (1 hunks)
- src/main/java/net/wurstclient/util/FakePlayerEntity.java (1 hunks)
- src/main/java/net/wurstclient/util/LastServerRememberer.java (1 hunks)
- src/main/java/net/wurstclient/util/ListWidget.java (1 hunks)
Additional comments: 103
gradle.properties (1)
- 8-16: The versions of Minecraft, yarn mappings, fabric loader, and the mod have been downgraded. Ensure that these versions are compatible with each other and that the downgrade does not introduce any known issues or incompatibilities with other dependencies or features of the mod.
src/main/java/net/wurstclient/mixinterface/IMinecraftClient.java (1)
- 10-10: The import statement for the
Session
class has been updated to reflect its new package location. Ensure that this change aligns with the changes in Minecraft's codebase and that theSession
class is used appropriately within theIMinecraftClient
interface.src/main/java/net/wurstclient/settings/filters/FilterHoglinsSetting.java (1)
- 1-25: The addition of the
FilterHoglinsSetting
class introduces a specific filter for Hoglins, aligning with the PR objectives to correct the classification of Hoglins within the game's entity system. The implementation correctly extendsEntityFilterCheckbox
and provides functionality to exclude Hoglins from being considered in certain filters. Ensure that this new filter is integrated and used appropriately wherever entity filtering is performed.src/main/java/net/wurstclient/altmanager/MinecraftProfile.java (1)
- 25-27: The return type of the
getUUID
method has been changed fromUUID
toString
. Ensure that this change does not break any existing functionality and that all instances wheregetUUID
is called are updated to handle a String return type. This change affects how UUIDs are handled within theMinecraftProfile
class and could have implications on functionality that relies on UUIDs.src/main/java/net/wurstclient/mixin/CustomPayloadC2SPacketAccessor.java (1)
- 1-33: The
CustomPayloadC2SPacketAccessor
mixin interface is correctly defined to provide access to the privatechannel
anddata
fields of theCustomPayloadC2SPacket
class. This enables modifications or access to these fields from other parts of the codebase, aligning with mixin best practices. Ensure that this mixin is used appropriately wherever access to these fields is required.src/main/java/net/wurstclient/mixin/ControlsListWidgetMixin.java (1)
- 29-31: The change in constructor parameters from
y
anditemHeight
totop
andbottom
inControlsListWidgetMixin
aligns with a more descriptive naming convention, enhancing code readability and maintainability.src/main/java/net/wurstclient/other_features/VanillaSpoofOtf.java (2)
- 44-44: Using
CustomPayloadC2SPacketAccessor
instead ofCustomPayloadC2SPacket
directly is a good practice as it adheres to the principle of encapsulation, allowing for safer and more controlled access to the packet's properties.- 50-60: The logic for handling different packet channels (
minecraft:register
,minecraft:brand
, andfabric
) is clear and straightforward. However, ensure that the string literals used for channel names are consistent and error-free across the codebase to prevent any issues with packet handling.Verification successful
Given the results and to ensure a thorough verification, it's necessary to adjust the search criteria to potentially capture more instances and contexts of the strings "minecraft:register", "minecraft:brand", and "fabric" across the codebase. Let's proceed with a more lenient search without quotes and aim to understand the usage of "fabric" in more detail.
The verification process has confirmed that the string literals "minecraft:register" and "minecraft:brand" are not used elsewhere in the codebase, suggesting no inconsistency issues with these specific channel names in packet handling. The usage of "fabric" is consistent and primarily related to the Fabric mod loader and its APIs, indicating a pattern of consistent usage within its context. Therefore, the review comment concerning the consistency and error-free usage of string literals for channel names in packet handling is addressed, and no inconsistency issues were found.
Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Verify consistency of channel names used in packet handling rg --type java '"minecraft:register"' 'src/main/java' rg --type java '"minecraft:brand"' 'src/main/java' rg --type java '"fabric"' 'src/main/java'Length of output: 270
Script:
#!/bin/bash # Adjusted search to verify consistency of channel names used in packet handling without quotes rg --type java minecraft:register 'src/main/java' rg --type java minecraft:brand 'src/main/java' rg --type java fabric 'src/main/java'Length of output: 2591
src/main/java/net/wurstclient/FriendsList.java (2)
- 63-63: Updating the method call from
getName().getString()
togetEntityName()
for retrieving entity names simplifies the code and directly uses the API provided for this purpose, which is a good practice for maintainability and readability.- 78-78: The use of
getEntityName()
in theisFriend
method is consistent with the previous change and ensures that the entity name retrieval logic is uniform across the class, which is beneficial for maintainability.src/main/java/net/wurstclient/commands/CopyItemCmd.java (1)
- 50-50: Changing the method for player name comparison to
getEntityName()
is a positive change, as it directly utilizes the API for retrieving the entity's name, which can lead to more straightforward and readable code.src/main/java/net/wurstclient/options/EnterProfileNameScreen.java (2)
- 84-88: Adding a
tick
method to handle the ticking ofvalueField
is a good practice, ensuring that the text field is updated appropriately. This addition enhances the UI's responsiveness and user experience.- 94-99: The modifications to the
render
method, including the explicit call torenderBackground
and the rendering ofvalueField
, follow best practices for UI rendering in Minecraft, ensuring that the background and interactive elements are rendered correctly.src/main/java/net/wurstclient/clickgui/screens/EditTextFieldScreen.java (2)
- 83-87: The addition of a
tick
method forvalueField
inEditTextFieldScreen
is consistent with best practices for UI components in Minecraft, ensuring that the text field is updated appropriately for user interactions.- 93-98: The modifications to the
render
method, including the call torenderBackground
and the rendering ofvalueField
, are correctly implemented, ensuring that the UI elements are rendered properly and enhancing the user experience.src/main/java/net/wurstclient/clickgui/screens/EditSliderScreen.java (2)
- 88-92: The addition of a
tick
method forvalueField
inEditSliderScreen
ensures that the text field is updated appropriately, which is crucial for maintaining a responsive and user-friendly UI.- 98-103: The modifications to the
render
method, including the call torenderBackground
and the rendering ofvalueField
, are correctly implemented. This ensures that the UI elements are rendered properly, contributing to a better user experience.src/main/java/net/wurstclient/altmanager/LoginManager.java (2)
- 27-82: The modifications to the
login
method to handle authentication using email and password, including the addition of exception handling for various scenarios, are well-implemented. This enhances the security and robustness of the authentication process. However, ensure that sensitive information is handled securely and that error messages do not expose unnecessary details that could be exploited.- 84-87: The update to the
changeCrackedName
method to create a session with a new name is straightforward and correctly implemented. This change allows for the dynamic handling of session information, which is essential for features like the alt manager.src/main/java/net/wurstclient/mixin/TitleScreenMixin.java (1)
- 44-48: Iterating over
Drawable
objects and checking if they are instances ofClickableWidget
in theonInitWidgetsNormal
method is a flexible approach that allows for handling a broader range of UI elements. This change enhances the mixin's ability to interact with the UI components of the title screen.src/main/java/net/wurstclient/settings/filterlists/EntityFilterList.java (1)
- 75-75: Adding
FilterHoglinsSetting
to thegenericCombat
method inEntityFilterList
correctly addresses the PR's primary objective of reclassifying Hoglins from passive to aggressive mobs. This change ensures that Hoglins are appropriately filtered in combat scenarios, aligning with the game's internal logic and enhancing gameplay consistency.src/main/java/net/wurstclient/hacks/TrollPotionHack.java (2)
- 110-112: The changes to the NBT keys "Amplifier", "Duration", and "Id" from lowercase to uppercase are correct and align with Minecraft's NBT data structure requirements. This ensures that the potion effects are properly recognized and applied by the game engine.
- 117-117: The use of
nbt.put("CustomPotionEffects", effects);
correctly assigns the modified potion effects to the item stack. This is a crucial step in ensuring that the potion carries the intended effects.src/main/java/net/wurstclient/hacks/KillPotionHack.java (2)
- 110-112: The changes to the NBT keys "Amplifier", "Duration", and "Id" from lowercase to uppercase are correct and align with Minecraft's NBT data structure requirements for potion effects. This ensures that the potion effects are properly recognized and applied by the game engine.
- 118-118: The use of
nbt.put("CustomPotionEffects", effects);
correctly assigns the modified potion effects to the item stack. This is essential for ensuring that the potion carries the intended effects.src/main/java/net/wurstclient/util/ChunkUtils.java (1)
- 58-58: The modification to use
p.getX()
andp.getZ()
in thegetAffectedChunk
method forChunkDataS2CPacket
instances is correct. This change ensures that the method accurately identifies the chunk affected by the packet, aligning with the expected data provided byChunkDataS2CPacket
.src/main/java/net/wurstclient/options/KeybindEditorScreen.java (3)
- 90-94: The addition of the
tick
method to handle ticking of thecommandField
is a good practice. It ensures that the text field is updated appropriately, enhancing the user interface's responsiveness and functionality.- 100-100: The removal of
partialTicks
from therenderBackground
call in therender
method is correct, asrenderBackground
does not require this parameter. This simplifies the method call and aligns with the expected parameters.- 113-113: Directly calling
super.render
instead of iterating overdrawables
to render each one individually is a streamlined approach. It leverages the built-in rendering logic of the parent class, simplifying the custom render method.src/main/java/net/wurstclient/mixin/DisconnectedScreenMixin.java (4)
- 22-22: The import of
GridWidget
indicates a shift towards using a grid-based layout, which can offer more flexibility and control over UI element positioning compared to a directional layout. This change is likely to enhance the UI design and layout management.- 44-44: The initialization of
grid
withGridWidget
is a crucial step in adopting a grid-based layout. This allows for more structured and flexible positioning of UI elements within the screen.- 79-79: The positioning of the
reconnectButton
within the grid using specific grid coordinates and margins demonstrates the flexibility and control provided by theGridWidget
. This approach facilitates precise placement of UI elements, enhancing the overall layout.- 84-84: Similarly, the positioning of the
autoReconnectButton
within the grid showcases the advantages of using a grid-based layout for UI design. The ability to specify grid coordinates and margins allows for a clean and organized arrangement of buttons.src/main/java/net/wurstclient/options/ZoomManagerScreen.java (2)
- 103-103: The adjustment to the background rendering logic in the
render
method is appropriate. Rendering the background before drawing text and UI elements ensures that the screen is properly prepared for the subsequent UI components.- 110-110: Directly calling
super.render
instead of iterating overdrawables
to render each one individually is a streamlined approach. It leverages the built-in rendering logic of the parent class, simplifying the custom render method and ensuring that all elements are rendered correctly.src/main/java/net/wurstclient/mixin/ClientPlayNetworkHandlerMixin.java (2)
- 10-12: The addition of import statements for
org.spongepowered.asm.mixin.Final
andorg.spongepowered.asm.mixin.Shadow
is necessary for accessing and modifying private fields in the mixin. These imports are correctly used and are essential for the mixin's functionality.- 41-50: The introduction of the
onSendPacket
method with an injection point at the "HEAD" of thesendPacket
method is a strategic enhancement for packet handling. This allows for intercepting and potentially canceling packets before they are sent, providing a mechanism for event firing and packet manipulation. However, ensure that canceling packets does not lead to unintended side effects in the game's networking behavior.Consider testing this change extensively in various networking scenarios to ensure that it does not introduce any negative side effects or disrupt normal game operations.
src/main/java/net/wurstclient/clickgui/screens/EditBlockScreen.java (4)
- 45-45: The positioning of UI elements (
y1
andy2
) has been adjusted. Ensure these changes align with the intended layout and do not cause any UI elements to overlap or become inaccessible.- 51-51: The
blockField
text field has been modified. Verify that the new dimensions (178x18
) and initial text settings are appropriate for the intended use case.- 93-97: The addition of the
tick
method ensures that theblockField
is updated each tick. This is a good practice for dynamic UI elements that may need to respond to user input or other changes over time.- 106-111: The rendering logic has been simplified by removing a loop for drawables and calling the superclass method for rendering. This change should improve maintainability and performance. However, ensure that this does not omit any necessary rendering steps that were previously handled in the loop.
src/main/java/net/wurstclient/nochatreports/ForcedChatReportsScreen.java (3)
- 18-18: The import statement has been updated to reflect changes in the Minecraft API. This is a necessary adjustment to ensure compatibility with the latest version of the game.
- 102-110: > 📝 NOTE
This review was outside the diff hunks and was mapped to the diff hunk with the greatest overlap. Original lines [105-117]
The
render
method signature has been updated, and the rendering logic has been adjusted accordingly. This change likely aligns with updates to the Minecraft API. Ensure that the new rendering logic correctly displays all UI elements as intended.
- 135-135: The method for determining if a disconnect reason is caused by No Chat Reports has been updated to use the new
LiteralTextContent
class. This change should ensure that the logic remains functional with the updated API. Verify that all instances of text content comparison have been updated to use the new class where applicable.Verification successful
Given the absence of any output from the executed script, and considering the specific nature of the review comment, it appears that there are no instances of the old class usage (
PlainTextContent.Literal
) left in the Java files of the codebase. This suggests that the codebase has been successfully updated to use the newLiteralTextContent
class where applicable for text content comparison. Therefore, the verification process indicates that the update has been correctly implemented according to the review comment.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Search for old class usage to ensure consistency. rg --type java 'PlainTextContent\.Literal'Length of output: 44
src/main/java/net/wurstclient/commands/PotionCmd.java (1)
- 83-85: The key identifiers within NBT data structures have been renamed from lowercase to camel case (
Id
,Amplifier
,Duration
). This change likely aligns with updates to the Minecraft API or internal data handling conventions. Ensure that these new key names are consistently used throughout the project when working with potion effects.Verification successful
To accurately verify the consistency of key identifier usage specifically for potion effects within NBT data structures, a more targeted search is necessary. The current results do not directly address the original concern, as they involve different functionalities unrelated to potion effects. A refined search focusing on NBT manipulation related to potions is needed.
The search results confirm that the camel case key identifiers ("Id", "Amplifier", "Duration") are consistently used across the project for manipulating potion effect-related NBT data structures, including in
PotionCmd.java
,KillPotionHack.java
, andTrollPotionHack.java
. This consistency addresses the original concern regarding the alignment with updates to the Minecraft API or internal data handling conventions for potion effects. Therefore, the changes made inPotionCmd.java
are verified to be consistent with the project's approach to handling potion effect NBT data.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Search for old key usage to ensure consistency. rg --type java '"id"|"amplifier"|"duration"'Length of output: 1156
Script:
#!/bin/bash # Search for NBT manipulation specifically related to potion effects. rg --type java 'putInt\("Amplifier"|putInt\("Duration"|putInt\("Id"'Length of output: 1585
src/main/java/net/wurstclient/nochatreports/NcrModRequiredScreen.java (1)
- 117-125: > 📝 NOTE
This review was outside the diff hunks and was mapped to the diff hunk with the greatest overlap. Original lines [120-132]
The
render
method signature has been updated, and the rendering logic has been adjusted accordingly. This change likely aligns with updates to the Minecraft API. Ensure that the new rendering logic correctly displays all UI elements as intended.src/main/java/net/wurstclient/mixin/PlayerSkinProviderMixin.java (2)
- 49-106: The
fetchSkinTextures
method has been replaced withloadSkin
, introducing new logic for handling textures and profiles. This change likely improves the mod's ability to manage skins and capes, including custom cape loading based on profiles. Ensure that this new method properly handles all cases, including error handling and asynchronous loading.- 108-128: A new method,
addWurstCape
, has been added to handle custom cape loading based on profiles. This feature enhances the mod's customization capabilities. Verify that the cape loading logic correctly handles different scenarios, such as missing capes or errors during loading.src/main/java/net/wurstclient/mixin/MinecraftClientMixin.java (4)
- 13-13: The addition of the
org.objectweb.asm.Opcodes
import suggests that ASM opcodes are being used for bytecode manipulation, specifically in the@Redirect
annotation forgetSessionProperties()
. Ensure that this usage aligns with the project's guidelines on bytecode manipulation and that the necessary ASM library version is included in the project dependencies.- 31-33: The imports for
ProfileKeys
,ProfileKeysImpl
, andSession
have been updated to reflect changes in the Minecraft client's utility classes. This adjustment is crucial for maintaining compatibility with the game's session and profile key management systems. Ensure that these changes are consistent with the updated Minecraft version and that there are no deprecated usages.Verification successful
The script output confirms that the imports for
ProfileKeys
,ProfileKeysImpl
, andSession
have been updated and are used consistently across the project in various files. This suggests that the changes are in line with maintaining compatibility with the Minecraft client's utility classes. However, without a more detailed analysis, it's not possible to fully verify the absence of deprecated usages of these classes. The information provided does support the initial review comment regarding the update and consistent use of these imports.* 121-128: The `@Redirect` annotation is used to modify the behavior of `getSessionProperties()` by redirecting the `session` field access to a custom method. This change allows for dynamic session handling, potentially supporting custom authentication mechanisms. However, ensure that this redirection does not introduce any unintended side effects, especially in multiplayer environments where session validation is critical.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Verify that the updated imports are used consistently across the project rg --type java "net.minecraft.client.util.(ProfileKeys|ProfileKeysImpl|Session)"Length of output: 1146
Verification successful
The review comment is accurate in highlighting the importance of ensuring that the redirection of
session
field access inMinecraftClientMixin.java
does not introduce unintended side effects. The usage ofgetSessionProperties()
inPlayerSkinProviderMixin.java
for loading player skins and adding custom capes directly relates to the session properties. This confirms that the redirection could significantly impact functionalities dependent on session properties, such as player skin loading. Therefore, it's crucial to carefully consider the implications of this change, especially in multiplayer environments where session validation and properties are critical.* 181-198: The `setSession` method now includes logic to create a `UserApiService` instance using a custom method `wurst_createUserApiService`. This approach encapsulates the creation logic and adds exception handling for `AuthenticationException`. Ensure that the fallback to `UserApiService.OFFLINE` in case of an exception does not adversely affect the user experience, especially in scenarios where online services are expected to be available.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Check for other usages of getSessionProperties that might be affected by this redirection rg --type java "getSessionProperties()"Length of output: 310
Script:
#!/bin/bash # Examine the usage of getSessionProperties() in PlayerSkinProviderMixin.java fd "PlayerSkinProviderMixin.java" --exec cat {}Length of output: 4799
src/main/java/net/wurstclient/clickgui/screens/SelectFileScreen.java (2)
- 139-143: The
mouseScrolled
method parameters have been renamed for clarity, and the rendering logic has been simplified by removing direct rendering of drawables in favor of calling the superclass method. This change improves code readability and maintainability. Ensure that the superclass method adequately handles all necessary rendering tasks previously performed directly.- 168-174: The rendering logic in the
render
method has been adjusted to callsuper.render
for drawing the screen's components. This change streamlines the rendering process and ensures consistency with the superclass's rendering behavior. Verify that this adjustment does not omit any custom rendering logic that was previously included.src/main/java/net/wurstclient/options/KeybindProfilesScreen.java (2)
- 147-151: The
mouseScrolled
method parameters have been renamed for clarity, and the rendering logic has been adjusted to call the superclass method for rendering. This change ensures that the scrolling behavior is consistent with the expected GUI framework behavior. Confirm that the superclass method handles all necessary scrolling interactions without any missing functionality.- 176-182: The rendering logic in the
render
method has been simplified by callingsuper.render
instead of iterating overdrawables
. This adjustment promotes code reuse and maintainability. Ensure that this change does not skip any custom rendering steps that were previously included.src/main/java/net/wurstclient/options/KeybindManagerScreen.java (2)
- 124-128: The
mouseScrolled
method parameters have been renamed for clarity, and the rendering logic has been adjusted to callsuper.render
instead of iterating overdrawables
. This change ensures that the scrolling behavior is consistent with the expected GUI framework behavior. Confirm that the superclass method handles all necessary scrolling interactions without any missing functionality.- 169-177: The rendering logic in the
render
method has been simplified by callingsuper.render
instead of iterating overdrawables
. This adjustment promotes code reuse and maintainability. Ensure that this change does not skip any custom rendering steps that were previously included.src/main/java/net/wurstclient/hacks/PlayerEspHack.java (2)
- 163-163: The change from
e.getName().getString()
toe.getEntityName()
for retrieving entity names is a good improvement for readability and efficiency. This adjustment ensures that the entity's name is directly accessed, potentially avoiding unnecessary string conversions.- 202-202: Similar to the previous comment, using
e.getEntityName()
here maintains consistency and improves code readability. It's good to see consistent changes across similar functionalities.src/main/java/net/wurstclient/hacks/XRayHack.java (1)
- 50-50: The addition of
"minecraft:crafting_table"
to the block list inXRayHack.java
aligns with the objective to adjust the list of block identifiers being checked. This change ensures that the crafting table block is included in the X-Ray view, which is a sensible addition given its significance in gameplay.src/main/java/net/wurstclient/serverfinder/CleanUpScreen.java (2)
- 206-206: Calling
renderBackground(context)
with thecontext
parameter is a significant change that aligns with the updated method signature in newer versions of the game's API. This ensures that the background is rendered correctly with the provided drawing context.- 213-213: The use of
super.render(context, mouseX, mouseY, partialTicks)
is a best practice for ensuring that the base class's render method is called, which can handle common rendering tasks. This change simplifies the rendering logic inCleanUpScreen.java
and ensures that inherited rendering functionalities are not bypassed.src/main/java/net/wurstclient/serverfinder/ServerFinderScreen.java (3)
- 159-160: The explicit call to
ipBox.tick()
and the empty line following it are part of thetick()
method's logic to update the state of the IP address input box. Ensuring that UI elements like text fields are updated each tick is crucial for responsive user interfaces.- 220-220: The call to
renderBackground(context)
at the beginning of therender
method ensures that the screen's background is drawn before any other UI elements. This is a standard practice in GUI rendering to ensure the background is rendered first, providing a clean slate for drawing other components.- 251-251: The call to
super.render(context, mouseX, mouseY, partialTicks)
at the end of therender
method is essential for ensuring that inherited rendering logic is executed. This includes rendering tooltips and other elements that might be handled by the base class.src/main/java/net/wurstclient/options/WurstOptionsScreen.java (1)
- 156-158: The changes to the
render
method, specifically callingsuper.render
and focusing on background rendering and button tooltips, are a good practice. This simplifies the rendering logic and ensures that the superclass's render method is utilized, which might include important rendering steps that should not be skipped. However, ensure that removing the iteration overdrawables
for rendering does not omit any necessary custom rendering logic that was previously included.src/main/java/net/wurstclient/clickgui/screens/EditBookOffersScreen.java (1)
- 193-193: Directly calling
super.render
in therender
method simplifies the rendering logic and ensures that the superclass's render method is utilized. This is a good practice as it can help maintain consistency and reduce code duplication. Ensure that this change does not skip any necessary custom rendering logic that was previously included.src/main/java/net/wurstclient/hacks/ChestEspHack.java (1)
- 115-117: The update to the
groups
list reflects the removal of certain block groups (pots
andcrafters
), which is not explicitly mentioned in the provided context but can be inferred from the absence of these groups in the list. This change seems to align with the PR objectives of updating functionality and logic. Ensure that the removal of these groups is intentional and does not affect other functionalities that might rely on them.src/main/java/net/wurstclient/clickgui/screens/EditBlockListScreen.java (3)
- 56-56: The adjustment of the
blockNameField
height by 1 unit seems minor but can impact the UI's appearance and user interaction. Ensure this change aligns with the intended design and does not introduce any alignment or spacing issues with other UI elements.- 150-157: > 📝 NOTE
This review was outside the diff hunks and was mapped to the diff hunk with the greatest overlap. Original lines [153-165]
Adding a
tick
method for theblockNameField
is a good practice to ensure the text field is updated appropriately, especially in dynamic UIs. This addition enhances the responsiveness and interactivity of the UI. Ensure that thetick
method is called at appropriate intervals to avoid unnecessary updates or performance issues.
- 188-200: > 📝 NOTE
This review was outside the diff hunks and was mapped to the diff hunk with the greatest overlap. Original lines [178-197]
The simplification of the rendering logic by replacing direct rendering of
drawables
withsuper.render
and adjusting coordinates for context fills is a positive change for maintainability and readability. However, ensure that this change does not alter the intended visual output or introduce any rendering issues, especially in edge cases or different screen resolutions.src/main/java/net/wurstclient/clickgui/screens/EditItemListScreen.java (3)
- 58-58: Adjusting the dimensions of the
TextFieldWidget
is crucial for ensuring a consistent and user-friendly UI. Verify that this change does not introduce any misalignments or inconsistencies with other UI components.- 152-159: > 📝 NOTE
This review was outside the diff hunks and was mapped to the diff hunk with the greatest overlap. Original lines [155-165]
The addition of a
tick
method for theitemNameField
is a good practice, ensuring the text field is updated appropriately. This enhances UI responsiveness and interactivity. Confirm that thetick
method is called at appropriate intervals to maintain performance.
- 177-183: > 📝 NOTE
This review was outside the diff hunks and was mapped to the diff hunk with the greatest overlap. Original lines [180-220]
Simplifying the rendering process by removing a loop and calling the superclass method, along with the addition of a
tick
method, improves code maintainability and readability. Ensure this change does not affect the intended visual output or introduce rendering issues.src/main/java/net/wurstclient/clickgui/screens/EditColorScreen.java (2)
- 158-165: The addition of a
tick()
method to update text fields is a good practice for dynamic UIs, ensuring that the text fields are responsive to user input and system changes. This enhances the user experience by keeping the UI elements up-to-date.- 155-176: > 📝 NOTE
This review was outside the diff hunks and was mapped to the diff hunk with the greatest overlap. Original lines [173-220]
Refactoring the
render()
method to improve rendering logic, including the removal of unused import statements, contributes to cleaner and more maintainable code. Ensure that these changes do not impact the visual fidelity or functionality of the UI components being rendered.src/main/java/net/wurstclient/WurstClient.java (1)
- 62-62: The change in
MC_VERSION
from "1.20.4" to "1.20.1" is noted. Ensure to verify that this version downgrade does not affect any functionalities or features that were dependent on version "1.20.4".src/main/java/net/wurstclient/clickgui/screens/EditBookOfferScreen.java (2)
- 249-251: Adding tick calls for
levelField
andpriceField
ensures these UI components are updated properly. This is a good practice for maintaining UI responsiveness.- 299-299: Replacing a loop for rendering
drawables
with a call tosuper.render()
simplifies the rendering logic and leverages inheritance. This is a positive change for maintainability and performance.src/main/java/net/wurstclient/hacks/BonemealAuraHack.java (4)
- 211-211: The addition of the boolean parameter
true
to theisFertilizable
method call forSaplingBlock
is noted. Ensure this aligns with the intended behavior for fertilization in the game mechanics.- 214-214: The addition of the boolean parameter
true
to theisFertilizable
method call forCropBlock
is noted. Ensure this aligns with the intended behavior for fertilization in the game mechanics.- 217-217: The addition of the boolean parameter
true
to theisFertilizable
method call forStemBlock
is noted. Ensure this aligns with the intended behavior for fertilization in the game mechanics.- 220-220: The addition of the boolean parameter
true
to theisFertilizable
method call forCocoaBlock
is noted. Ensure this aligns with the intended behavior for fertilization in the game mechanics.src/main/java/net/wurstclient/altmanager/AltRenderer.java (3)
- 44-50: The approach to load and store skin textures in
bindSkinTexture
method has been modified. Ensure that thePlayerListEntry
creation and the retrieval of the skin texture are correctly implemented and that there are no potential issues with UUID generation or texture retrieval.- 127-127: The logic to determine if a player's skin is slim in the
drawAltBody
method has been updated. This change usesDefaultSkinHelper.getModel()
with the player's UUID to check for "slim" skin type. Verify that this method accurately identifies slim and default skin types for all possible player names.- 258-258: Similar to the
drawAltBody
method, thedrawAltBack
method also includes an update to determine if a player's skin is slim. It's crucial to ensure consistency between these methods in handling slim skins. Confirm that the new approach provides accurate results across different player names and skin types.src/main/java/net/wurstclient/hacks/CrystalAuraHack.java (1)
- 254-254: The change from
e.getName().getString()
toe.getEntityName()
in thegetNearbyTargets
method is intended to improve the accuracy of entity name retrieval for filtering purposes. Ensure that this change does not affect the functionality of the filter list and thate.getEntityName()
provides the expected results in all scenarios where the entity name is used for filtering.src/main/java/net/wurstclient/altmanager/screens/AltEditorScreen.java (3)
- 146-147: The addition of
tick
calls fornameOrEmailBox
andpasswordBox
ensures that these text fields are updated each tick, which is essential for responsive UI elements. This change improves the user experience by ensuring text input fields behave as expected in dynamic UI environments.- 349-349: The modification to use
renderBackground(context)
directly in therender
method simplifies the rendering process by utilizing the inheritedrenderBackground
functionality. This change enhances code maintainability by reducing redundancy and leveraging existing methods.- 402-402: Replacing individual drawable rendering with a call to
super.render
in therender
method is a good practice. It ensures that the rendering logic defined in the superclass is not bypassed, which can include important rendering steps such as drawing background or other UI elements. This change promotes code reuse and consistency across different screens.src/main/java/net/wurstclient/hacks/AutoFarmHack.java (1)
- 209-209: Updating the logic to check if a block is an instance of
GourdBlock
instead of specifically checking forBlocks.PUMPKIN
orBlocks.MELON
is a more flexible and future-proof approach. This change allows the hack to correctly identify and harvest any gourd-type blocks, accommodating potential additions of new gourd blocks in future Minecraft versions. It's a good example of using polymorphism to simplify and improve the code's adaptability.src/main/java/net/wurstclient/navigator/NavigatorScreen.java (1)
- 113-124: > 📝 NOTE
This review was outside the diff hunks and was mapped to the diff hunk with the greatest overlap. Original lines [116-136]
The modification to the
mouseScrolled
method simplifies the scrolling logic by using a singledelta
parameter. This change enhances the method's readability and maintainability. However, ensure that the multiplication factor (delta * 4
) is appropriately calibrated for the user experience, as it directly affects the scroll speed. Testing with various scroll inputs might be necessary to find a comfortable scroll speed for users.src/main/java/net/wurstclient/clickgui/screens/AddBookOfferScreen.java (3)
- 240-243: The change in the
mouseScrolled
method signature to accept a singledouble amount
parameter simplifies the method and aligns with the changes made inNavigatorScreen.java
. This consistency across UI components is beneficial for maintainability. Ensure that the scrolling behavior is tested in this context as well, to confirm that the user experience remains smooth and intuitive.- 284-286: The addition of
tick()
calls forlevelField
andpriceField
is a good practice, ensuring that these text fields are updated appropriately each tick. This is crucial for maintaining responsive and interactive UI elements, especially in screens where user input is expected. It's recommended to continue this practice for any future UI elements that require regular updates.- 306-306: Replacing explicit rendering of
drawables
with a call tosuper.render()
simplifies the rendering logic and leverages the built-in handling of drawable elements by the parent class. This change not only reduces the amount of custom rendering code needed but also ensures that any updates or improvements to the parent class's rendering logic are automatically inherited. Good job on streamlining the rendering process.src/main/java/net/wurstclient/hacks/AnchorAuraHack.java (1)
- 336-336: The change from
e.getName().getString()
toe.getEntityName()
for checking if an entity is a friend is a logical update, assuminggetEntityName()
is a more direct or efficient method for retrieving the entity's name. However, ensure thatgetEntityName()
provides the same, expected string format asgetName().getString()
did, to avoid any unintended behavior changes in the friend check logic.src/main/java/net/wurstclient/navigator/NavigatorMainScreen.java (1)
- 192-192: Calling
searchBar.tick()
before checking for changes in the search text input is a good practice. This ensures that the search bar is updated at the beginning of each frame, which can improve the responsiveness and accuracy of the search functionality. It's important to ensure that this method does not introduce any performance issues by being called every frame, but given the context, it seems like a necessary update for UI responsiveness.src/main/java/net/wurstclient/altmanager/MicrosoftLoginManager.java (1)
- 33-33: The import statement for
Session
has been updated to reflect changes in the Minecraft client API. Ensure that all usages ofSession
in this file are compatible with the new import path. This change is crucial for maintaining compatibility with the latest Minecraft client versions.src/main/java/net/wurstclient/util/ListWidget.java (1)
- 328-332: The
mouseScrolled
method has been simplified to use a singleamount
parameter for scroll calculations. This change should simplify handling scroll events but requires thorough testing to ensure that the scrolling behavior in the list widget matches the expected user experience, especially in terms of scroll speed and direction.src/main/java/net/wurstclient/altmanager/screens/AltManagerScreen.java (3)
- 185-188: The
mouseScrolled
method's parameters have been updated todouble d, double e, double amount
, which aligns with the expected signature for overriding the method in the parent class. This change ensures that the method correctly handles mouse scroll events. The forwarding of the scroll event tolistGui.mouseScrolled
and the call tosuper.mouseScrolled
are correctly implemented, ensuring that the event is processed both by the custom GUI component and the base class logic.- 416-416: The call to
renderBackground(context)
within therender
method is correctly updated to match the expected method signature after the removal of theDrawable
import. This change ensures that the background of the AltManager screen is rendered appropriately using the providedDrawContext
, which is necessary for drawing operations in Minecraft's GUI system.- 472-472: Replacing direct rendering of
drawables
with a call tosuper.render
in therender
method is a significant improvement in terms of maintainability and modularity. This change leverages the rendering logic defined in the superclass, which likely includes rendering ofdrawables
among other things. It simplifies therender
method inAltManagerScreen
and ensures that any updates or fixes applied to the rendering logic in the superclass will automatically benefit this screen as well. This is a good practice in object-oriented design, promoting code reuse and reducing duplication.
public boolean mouseScrolled(double double_1, double double_2, | ||
double double_3) | ||
{ | ||
listGui.mouseScrolled(mouseX, mouseY, horizontalAmount, verticalAmount); | ||
return super.mouseScrolled(mouseX, mouseY, horizontalAmount, | ||
verticalAmount); | ||
listGui.mouseScrolled(double_1, double_2, double_3); | ||
return super.mouseScrolled(double_1, double_2, double_3); |
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.
Adjusting the parameter names in the mouseScrolled
method to more generic names (double_1
, double_2
, double_3
) improves consistency but might reduce readability. Consider using more descriptive names that indicate the purpose or usage of these parameters, such as mouseX
, mouseY
, and scrollAmount
.
- public boolean mouseScrolled(double double_1, double double_2, double double_3)
+ public boolean mouseScrolled(double mouseX, double mouseY, double scrollAmount)
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
public boolean mouseScrolled(double double_1, double double_2, | |
double double_3) | |
{ | |
listGui.mouseScrolled(mouseX, mouseY, horizontalAmount, verticalAmount); | |
return super.mouseScrolled(mouseX, mouseY, horizontalAmount, | |
verticalAmount); | |
listGui.mouseScrolled(double_1, double_2, double_3); | |
return super.mouseScrolled(double_1, double_2, double_3); | |
public boolean mouseScrolled(double mouseX, double mouseY, double scrollAmount) | |
{ | |
listGui.mouseScrolled(mouseX, mouseY, scrollAmount); | |
return super.mouseScrolled(mouseX, mouseY, scrollAmount); |
public boolean mouseScrolled(double double_1, double double_2, | ||
double double_3) | ||
{ | ||
listGui.mouseScrolled(mouseX, mouseY, horizontalAmount, verticalAmount); | ||
return super.mouseScrolled(mouseX, mouseY, horizontalAmount, | ||
verticalAmount); | ||
listGui.mouseScrolled(double_1, double_2, double_3); | ||
return super.mouseScrolled(double_1, double_2, double_3); |
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.
Tip
Codebase Verification
The review comment is correct. The parameter names for the mouseScrolled
method vary across the codebase, with some files using descriptive names and others using less descriptive names like double_1
, double_2
, and double_3
. This inconsistency supports the suggestion to refactor parameter names for improved readability and to ensure that these changes are consistently applied across the codebase where the mouseScrolled
method is overridden or called.
Analysis chain
Refactoring the parameters in the mouseScrolled
method to more descriptive names improves code readability. However, ensure that this change is consistently applied across the codebase where the mouseScrolled
method is overridden or called to maintain consistency.
Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Search for other occurrences of mouseScrolled to ensure consistency
rg --type java "public boolean mouseScrolled"
Length of output: 1539
@@ -86,7 +86,7 @@ public void onEnable() | |||
command = commandSetting.getValue().substring(1); | |||
|
|||
// collect player names | |||
String playerName = MC.getSession().getUsername(); | |||
String playerName = MC.getSession().getProfile().getName(); |
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.
Tip
Codebase Verification
The search results indicate that the old method getSession().getUsername()
is still being used in various parts of the project, suggesting an inconsistency in how the player's name is retrieved. This inconsistency could lead to potential issues, especially if the Minecraft API or session management changes further. It's recommended to update all instances to use the new method for consistency and to avoid potential bugs.
Analysis chain
The method for retrieving the player's name has been updated to use MC.getSession().getProfile().getName()
instead of a previously used method. This change likely aligns with updates to the Minecraft API or session management. Ensure that this new method is consistently used wherever the player's name is retrieved throughout the project.
Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Search for old method usage to ensure consistency.
rg --type java 'getSession\(\)\.getUsername\(\)'
Length of output: 1118
public boolean mouseScrolled(double double_1, double double_2, | ||
double double_3) | ||
{ | ||
listGui.mouseScrolled(mouseX, mouseY, horizontalAmount, verticalAmount); | ||
return super.mouseScrolled(mouseX, mouseY, horizontalAmount, | ||
verticalAmount); | ||
listGui.mouseScrolled(double_1, double_2, double_3); | ||
return super.mouseScrolled(double_1, double_2, double_3); |
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.
Tip
Codebase Verification
The verification process has revealed inconsistencies in the naming convention of parameters for the mouseScrolled
method across the codebase. While some classes use descriptive names such as mouseX
, mouseY
, and delta
or amount
, others use less descriptive names like double_1
, double_2
, and double_3
. This inconsistency contradicts the suggestion to ensure descriptive naming is applied consistently for code clarity. Therefore, the review comment is validated by the findings, highlighting the need for a uniform naming convention across the codebase for the mouseScrolled
method.
Analysis chain
The renaming of parameters in the mouseScrolled
method to more descriptive names is a good practice for code clarity. Ensure this change is consistently applied across the codebase to maintain readability and avoid confusion.
Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Search for other occurrences of mouseScrolled to ensure consistency
rg --type java "public boolean mouseScrolled"
Length of output: 1539
int id = StatusEffect.getRawId(effect.getEffectType()); | ||
tag.putInt("Id", id); | ||
tag.putInt("Amplifier", effect.getAmplifier()); | ||
tag.putInt("Duration", effect.getDuration()); |
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.
Tip
Codebase Verification
The verification process has revealed that there is still at least one instance in the PotionCmd.java
file where the old method Registries.STATUS_EFFECT
is being used, contrary to the expectation that all such instances would be replaced with direct usage of StatusEffect
. This indicates an inconsistency in applying the method change throughout the project.
Analysis chain
The method Registries.STATUS_EFFECT
has been replaced with direct usage of StatusEffect
for retrieving effect IDs. This change simplifies the code and likely aligns with updates to the Minecraft API. Ensure that this new method is consistently used wherever status effect IDs are retrieved throughout the project.
Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Search for old method usage to ensure consistency.
rg --type java 'Registries\.STATUS_EFFECT'
Length of output: 166
try | ||
{ | ||
MicrosoftLoginManager.login(email, password); | ||
}catch(Exception e) | ||
{ | ||
LoginManager.login(email, password); | ||
} |
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.
The introduction of a try-catch block in the login()
method to attempt login with MicrosoftLoginManager
and fallback to LoginManager
in case of an exception is a good practice. This ensures compatibility with both Microsoft and Mojang accounts, enhancing the flexibility of the authentication process. However, it's important to log or handle the caught exception to aid in debugging and provide feedback to the user.
Consider logging the exception or providing user feedback in case the Microsoft login attempt fails before falling back to Mojang authentication.
Caution
Deprecated, see the new pull request.