Package logisticspipes.network.packets.modules

Source Code of logisticspipes.network.packets.modules.ItemSinkDefault

package logisticspipes.network.packets.modules;

import logisticspipes.modules.ModuleItemSink;
import logisticspipes.network.abstractpackets.BooleanModuleCoordinatesPacket;
import logisticspipes.network.abstractpackets.ModernPacket;
import net.minecraft.entity.player.EntityPlayer;

public class ItemSinkDefault extends BooleanModuleCoordinatesPacket {

  public ItemSinkDefault(int id) {
    super(id);
  }

  @Override
  public ModernPacket template() {
    return new ItemSinkDefault(getId());
  }

  @Override
  public void processPacket(EntityPlayer player) {
    ModuleItemSink module = this.getLogisticsModule(player, ModuleItemSink.class);
    if(module == null) return;
    module.setDefaultRoute(isFlag());
  }
}
TOP

Related Classes of logisticspipes.network.packets.modules.ItemSinkDefault

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.