Fix for /f permanent and /f peaceful commands giving an NPE if run from console
Fix for rare NPE when Spout territory info update is run and affected player disconnects at precisely that moment Clarified "cannot attack neutral faction" messages to indicate enemy status is needed Updated Bukkit lib to correspond with CB 1337
This commit is contained in:
@ -3,6 +3,8 @@ package com.massivecraft.factions.integration;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import com.massivecraft.factions.Board;
|
||||
import com.massivecraft.factions.Conf;
|
||||
import com.massivecraft.factions.FLocation;
|
||||
@ -44,7 +46,11 @@ public class SpoutMainListener extends SpoutListener
|
||||
|
||||
public boolean updateTerritoryDisplay(FPlayer player)
|
||||
{
|
||||
SpoutPlayer sPlayer = SpoutManager.getPlayer(player.getPlayer());
|
||||
Player p = player.getPlayer();
|
||||
if (p == null)
|
||||
return false;
|
||||
|
||||
SpoutPlayer sPlayer = SpoutManager.getPlayer(p);
|
||||
if (!sPlayer.isSpoutCraftEnabled() || (Conf.spoutTerritoryDisplaySize <= 0 && ! Conf.spoutTerritoryNoticeShow))
|
||||
return false;
|
||||
|
||||
|
Reference in New Issue
Block a user