Added clover leaf patches, add jars, tweaked food

This commit is contained in:
Matt Caughey 2013-11-14 06:39:11 -05:00
parent be3d2a6e55
commit c31e576bc5
32 changed files with 235 additions and 12 deletions

View File

@ -69,6 +69,8 @@ public class BlockReferences {
bamboo (Blocks.bamboo, 0), bamboo (Blocks.bamboo, 0),
cloverPatchItem (Blocks.foliage, 13),
koruItem (Blocks.foliage, 12),
dryGrassItem (Blocks.foliage, 11), dryGrassItem (Blocks.foliage, 11),
wheatGrassItem (Blocks.foliage, 10), wheatGrassItem (Blocks.foliage, 10),
shrubItem (Blocks.foliage, 9), shrubItem (Blocks.foliage, 9),

View File

@ -64,6 +64,7 @@ import biomesoplenty.worldgen.WorldGenCanyon;
import biomesoplenty.worldgen.WorldGenCanyonGrass; import biomesoplenty.worldgen.WorldGenCanyonGrass;
import biomesoplenty.worldgen.WorldGenCattail; import biomesoplenty.worldgen.WorldGenCattail;
import biomesoplenty.worldgen.WorldGenCloud; import biomesoplenty.worldgen.WorldGenCloud;
import biomesoplenty.worldgen.WorldGenCloverPatch;
import biomesoplenty.worldgen.WorldGenCobwebs; import biomesoplenty.worldgen.WorldGenCobwebs;
import biomesoplenty.worldgen.WorldGenCoral; import biomesoplenty.worldgen.WorldGenCoral;
import biomesoplenty.worldgen.WorldGenCrystal1; import biomesoplenty.worldgen.WorldGenCrystal1;
@ -241,6 +242,7 @@ public class BiomeDecoratorBOP extends BiomeDecorator
public WorldGenerator icyIrisGen; public WorldGenerator icyIrisGen;
public WorldGenerator redwoodShrubGen; public WorldGenerator redwoodShrubGen;
public WorldGenerator koruGen; public WorldGenerator koruGen;
public WorldGenerator cloverPatchGen;
public WorldGenerator waspHiveGen; public WorldGenerator waspHiveGen;
public WorldGenerator rootGen; public WorldGenerator rootGen;
public WorldGenerator stalagmiteGen; public WorldGenerator stalagmiteGen;
@ -344,6 +346,7 @@ public class BiomeDecoratorBOP extends BiomeDecorator
public int waterReedsPerChunk; public int waterReedsPerChunk;
public int redwoodShrubsPerChunk; public int redwoodShrubsPerChunk;
public int koruPerChunk; public int koruPerChunk;
public int cloverPatchesPerChunk;
public int waspHivesPerChunk; public int waspHivesPerChunk;
public int rootsPerChunk; public int rootsPerChunk;
public int stalagmitesPerChunk; public int stalagmitesPerChunk;
@ -559,6 +562,7 @@ public class BiomeDecoratorBOP extends BiomeDecorator
waterReedGen = new WorldGenWaterReeds(); waterReedGen = new WorldGenWaterReeds();
redwoodShrubGen = new WorldGenRedwoodShrub(0,0); redwoodShrubGen = new WorldGenRedwoodShrub(0,0);
koruGen = new WorldGenTallGrass(Blocks.foliage.get().blockID, 12); koruGen = new WorldGenTallGrass(Blocks.foliage.get().blockID, 12);
cloverPatchGen = new WorldGenCloverPatch(Blocks.foliage.get().blockID, 13);
rootGen = new WorldGenBOPTallGrass(Blocks.plants.get().blockID, 15); rootGen = new WorldGenBOPTallGrass(Blocks.plants.get().blockID, 15);
stalagmiteGen = new WorldGenBOPTallGrass(Blocks.stoneFormations.get().blockID, 0); stalagmiteGen = new WorldGenBOPTallGrass(Blocks.stoneFormations.get().blockID, 0);
stalactiteGen = new WorldGenBOPTallGrass(Blocks.stoneFormations.get().blockID, 1); stalactiteGen = new WorldGenBOPTallGrass(Blocks.stoneFormations.get().blockID, 1);
@ -656,6 +660,7 @@ public class BiomeDecoratorBOP extends BiomeDecorator
waterReedsPerChunk = 0; waterReedsPerChunk = 0;
redwoodShrubsPerChunk = 0; redwoodShrubsPerChunk = 0;
koruPerChunk = 0; koruPerChunk = 0;
cloverPatchesPerChunk = 0;
waspHivesPerChunk = 0; waspHivesPerChunk = 0;
rootsPerChunk = 9; rootsPerChunk = 9;
stalagmitesPerChunk = 3; stalagmitesPerChunk = 3;
@ -1343,6 +1348,14 @@ public class BiomeDecoratorBOP extends BiomeDecorator
koruGen.generate(currentWorld, randomGenerator, var3, var4, var5); koruGen.generate(currentWorld, randomGenerator, var3, var4, var5);
} }
for (var2 = 0; var2 < cloverPatchesPerChunk; ++var2)
{
var3 = chunk_X + randomGenerator.nextInt(16) + 8;
var4 = randomGenerator.nextInt(256);
var5 = chunk_Z + randomGenerator.nextInt(16) + 8;
cloverPatchGen.generate(currentWorld, randomGenerator, var3, var4, var5);
}
for (var2 = 0; var2 < rootsPerChunk; ++var2) for (var2 = 0; var2 < rootsPerChunk; ++var2)
{ {
var3 = chunk_X + randomGenerator.nextInt(16) + 8; var3 = chunk_X + randomGenerator.nextInt(16) + 8;

View File

@ -28,6 +28,7 @@ public class BiomeGenBambooForest extends BiomeGenBase implements IWCFog
customBiomeDecorator.reedsBOPPerChunk = 6; customBiomeDecorator.reedsBOPPerChunk = 6;
customBiomeDecorator.wheatGrassPerChunk = 3; customBiomeDecorator.wheatGrassPerChunk = 3;
customBiomeDecorator.shrubsPerChunk = 6; customBiomeDecorator.shrubsPerChunk = 6;
customBiomeDecorator.cloverPatchesPerChunk = 10;
customBiomeDecorator.generatePumpkins = false; customBiomeDecorator.generatePumpkins = false;
} }

