From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Ben Kerllenevich <me@notom3ga.me>
Date: Tue, 25 May 2021 16:30:30 -0400
Subject: [PATCH] API for any mob to burn daylight

Co-authored by: Encode42 <me@encode42.dev>

diff --git a/src/main/java/org/bukkit/entity/Entity.java b/src/main/java/org/bukkit/entity/Entity.java
index 0b8357f012e3bafcd3b5fb4043392b42cf5cfc2a..c9d64da90a05f252d91dd10d2d5f62ba66afb944 100644
--- a/src/main/java/org/bukkit/entity/Entity.java
+++ b/src/main/java/org/bukkit/entity/Entity.java
@@ -819,5 +819,12 @@ public interface Entity extends Metadatable, CommandSender, Nameable, Persistent
      * @return Whether the entity was successfully spawned.
      */
     boolean spawnAt(@NotNull Location location, @NotNull org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason spawnReason);
+
+    /**
+     * Checks if the entity is in daylight
+     *
+     * @return True if in daylight
+     */
+    boolean isInDaylight();
     // Purpur end
 }
diff --git a/src/main/java/org/bukkit/entity/LivingEntity.java b/src/main/java/org/bukkit/entity/LivingEntity.java
index 0f9dbacb6851b27b2e5b1aa1cf994ccb313f0f45..bbae010cedf30d0e3336a8f03ee00a0a824cb08d 100644
--- a/src/main/java/org/bukkit/entity/LivingEntity.java
+++ b/src/main/java/org/bukkit/entity/LivingEntity.java
@@ -932,5 +932,19 @@ public interface LivingEntity extends Attributable, Damageable, ProjectileSource
      * @param slot Equipment slot to play break animation for
      */
     void broadcastItemBreak(@NotNull org.bukkit.inventory.EquipmentSlot slot);
+
+    /**
+     * If this mob will burn in the sunlight
+     *
+     * @return True if mob will burn in sunlight
+     */
+    boolean shouldBurnInDay();
+
+    /**
+     * Set if this mob should burn in the sunlight
+     *
+     * @param shouldBurnInDay True to burn in sunlight
+     */
+    void setShouldBurnInDay(boolean shouldBurnInDay);
     // Purpur end
 }
