MCPcopy Create free account
hub / github.com/DGVPSH/SlackOpen / getSubItems

Method getSubItems

src/main/java/net/minecraft/item/ItemBanner.java:141–153  ·  view source on GitHub ↗

returns a list of items with the same ID, but different meta (eg: dye returns 16 items) @param subItems The List of sub-items. This is a List of ItemStacks.

(Item itemIn, CreativeTabs tab, List<ItemStack> subItems)

Source from the content-addressed store, hash-verified

139 * @param subItems The List of sub-items. This is a List of ItemStacks.
140 */
141 public void getSubItems(Item itemIn, CreativeTabs tab, List<ItemStack> subItems)
142 {
143 for (EnumDyeColor enumdyecolor : EnumDyeColor.values())
144 {
145 NBTTagCompound nbttagcompound = new NBTTagCompound();
146 TileEntityBanner.func_181020_a(nbttagcompound, enumdyecolor.getDyeDamage(), null);
147 NBTTagCompound nbttagcompound1 = new NBTTagCompound();
148 nbttagcompound1.setTag("BlockEntityTag", nbttagcompound);
149 ItemStack itemstack = new ItemStack(itemIn, 1, enumdyecolor.getDyeDamage());
150 itemstack.setTagCompound(nbttagcompound1);
151 subItems.add(itemstack);
152 }
153 }
154
155 /**
156 * gets the CreativeTab this item is displayed on

Callers

nothing calls this directly

Calls 6

func_181020_aMethod · 0.95
setTagMethod · 0.95
setTagCompoundMethod · 0.95
valuesMethod · 0.80
getDyeDamageMethod · 0.80
addMethod · 0.45

Tested by

no test coverage detected