View File

@ -26,6 +26,7 @@ public class BiomeGenBirchForest extends BiomeGenBase
customBiomeDecorator.lilyOfTheValleysPerChunk = 15; customBiomeDecorator.lilyOfTheValleysPerChunk = 15;
customBiomeDecorator.wheatGrassPerChunk = 1; customBiomeDecorator.wheatGrassPerChunk = 1;
customBiomeDecorator.shrubsPerChunk = 1; customBiomeDecorator.shrubsPerChunk = 1;
customBiomeDecorator.cloverPatchesPerChunk = 20;
} }
/** /**

View File

@ -27,6 +27,7 @@ public class BiomeGenCherryBlossomGrove extends BiomeGenBase
customBiomeDecorator.lilyflowersPerChunk = 9; customBiomeDecorator.lilyflowersPerChunk = 9;
customBiomeDecorator.wheatGrassPerChunk = 1; customBiomeDecorator.wheatGrassPerChunk = 1;
customBiomeDecorator.shrubsPerChunk = 2; customBiomeDecorator.shrubsPerChunk = 2;
customBiomeDecorator.cloverPatchesPerChunk = 15;
customBiomeDecorator.generatePumpkins = false; customBiomeDecorator.generatePumpkins = false;
} }

View File

@ -43,6 +43,7 @@ public class BiomeGenConiferousForest extends BiomeGenBase
customBiomeDecorator.sandPerChunk2 = -999; customBiomeDecorator.sandPerChunk2 = -999;
customBiomeDecorator.gravelPerChunk = 1; customBiomeDecorator.gravelPerChunk = 1;
customBiomeDecorator.gravelPerChunk2 = 1; customBiomeDecorator.gravelPerChunk2 = 1;
customBiomeDecorator.cloverPatchesPerChunk = 10;
} }
/** /**

View File

@ -44,6 +44,7 @@ public class BiomeGenFungiForest extends BiomeGenBase implements IWCFog
customBiomeDecorator.reedsBOPPerChunk = 1; customBiomeDecorator.reedsBOPPerChunk = 1;
customBiomeDecorator.wheatGrassPerChunk = 3; customBiomeDecorator.wheatGrassPerChunk = 3;
customBiomeDecorator.shrubsPerChunk = 1; customBiomeDecorator.shrubsPerChunk = 1;
customBiomeDecorator.cloverPatchesPerChunk = 20;
customBiomeDecorator.generateMycelium = true; customBiomeDecorator.generateMycelium = true;
customBiomeDecorator.generatePumpkins = true; customBiomeDecorator.generatePumpkins = true;
waterColorMultiplier = 65326; waterColorMultiplier = 65326;

View File

@ -31,6 +31,7 @@ public class BiomeGenGrove extends BiomeGenBase
customBiomeDecorator.lilyflowersPerChunk = 3; customBiomeDecorator.lilyflowersPerChunk = 3;
customBiomeDecorator.berryBushesPerChunk = 2; customBiomeDecorator.berryBushesPerChunk = 2;
customBiomeDecorator.shrubsPerChunk = 3; customBiomeDecorator.shrubsPerChunk = 3;
customBiomeDecorator.cloverPatchesPerChunk = 20;
customBiomeDecorator.generatePumpkins = false; customBiomeDecorator.generatePumpkins = false;
} }

View File

@ -36,6 +36,7 @@ public class BiomeGenLushSwamp extends BiomeGenBase
customBiomeDecorator.shrubsPerChunk = 5; customBiomeDecorator.shrubsPerChunk = 5;
customBiomeDecorator.koruPerChunk = 1; customBiomeDecorator.koruPerChunk = 1;
customBiomeDecorator.waterReedsPerChunk = 6; customBiomeDecorator.waterReedsPerChunk = 6;
customBiomeDecorator.cloverPatchesPerChunk = 10;
spawnableMonsterList.add(new SpawnListEntry(EntitySlime.class, 1, 1, 1)); spawnableMonsterList.add(new SpawnListEntry(EntitySlime.class, 1, 1, 1));
} }

View File

@ -33,6 +33,7 @@ public class BiomeGenMeadow extends BiomeGenBase
customBiomeDecorator.hydrangeasPerChunk = 3; customBiomeDecorator.hydrangeasPerChunk = 3;
customBiomeDecorator.sunflowersPerChunk = 1; customBiomeDecorator.sunflowersPerChunk = 1;
customBiomeDecorator.shrubsPerChunk = 5; customBiomeDecorator.shrubsPerChunk = 5;
customBiomeDecorator.cloverPatchesPerChunk = 15;
customBiomeDecorator.generatePumpkins = false; customBiomeDecorator.generatePumpkins = false;
spawnableCreatureList.add(new SpawnListEntry(EntityHorse.class, 5, 2, 6)); spawnableCreatureList.add(new SpawnListEntry(EntityHorse.class, 5, 2, 6));
} }

View File

@ -27,6 +27,7 @@ public class BiomeGenMeadowForest extends BiomeGenBase
customBiomeDecorator.sandPerChunk = -999; customBiomeDecorator.sandPerChunk = -999;
customBiomeDecorator.sandPerChunk2 = -999; customBiomeDecorator.sandPerChunk2 = -999;
customBiomeDecorator.hydrangeasPerChunk = 3; customBiomeDecorator.hydrangeasPerChunk = 3;
customBiomeDecorator.cloverPatchesPerChunk = 10;
customBiomeDecorator.generatePumpkins = true; customBiomeDecorator.generatePumpkins = true;
} }

View File

@ -50,6 +50,7 @@ public class BiomeGenMysticGrove extends BiomeGenBase implements IWCFog
customBiomeDecorator.blueMilksPerChunk = 1; customBiomeDecorator.blueMilksPerChunk = 1;
customBiomeDecorator.lilyflowersPerChunk = 3; customBiomeDecorator.lilyflowersPerChunk = 3;
customBiomeDecorator.poisonWaterPerChunk = 1; customBiomeDecorator.poisonWaterPerChunk = 1;
customBiomeDecorator.cloverPatchesPerChunk = 10;
waterColorMultiplier = 16715898; waterColorMultiplier = 16715898;
spawnableMonsterList.clear(); spawnableMonsterList.clear();
spawnableCreatureList.clear(); spawnableCreatureList.clear();

View File

@ -50,6 +50,7 @@ public class BiomeGenMysticGroveThin extends BiomeGenBase implements IWCFog
customBiomeDecorator.blueMilksPerChunk = 1; customBiomeDecorator.blueMilksPerChunk = 1;
customBiomeDecorator.lilyflowersPerChunk = 3; customBiomeDecorator.lilyflowersPerChunk = 3;
customBiomeDecorator.poisonWaterPerChunk = 1; customBiomeDecorator.poisonWaterPerChunk = 1;
customBiomeDecorator.cloverPatchesPerChunk = 20;
waterColorMultiplier = 16715898; waterColorMultiplier = 16715898;
spawnableMonsterList.clear(); spawnableMonsterList.clear();
spawnableCreatureList.clear(); spawnableCreatureList.clear();

View File

@ -33,6 +33,7 @@ public class BiomeGenOrchard extends BiomeGenBase
customBiomeDecorator.carrotsPerChunk = 1; customBiomeDecorator.carrotsPerChunk = 1;
customBiomeDecorator.shrubsPerChunk = 10; customBiomeDecorator.shrubsPerChunk = 10;
customBiomeDecorator.waterReedsPerChunk = 4; customBiomeDecorator.waterReedsPerChunk = 4;
customBiomeDecorator.cloverPatchesPerChunk = 15;
spawnableCreatureList.add(new SpawnListEntry(EntityHorse.class, 5, 2, 6)); spawnableCreatureList.add(new SpawnListEntry(EntityHorse.class, 5, 2, 6));
} }

View File

@ -33,6 +33,7 @@ public class BiomeGenRainforest extends BiomeGenBase
customBiomeDecorator.wheatGrassPerChunk = 10; customBiomeDecorator.wheatGrassPerChunk = 10;
customBiomeDecorator.shrubsPerChunk = 5; customBiomeDecorator.shrubsPerChunk = 5;
customBiomeDecorator.generatePumpkins = false; customBiomeDecorator.generatePumpkins = false;
customBiomeDecorator.cloverPatchesPerChunk = 20;
spawnableMonsterList.add(new SpawnListEntry(EntityOcelot.class, 2, 1, 1)); spawnableMonsterList.add(new SpawnListEntry(EntityOcelot.class, 2, 1, 1));
spawnableMonsterList.add(new SpawnListEntry(EntityJungleSpider.class, 12, 6, 6)); spawnableMonsterList.add(new SpawnListEntry(EntityJungleSpider.class, 12, 6, 6));
} }

View File

@ -48,6 +48,7 @@ public class BiomeGenWetland extends BiomeGenBase implements IWCFog
customBiomeDecorator.shrubsPerChunk = 10; customBiomeDecorator.shrubsPerChunk = 10;
customBiomeDecorator.waterReedsPerChunk = 8; customBiomeDecorator.waterReedsPerChunk = 8;
customBiomeDecorator.koruPerChunk = 1; customBiomeDecorator.koruPerChunk = 1;
customBiomeDecorator.cloverPatchesPerChunk = 15;
spawnableCreatureList.clear(); spawnableCreatureList.clear();
spawnableWaterCreatureList.clear(); spawnableWaterCreatureList.clear();
spawnableMonsterList.add(new SpawnListEntry(EntitySlime.class, 10, 1, 3)); spawnableMonsterList.add(new SpawnListEntry(EntitySlime.class, 10, 1, 3));

View File

@ -24,6 +24,7 @@ public class BiomeGenWoodland extends BiomeGenBase
customBiomeDecorator.toadstoolsPerChunk = 3; customBiomeDecorator.toadstoolsPerChunk = 3;
customBiomeDecorator.shrubsPerChunk = 20; customBiomeDecorator.shrubsPerChunk = 20;
customBiomeDecorator.waterReedsPerChunk = 2; customBiomeDecorator.waterReedsPerChunk = 2;
customBiomeDecorator.cloverPatchesPerChunk = 10;
} }
@Override @Override

View File

@ -27,9 +27,9 @@ public class BiomeGenPromisedLandShrub extends BiomeGenBase implements IWCFog
customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator; customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
topBlock = (byte)Blocks.holyGrass.get().blockID; topBlock = (byte)Blocks.holyGrass.get().blockID;
fillerBlock = (byte)Blocks.holyDirt.get().blockID; fillerBlock = (byte)Blocks.holyDirt.get().blockID;
customBiomeDecorator.treesPerChunk = 50; customBiomeDecorator.treesPerChunk = 40;
customBiomeDecorator.grassPerChunk = -999; customBiomeDecorator.grassPerChunk = -999;
customBiomeDecorator.holyTallGrassPerChunk = 10; customBiomeDecorator.holyTallGrassPerChunk = 50;
customBiomeDecorator.promisedWillowPerChunk = 80; customBiomeDecorator.promisedWillowPerChunk = 80;
customBiomeDecorator.rainbowflowersPerChunk = 5; customBiomeDecorator.rainbowflowersPerChunk = 5;
customBiomeDecorator.generateLakes = false; customBiomeDecorator.generateLakes = false;

View File

@ -38,7 +38,7 @@ import cpw.mods.fml.relauncher.SideOnly;
public class BlockBOPFoliage extends BlockFlower implements IShearable public class BlockBOPFoliage extends BlockFlower implements IShearable
{ {
private static final String[] foliageTypes = new String[] {"algae", "shortgrass", "mediumgrass", "highgrassbottom", "bush", "sprout", "highgrasstop", "poisonivy", "berrybush", "shrub", "wheatgrass", "dampgrass", "koru"}; private static final String[] foliageTypes = new String[] {"algae", "shortgrass", "mediumgrass", "highgrassbottom", "bush", "sprout", "highgrasstop", "poisonivy", "berrybush", "shrub", "wheatgrass", "dampgrass", "koru", "cloverpatch"};
private Icon[] textures; private Icon[] textures;
public Icon shrubBranch; public Icon shrubBranch;
@ -281,6 +281,9 @@ public class BlockBOPFoliage extends BlockFlower implements IShearable
case 2: // Medium Grass case 2: // Medium Grass
return AxisAlignedBB.getBoundingBox(x + 0.1D, y, z + 0.1D, x + 0.9D, y + 0.6D, z + 0.9D); return AxisAlignedBB.getBoundingBox(x + 0.1D, y, z + 0.1D, x + 0.9D, y + 0.6D, z + 0.9D);
case 13: //Clover Patch
return AxisAlignedBB.getBoundingBox(x, y, z, x + 1.0D, y + 0.015625D, z + 1.0D);
default: default:
return AxisAlignedBB.getBoundingBox(x + 0.1D, y, z + 0.1D, x + 0.9D, y + 0.8D, z + 0.9D); return AxisAlignedBB.getBoundingBox(x + 0.1D, y, z + 0.1D, x + 0.9D, y + 0.8D, z + 0.9D);
@ -320,6 +323,12 @@ public class BlockBOPFoliage extends BlockFlower implements IShearable
maxX = maxZ = 0.9F; maxX = maxZ = 0.9F;
maxY = 0.6F; maxY = 0.6F;
break; break;
case 13:
minX = minY = minZ = 0F;
maxX = maxZ = 1.0F;
maxY = 0.015625F;
break;
default: default:
minX = minZ = 0.1F; minX = minZ = 0.1F;

View File

@ -27,10 +27,22 @@ public class FoliageRenderer implements ISimpleBlockRenderingHandler
if (modelId == RenderUtils.foliageModel) if (modelId == RenderUtils.foliageModel)
{ {
if (meta == 0) if (block == Blocks.foliage.get())
return renderBlockAlgae(renderer, block, x, y, z); {
if (meta == 0)
return renderBlockAlgae(renderer, block, x, y, z);
else if (meta == 13)
return renderBlockClover(renderer, block, x, y, z);
else
return renderCrossedSquares(block, x, y, z, renderer);
}
else else
return renderCrossedSquares(block, x, y, z, renderer); {
if (meta == 0)
return renderBlockAlgae(renderer, block, x, y, z);
else
return renderCrossedSquares(block, x, y, z, renderer);
}
} }
return true; return true;
} }
@ -98,6 +110,58 @@ public class FoliageRenderer implements ISimpleBlockRenderingHandler
tessellator.addVertexWithUV((double)(f1 + f3 - f4), (double)((float)y + f), (double)(f2 + f3 + f4), d0, d1); tessellator.addVertexWithUV((double)(f1 + f3 - f4), (double)((float)y + f), (double)(f2 + f3 + f4), d0, d1);
return true; return true;
} }
public boolean renderBlockClover(RenderBlocks renderer, Block block, int x, int y, int z)
{
Tessellator tessellator = Tessellator.instance;
Icon icon = renderer.getBlockIconFromSideAndMetadata(block, 1, 13);
if (renderer.hasOverrideBlockTexture())
{
icon = renderer.overrideBlockTexture;
}
float cf = 1.0F;
int cl = block.colorMultiplier(renderer.blockAccess, x, y, z);
float c1 = (cl >> 16 & 255) / 255.0F;
float c2 = (cl >> 8 & 255) / 255.0F;
float c3 = (cl & 255) / 255.0F;
if (EntityRenderer.anaglyphEnable)
{
float f4 = (c1 * 30.0F + c2 * 59.0F + c3 * 11.0F) / 100.0F;
float f5 = (c1 * 30.0F + c2 * 70.0F) / 100.0F;
float f6 = (c1 * 30.0F + c3 * 70.0F) / 100.0F;
c1 = f4;
c2 = f5;
c3 = f6;
}
tessellator.setColorOpaque_F(cf * c1, cf * c2, cf * c3);
float f = 0.1F;
double d0 = (double)icon.getMinU();
double d1 = (double)icon.getMinV();
double d2 = (double)icon.getMaxU();
double d3 = (double)icon.getMaxV();
long l = (long)(x * 3129871) ^ (long)z * 116129781L ^ (long)y;
l = l * l * 42317861L + l * 11L;
int i1 = (int)(l >> 16 & 3L);
tessellator.setBrightness(block.getMixedBrightnessForBlock(renderer.blockAccess, x, y, z));
float f1 = (float)x + 0.5F;
float f2 = (float)z + 0.5F;
float f3 = (float)(i1 & 1) * 0.5F * (float)(1 - i1 / 2 % 2 * 2);
float f4 = (float)(i1 + 1 & 1) * 0.5F * (float)(1 - (i1 + 1) / 2 % 2 * 2);
tessellator.addVertexWithUV((double)(f1 + f3 - f4), (double)((float)y + f), (double)(f2 + f3 + f4), d0, d1);
tessellator.addVertexWithUV((double)(f1 + f3 + f4), (double)((float)y + f), (double)(f2 - f3 + f4), d2, d1);
tessellator.addVertexWithUV((double)(f1 - f3 + f4), (double)((float)y + f), (double)(f2 - f3 - f4), d2, d3);
tessellator.addVertexWithUV((double)(f1 - f3 - f4), (double)((float)y + f), (double)(f2 + f3 - f4), d0, d3);
tessellator.addVertexWithUV((double)(f1 - f3 - f4), (double)((float)y + f), (double)(f2 + f3 - f4), d0, d3);
tessellator.addVertexWithUV((double)(f1 - f3 + f4), (double)((float)y + f), (double)(f2 - f3 - f4), d2, d3);
tessellator.addVertexWithUV((double)(f1 + f3 + f4), (double)((float)y + f), (double)(f2 - f3 + f4), d2, d1);
tessellator.addVertexWithUV((double)(f1 + f3 - f4), (double)((float)y + f), (double)(f2 + f3 + f4), d0, d1);
return true;
}
private boolean renderCrossedSquares(Block par1Block, int par2, int par3, int par4, RenderBlocks renderer) private boolean renderCrossedSquares(Block par1Block, int par2, int par3, int par4, RenderBlocks renderer)
{ {

View File

@ -259,7 +259,7 @@ public class BOPCrafting
{ {
GameRegistry.addRecipe(new ItemStack(Items.dartBlower.get(), 1), new Object[] {"R R", "R R", "R R", Character.valueOf('R'), new ItemStack(Blocks.plants.get(), 1, 8)}); GameRegistry.addRecipe(new ItemStack(Items.dartBlower.get(), 1), new Object[] {"R R", "R R", "R R", Character.valueOf('R'), new ItemStack(Blocks.plants.get(), 1, 8)});
GameRegistry.addRecipe(new ItemStack(Items.dart.get(), 4, 0), new Object[] {"T", "R", "F", Character.valueOf('T'), new ItemStack(Blocks.plants.get(), 1, 5), Character.valueOf('R'), new ItemStack(Blocks.plants.get(), 1, 8), Character.valueOf('F'), Item.feather}); GameRegistry.addRecipe(new ItemStack(Items.dart.get(), 4, 0), new Object[] {"T", "R", "F", Character.valueOf('T'), new ItemStack(Blocks.plants.get(), 1, 5), Character.valueOf('R'), new ItemStack(Blocks.plants.get(), 1, 8), Character.valueOf('F'), Item.feather});
GameRegistry.addRecipe(new ItemStack(Items.dart.get(), 1, 1), new Object[] {"P", "D", Character.valueOf('P'), new ItemStack(Items.miscItems.get(), 1, 3), Character.valueOf('D'), new ItemStack(Items.dart.get(), 1, 0)}); GameRegistry.addShapelessRecipe(new ItemStack(Items.dart.get(), 1, 1), new Object[] {new ItemStack(Items.miscItems.get(), 1, 13), new ItemStack(Items.dart.get(), 1, 0)});
} }
@ -287,7 +287,7 @@ public class BOPCrafting
//Plants //Plants
GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 2, 1), new Object[] {new ItemStack(Blocks.mushrooms.get(),1,0)}); GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 2, 1), new Object[] {new ItemStack(Blocks.mushrooms.get(),1,0)});
GameRegistry.addShapelessRecipe(new ItemStack(Items.miscItems.get(), 1, 3), new Object[] {new ItemStack(Blocks.foliage.get(),1,7)}); GameRegistry.addShapelessRecipe(new ItemStack(Items.miscItems.get(), 1, 13), new Object[] {new ItemStack(Blocks.foliage.get(),1,7), new ItemStack(Items.miscItems.get(),1, 11)});
GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 4), new Object[] {Item.bowlEmpty, new ItemStack(Items.food.get(), 1, 0), Item.appleRed, Item.melon}); GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 4), new Object[] {Item.bowlEmpty, new ItemStack(Items.food.get(), 1, 0), Item.appleRed, Item.melon});
GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 5), new Object[] {Item.bowlEmpty, new ItemStack(Items.food.get(), 1, 2), Item.carrot, Item.potato}); GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 5), new Object[] {Item.bowlEmpty, new ItemStack(Items.food.get(), 1, 2), Item.carrot, Item.potato});
GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 6), new Object[] {Item.bowlEmpty, new ItemStack(Blocks.mushrooms.get(), 1, 0), new ItemStack(Blocks.mushrooms.get(), 1, 1), new ItemStack(Blocks.mushrooms.get(), 1, 2)}); GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 6), new Object[] {Item.bowlEmpty, new ItemStack(Blocks.mushrooms.get(), 1, 0), new ItemStack(Blocks.mushrooms.get(), 1, 1), new ItemStack(Blocks.mushrooms.get(), 1, 2)});

View File

@ -17,7 +17,7 @@ import cpw.mods.fml.relauncher.SideOnly;
public class ItemBlockFoliage extends ItemColored public class ItemBlockFoliage extends ItemColored
{ {
private static final String[] foliageTypes = new String[] {"algae", "shortgrass", "mediumgrass", "highgrassbottom", "bush", "sprout", "highgrasstop", "poisonivy", "berrybush", "shrub", "wheatgrass", "dampgrass", "koru"}; private static final String[] foliageTypes = new String[] {"algae", "shortgrass", "mediumgrass", "highgrassbottom", "bush", "sprout", "highgrasstop", "poisonivy", "berrybush", "shrub", "wheatgrass", "dampgrass", "koru", "cloverpatch"};
@SideOnly(Side.CLIENT) @SideOnly(Side.CLIENT)
private Icon[] textures; private Icon[] textures;
private static final int GRASSTOP = 6; private static final int GRASSTOP = 6;

View File

@ -8,12 +8,13 @@ import net.minecraft.item.Item;
import net.minecraft.item.ItemStack; import net.minecraft.item.ItemStack;
import net.minecraft.util.Icon; import net.minecraft.util.Icon;
import biomesoplenty.BiomesOPlenty; import biomesoplenty.BiomesOPlenty;
import biomesoplenty.api.Items;
import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly; import cpw.mods.fml.relauncher.SideOnly;
public class ItemBOP extends Item public class ItemBOP extends Item
{ {
private static String[] items = {"mudbrick", "ash", "emptyhoneycomb", "poison", "crystalshard", "bluedye", "browndye", "greendye", "whitedye", "blackdye", "ghastlysoul"}; private static String[] items = {"mudbrick", "ash", "emptyhoneycomb", "thing", "crystalshard", "bluedye", "browndye", "greendye", "whitedye", "blackdye", "ghastlysoul", "jarempty", "jarhoney", "jarpoison"};
@SideOnly(Side.CLIENT) @SideOnly(Side.CLIENT)
private Icon[] textures; private Icon[] textures;
@ -55,6 +56,25 @@ public class ItemBOP extends Item
return textures[meta]; return textures[meta];
} }
@Override
public int getItemStackLimit(ItemStack par1ItemStack)
{
if (par1ItemStack.itemID == this.itemID && par1ItemStack.getItemDamage() == 11)
{
return 1;
}
if (par1ItemStack.itemID == this.itemID && par1ItemStack.getItemDamage() == 12)
{
return 1;
}
if (par1ItemStack.itemID == this.itemID && par1ItemStack.getItemDamage() == 13)
{
return 1;
}
return 64;
}
@SuppressWarnings({ "rawtypes", "unchecked" }) @SuppressWarnings({ "rawtypes", "unchecked" })
@Override @Override

View File

@ -5,6 +5,7 @@ import java.util.List;
import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.creativetab.CreativeTabs; import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.EnumAction;
import net.minecraft.item.Item; import net.minecraft.item.Item;
import net.minecraft.item.ItemFood; import net.minecraft.item.ItemFood;
import net.minecraft.item.ItemStack; import net.minecraft.item.ItemStack;
@ -110,6 +111,62 @@ public class ItemBOPFood extends ItemFood
return itemstack; return itemstack;
} }
/**
* returns the action that specifies what animation to play when the items is being used
*/
public EnumAction getItemUseAction(ItemStack par1ItemStack)
{
if (par1ItemStack.itemID == this.itemID && par1ItemStack.getItemDamage() == 10)
{
return EnumAction.drink;
}
return EnumAction.eat;
}
@Override
public int getItemStackLimit(ItemStack par1ItemStack)
{
if (par1ItemStack.itemID == this.itemID && par1ItemStack.getItemDamage() == 4)
{
return 1;
}
if (par1ItemStack.itemID == this.itemID && par1ItemStack.getItemDamage() == 5)
{
return 1;
}
if (par1ItemStack.itemID == this.itemID && par1ItemStack.getItemDamage() == 6)
{
return 1;
}
return 64;
}
/**
* How long it takes to use or consume an item
*/
@Override
public int getMaxItemUseDuration(ItemStack par1ItemStack)
{
if (par1ItemStack.itemID == this.itemID && par1ItemStack.getItemDamage() == 0)
{
return 8;
}
if (par1ItemStack.itemID == this.itemID && par1ItemStack.getItemDamage() == 3)
{
return 12;
}
if (par1ItemStack.itemID == this.itemID && par1ItemStack.getItemDamage() == 9)
{
return 16;
}
return 32;
}
@Override @Override
protected void onFoodEaten(ItemStack itemstack, World world, EntityPlayer player) protected void onFoodEaten(ItemStack itemstack, World world, EntityPlayer player)
{ {

View File

@ -12,7 +12,7 @@ public class WorldGenCloud extends WorldGenerator
@Override @Override
public boolean generate(World par1World, Random par2Random, int par3, int par4, int par5) public boolean generate(World par1World, Random par2Random, int par3, int par4, int par5)
{ {
int var998 = par2Random.nextInt(7); int var998 = par2Random.nextInt(10);
if (var998 != 0) if (var998 != 0)
{ {

View File

@ -0,0 +1,40 @@
package biomesoplenty.worldgen;
import java.util.Random;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import net.minecraft.world.gen.feature.WorldGenerator;
public class WorldGenCloverPatch extends WorldGenerator
{
/** The ID of the plant block used in this plant generator. */
private int plantBlockId;
private int plantBlockMeta;
public WorldGenCloverPatch(int par1, int meta)
{
plantBlockId = par1;
plantBlockMeta = meta;
}
@Override
public boolean generate(World par1World, Random par2Random, int par3, int par4, int par5)
{
for (int l = 0; l < 128; ++l)
{
int i1 = par3 + par2Random.nextInt(6) - par2Random.nextInt(6);
int j1 = par4;
int k1 = par5 + par2Random.nextInt(6) - par2Random.nextInt(6);
if (par1World.isAirBlock(i1, j1, k1) && (!par1World.provider.hasNoSky || j1 < 127) && (par1World.getFullBlockLightValue(i1, j1, k1) >= 8 || par1World.canBlockSeeTheSky(i1, j1, k1))
&& Block.blocksList[plantBlockId].canPlaceBlockOnSide(par1World, i1, j1, k1, 1, new ItemStack(plantBlockId, 1, plantBlockMeta)))
{
par1World.setBlock(i1, j1, k1, plantBlockId, plantBlockMeta, 2);
}
}
return true;
}
}

View File

@ -76,6 +76,7 @@ tile.bop.foliage.shrub.name=Shrub
tile.bop.foliage.wheatgrass.name=Wheat Grass tile.bop.foliage.wheatgrass.name=Wheat Grass
tile.bop.foliage.dampgrass.name=Damp Grass tile.bop.foliage.dampgrass.name=Damp Grass
tile.bop.foliage.koru.name=Koru tile.bop.foliage.koru.name=Koru
tile.bop.foliage.cloverpatch.name=Clover Patch
tile.bop.petals.bigflowerred.name=Giant Red Flower tile.bop.petals.bigflowerred.name=Giant Red Flower
tile.bop.petals.bigfloweryellow.name=Giant Yellow Flower tile.bop.petals.bigfloweryellow.name=Giant Yellow Flower
@ -307,7 +308,6 @@ item.bop.mudball.name=Mud Ball
item.bop.miscItems.mudbrick.name=Mud Brick item.bop.miscItems.mudbrick.name=Mud Brick
item.bop.miscItems.ash.name=Pile of Ashes item.bop.miscItems.ash.name=Pile of Ashes
item.bop.miscItems.poison.name=Poison
item.bop.miscItems.emptyhoneycomb.name=Empty Honeycomb item.bop.miscItems.emptyhoneycomb.name=Empty Honeycomb
item.bop.miscItems.crystalshard.name=Celestial Crystal Shard item.bop.miscItems.crystalshard.name=Celestial Crystal Shard
item.bop.miscItems.bluedye.name=Blue Dye item.bop.miscItems.bluedye.name=Blue Dye
@ -316,6 +316,9 @@ item.bop.miscItems.greendye.name=Green Dye
item.bop.miscItems.whitedye.name=White Dye item.bop.miscItems.whitedye.name=White Dye
item.bop.miscItems.blackdye.name=Black Dye item.bop.miscItems.blackdye.name=Black Dye
item.bop.miscItems.ghastlysoul.name=Ghastly Soul item.bop.miscItems.ghastlysoul.name=Ghastly Soul
item.bop.miscItems.jarempty.name=Empty Jar
item.bop.miscItems.jarhoney.name=Honey Jar
item.bop.miscItems.jarpoison.name=Poison Extract Jar
item.bop.gems.amethyst.name=Amethyst item.bop.gems.amethyst.name=Amethyst
item.bop.gems.ruby.name=Ruby item.bop.gems.ruby.name=Ruby

Binary file not shown.

Before

Width:  |  Height:  |  Size: 467 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 591 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 299 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 303 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 303 B