use of mcjty.rftools.dimension.network.PacketCheckDimletConfig in project RFTools by McJty.
the class RfToolsDimensionManager method checkDimletConfig.
/**
* Check if the client dimlet id's match with the server.
* This is executed on the server to the clients.
*/
public void checkDimletConfig(EntityPlayer player) {
if (!player.getEntityWorld().isRemote) {
// Send over dimlet configuration to the client so that the client can check that the id's match.
Logging.log("Send validation data to the client");
DimletMapping mapping = DimletMapping.getDimletMapping(player.getEntityWorld());
Map<Integer, DimletKey> dimlets = new HashMap<Integer, DimletKey>();
for (Integer id : mapping.getIds()) {
dimlets.put(id, mapping.getKey(id));
}
RFToolsMessages.INSTANCE.sendTo(new PacketCheckDimletConfig(dimlets), (EntityPlayerMP) player);
}
}
Aggregations