Merge remote-tracking branch 'origin/master' into 1.11.X

master
Bartek Bok 2017-08-04 19:53:16 +02:00
commit 76c2d772ad
No known key found for this signature in database
GPG Key ID: D4AB7344B821F0B5
4 changed files with 50 additions and 3 deletions

@ -1 +1 @@
Subproject commit 939dab0a24e72bcb972838359ba7688b54f83ae5
Subproject commit 967f667bbdac6a0a3978ba669091c483eddec536

View File

@ -1,4 +1,4 @@
mod_version=1.7
mod_version=1.7.1
api_version=1.1
opc_api_version=3.5-unstable
mc_version=1.11.2

View File

@ -8,11 +8,14 @@ import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.util.EnumFacing;
import net.minecraft.util.EnumHand;
import net.minecraft.util.ITickable;
import net.minecraft.util.math.AxisAlignedBB;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.Vec3d;
import openblocks.Config;
import openmods.api.IActivateAwareTile;
import openmods.api.IAddAwareTile;
import openmods.api.INeighbourAwareTile;
import openmods.api.IPlaceAwareTile;
@ -21,7 +24,7 @@ import openmods.sync.SyncableFloat;
import openmods.tileentity.SyncedTileEntity;
import openmods.utils.BlockUtils;
public class TileEntityFan extends SyncedTileEntity implements IPlaceAwareTile, INeighbourAwareTile, IAddAwareTile, ITickable {
public class TileEntityFan extends SyncedTileEntity implements IPlaceAwareTile, INeighbourAwareTile, IAddAwareTile, ITickable, IActivateAwareTile {
private static final double CONE_HALF_APERTURE = 1.2 / 2.0;
private SyncableFloat angle;
@ -131,4 +134,14 @@ public class TileEntityFan extends SyncedTileEntity implements IPlaceAwareTile,
}
}
@Override
public boolean onBlockActivated(EntityPlayer player, EnumHand hand, EnumFacing side, float hitX, float hitY, float hitZ) {
if (!world.isRemote && hand == EnumHand.MAIN_HAND) {
angle.set(angle.get() + (player.isSneaking()? -10f : +10f));
sync();
return true;
}
return false;
}
}

View File

@ -1,4 +1,38 @@
[
{
"version" : "1.7.1",
"sections" :
[
{
"title": "openblocks.gui.features",
"lines":
[
"Port to MC 1.11.2",
"Right clicking on fan will rotate it (same as flag)",
"Added new trophies"
]
},
{
"title": "openblocks.gui.bugfixes",
"lines":
[
"Fixed Sky Block rendering behind glass",
"Fix couple of custom recipes",
"Fix off-hand glider behaviour",
"Fix flag placing and dropping",
"Grave can now be safely disabled"
]
},
{
"title" : "openblocks.gui.tweaks",
"lines" :
[
"Item placer now tries to place item on inventory change",
"Flags with different colors no longer stack"
]
}
]
},
{
"version" : "1.7",
"sections" :