Profile Tab + Config Sync

This commit is contained in:
Kam committed 2025-01-24 00:29:11 -05:00
1 parent c7c981f4a7
commit 62482c307c
5 files changed
+33

No files matched your search

@@ -136,6 +136,10 @@ public class PacketHandlerClient extends PacketHandlerServer{
SyncController.clientSyncRemove(synctype, id);
}
else if(type == EnumPacketClient.SYNC_CONFIG){
NBTTagCompound configNBT = Server.readNBT(buffer);
SyncController.receiveConfigs(configNBT);
}
else if(type == EnumPacketClient.MARK_DATA){
Entity entity = Minecraft.getMinecraft().theWorld.getEntityByID(buffer.readInt());
if(!(entity instanceof EntityNPCInterface))
@@ -8,6 +8,7 @@ import net.minecraft.util.ResourceLocation;
import noppes.npcs.client.gui.util.GuiMenuSideButton;
import noppes.npcs.client.gui.util.GuiNPCInterface;
import noppes.npcs.config.ConfigClient;
import noppes.npcs.config.ConfigMain;
import tconstruct.client.tabs.InventoryTabCustomNpc;
import tconstruct.client.tabs.TabRegistry;
@@ -67,6 +68,16 @@ public class GuiCNPCInventory extends GuiNPCInterface {
addButton(dbcButton);
}
if(ConfigMain.EnableProfiles){
y += 21;
GuiMenuSideButton profileButton = new GuiMenuSideButton(105, guiLeft + xSize + 37, this.guiTop + y, 22, 22, "");
profileButton.rightSided = true;
profileButton.active = activeTab == 5;
profileButton.renderIconPosX = 80;
profileButton.renderResource = specialIcons;
addButton(profileButton);
}
y += 21;
GuiMenuSideButton clientButton = new GuiMenuSideButton(103, guiLeft + xSize + 37, this.guiTop + y, 22, 22, "");
clientButton.rightSided = true;