2015-08-29 14:33:25 +02:00
|
|
|
/*
|
|
|
|
* This file ("PacketHandler.java") is part of the Actually Additions Mod for Minecraft.
|
|
|
|
* It is created and owned by Ellpeck and distributed
|
|
|
|
* under the Actually Additions License to be found at
|
2016-01-03 16:05:51 +01:00
|
|
|
* http://ellpeck.de/actaddlicense/
|
2015-08-29 14:33:25 +02:00
|
|
|
* View the source code at https://github.com/Ellpeck/ActuallyAdditions
|
|
|
|
*
|
2016-01-03 16:05:51 +01:00
|
|
|
* © 2016 Ellpeck
|
2015-08-29 14:33:25 +02:00
|
|
|
*/
|
|
|
|
|
2016-01-05 04:47:35 +01:00
|
|
|
package de.ellpeck.actuallyadditions.mod.network;
|
2015-02-20 22:45:33 +01:00
|
|
|
|
2016-01-05 04:47:35 +01:00
|
|
|
import de.ellpeck.actuallyadditions.mod.network.gui.PacketGuiButton;
|
|
|
|
import de.ellpeck.actuallyadditions.mod.network.gui.PacketGuiNumber;
|
|
|
|
import de.ellpeck.actuallyadditions.mod.network.gui.PacketGuiString;
|
|
|
|
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
|
2016-01-07 18:20:59 +01:00
|
|
|
import net.minecraftforge.fml.common.network.NetworkRegistry;
|
|
|
|
import net.minecraftforge.fml.common.network.simpleimpl.SimpleNetworkWrapper;
|
|
|
|
import net.minecraftforge.fml.relauncher.Side;
|
2015-02-20 22:45:33 +01:00
|
|
|
|
|
|
|
public class PacketHandler{
|
|
|
|
|
|
|
|
public static SimpleNetworkWrapper theNetwork;
|
|
|
|
|
|
|
|
public static void init(){
|
2015-03-29 15:29:05 +02:00
|
|
|
theNetwork = NetworkRegistry.INSTANCE.newSimpleChannel(ModUtil.MOD_ID_LOWER);
|
2015-02-20 22:45:33 +01:00
|
|
|
|
2015-07-02 04:21:21 +02:00
|
|
|
theNetwork.registerMessage(PacketGuiButton.Handler.class, PacketGuiButton.class, 0, Side.SERVER);
|
2015-10-18 15:28:06 +02:00
|
|
|
theNetwork.registerMessage(PacketGuiNumber.Handler.class, PacketGuiNumber.class, 1, Side.SERVER);
|
|
|
|
theNetwork.registerMessage(PacketGuiString.Handler.class, PacketGuiString.class, 2, Side.SERVER);
|
2015-12-09 18:47:42 +01:00
|
|
|
theNetwork.registerMessage(PacketParticle.Handler.class, PacketParticle.class, 3, Side.CLIENT);
|
2016-01-17 20:46:51 +01:00
|
|
|
theNetwork.registerMessage(PacketUpdateTileEntity.Handler.class, PacketUpdateTileEntity.class, 4, Side.CLIENT);
|
2015-02-20 22:45:33 +01:00
|
|
|
}
|
|
|
|
}
|