mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-19 11:59:25 +00:00
Both update patches scripts no longer remove svn entries. Added the forge_client\bin and forge_server\bin folders to the svn ignore.
49 lines
1.7 KiB
Diff
49 lines
1.7 KiB
Diff
--- ../src_base/minecraft/net/minecraft/src/BlockCrops.java 0000-00-00 00:00:00.000000000 -0000
|
|
+++ ../src_work/minecraft/net/minecraft/src/BlockCrops.java 0000-00-00 00:00:00.000000000 -0000
|
|
@@ -5,6 +5,7 @@
|
|
package net.minecraft.src;
|
|
|
|
import java.util.Random;
|
|
+import java.util.ArrayList;
|
|
|
|
// Referenced classes of package net.minecraft.src:
|
|
// BlockFlower, Block, World, EntityItem,
|
|
@@ -108,27 +109,16 @@
|
|
return 6;
|
|
}
|
|
|
|
- public void dropBlockAsItemWithChance(World world, int i, int j, int k, int l, float f)
|
|
- {
|
|
- super.dropBlockAsItemWithChance(world, i, j, k, l, f);
|
|
- if(world.multiplayerWorld)
|
|
- {
|
|
- return;
|
|
- }
|
|
- for(int i1 = 0; i1 < 3; i1++)
|
|
- {
|
|
- if(world.rand.nextInt(15) <= l)
|
|
- {
|
|
- float f1 = 0.7F;
|
|
- float f2 = world.rand.nextFloat() * f1 + (1.0F - f1) * 0.5F;
|
|
- float f3 = world.rand.nextFloat() * f1 + (1.0F - f1) * 0.5F;
|
|
- float f4 = world.rand.nextFloat() * f1 + (1.0F - f1) * 0.5F;
|
|
- EntityItem entityitem = new EntityItem(world, (float)i + f2, (float)j + f3, (float)k + f4, new ItemStack(Item.seeds));
|
|
- entityitem.delayBeforeCanPickup = 10;
|
|
- world.entityJoinedWorld(entityitem);
|
|
- }
|
|
- }
|
|
-
|
|
+ public ArrayList<ItemStack> getBlockDropped(World world,
|
|
+ int i, int j, int k, int md) {
|
|
+ ArrayList<ItemStack> tr=new ArrayList<ItemStack>();
|
|
+ if(md==7) tr.add(new ItemStack(Item.wheat));
|
|
+
|
|
+ for(int n=0; n<3; n++) {
|
|
+ if(world.rand.nextInt(15) <= md)
|
|
+ tr.add(new ItemStack(Item.seeds));
|
|
+ }
|
|
+ return tr;
|
|
}
|
|
|
|
public int idDropped(int i, Random random)
|