use of mcjty.rftoolsdim.api.dimlet.IDimletConfigurationManager in project RFToolsDimensions by McJty.
the class RFToolsDim method imcCallback.
@Mod.EventHandler
public void imcCallback(FMLInterModComms.IMCEvent event) {
for (FMLInterModComms.IMCMessage message : event.getMessages()) {
if ("getDimletConfigurationManager".equalsIgnoreCase(message.key)) {
Optional<Function<IDimletConfigurationManager, Void>> value = message.getFunctionValue(IDimletConfigurationManager.class, Void.class);
String mod = message.getSender();
Logging.log("Received RFTools Dimensions dimlet reconfiguration request from mod '" + mod + "'");
value.get().apply(new DimletConfigurationManager(mod));
} else if ("getDimensionManager".equalsIgnoreCase(message.key)) {
Optional<Function<IDimensionManager, Void>> value = message.getFunctionValue(IDimensionManager.class, Void.class);
String mod = message.getSender();
Logging.log("Received RFTools dimension manager request from mod '" + mod + "'");
value.get().apply(new DimensionManager());
}
}
}
Aggregations