Fixed #293 - Hand crank causing inability to make large gears
This commit is contained in:
parent
74d1609640
commit
14131914b3
5 changed files with 18 additions and 23 deletions
|
@ -53,8 +53,7 @@ allprojects {
|
|||
url = "http://files.minecraftforge.net/maven"
|
||||
}
|
||||
ivy {
|
||||
name 'CB FS'
|
||||
artifactPattern "http://files.minecraftforge.net/[module]/[module]-dev-[revision].[ext]"
|
||||
artifactPattern "http://www.chickenbones.craftsaddle.org/Files/New_Versions/1.6.4/[module]-dev%20[revision].[ext]"
|
||||
}
|
||||
mavenCentral()
|
||||
}
|
||||
|
@ -64,6 +63,7 @@ allprojects {
|
|||
compile group: 'calclaviacore', name: 'calclavia-core', version: "${rootProject.config.version.calclaviacore}", classifier: "dev"
|
||||
compile name: 'CodeChickenLib', version: "${config.version.minecraft}-${config.version.cclib}", ext: 'jar'
|
||||
compile name: 'ForgeMultipart', version: "${config.version.minecraft}-${config.version.fmp}", ext: 'jar'
|
||||
compile name: 'NotEnoughItems', version: "${config.version.nei}", ext: 'jar'
|
||||
}
|
||||
|
||||
jar {
|
||||
|
|
|
@ -115,15 +115,19 @@ public class PartGear extends PartMechanical implements IMechanical, IMultiBlock
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean activate(EntityPlayer player, MovingObjectPosition hit, ItemStack item)
|
||||
public boolean activate(EntityPlayer player, MovingObjectPosition hit, ItemStack itemStack)
|
||||
{
|
||||
if (item != null && item.getItem() instanceof ItemHandCrank)
|
||||
if (itemStack != null && itemStack.getItem() instanceof ItemHandCrank)
|
||||
{
|
||||
getMultiBlock().get().manualCrankTime = 10;
|
||||
world().playSoundEffect(x() + 0.5, y() + 0.5, z() + 0.5, Reference.PREFIX + "gearCrank", 0.5f, 0.9f + world().rand.nextFloat() * 0.2f);
|
||||
player.addExhaustion(0.01f);
|
||||
return true;
|
||||
}
|
||||
|
||||
if (WrenchUtility.isWrench(itemStack))
|
||||
{
|
||||
if (player.isSneaking())
|
||||
{
|
||||
getMultiBlock().toggleConstruct();
|
||||
}
|
||||
else if (ControlKeyModifer.isControlDown(player))
|
||||
{
|
||||
if (!world().isRemote)
|
||||
{
|
||||
|
@ -133,9 +137,7 @@ public class PartGear extends PartMechanical implements IMechanical, IMultiBlock
|
|||
}
|
||||
else
|
||||
{
|
||||
getMultiBlock().get().manualCrankTime = 10;
|
||||
world().playSoundEffect(x() + 0.5, y() + 0.5, z() + 0.5, Reference.PREFIX + "gearCrank", 0.5f, 0.9f + world().rand.nextFloat() * 0.2f);
|
||||
player.addExhaustion(0.01f);
|
||||
getMultiBlock().toggleConstruct();
|
||||
}
|
||||
|
||||
return true;
|
||||
|
@ -149,7 +151,7 @@ public class PartGear extends PartMechanical implements IMechanical, IMultiBlock
|
|||
}
|
||||
}
|
||||
|
||||
return super.activate(player, hit, item);
|
||||
return super.activate(player, hit, itemStack);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -49,15 +49,6 @@ public class BlockFilter extends BlockTile
|
|||
world.scheduleBlockUpdate(x, y, z, blockID, 20);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addCollisionBoxesToList(World par1World, int par2, int par3, int par4, AxisAlignedBB par5AxisAlignedBB, List par6List, Entity entity)
|
||||
{
|
||||
if (entity instanceof EntityItem)
|
||||
return;
|
||||
|
||||
super.addCollisionBoxesToList(par1World, par2, par3, par4, par5AxisAlignedBB, par6List, entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateTick(World world, int x, int y, int z, Random random)
|
||||
{
|
||||
|
|
|
@ -135,7 +135,7 @@ public class TileGrinderWheel extends TileMechanical implements IRotatable
|
|||
|
||||
if (!this.worldObj.isRemote)
|
||||
{
|
||||
EntityItem entityItem = new EntityItem(this.worldObj, entity.posX, entity.posY - 1.2, entity.posZ, outputStack.copy());
|
||||
EntityItem entityItem = new EntityItem(this.worldObj, entity.posX, entity.posY - 1.2, entity.posZ, outputStack);
|
||||
entityItem.delayBeforeCanPickup = 20;
|
||||
entityItem.motionX = 0;
|
||||
entityItem.motionY = 0;
|
||||
|
|
|
@ -65,7 +65,9 @@ tile.resonantinduction\:fluidPipe.1.name=Stone Trough
|
|||
item.resonantinduction\:gear.0.name=Wooden Gear
|
||||
item.resonantinduction\:gear.1.name=Stone Gear
|
||||
item.resonantinduction\:gear.2.name=Metal Gear
|
||||
item.resonantinduction\:gearShaft.name=Gear Shaft
|
||||
item.resonantinduction\:gearShaft.0.name=Wooden Gear Shaft
|
||||
item.resonantinduction\:gearShaft.1.name=Stone Gear Shaft
|
||||
item.resonantinduction\:gearShaft.2.name=Metal Gear Shaft
|
||||
tile.resonantinduction\:windTurbine.name=Wind Turbine
|
||||
tile.resonantinduction\:windTurbine.tooltip=The wind turbine generates power through air flow and pressure.
|
||||
tile.resonantinduction\:waterTurbine.name=Water Turbine
|
||||
|
|
Loading…
Reference in a new issue