This commit is contained in:
nossr50 2020-10-08 16:34:59 -07:00
parent 20c69b63af
commit f5294387b0
3 changed files with 4 additions and 4 deletions

View File

@ -17,6 +17,7 @@ Version 2.1.148
Nether Portal spawned mobs are tracked persistently and are no longer forgotten about after a restart Nether Portal spawned mobs are tracked persistently and are no longer forgotten about after a restart
Endermen who target endermite are tracked persistently and are no longer forgotten about after a restart Endermen who target endermite are tracked persistently and are no longer forgotten about after a restart
COTW spawned mobs are tracked persistently and are no longer forgotten about after a restart COTW spawned mobs are tracked persistently and are no longer forgotten about after a restart
Player bred mobs are tracked persistently and are no longer forgotten about after a restart
NOTES: NOTES:

View File

@ -2,6 +2,7 @@ package com.gmail.nossr50.util.compat.layers.persistentdata;
import com.gmail.nossr50.api.exceptions.IncompleteNamespacedKeyRegister; import com.gmail.nossr50.api.exceptions.IncompleteNamespacedKeyRegister;
import com.gmail.nossr50.mcMMO; import com.gmail.nossr50.mcMMO;
import org.bukkit.Bukkit;
import org.bukkit.NamespacedKey; import org.bukkit.NamespacedKey;
import org.bukkit.block.Furnace; import org.bukkit.block.Furnace;
import org.bukkit.enchantments.Enchantment; import org.bukkit.enchantments.Enchantment;
@ -37,7 +38,6 @@ public class SpigotPersistentDataLayer_1_14 extends AbstractPersistentDataLayer
private void initMobFlagKeyMap() throws IncompleteNamespacedKeyRegister { private void initMobFlagKeyMap() throws IncompleteNamespacedKeyRegister {
for(MobMetaFlagType mobMetaFlagType : MobMetaFlagType.values()) { for(MobMetaFlagType mobMetaFlagType : MobMetaFlagType.values()) {
switch(mobMetaFlagType) { switch(mobMetaFlagType) {
case MOB_SPAWNER_MOB: case MOB_SPAWNER_MOB:
mobFlagKeyMap.put(mobMetaFlagType, NSK_MOB_SPAWNER_MOB); mobFlagKeyMap.put(mobMetaFlagType, NSK_MOB_SPAWNER_MOB);
break; break;
@ -67,7 +67,7 @@ public class SpigotPersistentDataLayer_1_14 extends AbstractPersistentDataLayer
@Override @Override
public boolean hasMobFlag(@NotNull MobMetaFlagType flag, @NotNull LivingEntity livingEntity) { public boolean hasMobFlag(@NotNull MobMetaFlagType flag, @NotNull LivingEntity livingEntity) {
return livingEntity.getPersistentDataContainer().has(mobFlagKeyMap.get(flag), PersistentDataType.SHORT); return livingEntity.getPersistentDataContainer().has(mobFlagKeyMap.get(flag), PersistentDataType.BYTE);
} }
@Override @Override

View File

@ -552,5 +552,4 @@ Experience_Values:
Zombie_Pigman: 3.0 Zombie_Pigman: 3.0
Zombified_Piglin: 3.0 Zombified_Piglin: 3.0
Strider: 1.2 Strider: 1.2
Zoglin: 2.5 Zoglin: 2.5