serverScoreboard.removeTeam( team.getName() );
return;
}
// Create or get old team
Team t;
if ( team.getMode() == 0 )
{
t = new Team( team.getName() );
serverScoreboard.addTeam( t );
} else
{
t = serverScoreboard.getTeam( team.getName() );
}
if ( t != null )
{
if ( team.getMode() == 0 || team.getMode() == 2 )
{
t.setDisplayName( team.getDisplayName() );
t.setPrefix( team.getPrefix() );
t.setSuffix( team.getSuffix() );
t.setFriendlyFire( team.getFriendlyFire() );
t.setNameTagVisibility( team.getNameTagVisibility() );
t.setColor( team.getColor() );
}
if ( team.getPlayers() != null )
{
for ( String s : team.getPlayers() )
{
if ( team.getMode() == 0 || team.getMode() == 3 )
{
t.addPlayer( s );
} else
{
t.removePlayer( s );
}
}
}
}
}