Skip to content

Commit

Permalink
EntityTag.rotation: fix describes to support all hanging types
Browse files Browse the repository at this point in the history
  • Loading branch information
mcmonkey4eva committed May 7, 2022
1 parent 5f05abe commit 81bdeab
Showing 1 changed file with 1 addition and 3 deletions.
Expand Up @@ -9,7 +9,6 @@
import com.denizenscript.denizencore.tags.Attribute;
import com.denizenscript.denizencore.utilities.CoreUtilities;
import org.bukkit.block.BlockFace;
import org.bukkit.entity.EntityType;
import org.bukkit.entity.Hanging;

public class EntityRotation implements Property {
Expand All @@ -18,8 +17,7 @@ public static boolean describes(ObjectTag entity) {
if (!(entity instanceof EntityTag)) {
return false;
}
return ((EntityTag) entity).getBukkitEntityType() == EntityType.PAINTING
|| ((EntityTag) entity).getBukkitEntityType() == EntityType.ITEM_FRAME;
return ((EntityTag) entity).getBukkitEntity() instanceof Hanging;
}

public static EntityRotation getFrom(ObjectTag entity) {
Expand Down

0 comments on commit 81bdeab

Please sign in to comment.