public class PartyVsParty extends AbstractFight implements PartyFight
Modifier and Type | Field and Description |
---|---|
Party |
p1 |
Party |
p2 |
PartyVsPartyRequest |
request |
arena, bed1Broken, bed2Broken, blockChanges, blockLimitReached, currentFight, durationLimit, kit, maxBlockChanges, started, statistics
Constructor and Description |
---|
PartyVsParty(StrikePractice plugin,
Party p1,
Party p2,
BattleKit kit) |
Modifier and Type | Method and Description |
---|---|
boolean |
allowSpectating()
Gets if specatting is allowed in the fight.
|
boolean |
canStart()
Gets if the fight can be started.
|
void |
forceEnd(Party loser) |
void |
forceEnd(java.lang.String reason) |
java.util.List<java.lang.String> |
getOpponents(Player p)
Dead players should be included in the list if online.
|
Party[] |
getParties() |
Party |
getParty1() |
Party |
getParty2() |
java.util.HashSet<java.lang.String> |
getPartyAlive1() |
java.util.HashSet<java.lang.String> |
getPartyAlive2() |
java.util.List<java.lang.String> |
getTeammates(Player p)
The given player should be included in the list.
|
void |
handleDeath(Player p)
This will be called when the player died
|
boolean |
hasEnded()
Gets if this fight has ended.
|
boolean |
isQueue() |
void |
setQueue(boolean queue) |
void |
start()
Starts the actual fight
|
addBlockChange, clearBlockChanges, getArena, getBlockChanges, getBlockChangesMap, getCurrentFight, getDuration, getDurationLimit, getEnded, getFights, getKit, getMaxBlockChanges, getStarted, getStatistics, getStatistics, getStatistics, handleDisappear, isBed1Broken, isBed2Broken, isInFight, sendSpectatorMessages, sendSpectatorMessages, setArena, setBed1Broken, setBed2Broken, setCurrentFight, setKit, setMaxBlockChanges, setStartedAfterCountdown
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forceEndDelayed, getFightStatistics, getFightStatistics, getPlayerNames, getPlayersInFight, getSpectators, hasStarted, playersAreOpponents, playersAreTeammates, saveFight
public Party p1
public Party p2
public PartyVsPartyRequest request
public boolean canStart()
Fight
public Party[] getParties()
getParties
in interface PartyFight
public void start()
Fight
start
in interface Fight
start
in class AbstractFight
public void handleDeath(Player p)
Fight
handleDeath
in interface Fight
p
- player who died.public boolean allowSpectating()
Fight
allowSpectating
in interface Fight
public boolean hasEnded()
public Party getParty1()
public Party getParty2()
public java.util.HashSet<java.lang.String> getPartyAlive1()
public boolean isQueue()
public void setQueue(boolean queue)
public java.util.HashSet<java.lang.String> getPartyAlive2()
public void forceEnd(Party loser)
public java.util.List<java.lang.String> getTeammates(Player p)
Fight
getTeammates
in interface Fight
public java.util.List<java.lang.String> getOpponents(Player p)
Fight
getOpponents
in interface Fight