Refactor all Gecko Internal support to CustomModel

This commit is contained in:
Kam committed 2023-11-16 17:46:12 -05:00
1 parent c67a8e43cb
commit ff49b1ffbd
11 files changed
+38 -111

No files matched your search

@@ -15,6 +15,9 @@ import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.world.World;
import noppes.npcs.client.Client;
import noppes.npcs.client.NoppesUtil;
import noppes.npcs.client.gui.model.custom.GuiCustomAnimFileSelection;
import noppes.npcs.client.gui.model.custom.GuiCustomAnimationSelection;
import noppes.npcs.client.gui.model.custom.GuiCustomModelSelection;
import noppes.npcs.client.gui.util.*;
import noppes.npcs.constants.EnumPacketServer;
import noppes.npcs.compat.PixelmonHelper;
@@ -325,15 +328,15 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol
}
if(button.id == 202){
NoppesUtil.openGUI(player, new GuiGeckoModelSelection(npc, this));
NoppesUtil.openGUI(player, new GuiCustomModelSelection(npc, this));
}
if(button.id == 203){
NoppesUtil.openGUI(player, new GuiGeckoAnimFileSelection(npc, this));
NoppesUtil.openGUI(player, new GuiCustomAnimFileSelection(npc, this));
}
if(button.id == 204){
NoppesUtil.openGUI(player, new GuiGeckoAnimationSelection(npc, this, (name)-> npc.display.idleAnim=name));
NoppesUtil.openGUI(player, new GuiCustomAnimationSelection(npc, this, (name)-> npc.display.idleAnim=name));
}
}
@@ -1,4 +1,4 @@
package noppes.npcs.client.gui.model;
package noppes.npcs.client.gui.model.custom;
import net.minecraft.client.gui.GuiButton;
import net.minecraft.client.gui.GuiScreen;
@@ -9,14 +9,13 @@ import noppes.npcs.entity.EntityNPCInterface;
import software.bernie.geckolib3.resource.GeckoLibCache;
import java.util.Collections;
import java.util.HashSet;
import java.util.Vector;
public class GuiGeckoAnimFileSelection extends GuiNPCInterface {
public class GuiCustomAnimFileSelection extends GuiNPCInterface {
public GuiNPCStringSlot slot;
public GuiScreen parent;
public GuiGeckoAnimFileSelection(EntityNPCInterface npc, GuiScreen parent){
public GuiCustomAnimFileSelection(EntityNPCInterface npc, GuiScreen parent){
super(npc);
drawDefaultBackground = false;
title = "";
@@ -1,4 +1,4 @@
package noppes.npcs.client.gui.model;
package noppes.npcs.client.gui.model.custom;
import net.minecraft.client.gui.GuiButton;
import net.minecraft.client.gui.GuiScreen;
@@ -11,16 +11,15 @@ import software.bernie.geckolib3.file.AnimationFile;
import software.bernie.geckolib3.resource.GeckoLibCache;
import java.util.Collections;
import java.util.HashSet;
import java.util.Vector;
import java.util.function.Consumer;
public class GuiGeckoAnimationSelection extends GuiNPCInterface {
public class GuiCustomAnimationSelection extends GuiNPCInterface {
public GuiNPCStringSlot slot;
public GuiScreen parent;
public Consumer<String> action;
public GuiGeckoAnimationSelection(EntityNPCInterface npc, GuiScreen parent, Consumer<String> action){
public GuiCustomAnimationSelection(EntityNPCInterface npc, GuiScreen parent, Consumer<String> action){
super(npc);
drawDefaultBackground = false;
title = "";
@@ -1,4 +1,4 @@
package noppes.npcs.client.gui.model;
package noppes.npcs.client.gui.model.custom;
import net.minecraft.client.gui.GuiButton;
import net.minecraft.client.gui.GuiScreen;
@@ -9,14 +9,13 @@ import noppes.npcs.entity.EntityNPCInterface;
import software.bernie.geckolib3.resource.GeckoLibCache;
import java.util.Collections;
import java.util.HashSet;
import java.util.Vector;
public class GuiGeckoModelSelection extends GuiNPCInterface {
public class GuiCustomModelSelection extends GuiNPCInterface {
public GuiNPCStringSlot slot;
public GuiScreen parent;
public GuiGeckoModelSelection(EntityNPCInterface npc, GuiScreen parent){
public GuiCustomModelSelection(EntityNPCInterface npc, GuiScreen parent){
super(npc);
drawDefaultBackground = false;
title = "";