Added some Events (#1096)
* Added PlayerBanEvent, PlayerUnbanEvent, PlayerIpBanEvent, and PlayerIpUnbanEvent. * Removed Unecessary import (oops) * Formatted code * Fixed a little oopsie * Prevent NPE * add another line..
This commit is contained in:
@@ -138,7 +138,7 @@ public class EventType{
|
||||
public final Player player;
|
||||
public final Item item;
|
||||
public final int amount;
|
||||
|
||||
|
||||
public DepositEvent(Tile tile, Player player, Item item, int amount){
|
||||
this.tile = tile;
|
||||
this.player = player;
|
||||
@@ -146,7 +146,7 @@ public class EventType{
|
||||
this.amount = amount;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** Called when the player taps a block. */
|
||||
public static class TapEvent{
|
||||
public final Tile tile;
|
||||
@@ -157,7 +157,7 @@ public class EventType{
|
||||
this.player = player;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** Called when the player sets a specific block. */
|
||||
public static class TapConfigEvent{
|
||||
public final Tile tile;
|
||||
@@ -310,7 +310,7 @@ public class EventType{
|
||||
/** Called after connecting; when a player recieves world data and is ready to play.*/
|
||||
public static class PlayerJoin{
|
||||
public final Player player;
|
||||
|
||||
|
||||
public PlayerJoin(Player player){
|
||||
this.player = player;
|
||||
}
|
||||
@@ -327,11 +327,45 @@ public class EventType{
|
||||
|
||||
public static class PlayerLeave{
|
||||
public final Player player;
|
||||
|
||||
|
||||
public PlayerLeave(Player player){
|
||||
this.player = player;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public static class PlayerBanEvent{
|
||||
public final Player player;
|
||||
|
||||
public PlayerBanEvent(Player player){
|
||||
this.player = player;
|
||||
}
|
||||
}
|
||||
|
||||
public static class PlayerUnbanEvent{
|
||||
public final Player player;
|
||||
|
||||
public PlayerUnbanEvent(Player player){
|
||||
this.player = player;
|
||||
}
|
||||
}
|
||||
|
||||
public static class PlayerIpBanEvent{
|
||||
public final String ip;
|
||||
|
||||
|
||||
public PlayerIpBanEvent(String ip){
|
||||
this.ip = ip;
|
||||
}
|
||||
}
|
||||
|
||||
public static class PlayerIpUnbanEvent{
|
||||
public final String ip;
|
||||
|
||||
|
||||
public PlayerIpUnbanEvent(String ip){
|
||||
this.ip = ip;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user