org.bukkit.entity.Zombie.setBaby()方法的使用及代码示例

x33g5p2x  于2022-02-05 转载在 其他  
字(2.3k)|赞(0)|评价(0)|浏览(81)

本文整理了Java中org.bukkit.entity.Zombie.setBaby()方法的一些代码示例,展示了Zombie.setBaby()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Zombie.setBaby()方法的具体详情如下:
包路径:org.bukkit.entity.Zombie
类名称:Zombie
方法名:setBaby

Zombie.setBaby介绍

[英]Sets whether the zombie is a baby
[中]设置僵尸是否为婴儿

代码示例

代码示例来源:origin: elBukkit/MagicPlugin

@Override
public void apply(Entity entity) {
  if (!(entity instanceof Zombie)) return;
  Zombie zombie = (Zombie)entity;
  zombie.setBaby(isBaby);
}

代码示例来源:origin: EngineHub/CommandHelper

@Override
  public void setBaby(boolean isBaby) {
    getHandle().setBaby(isBaby);
  }
}

代码示例来源:origin: libraryaddict/LibsDisguises

((Zombie) bukkitEntity).setBaby(true);

代码示例来源:origin: elBukkit/MagicPlugin

zombie.setBaby(false);
zombie.setBaby(true);
showEntityInfo(sender, testEntity, label, formatter);

代码示例来源:origin: garbagemule/MobArena

case "babyzombie":
case "babypigman":
  ((Zombie) e).setBaby(true);
  break;
case "killerbunny":

代码示例来源:origin: nsporillo/GlobalWarming

case PIG_ZOMBIE:
case ZOMBIE_VILLAGER:
  ((Zombie)entity).setBaby(true);
break;

代码示例来源:origin: EngineHub/CommandBook

((Ageable) creature).setBaby();
} else if (creature instanceof Zombie) {
  ((Zombie) creature).setBaby(true);

代码示例来源:origin: EngineHub/CommandHelper

switch(ztype) {
  case BABY:
    z.setBaby(true);
    break;

代码示例来源:origin: elBukkit/MagicPlugin

} else  if (li instanceof Zombie && !((Zombie)li).isBaby()) {
  context.registerModified(li);
  ((Zombie)li).setBaby(true);
} else  if (li instanceof Slime && ((Slime)li).getSize() > 1) {
  context.registerModified(li);
  Entity replacement = targetLocation.getWorld().spawnEntity(targetLocation, replaceType);
  if (replacement instanceof Zombie) {
    ((Zombie)replacement).setBaby(false);

代码示例来源:origin: elBukkit/MagicPlugin

} else {
  context.registerModified(li);
  ((Zombie) li).setBaby(false);

代码示例来源:origin: elBukkit/MagicPlugin

((Zombie) li).setBaby(false);

代码示例来源:origin: eccentricdevotion/TARDIS

case ZOMBIE:
  Zombie zombie = (Zombie) ent;
  zombie.setBaby(m.isBaby());
  EntityEquipment ez = zombie.getEquipment();
  if (m.getEquipment() != null) {

代码示例来源:origin: elBukkit/MagicPlugin

Entity zombie = targetLocation.getWorld().spawnEntity(targetLocation, EntityType.ZOMBIE);
  if (zombie instanceof Zombie) {
    ((Zombie)zombie).setBaby(false);
} else  if (li instanceof Zombie && !((Zombie)li).isBaby()) {
  registerModified(li);
  ((Zombie)li).setBaby(true);
} else  if (li instanceof PigZombie && !((PigZombie)li).isBaby()) {
  registerModified(li);

相关文章