All Downloads are FREE. Search and download functionalities are using the official Maven repository.

cn.nukkit.entity.EntityAngryable Maven / Gradle / Ivy

There is a newer version: 1.20.40-r1
Show newest version
package cn.nukkit.entity;

import cn.nukkit.api.PowerNukkitXOnly;
import cn.nukkit.api.Since;
import cn.nukkit.entity.ai.memory.CoreMemoryTypes;

/**
 * 可生气实体

*/ @PowerNukkitXOnly @Since("1.19.50-r3") public interface EntityAngryable extends EntityComponent { default boolean isAngry() { return getMemoryStorage().get(CoreMemoryTypes.IS_ANGRY); } default void setAngry(boolean angry) { getMemoryStorage().put(CoreMemoryTypes.IS_ANGRY, angry); asEntity().setDataFlag(Entity.DATA_FLAGS, Entity.DATA_FLAG_ANGRY, angry); } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy