Package com.flansmod.common.teams

Examples of com.flansmod.common.teams.Team$ComparatorScore


    drawString(fontRendererObj, teamInfo.map, m + 6, n + 6, 0xffffff);
    drawString(fontRendererObj, teamInfo.gametype, m + 312 - 6 - fontRendererObj.getStringWidth(teamInfo.gametype), n + 6, 0xffffff);
   
    if(teamInfo.roundOver())
    {
      Team winners = teamInfo.getWinner();
      //Time limit was hit
      if(winners == null)
      {
        drawString(fontRendererObj, "Time Ran Out!", m + 10, n + 20, 0xffffff);
      }
View Full Code Here


          event.entityLiving.setCurrentItemOrArmor(armour.type + 1, new ItemStack(armour.item));
      }
      else if(Team.teams.size() > 0)
      {
        //Give a random set of armour
        Team team = Team.teams.get(event.world.rand.nextInt(Team.teams.size()));
        if(team.hat != null)
          event.entityLiving.setCurrentItemOrArmor(1, team.hat.copy());
        if(team.chest != null)
          event.entityLiving.setCurrentItemOrArmor(2, team.chest.copy());
        //if(team.legs != null)
View Full Code Here

  public void doRender(Entity entity, double d, double d1, double d2, float f, float f1)
  {
    bindEntityTexture(entity);
    EntityFlag flag = (EntityFlag)entity;
    int teamID = flag.getTeamID();
    Team team = FlansModClient.getTeam(teamID);
    if(team == null)
    {
      //Give each team a default colour
      switch(teamID)
      {
View Full Code Here

            else
            {
              data.writeInt(TeamsManager.getInstance().currentRound.teams.length);
              for(int i = 0; i < TeamsManager.getInstance().currentRound.teams.length; i++)
              {
                Team team = TeamsManager.getInstance().currentRound.teams[i];
                if(team == null)
                {
                  writeUTF(data, "none");
                  continue;
                }
                writeUTF(data, team.shortName);
                data.writeInt(team.score);
                data.writeBoolean(TeamsManager.getInstance().currentRound.gametype.teamHasWon(team));
                team.sortPlayers();
                data.writeInt(team.members.size());
                for(int j = 0; j < team.members.size(); j++)
                {
                  String username = team.members.get(j);
                  PlayerData playerData = PlayerHandler.getPlayerData(username, Side.SERVER);
                  writeUTF(data, username);
                  if(playerData == null)
                  {
                    data.writeInt(0);
                    data.writeInt(0);
                    data.writeInt(0);
                    writeUTF(data, "");
                  }
                  else
                  {
                    data.writeInt(playerData.score);
                    data.writeInt(playerData.zombieScore);
                    data.writeInt(playerData.kills);
                    data.writeInt(playerData.deaths);
                    writeUTF(data, playerData.playerClass.shortName);
                  }
                }
              }
            }
        }
        else
        {
          data.writeBoolean(false);
          ArrayList<String> playerNames = new ArrayList<String>();
          for(int i = 0; i < TeamsManager.getInstance().currentRound.teams.length; i++)
            {
              Team team = TeamsManager.getInstance().currentRound.teams[i];
              if(team == null || team.members == null)
              {
                continue;
              }
              playerNames.addAll(team.members);
View Full Code Here

    if(event.entity instanceof EntityPlayer && teamInfo != null && teamInfo.gametype != null && !"No Gametype".equals(teamInfo.gametype))
    {
      PlayerScoreData rendering = teamInfo.getPlayerScoreData(event.entity.getCommandSenderName());
      PlayerScoreData thePlayer = teamInfo.getPlayerScoreData(minecraft.thePlayer.getCommandSenderName());
     
      Team renderingTeam = rendering == null ? Team.spectators : rendering.team.team;
      Team thePlayerTeam = thePlayer == null ? Team.spectators : thePlayer.team.team;
           
      //Do custom skin overrides
      //If we have no stored skin, try to get it
      if(data.skin == null)
        data.skin = ((AbstractClientPlayer)event.entityPlayer).getLocationSkin();
View Full Code Here

    if(!(living instanceof EntityPlayer) || shooter == null || PlayerHandler.getPlayerData(shooter) == null)
    {
      return super.func_151519_b(living);
    }
    EntityPlayer player = (EntityPlayer)living;
      Team killedTeam = PlayerHandler.getPlayerData(player).team;
      Team killerTeam = PlayerHandler.getPlayerData(shooter).team;
     
      FlansMod.getPacketHandler().sendToDimension(new PacketKillMessage(headshot, weapon, (killedTeam == null ? "f" : killedTeam.textColour) + player.getCommandSenderName()(killerTeam == null ? "f" : killerTeam.textColour) + shooter.getCommandSenderName()), living.dimension);
     
        return new ChatComponentText("#flansmod");//flanDeath." + weapon.shortName + "." + (killedTeam == null ? "f" : killedTeam.textColour) + player.getCommandSenderName() + "." + (killerTeam == null ? "f" : killerTeam.textColour) + shooter.getCommandSenderName());
    }
View Full Code Here

TOP

Related Classes of com.flansmod.common.teams.Team$ComparatorScore

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.