From 28d29d392792ce005e91be2c76fd796190166fdc Mon Sep 17 00:00:00 2001 From: zml2008 Date: Sat, 14 Jan 2012 18:03:54 -0800 Subject: [PATCH] Added the spawn egg from 1.1 --- src/main/java/com/sk89q/worldedit/blocks/ItemID.java | 5 +++-- src/main/java/com/sk89q/worldedit/blocks/ItemType.java | 6 ++++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/sk89q/worldedit/blocks/ItemID.java b/src/main/java/com/sk89q/worldedit/blocks/ItemID.java index d7301e0aa..b591a41aa 100644 --- a/src/main/java/com/sk89q/worldedit/blocks/ItemID.java +++ b/src/main/java/com/sk89q/worldedit/blocks/ItemID.java @@ -152,8 +152,9 @@ public final class ItemID { public static final int CAULDRON = 380; public static final int EYE_OF_ENDER = 381; public static final int GLISTERING_MELON = 382; - public static final int GOLD_RECORD = 2256; // deprecated, but leave it there - public static final int GREEN_RECORD = 2257; // deprecated, but leave it there + public static final int SPAWN_EGG = 383; + @Deprecated public static final int GOLD_RECORD = 2256; // deprecated, but leave it there + @Deprecated public static final int GREEN_RECORD = 2257; // deprecated, but leave it there public static final int DISC_13 = 2256; public static final int DISC_CAT = 2257; public static final int DISC_BLOCKS = 2258; diff --git a/src/main/java/com/sk89q/worldedit/blocks/ItemType.java b/src/main/java/com/sk89q/worldedit/blocks/ItemType.java index 96ad3538c..69b94db6c 100644 --- a/src/main/java/com/sk89q/worldedit/blocks/ItemType.java +++ b/src/main/java/com/sk89q/worldedit/blocks/ItemType.java @@ -288,6 +288,7 @@ public enum ItemType { CAULDRON_ITEM(ItemID.CAULDRON, "Cauldron", "cauldron"), EYE_OF_ENDER(ItemID.EYE_OF_ENDER, "Eye of Ender", "eyeofender", "endereye"), GLISTERING_MELON(ItemID.GLISTERING_MELON, "Glistering Melon", "glisteringmelon", "goldmelon"), + SPAWN_EGG(ItemID.SPAWN_EGG, "Spawn Egg", "spawnegg", "spawn", "mobspawnegg"), DISC_13(ItemID.DISC_13, "Music Disc - 13", "disc_13"), DISC_CAT(ItemID.DISC_CAT, "Music Disc - Cat", "disc_cat"), DISC_BLOCKS(ItemID.DISC_BLOCKS, "Music Disc - blocks", "disc_blocks"), @@ -301,8 +302,8 @@ public enum ItemType { DISC_11(ItemID.DISC_11, "Music Disc - 11", "disc_11"), // deprecated - GOLD_RECORD(ItemID.GOLD_RECORD, "Gold Record", "goldrecord", "golddisc"), - GREEN_RECORD(ItemID.GREEN_RECORD, "Green Record", "greenrecord", "greenddisc"); + @Deprecated GOLD_RECORD(ItemID.GOLD_RECORD, "Gold Record", "goldrecord", "golddisc"), + @Deprecated GREEN_RECORD(ItemID.GREEN_RECORD, "Green Record", "greenrecord", "greenddisc"); /** * Stores a map of the IDs for fast access. @@ -631,6 +632,7 @@ public enum ItemType { usesDamageValue.add(ItemID.INK_SACK); usesDamageValue.add(ItemID.POTION); usesDamageValue.add(ItemID.GLASS_BOTTLE); + usesDamageValue.add(ItemID.SPAWN_EGG); } /**