2021-06-07 00:46:16 +02:00
|
|
|
package com.jozufozu.flywheel.event;
|
|
|
|
|
|
|
|
import com.jozufozu.flywheel.backend.Backend;
|
|
|
|
|
|
|
|
import net.minecraftforge.eventbus.api.Event;
|
2021-09-15 09:26:51 +02:00
|
|
|
import net.minecraftforge.fml.event.IModBusEvent;
|
2021-06-07 00:46:16 +02:00
|
|
|
|
|
|
|
public class GatherContextEvent extends Event implements IModBusEvent {
|
|
|
|
|
|
|
|
private final Backend backend;
|
2021-08-13 20:23:09 +02:00
|
|
|
private final boolean firstLoad;
|
2021-06-07 00:46:16 +02:00
|
|
|
|
2021-08-13 20:23:09 +02:00
|
|
|
public GatherContextEvent(Backend backend, boolean firstLoad) {
|
2021-06-07 00:46:16 +02:00
|
|
|
this.backend = backend;
|
2021-08-13 20:23:09 +02:00
|
|
|
this.firstLoad = firstLoad;
|
2021-06-07 00:46:16 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
public Backend getBackend() {
|
|
|
|
return backend;
|
|
|
|
}
|
2021-08-13 20:23:09 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @return true iff it is the first time the event is fired.
|
|
|
|
*/
|
|
|
|
public boolean isFirstLoad() {
|
|
|
|
return firstLoad;
|
|
|
|
}
|
2021-06-07 00:46:16 +02:00
|
|
|
}
|