-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added integration with Mod Menu (#56)
* Added integration with Mod Menu feat: added integration with Mod Menu + Created an entrypoint for ModMenu and added it to fabric.mod.json + Added ModMenu as a recommended mod in fabric.mod.json + Added ModMenu to gradle.build and gradle.properties - Removed Fn+7 keybind for accessing the ModeSwitcherScreen * Renamed some parameters for consistency Renamed the parameters of the render() function in SettingsScreen.java to match those of the render() function in ModeSwitcherScreen.java * Revert "Renamed some parameters for consistency" This reverts commit 2ff665b. * Restored F7 keybind + Restored the original constructor + Added a second constructor for ModMenu integration * Fixed "Done" button functionality The settings screen's "Done" button now returns to the previous screen, either in-game or the mod menu, depending on how it was opened + Overrides onClose() to set the screen to the parent screen * Changed default screen for Lighty settings Changed the default settings screen from "ModeSwitcherScreen" to "SettingsScreen" to match the changes made in the latest Lighty version and to allow for easier porting to it * Restored a call to Compute.clear() * Confirmed compatibility with MC 1.20.4 Confirmed compatibility with MC 1.20.4 after updating the gradle and loom versions * Added missing whitespace * Revert "Confirmed compatibility with MC 1.20.4" This reverts commit 562bb73. * Remapped F7 keybind to open the original Screen
- Loading branch information
Showing
6 changed files
with
48 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
fabric/src/main/java/dev/schmarrn/lighty/fabric/ModMenuIntegration.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package dev.schmarrn.lighty.fabric; | ||
|
||
import com.terraformersmc.modmenu.api.ConfigScreenFactory; | ||
import com.terraformersmc.modmenu.api.ModMenuApi; | ||
import dev.schmarrn.lighty.ui.SettingsScreen; | ||
|
||
public class ModMenuIntegration implements ModMenuApi { | ||
@Override | ||
public ConfigScreenFactory<?> getModConfigScreenFactory() { | ||
return SettingsScreen::new; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters