Skip to content

Commit

Permalink
-Fixed issue with item dislocator pickup sound playing continuously.
Browse files Browse the repository at this point in the history
-Fixed swords being ineffective against blocks like web and leaves.
-Fixed issue were portal blocks could be broken and placed in survival.
-Removed IInventory support from placed items as it was never intended to be a thing and may have caused some dupe bugs.
  • Loading branch information
brandon3055 committed Feb 26, 2018
1 parent 4570abb commit 76dff8b
Show file tree
Hide file tree
Showing 11 changed files with 234 additions and 99 deletions.
8 changes: 7 additions & 1 deletion Change Log.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
######## 2.3.9.x ########
######## 2.3.10.x ########
-Fixed issue with item dislocator pickup sound playing continuously.
-Fixed swords being ineffective against blocks like web and leaves.
-Fixed issue were portal blocks could be broken and placed in survival.
-Removed IInventory support from placed items as it was never intended to be a thing and may have caused some dupe bugs.

######## 2.3.9.283 ########
-Fixed draconium chest recipe shift clicking from jei.
-Fixed missing ore dictionary entries for nether and end draconium ore.
-Fixed missing FE support on armor.
Expand Down
2 changes: 1 addition & 1 deletion build.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
mc_version=1.12
mod_version=2.3.9
mod_version=2.3.10
forge_version=14.21.1.2443
mappings=snapshot_20171003
bcore_version=2.4.0.+
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,8 +180,8 @@ else if (hit == null) {
return ItemStack.EMPTY;
}

if (hit.subHit > 0 && ((TilePlacedItem) tile).getStackInSlot(hit.subHit - 1) != null) {
return ((TilePlacedItem) tile).getStackInSlot(hit.subHit - 1);
if (hit.subHit > 0 && ((TilePlacedItem) tile).inventory.getStackInSlot(hit.subHit - 1) != null) {
return ((TilePlacedItem) tile).inventory.getStackInSlot(hit.subHit - 1);
}
}

Expand Down
10 changes: 10 additions & 0 deletions src/main/java/com/brandon3055/draconicevolution/blocks/Portal.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
import net.minecraft.block.state.BlockStateContainer;
import net.minecraft.block.state.IBlockState;
import net.minecraft.entity.Entity;
import net.minecraft.init.Items;
import net.minecraft.item.Item;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.EnumFacing;
import net.minecraft.util.math.AxisAlignedBB;
Expand All @@ -19,6 +21,8 @@

import javax.annotation.Nullable;

import java.util.Random;

import static net.minecraft.util.EnumFacing.Axis.*;

/**
Expand All @@ -33,6 +37,7 @@ public class Portal extends BlockBCore implements ITileEntityProvider {
public static final PropertyBool DRAW_WEST = PropertyBool.create("drawwest");

public Portal() {
this.setBlockUnbreakable();
this.setDefaultState(this.blockState.getBaseState().withProperty(AXIS, X).withProperty(DRAW_UP, true).withProperty(DRAW_DOWN, true).withProperty(DRAW_EAST, true).withProperty(DRAW_WEST, true));
}

Expand Down Expand Up @@ -80,6 +85,11 @@ public IBlockState getActualState(IBlockState state, IBlockAccess worldIn, Block
return state;
}

@Override
public Item getItemDropped(IBlockState state, Random rand, int fortune) {
return Items.AIR;
}

//endregion

//region Portal Logic
Expand Down

0 comments on commit 76dff8b

Please sign in to comment.