Search in sources :

Example 1 with MessageTurretBase

use of omtteam.openmodularturrets.network.messages.MessageTurretBase in project OpenModularTurrets by OpenModularTurretsTeam.

the class TurretBaseContainer method detectAndSendChanges.

@Override
public void detectAndSendChanges() {
    super.detectAndSendChanges();
    DebugHandler.getInstance().setListeners(this.listeners);
    for (IContainerListener listener : this.listeners) {
        if (listener instanceof EntityPlayerMP) {
            NetworkingHandler.INSTANCE.sendTo(new MessageTurretBase(this.tileEntity), (EntityPlayerMP) listener);
        }
    }
}
Also used : IContainerListener(net.minecraft.inventory.IContainerListener) EntityPlayerMP(net.minecraft.entity.player.EntityPlayerMP) MessageTurretBase(omtteam.openmodularturrets.network.messages.MessageTurretBase)

Example 2 with MessageTurretBase

use of omtteam.openmodularturrets.network.messages.MessageTurretBase in project OpenModularTurrets by OpenModularTurretsTeam.

the class ConfigContainer method detectAndSendChanges.

@Override
public void detectAndSendChanges() {
    super.detectAndSendChanges();
    DebugHandler.getInstance().setListeners(this.listeners);
    for (IContainerListener listener : this.listeners) {
        if (listener instanceof EntityPlayerMP) {
            NetworkingHandler.INSTANCE.sendTo(new MessageTurretBase(this.tileEntity), (EntityPlayerMP) listener);
        }
    }
}
Also used : IContainerListener(net.minecraft.inventory.IContainerListener) EntityPlayerMP(net.minecraft.entity.player.EntityPlayerMP) MessageTurretBase(omtteam.openmodularturrets.network.messages.MessageTurretBase)

Aggregations

EntityPlayerMP (net.minecraft.entity.player.EntityPlayerMP)2 IContainerListener (net.minecraft.inventory.IContainerListener)2 MessageTurretBase (omtteam.openmodularturrets.network.messages.MessageTurretBase)2