mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-17 15:45:10 +00:00
Remove Redundant Old Packet Handlers
This commit is contained in:
1 parent
0f948a9d62
commit
fe7c24186d
8 files changed
+1
-440
No files matched your search
@@ -22,10 +22,7 @@ public class CommonProxy implements IGuiHandler {
|
||||
public boolean newVersionAvailable = false;
|
||||
public int revision = 1;
|
||||
|
||||
public void load() {
|
||||
CustomNpcs.Channel.register(new PacketHandlerServer());
|
||||
CustomNpcs.ChannelPlayer.register(new PacketHandlerPlayer());
|
||||
}
|
||||
public void load() {}
|
||||
|
||||
public PlayerData getPlayerData(EntityPlayer player) {
|
||||
return null;
|
||||
|
||||
@@ -55,9 +55,6 @@ public class CustomNpcs {
|
||||
|
||||
public static boolean FreezeNPCs = false;
|
||||
|
||||
public static FMLEventChannel Channel;
|
||||
public static FMLEventChannel ChannelPlayer;
|
||||
|
||||
public static final MarkovGenerator[] MARKOV_GENERATOR = new MarkovGenerator[10];
|
||||
|
||||
public static boolean InitIgnore = false;
|
||||
@@ -87,9 +84,6 @@ public class CustomNpcs {
|
||||
|
||||
@EventHandler
|
||||
public void load(FMLPreInitializationEvent ev) {
|
||||
Channel = NetworkRegistry.INSTANCE.newEventDrivenChannel("CustomNPCs");
|
||||
ChannelPlayer = NetworkRegistry.INSTANCE.newEventDrivenChannel("CustomNPCsPlayer");
|
||||
|
||||
PacketHandler.Instance = new PacketHandler();
|
||||
|
||||
MinecraftServer server = MinecraftServer.getServer();
|
||||
|
||||
@@ -259,16 +259,6 @@ public class NoppesUtilPlayer {
|
||||
|
||||
bankData.openBankGui(player, npc, bank.id, container.slot);
|
||||
}
|
||||
public static void sendData(EnumPlayerPacket enu, Object... obs) {
|
||||
ByteBuf buffer = Unpooled.buffer();
|
||||
try {
|
||||
if(!Server.fillBuffer(buffer, enu, obs))
|
||||
return;
|
||||
CustomNpcs.ChannelPlayer.sendToServer(new FMLProxyPacket(buffer,"CustomNPCsPlayer"));
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
public static void dialogSelected(int dialogId, int optionId, EntityPlayerMP player, EntityNPCInterface npc) {
|
||||
Dialog dialog = DialogController.Instance.dialogs.get(dialogId);
|
||||
|
||||
@@ -1,327 +0,0 @@
|
||||
package noppes.npcs;
|
||||
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.common.network.FMLNetworkEvent.ServerCustomPacketEvent;
|
||||
import io.netty.buffer.ByteBuf;
|
||||
import kamkeel.npcs.network.packets.data.large.GuiDataPacket;
|
||||
import kamkeel.npcs.util.ByteBufUtils;
|
||||
import net.minecraft.entity.player.EntityPlayerMP;
|
||||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.ItemEditableBook;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.item.ItemWritableBook;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagString;
|
||||
import net.minecraft.network.NetHandlerPlayServer;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import noppes.npcs.blocks.tiles.TileBigSign;
|
||||
import noppes.npcs.blocks.tiles.TileBook;
|
||||
import noppes.npcs.constants.*;
|
||||
import noppes.npcs.containers.ContainerMail;
|
||||
import noppes.npcs.controllers.PartyController;
|
||||
import noppes.npcs.controllers.PlayerDataController;
|
||||
import noppes.npcs.controllers.PlayerQuestController;
|
||||
import noppes.npcs.controllers.ScriptController;
|
||||
import noppes.npcs.controllers.data.*;
|
||||
import noppes.npcs.entity.EntityNPCInterface;
|
||||
import noppes.npcs.roles.RoleCompanion;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.Iterator;
|
||||
|
||||
public class PacketHandlerPlayer{
|
||||
|
||||
@SubscribeEvent
|
||||
public void onServerPacket(ServerCustomPacketEvent event) {
|
||||
EntityPlayerMP player = ((NetHandlerPlayServer)event.handler).playerEntity;
|
||||
ByteBuf buffer = event.packet.payload();
|
||||
try {
|
||||
player(buffer, player, EnumPlayerPacket.values()[buffer.readInt()]);
|
||||
} catch (IOException e) {
|
||||
LogWriter.except(e);
|
||||
}
|
||||
}
|
||||
|
||||
private void player(ByteBuf buffer, EntityPlayerMP player, EnumPlayerPacket type) throws IOException {
|
||||
// if(type == EnumPlayerPacket.CompanionTalentExp){
|
||||
// EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
// if(npc == null || npc.advanced.role != EnumRoleType.Companion || player != npc.getOwner())
|
||||
// return;
|
||||
// int id = buffer.readInt();
|
||||
// int exp = buffer.readInt();
|
||||
// RoleCompanion role = (RoleCompanion) npc.roleInterface;
|
||||
// if(exp <= 0 || !role.canAddExp(-exp) || id < 0 || id >= EnumCompanionTalent.values().length) //should never happen unless hacking
|
||||
// return;
|
||||
// EnumCompanionTalent talent = EnumCompanionTalent.values()[id];
|
||||
// role.addExp(-exp);
|
||||
// role.addTalentExp(talent, exp);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.CompanionOpenInv){
|
||||
// EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
// if(npc == null || npc.advanced.role != EnumRoleType.Companion || player != npc.getOwner())
|
||||
// return;
|
||||
// NoppesUtilServer.sendOpenGui(player, EnumGuiType.CompanionInv, npc);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.KeyPressed) {
|
||||
// if(ScriptController.Instance.languages.isEmpty()) {
|
||||
// return;
|
||||
// }
|
||||
//
|
||||
// int button = buffer.readInt();
|
||||
// boolean isCtrlPressed = buffer.readBoolean();
|
||||
// boolean isShiftPressed = buffer.readBoolean();
|
||||
// boolean isAltPressed = buffer.readBoolean();
|
||||
// boolean isMetaPressed = buffer.readBoolean();
|
||||
// boolean buttonDown = buffer.readBoolean();
|
||||
//
|
||||
// String ints = ByteBufUtils.readString(buffer);
|
||||
// String[] split = ints.split(",");
|
||||
// int[] keysDown;
|
||||
//
|
||||
// if(ints.length() > 0) {
|
||||
// keysDown = new int[split.length];
|
||||
// try {
|
||||
// for (int i = 0; i < split.length; i++) {
|
||||
// keysDown[i] = Integer.parseInt(split[i]);
|
||||
// }
|
||||
// }
|
||||
// catch (NumberFormatException ignored){
|
||||
// }
|
||||
// } else {
|
||||
// keysDown = new int[0];
|
||||
// }
|
||||
//
|
||||
// EventHooks.onPlayerKeyPressed(player, button, isCtrlPressed, isShiftPressed, isAltPressed, isMetaPressed, buttonDown, keysDown);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.MouseClicked) {
|
||||
// if(ScriptController.Instance.languages.isEmpty()) {
|
||||
// return;
|
||||
// }
|
||||
//
|
||||
// int button = buffer.readInt();
|
||||
// int mouseWheel = buffer.readInt();
|
||||
// boolean buttonDown = buffer.readBoolean();
|
||||
//
|
||||
// boolean isCtrlPressed = buffer.readBoolean();
|
||||
// boolean isShiftPressed = buffer.readBoolean();
|
||||
// boolean isAltPressed = buffer.readBoolean();
|
||||
// boolean isMetaPressed = buffer.readBoolean();
|
||||
//
|
||||
// String ints = ByteBufUtils.readString(buffer);
|
||||
// String[] split = ints.split(",");
|
||||
// int[] keysDown;
|
||||
//
|
||||
// if(ints.length() > 0) {
|
||||
// keysDown = new int[split.length];
|
||||
// try {
|
||||
// for (int i = 0; i < split.length; i++) {
|
||||
// keysDown[i] = Integer.parseInt(split[i]);
|
||||
// }
|
||||
// }
|
||||
// catch (NumberFormatException ignored){
|
||||
// }
|
||||
// } else {
|
||||
// keysDown = new int[0];
|
||||
// }
|
||||
//
|
||||
// EventHooks.onPlayerMouseClicked(player, button, mouseWheel, buttonDown, isCtrlPressed, isShiftPressed, isAltPressed, isMetaPressed, keysDown);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.FollowerHire){
|
||||
// EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
// if(npc == null || npc.advanced.role != EnumRoleType.Follower)
|
||||
// return;
|
||||
// NoppesUtilPlayer.hireFollower(player, npc);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.FollowerExtend){
|
||||
// EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
// if(npc == null || npc.advanced.role != EnumRoleType.Follower)
|
||||
// return;
|
||||
// NoppesUtilPlayer.extendFollower(player, npc);
|
||||
// GuiDataPacket.sendGuiData(player, npc.roleInterface.writeToNBT(new NBTTagCompound()));
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.FollowerState){
|
||||
// EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
// if(npc == null || npc.advanced.role != EnumRoleType.Follower)
|
||||
// return;
|
||||
// NoppesUtilPlayer.changeFollowerState(player,npc);
|
||||
// GuiDataPacket.sendGuiData(player, npc.roleInterface.writeToNBT(new NBTTagCompound()));
|
||||
// }
|
||||
// if(type == EnumPlayerPacket.RoleGet){
|
||||
// EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
// if(npc == null || npc.advanced.role == EnumRoleType.None)
|
||||
// return;
|
||||
// GuiDataPacket.sendGuiData(player, npc.roleInterface.writeToNBT(new NBTTagCompound()));
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.Transport){
|
||||
// EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
// if(npc == null || npc.advanced.role != EnumRoleType.Transporter)
|
||||
// return;
|
||||
// NoppesUtilPlayer.transport(player, npc, ByteBufUtils.readString(buffer));
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.BankUpgrade){
|
||||
// EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
// if(npc == null || npc.advanced.role != EnumRoleType.Bank)
|
||||
// return;
|
||||
// NoppesUtilPlayer.bankUpgrade(player, npc);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.BankUnlock){
|
||||
// EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
// if(npc == null || npc.advanced.role != EnumRoleType.Bank)
|
||||
// return;
|
||||
// NoppesUtilPlayer.bankUnlock(player, npc);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.BankSlotOpen){
|
||||
// EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
// if(npc == null || npc.advanced.role != EnumRoleType.Bank)
|
||||
// return;
|
||||
// int slot = buffer.readInt();
|
||||
// int bankId = buffer.readInt();
|
||||
// BankData data = PlayerDataController.Instance.getBankData(player,bankId).getBankOrDefault(bankId);
|
||||
// data.openBankGui(player, npc, bankId, slot);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.Dialog){
|
||||
// EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
// if(npc == null)
|
||||
// return;
|
||||
// NoppesUtilPlayer.dialogSelected(buffer.readInt(), buffer.readInt(), player, npc);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.CheckQuestCompletion){
|
||||
// PlayerData playerData = PlayerDataController.Instance.getPlayerData(player);
|
||||
// PlayerQuestData questData = PlayerDataController.Instance.getPlayerData(player).questData;
|
||||
// Party playerParty = playerData.getPlayerParty();
|
||||
// if(playerParty != null)
|
||||
// PartyController.Instance().checkQuestCompletion(playerParty, null);
|
||||
//
|
||||
// questData.checkQuestCompletion(playerData, null);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.QuestLog){
|
||||
// NoppesUtilPlayer.sendQuestLogData(player);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.TrackedQuest){
|
||||
// NoppesUtilPlayer.sendTrackedQuest(player);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.FactionsGet){
|
||||
// PlayerFactionData data = PlayerDataController.Instance.getPlayerData(player).factionData;
|
||||
// GuiDataPacket.sendGuiData(player, data.getPlayerGuiData());
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.MailGet){
|
||||
// PlayerMailData data = PlayerDataController.Instance.getPlayerData(player).mailData;
|
||||
// GuiDataPacket.sendGuiData(player, data.saveNBTData(new NBTTagCompound()));
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.MailDelete){
|
||||
// long time = buffer.readLong();
|
||||
// String username = ByteBufUtils.readString(buffer);
|
||||
// PlayerMailData data = PlayerDataController.Instance.getPlayerData(player).mailData;
|
||||
//
|
||||
// Iterator<PlayerMail> it = data.playermail.iterator();
|
||||
// while(it.hasNext()){
|
||||
// PlayerMail mail = it.next();
|
||||
// if(mail.time == time && mail.sender.equals(username)){
|
||||
// it.remove();
|
||||
// }
|
||||
// }
|
||||
// GuiDataPacket.sendGuiData(player, data.saveNBTData(new NBTTagCompound()));
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.MailSend){
|
||||
// if(!(player.openContainer instanceof ContainerMail))
|
||||
// return;
|
||||
// String username = PlayerDataController.Instance.hasPlayer(ByteBufUtils.readString(buffer));
|
||||
// if(username.isEmpty()){
|
||||
// NoppesUtilServer.sendGuiError(player, 0);
|
||||
// return;
|
||||
// }
|
||||
//
|
||||
// PlayerMail mail = new PlayerMail();
|
||||
// //String s = player.func_145748_c_().getFormattedText();
|
||||
// String s = player.getDisplayName();
|
||||
// if(!s.equals(player.getCommandSenderName()))
|
||||
// s += "(" + player.getCommandSenderName() + ")";
|
||||
// mail.readNBT(ByteBufUtils.readNBT(buffer));
|
||||
// mail.sender = s;
|
||||
// mail.items = ((ContainerMail)player.openContainer).mail.items;
|
||||
//
|
||||
// if(mail.subject.isEmpty()){
|
||||
// NoppesUtilServer.sendGuiError(player, 1);
|
||||
// return;
|
||||
// }
|
||||
// PlayerDataController.Instance.addPlayerMessage(username, mail);
|
||||
//
|
||||
// NBTTagCompound comp = new NBTTagCompound();
|
||||
// comp.setString("username", username);
|
||||
// NoppesUtilServer.sendGuiClose(player, 1,comp);
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.MailboxOpenMail){
|
||||
// long time = buffer.readLong();
|
||||
// String username = ByteBufUtils.readString(buffer);
|
||||
// player.closeContainer();
|
||||
// PlayerMailData data = PlayerDataController.Instance.getPlayerData(player).mailData;
|
||||
//
|
||||
// Iterator<PlayerMail> it = data.playermail.iterator();
|
||||
// while(it.hasNext()){
|
||||
// PlayerMail mail = it.next();
|
||||
// if(mail.time == time && mail.sender.equals(username)){
|
||||
// ContainerMail.staticmail = mail;
|
||||
// player.openGui(CustomNpcs.instance, EnumGuiType.PlayerMailman.ordinal(), player.worldObj, 0, 0, 0);
|
||||
// break;
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.MailRead){
|
||||
// long time = buffer.readLong();
|
||||
// String username = ByteBufUtils.readString(buffer);
|
||||
// PlayerMailData data = PlayerDataController.Instance.getPlayerData(player).mailData;
|
||||
//
|
||||
// Iterator<PlayerMail> it = data.playermail.iterator();
|
||||
// while(it.hasNext()){
|
||||
// PlayerMail mail = it.next();
|
||||
// if(mail.time == time && mail.sender.equals(username)){
|
||||
// mail.beenRead = true;
|
||||
// if(mail.hasQuest())
|
||||
// PlayerQuestController.addActiveQuest(new QuestData(mail.getQuest()), player);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.SignSave) {
|
||||
// int x = buffer.readInt(), y = buffer.readInt(), z = buffer.readInt();
|
||||
// if (player.worldObj.blockExists(x, y, z)) {
|
||||
// TileEntity tile = player.worldObj.getTileEntity(x, y, z);
|
||||
// if(!(tile instanceof TileBigSign))
|
||||
// return;
|
||||
// TileBigSign sign = (TileBigSign) tile;
|
||||
// if (sign.canEdit) {
|
||||
// sign.setText(ByteBufUtils.readString(buffer));
|
||||
// sign.canEdit = false;
|
||||
// player.worldObj.markBlockForUpdate(x, y, z);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.SaveBook) {
|
||||
// int x = buffer.readInt(), y = buffer.readInt(), z = buffer.readInt();
|
||||
// if (player.worldObj.blockExists(x, y, z)) {
|
||||
// TileEntity tileentity = player.worldObj.getTileEntity(x, y, z);
|
||||
// if (!(tileentity instanceof TileBook))
|
||||
// return;
|
||||
// TileBook tile = (TileBook) tileentity;
|
||||
// if (tile.book.getItem() == Items.written_book)
|
||||
// return;
|
||||
// boolean sign = buffer.readBoolean();
|
||||
// ItemStack book = ItemStack.loadItemStackFromNBT(ByteBufUtils.readNBT(buffer));
|
||||
// if (book == null)
|
||||
// return;
|
||||
// if (book.getItem() == Items.writable_book && !sign && ItemWritableBook.func_150930_a(book.getTagCompound())) {
|
||||
// tile.book.setTagInfo("pages", book.getTagCompound().getTagList("pages", 8));
|
||||
// }
|
||||
// if (book.getItem() == Items.written_book && sign && ItemEditableBook.validBookTagContents(book.getTagCompound())) {
|
||||
// tile.book.setTagInfo("author", new NBTTagString(player.getCommandSenderName()));
|
||||
// tile.book.setTagInfo("title", new NBTTagString(book.getTagCompound().getString("title")));
|
||||
// tile.book.setTagInfo("pages", book.getTagCompound().getTagList("pages", 8));
|
||||
// tile.book.func_150996_a(Items.written_book);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// else if(type == EnumPlayerPacket.ScreenSize){
|
||||
// int width = buffer.readInt(), height = buffer.readInt();
|
||||
// PlayerDataController.Instance.getPlayerData(player).screenSize.setSize(width,height);
|
||||
// }
|
||||
}
|
||||
}
|
||||
@@ -1,51 +0,0 @@
|
||||
package noppes.npcs;
|
||||
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.common.network.FMLNetworkEvent.ServerCustomPacketEvent;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import io.netty.buffer.ByteBuf;
|
||||
import kamkeel.npcs.network.PacketUtil;
|
||||
import kamkeel.npcs.network.packets.data.large.GuiDataPacket;
|
||||
import kamkeel.npcs.util.ByteBufUtils;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.entity.player.EntityPlayerMP;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.network.NetHandlerPlayServer;
|
||||
import net.minecraft.server.MinecraftServer;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import noppes.npcs.blocks.tiles.TileScripted;
|
||||
import noppes.npcs.config.ConfigDebug;
|
||||
import noppes.npcs.config.ConfigScript;
|
||||
import noppes.npcs.constants.*;
|
||||
import noppes.npcs.controllers.*;
|
||||
import noppes.npcs.controllers.data.*;
|
||||
import noppes.npcs.entity.EntityNPCInterface;
|
||||
import noppes.npcs.scripted.NpcAPI;
|
||||
import noppes.npcs.scripted.item.ScriptCustomItem;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
public class PacketHandlerServer{
|
||||
|
||||
@SubscribeEvent
|
||||
public void onServerPacket(ServerCustomPacketEvent event) {
|
||||
EntityPlayerMP player = ((NetHandlerPlayServer)event.handler).playerEntity;
|
||||
ByteBuf in = event.packet.payload();
|
||||
EnumPacketServer type = null;
|
||||
try {
|
||||
type = EnumPacketServer.values()[in.readInt()];
|
||||
|
||||
ItemStack item = player.inventory.getCurrentItem();
|
||||
|
||||
EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(player);
|
||||
} catch (Exception e) {
|
||||
LogWriter.error("Error with EnumPacketServer." + type, e);
|
||||
}
|
||||
}
|
||||
|
||||
private void warn(EntityPlayer player, String warning){
|
||||
MinecraftServer.getServer().logWarning(player.getCommandSenderName() + ": " + warning);
|
||||
}
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
package noppes.npcs.client;
|
||||
|
||||
import cpw.mods.fml.common.network.internal.FMLProxyPacket;
|
||||
import io.netty.buffer.ByteBuf;
|
||||
import io.netty.buffer.Unpooled;
|
||||
import noppes.npcs.CustomNpcs;
|
||||
import noppes.npcs.Server;
|
||||
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
public class Client {
|
||||
|
||||
public static void sendData(final EnumPacketServer enu, final Object... obs) {
|
||||
ByteBuf buffer = Unpooled.buffer();
|
||||
try {
|
||||
if(!Server.fillBuffer(buffer, enu, obs))
|
||||
return;
|
||||
CustomNpcs.Channel.sendToServer(new FMLProxyPacket(buffer, "CustomNPCs"));
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -83,8 +83,6 @@ public class ClientProxy extends CommonProxy {
|
||||
public void load() {
|
||||
Font = new FontContainer(ConfigClient.FontType, ConfigClient.FontSize);
|
||||
createFolders();
|
||||
CustomNpcs.Channel.register(new PacketHandlerClient());
|
||||
CustomNpcs.ChannelPlayer.register(new PacketHandlerPlayer());
|
||||
new MusicController();
|
||||
new ScriptSoundController();
|
||||
|
||||
|
||||
@@ -1,16 +0,0 @@
|
||||
package noppes.npcs.client;
|
||||
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.common.network.FMLNetworkEvent;
|
||||
import noppes.npcs.PacketHandlerServer;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
public class PacketHandlerClient extends PacketHandlerServer {
|
||||
|
||||
@SubscribeEvent
|
||||
public void onPacketData(FMLNetworkEvent.ClientCustomPacketEvent event) {
|
||||
// Need this here for testing and registry for now until
|
||||
// conversion is done
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user