diff --git a/src/main/java/net/aufdemrand/denizen/objects/dEntity.java b/src/main/java/net/aufdemrand/denizen/objects/dEntity.java index 00f08aa87c..ab62d56007 100644 --- a/src/main/java/net/aufdemrand/denizen/objects/dEntity.java +++ b/src/main/java/net/aufdemrand/denizen/objects/dEntity.java @@ -2310,6 +2310,19 @@ && getBukkitEntity() instanceof Item) { .getAttribute(attribute.fulfill(1)); } + // <--[tag] + // @attribute + // @returns Element(Boolean) + // @mechanism dEntity.glowing + // @group attributes + // @description + // Returns whether this entity is glowing. + // --> + if (attribute.startsWith("glowing")) { + return new Element(getLivingEntity().isGlowing()) + .getAttribute(attribute.fulfill(1)); + } + ///////////////////// // TYPE ATTRIBUTES ///////////////// @@ -2722,6 +2735,19 @@ public void adjust(Mechanism mechanism) { getLivingEntity().setGliding(value.asBoolean()); } + // <--[mechanism] + // @object dEntity + // @name glowing + // @input Element(Boolean) + // @description + // Sets whether this entity is glowing. + // @tags + // + // --> + if (mechanism.matches("glowing") && mechanism.requireBoolean()) { + getLivingEntity().setGlowing(value.asBoolean()); + } + // Iterate through this object's properties' mechanisms for (Property property : PropertyParser.getProperties(this)) { property.adjust(mechanism);