Saber-Factions/src/main/java/com/massivecraft/factions/event/FactionDisbandEvent.java

40 lines
954 B
Java
Raw Normal View History

package com.massivecraft.factions.event;
import com.massivecraft.factions.FPlayer;
import com.massivecraft.factions.FPlayers;
import com.massivecraft.factions.Faction;
import com.massivecraft.factions.Factions;
2014-04-04 20:55:21 +02:00
import org.bukkit.entity.Player;
import org.bukkit.event.Cancellable;
import org.bukkit.event.Event;
import org.bukkit.event.HandlerList;
public class FactionDisbandEvent extends FactionEvent implements Cancellable {
private boolean cancelled = false;
2014-04-04 20:55:21 +02:00
private Player sender;
2014-04-04 20:55:21 +02:00
public FactionDisbandEvent(Player sender, String factionId) {
super(Factions.i.get(factionId));
2014-07-01 22:10:18 +02:00
this.sender = sender;
2014-04-04 20:55:21 +02:00
}
2014-04-04 20:55:21 +02:00
public FPlayer getFPlayer() {
return FPlayers.i.get(sender);
}
2014-04-04 20:55:21 +02:00
public Player getPlayer() {
return sender;
}
2014-04-04 20:55:21 +02:00
@Override
public boolean isCancelled() {
return cancelled;
}
2014-04-04 20:55:21 +02:00
@Override
public void setCancelled(boolean c) {
cancelled = c;
}
}