Skip to content

Commit

Permalink
update MaFgLib
Browse files Browse the repository at this point in the history
  • Loading branch information
TexBlock committed Jul 29, 2024
1 parent 0660846 commit 4196557
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
1 change: 0 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
## Change
- fixed [#48](https://github.com/ThinkingStudios/Litematica-Forge/issues/48)
- update mafglib version
6 changes: 3 additions & 3 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -7,19 +7,19 @@ loom.platform=forge
# minecraft version
minecraft_version=1.19.2
# forge version, latest version can be found on https://files.minecraftforge.net/
forge_version=1.19.2-43.3.13
forge_version=1.19.2-43.4.2
# yarn, latest version can be found on https://fabricmc.net/develop/
yarn_mappings=1.19.2+build.28

# Mod Properties
mod_version=0.1.9
mod_version=0.1.10
maven_group=org.thinkingstudio.forgematica
archives_base_name=Forgematica
mod_id=forgematica
mod_author=ThinkingStudio

# Dependencies
malilib_version=0.1.12-mc1.19.2
malilib_version=0.1.13-mc1.19.2

# Publish Properties
modrinth_id=dCKRaeBC
Expand Down
11 changes: 8 additions & 3 deletions src/main/java/org/thinkingstudio/forgematica/Forgematica.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,22 @@
import fi.dy.masa.litematica.Reference;
import fi.dy.masa.litematica.gui.GuiConfigs;
import fi.dy.masa.malilib.event.InitializationHandler;
import net.minecraftforge.fml.ModContainer;
import net.minecraftforge.fml.ModLoadingContext;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.loading.FMLLoader;
import org.thinkingstudio.mafglib.util.ForgePlatformUtils;
import org.thinkingstudio.mafglib.util.ForgeUtils;

@Mod(Reference.MOD_ID)
public class Forgematica {
public Forgematica() {
if (FMLLoader.getDist().isClient()) {
ForgePlatformUtils.getInstance().getClientModIgnoredServerOnly();
ModContainer modContainer = ModLoadingContext.get().getActiveContainer();

ForgeUtils.getInstance().getClientModIgnoredServerOnly(modContainer);
InitializationHandler.getInstance().registerInitializationHandler(new InitHandler());
ForgePlatformUtils.getInstance().registerModConfigScreen(Reference.MOD_ID, (screen) -> {

ForgeUtils.getInstance().registerModConfigScreen(modContainer, (screen) -> {
GuiConfigs gui = new GuiConfigs();
gui.setParent(screen);
return gui;
Expand Down

0 comments on commit 4196557

Please sign in to comment.