org.bukkit.inventory.HorseInventory#org.bukkit.entity.ChestedHorse源码实例Demo

下面列出了org.bukkit.inventory.HorseInventory#org.bukkit.entity.ChestedHorse 实例代码,或者点击链接到github查看源代码,也可以在右侧发表评论。

源代码1 项目: SonarPet   文件: EntityHorsePet.java
@Override
public void setChested(boolean flag) {
    if (Versioning.NMS_VERSION.compareTo(NmsVersion.v1_11_R1) >= 0) {
        if (!(getBukkitEntity() instanceof ChestedHorse)) {
            /*
             * To fail silently, or to throw an exception; that is the question.
             * Whether is nobler to be confusing and get a bug report,
             * or be annoying and get a bug report?
             */
            return;
        }
    }
    getEntity().setCarryingChest(flag);
}
 
源代码2 项目: SonarPet   文件: NMSEntityHorseImpl.java
@Override
public void setCarryingChest(boolean flag) {
    if (getBukkitEntity() instanceof ChestedHorse) {
        ((ChestedHorse) getBukkitEntity()).setCarryingChest(flag);
    }
}
 
源代码3 项目: SonarPet   文件: NMSEntityHorseImpl.java
@Override
public void setCarryingChest(boolean flag) {
    if (getBukkitEntity() instanceof ChestedHorse) {
        ((ChestedHorse) getBukkitEntity()).setCarryingChest(flag);
    }
}