Posted October 26, 201410 yr How do i make a block drop 1-3 items (randomly) I have this code for dropping items @Override public ArrayList<ItemStack> getDrops(World world, int x, int y, int z, int metadata, int fortune) { ArrayList<ItemStack> items = new ArrayList<ItemStack>(); items.add(new ItemStack(InitItem.StrawberrySeed)); items.add(new ItemStack(InitItem.Strawberry)); return items; }
October 26, 201410 yr Use an instance of Random. BEFORE ASKING FOR HELP READ THE EAQ! I'll help if I can. Apologies if I do something obviously stupid. If you don't know basic Java yet, go and follow these tutorials.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.