From abbb7415bd64be8693e93d83ff01a85ee4b37e52 Mon Sep 17 00:00:00 2001 From: Jake Potrebic Date: Fri, 14 Jun 2024 13:38:42 -0700 Subject: [PATCH] remove old vanilla goals --- .../paper/entity/ai/VanillaGoal.java | 684 ------------------ .../types/goal/MobGoalGenerator.java | 109 --- 2 files changed, 793 deletions(-) diff --git a/paper-api-generator/generated/com/destroystokyo/paper/entity/ai/VanillaGoal.java b/paper-api-generator/generated/com/destroystokyo/paper/entity/ai/VanillaGoal.java index 0f8111e46b..3add91218d 100644 --- a/paper-api-generator/generated/com/destroystokyo/paper/entity/ai/VanillaGoal.java +++ b/paper-api-generator/generated/com/destroystokyo/paper/entity/ai/VanillaGoal.java @@ -31,12 +31,10 @@ import org.bukkit.entity.Ocelot; import org.bukkit.entity.Panda; import org.bukkit.entity.Parrot; import org.bukkit.entity.Phantom; -import org.bukkit.entity.PigZombie; import org.bukkit.entity.PolarBear; import org.bukkit.entity.PufferFish; import org.bukkit.entity.Rabbit; import org.bukkit.entity.Raider; -import org.bukkit.entity.Ravager; import org.bukkit.entity.Shulker; import org.bukkit.entity.Silverfish; import org.bukkit.entity.SkeletonHorse; @@ -46,7 +44,6 @@ import org.bukkit.entity.Spider; import org.bukkit.entity.Squid; import org.bukkit.entity.Strider; import org.bukkit.entity.Tameable; -import org.bukkit.entity.TraderLlama; import org.bukkit.entity.Turtle; import org.bukkit.entity.Vex; import org.bukkit.entity.Vindicator; @@ -54,7 +51,6 @@ import org.bukkit.entity.WanderingTrader; import org.bukkit.entity.Wither; import org.bukkit.entity.Wolf; import org.bukkit.entity.Zombie; -import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NotNull; /** @@ -440,686 +436,6 @@ public interface VanillaGoal extends Goal { GoalKey ZOMBIE_ATTACK_TURTLE_EGG = create("zombie_attack_turtle_egg", Zombie.class); - /** - * Removed in 1.20.2 - */ - @Deprecated( - since = "1.20.2" - ) - GoalKey VINDICATOR_MELEE_ATTACK = create("vindicator_melee_attack", Vindicator.class); - - /** - * Removed in 1.20.2 - */ - @Deprecated( - since = "1.20.2" - ) - GoalKey RAVAGER_MELEE_ATTACK = create("ravager_melee_attack", Ravager.class); - - /** - * Removed in 1.20.2 - */ - @Deprecated( - since = "1.20.2" - ) - GoalKey EVIL_RABBIT_ATTACK = create("evil_rabbit_attack", Rabbit.class); - - /** - * Removed in 1.16 - */ - @Deprecated( - forRemoval = true, - since = "1.16" - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey ANGER = create("anger", PigZombie.class); - - /** - * Removed in 1.16 - */ - @Deprecated( - forRemoval = true, - since = "1.16" - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey ANGER_OTHER = create("anger_other", PigZombie.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey BLAZE_FIREBALL = create("blaze_fireball", Blaze.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey TEMPT_CHANCE = create("tempt_chance", Cat.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey DOLPHIN_PLAY_WITH_ITEMS = create("dolphin_play_with_items", Dolphin.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey DROWNED_GOTO_BEACH = create("drowned_goto_beach", Drowned.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey DROWNED_GOTO_WATER = create("drowned_goto_water", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey ENDERMAN_PICKUP_BLOCK = create("enderman_pickup_block", Enderman.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey ENDERMAN_PLACE_BLOCK = create("enderman_place_block", Enderman.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey PLAYER_WHO_LOOKED_AT_TARGET = create("player_who_looked_at_target", Enderman.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey EVOKER_CAST_SPELL = create("evoker_cast_spell", Evoker.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey FOX_DEFEND_TRUSTED = create("fox_defend_trusted", Fox.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey FOX_FACEPLANT = create("fox_faceplant", Fox.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey FOX_PERCH_AND_SEARCH = create("fox_perch_and_search", Fox.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey FOX_SLEEP = create("fox_sleep", Fox.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey FOX_SEEK_SHELTER = create("fox_seek_shelter", Fox.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey FOX_STALK_PREY = create("fox_stalk_prey", Fox.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey GHAST_ATTACK_TARGET = create("ghast_attack_target", Ghast.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey GHAST_IDLE_MOVE = create("ghast_idle_move", Ghast.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey GHAST_MOVE_TOWARDS_TARGET = create("ghast_move_towards_target", Ghast.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SPELLCASTER_CAST_SPELL = create("spellcaster_cast_spell", Spellcaster.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey LLAMATRADER_DEFENDED_WANDERING_TRADER = create("llamatrader_defended_wandering_trader", TraderLlama.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey PANDA_HURT_BY_TARGET = create("panda_hurt_by_target", Panda.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey POLARBEAR_ATTACK_PLAYERS = create("polarbear_attack_players", PolarBear.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey POLARBEAR_HURT_BY = create("polarbear_hurt_by", PolarBear.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey POLARBEAR_MELEE = create("polarbear_melee", PolarBear.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey POLARBEAR_PANIC = create("polarbear_panic", PolarBear.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey EAT_CARROTS = create("eat_carrots", Rabbit.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey KILLER_RABBIT_MELEE_ATTACK = create("killer_rabbit_melee_attack", Rabbit.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey RABBIT_AVOID_TARGET = create("rabbit_avoid_target", Rabbit.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey RAIDER_HOLD_GROUND = create("raider_hold_ground", Raider.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey RAIDER_OBTAIN_BANNER = create("raider_obtain_banner", Raider.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SHULKER_DEFENSE = create("shulker_defense", Shulker.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SHULKER_NEAREST = create("shulker_nearest", Shulker.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SILVERFISH_HIDE_IN_BLOCK = create("silverfish_hide_in_block", Silverfish.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SILVERFISH_WAKE_OTHERS = create("silverfish_wake_others", Silverfish.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SLIME_IDLE = create("slime_idle", Slime.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SLIME_NEAREST_PLAYER = create("slime_nearest_player", Slime.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SLIME_RANDOM_JUMP = create("slime_random_jump", Slime.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SPIDER_MELEE_ATTACK = create("spider_melee_attack", Spider.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SPIDER_NEAREST_ATTACKABLE_TARGET = create("spider_nearest_attackable_target", Spider.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SQUID = create("squid", Squid.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey TURTLE_GOTO_WATER = create("turtle_goto_water", Turtle.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey TURTLE_TEMPT = create("turtle_tempt", Turtle.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey VEX_COPY_TARGET_OF_OWNER = create("vex_copy_target_of_owner", Vex.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey VILLAGERTRADER_WANDER_TO_POSITION = create("villagertrader_wander_to_position", WanderingTrader.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey ARROW_ATTACK = create("arrow_attack", RangedEntity.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey AVOID_TARGET = create("avoid_target", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey BOW_SHOOT = create("bow_shoot", Monster.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey BREATH = create("breath", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey CAT_SIT_ON_BED = create("cat_sit_on_bed", Cat.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey CROSSBOW_ATTACK = create("crossbow_attack", Monster.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey DOOR_OPEN = create("door_open", Mob.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey EAT_TILE = create("eat_tile", Mob.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey FISH_SCHOOL = create("fish_school", Fish.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey FOLLOW_ENTITY = create("follow_entity", Mob.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey HORSE_TRAP = create("horse_trap", SkeletonHorse.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey HURT_BY_TARGET = create("hurt_by_target", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey JUMP_ON_BLOCK = create("jump_on_block", Cat.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey LEAP_AT_TARGET = create("leap_at_target", Mob.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey LLAMA_FOLLOW = create("llama_follow", Llama.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey MOVE_TOWARDS_TARGET = create("move_towards_target", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey NEAREST_ATTACKABLE_TARGET = create("nearest_attackable_target", Mob.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey NEAREST_ATTACKABLE_TARGET_WITCH = create("nearest_attackable_target_witch", Raider.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey NEAREST_VILLAGE = create("nearest_village", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey OWNER_HURT_BY_TARGET = create("owner_hurt_by_target", Tameable.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey OWNER_HURT_TARGET = create("owner_hurt_target", Tameable.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey PERCH = create("perch", Parrot.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey RAID = create("raid", Raider.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey RANDOM_FLY = create("random_fly", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey RANDOM_LOOKAROUND = create("random_lookaround", Mob.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey RANDOM_STROLL_LAND = create("random_stroll_land", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey RANDOM_SWIM = create("random_swim", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey RANDOM_TARGET_NON_TAMED = create("random_target_non_tamed", Tameable.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey SIT = create("sit", Tameable.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey STROLL_VILLAGE = create("stroll_village", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey TAME = create("tame", AbstractHorse.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey WATER = create("water", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey WATER_JUMP = create("water_jump", Dolphin.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey STROLL_VILLAGE_GOLEM = create("stroll_village_golem", Creature.class); - - @Deprecated( - forRemoval = true - ) - @ApiStatus.ScheduledForRemoval( - inVersion = "1.21" - ) - GoalKey UNIVERSAL_ANGER_RESET = create("universal_anger_reset", Mob.class); - private static @NotNull GoalKey create(final @NotNull String key, final @NotNull Class type) { return GoalKey.of(type, NamespacedKey.minecraft(key)); diff --git a/paper-api-generator/src/main/java/io/papermc/generator/types/goal/MobGoalGenerator.java b/paper-api-generator/src/main/java/io/papermc/generator/types/goal/MobGoalGenerator.java index 7f94034424..aaa6e6ad19 100644 --- a/paper-api-generator/src/main/java/io/papermc/generator/types/goal/MobGoalGenerator.java +++ b/paper-api-generator/src/main/java/io/papermc/generator/types/goal/MobGoalGenerator.java @@ -71,95 +71,6 @@ public class MobGoalGenerator extends SimpleGenerator { private static final String CLASS_HEADER = Javadocs.getVersionDependentClassHeader("Mob Goals"); - private static final DeprecatedEntry[] DEPRECATED_ENTRIES = { - // - new DeprecatedEntry(Vindicator.class, "vindicator_melee_attack", null, "1.20.2"), - new DeprecatedEntry(Ravager.class, "ravager_melee_attack", null, "1.20.2"), - new DeprecatedEntry(Rabbit.class, "evil_rabbit_attack", null, "1.20.2"), - new DeprecatedEntry(PigZombie.class, "anger", "1.21", "1.16"), - new DeprecatedEntry(PigZombie.class, "anger_other", "1.21", "1.16"), - new DeprecatedEntry(Blaze.class, "blaze_fireball", "1.21", null), - new DeprecatedEntry(Cat.class, "tempt_chance", "1.21", null), - new DeprecatedEntry(Dolphin.class, "dolphin_play_with_items", "1.21", null), - new DeprecatedEntry(Drowned.class, "drowned_goto_beach", "1.21", null), - new DeprecatedEntry(Creature.class, "drowned_goto_water", "1.21", null), - new DeprecatedEntry(Enderman.class, "enderman_pickup_block", "1.21", null), - new DeprecatedEntry(Enderman.class, "enderman_place_block", "1.21", null), - new DeprecatedEntry(Enderman.class, "player_who_looked_at_target", "1.21", null), - new DeprecatedEntry(Evoker.class, "evoker_cast_spell", "1.21", null), - new DeprecatedEntry(Fox.class, "fox_defend_trusted", "1.21", null), - new DeprecatedEntry(Fox.class, "fox_faceplant", "1.21", null), - new DeprecatedEntry(Fox.class, "fox_perch_and_search", "1.21", null), - new DeprecatedEntry(Fox.class, "fox_sleep", "1.21", null), - new DeprecatedEntry(Fox.class, "fox_seek_shelter", "1.21", null), - new DeprecatedEntry(Fox.class, "fox_stalk_prey", "1.21", null), - new DeprecatedEntry(Ghast.class, "ghast_attack_target", "1.21", null), - new DeprecatedEntry(Ghast.class, "ghast_idle_move", "1.21", null), - new DeprecatedEntry(Ghast.class, "ghast_move_towards_target", "1.21", null), - new DeprecatedEntry(Spellcaster.class, "spellcaster_cast_spell", "1.21", null), - new DeprecatedEntry(TraderLlama.class, "llamatrader_defended_wandering_trader", "1.21", null), - new DeprecatedEntry(Panda.class, "panda_hurt_by_target", "1.21", null), - new DeprecatedEntry(PolarBear.class, "polarbear_attack_players", "1.21", null), - new DeprecatedEntry(PolarBear.class, "polarbear_hurt_by", "1.21", null), - new DeprecatedEntry(PolarBear.class, "polarbear_melee", "1.21", null), - new DeprecatedEntry(PolarBear.class, "polarbear_panic", "1.21", null), - new DeprecatedEntry(Rabbit.class, "eat_carrots", "1.21", null), - new DeprecatedEntry(Rabbit.class, "killer_rabbit_melee_attack", "1.21", null), - new DeprecatedEntry(Rabbit.class, "rabbit_avoid_target", "1.21", null), - new DeprecatedEntry(Raider.class, "raider_hold_ground", "1.21", null), - new DeprecatedEntry(Raider.class, "raider_obtain_banner", "1.21", null), - new DeprecatedEntry(Shulker.class, "shulker_defense", "1.21", null), - new DeprecatedEntry(Shulker.class, "shulker_nearest", "1.21", null), - new DeprecatedEntry(Silverfish.class, "silverfish_hide_in_block", "1.21", null), - new DeprecatedEntry(Silverfish.class, "silverfish_wake_others", "1.21", null), - new DeprecatedEntry(Slime.class, "slime_idle", "1.21", null), - new DeprecatedEntry(Slime.class, "slime_nearest_player", "1.21", null), - new DeprecatedEntry(Slime.class, "slime_random_jump", "1.21", null), - new DeprecatedEntry(Spider.class, "spider_melee_attack", "1.21", null), - new DeprecatedEntry(Spider.class, "spider_nearest_attackable_target", "1.21", null), - new DeprecatedEntry(Squid.class, "squid", "1.21", null), - new DeprecatedEntry(Turtle.class, "turtle_goto_water", "1.21", null), - new DeprecatedEntry(Turtle.class, "turtle_tempt", "1.21", null), - new DeprecatedEntry(Vex.class, "vex_copy_target_of_owner", "1.21", null), - new DeprecatedEntry(WanderingTrader.class, "villagertrader_wander_to_position", "1.21", null), - new DeprecatedEntry(RangedEntity.class, "arrow_attack", "1.21", null), - new DeprecatedEntry(Creature.class, "avoid_target", "1.21", null), - new DeprecatedEntry(Monster.class, "bow_shoot", "1.21", null), - new DeprecatedEntry(Creature.class, "breath", "1.21", null), - new DeprecatedEntry(Cat.class, "cat_sit_on_bed", "1.21", null), - new DeprecatedEntry(Monster.class, "crossbow_attack", "1.21", null), - new DeprecatedEntry(Mob.class, "door_open", "1.21", null), - new DeprecatedEntry(Mob.class, "eat_tile", "1.21", null), - new DeprecatedEntry(Fish.class, "fish_school", "1.21", null), - new DeprecatedEntry(Mob.class, "follow_entity", "1.21", null), - new DeprecatedEntry(SkeletonHorse.class, "horse_trap", "1.21", null), - new DeprecatedEntry(Creature.class, "hurt_by_target", "1.21", null), - new DeprecatedEntry(Cat.class, "jump_on_block", "1.21", null), - new DeprecatedEntry(Mob.class, "leap_at_target", "1.21", null), - new DeprecatedEntry(Llama.class, "llama_follow", "1.21", null), - new DeprecatedEntry(Creature.class, "move_towards_target", "1.21", null), - new DeprecatedEntry(Mob.class, "nearest_attackable_target", "1.21", null), - new DeprecatedEntry(Raider.class, "nearest_attackable_target_witch", "1.21", null), - new DeprecatedEntry(Creature.class, "nearest_village", "1.21", null), - new DeprecatedEntry(Tameable.class, "owner_hurt_by_target", "1.21", null), - new DeprecatedEntry(Tameable.class, "owner_hurt_target", "1.21", null), - new DeprecatedEntry(Parrot.class, "perch", "1.21", null), - new DeprecatedEntry(Raider.class, "raid", "1.21", null), - new DeprecatedEntry(Creature.class, "random_fly", "1.21", null), - new DeprecatedEntry(Mob.class, "random_lookaround", "1.21", null), - new DeprecatedEntry(Creature.class, "random_stroll_land", "1.21", null), - new DeprecatedEntry(Creature.class, "random_swim", "1.21", null), - new DeprecatedEntry(Tameable.class, "random_target_non_tamed", "1.21", null), - new DeprecatedEntry(Tameable.class, "sit", "1.21", null), - new DeprecatedEntry(Creature.class, "stroll_village", "1.21", null), - new DeprecatedEntry(AbstractHorse.class, "tame", "1.21", null), - new DeprecatedEntry(Creature.class, "water", "1.21", null), - new DeprecatedEntry(Dolphin.class, "water_jump", "1.21", null), - new DeprecatedEntry(Creature.class, "stroll_village_golem", "1.21", null), - new DeprecatedEntry(Mob.class, "universal_anger_reset", "1.21", null) - // - }; - public MobGoalGenerator(final String keysClassName, final String pkg) { super(keysClassName, pkg); } @@ -216,26 +127,6 @@ public class MobGoalGenerator extends SimpleGenerator { typeBuilder.addField(fieldBuilder.build()); } - for (final DeprecatedEntry value : DEPRECATED_ENTRIES) { - TypeName typedKey = ParameterizedTypeName.get(GoalKey.class, value.entity); - NamespacedKey key = NamespacedKey.minecraft(value.entryName); - - String keyPath = key.getKey(); - String fieldName = Formatting.formatKeyAsField(keyPath); - FieldSpec.Builder fieldBuilder = FieldSpec.builder(typedKey, fieldName, PUBLIC, STATIC, FINAL) - .addAnnotation(Annotations.deprecatedVersioned(value.removedVersion, value.removalVersion != null)) - .initializer("$N($S, $T.class)", createMethod.build(), keyPath, value.entity); - - if (value.removedVersion != null) { - fieldBuilder.addJavadoc("Removed in $L", value.removedVersion); - } - if (value.removalVersion != null) { - fieldBuilder.addAnnotation(Annotations.scheduledRemoval(value.removalVersion)); - } - - typeBuilder.addField(fieldBuilder.build()); - } - return typeBuilder.addMethod(createMethod.build()).build(); }