Package org.spoutcraft.client.entity

Examples of org.spoutcraft.client.entity.CraftLivingEntity


  }

  public void run(int id) {
    Entity e = SpoutClient.getInstance().getEntityFromId(entityId);
    if (e != null && e instanceof EntityLivingBase) {
      CraftLivingEntity living = (CraftLivingEntity)e.spoutEnty;
      // Check to see if this title is our username, if so, use defaults
      if (e instanceof EntityPlayer) {
        EntityPlayer player = (EntityPlayer)e;
        if (player.vip != null && title.equals(player.username)) {
          title = player.vip.getTitle();
        }
      }
      if (title.equals("reset")) {
        living.resetTitle();
        SpoutcraftWorld spworld = (SpoutcraftWorld) living.getWorld();
        spworld.getHandle().customTitles.remove(entityId);
      } else {
        living.setTitle(title);
        SpoutcraftWorld spworld = (SpoutcraftWorld) living.getWorld();
        spworld.getHandle().customTitles.put(living.getEntityId(), title);
      }
    }
  }
View Full Code Here

TOP

Related Classes of org.spoutcraft.client.entity.CraftLivingEntity

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.