Move stuff over from OTEMod
This commit is contained in:
parent
fb71db187d
commit
f27c76f334
40 changed files with 2036 additions and 5 deletions
|
@ -0,0 +1,18 @@
|
|||
package dev.zontreck.essentials.events;
|
||||
|
||||
import dev.zontreck.essentials.homes.Home;
|
||||
import net.minecraftforge.eventbus.api.Cancelable;
|
||||
import net.minecraftforge.eventbus.api.Event;
|
||||
|
||||
/**
|
||||
* This event may be cancelled if the home is in a invalid location, like in the middle of a claim they have no rights to
|
||||
*/
|
||||
@Cancelable
|
||||
public class HomeCreatedEvent extends Event
|
||||
{
|
||||
public Home home;
|
||||
public HomeCreatedEvent(Home home)
|
||||
{
|
||||
this.home=home;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,19 @@
|
|||
package dev.zontreck.essentials.events;
|
||||
|
||||
import dev.zontreck.essentials.homes.Home;
|
||||
import net.minecraftforge.eventbus.api.Cancelable;
|
||||
import net.minecraftforge.eventbus.api.Event;
|
||||
|
||||
/**
|
||||
* This event cannot be cancelled.
|
||||
*/
|
||||
public class HomeDeletedEvent extends Event
|
||||
{
|
||||
|
||||
public Home home;
|
||||
public HomeDeletedEvent(Home home)
|
||||
{
|
||||
this.home=home;
|
||||
}
|
||||
|
||||
}
|
22
src/main/java/dev/zontreck/essentials/events/RTPEvent.java
Normal file
22
src/main/java/dev/zontreck/essentials/events/RTPEvent.java
Normal file
|
@ -0,0 +1,22 @@
|
|||
package dev.zontreck.essentials.events;
|
||||
|
||||
import dev.zontreck.libzontreck.vectors.Vector3;
|
||||
import dev.zontreck.libzontreck.vectors.WorldPosition;
|
||||
import net.minecraft.server.level.ServerLevel;
|
||||
import net.minecraft.server.level.ServerPlayer;
|
||||
import net.minecraftforge.eventbus.api.Cancelable;
|
||||
import net.minecraftforge.eventbus.api.Event;
|
||||
|
||||
@Cancelable
|
||||
public class RTPEvent extends Event
|
||||
{
|
||||
public ServerPlayer player;
|
||||
public WorldPosition position;
|
||||
|
||||
public RTPEvent(ServerPlayer player, WorldPosition position)
|
||||
{
|
||||
this.player=player;
|
||||
this.position=position;
|
||||
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue