Skip to content

Commit

Permalink
Merge pull request #430 from GrowthcraftCE/development
Browse files Browse the repository at this point in the history
2.7.2 Release
  • Loading branch information
Alatyami authored Jan 3, 2017
2 parents 04d8247 + f150ace commit 9e93ebe
Show file tree
Hide file tree
Showing 8 changed files with 435 additions and 404 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
Growthcraft
Growthcraft
===========

[![Minecraft Version](http://img.shields.io/minecraft/1.7.10.png?color=green)](https://minecraft.net/)
[![Growthcraft Version](http://img.shields.io/growthcraft/2.7.0.png?color=green)](https://github.com/GrowthcraftCE/Growthcraft-1.7)
[![Growthcraft Version](http://img.shields.io/growthcraft/2.7.2.png?color=green)](https://github.com/GrowthcraftCE/Growthcraft-1.7)
[![Forge Version](http://img.shields.io/forge/10.13.4.1566.png?color=green)](http://files.minecraftforge.net/)
[![Java Version](http://img.shields.io/java/7.png?color=green)](https://www.java.com/en/)
[![Build Status](https://travis-ci.org/GrowthcraftCE/Growthcraft-1.7.svg?branch=master)](https://travis-ci.org/GrowthcraftCE/Growthcraft-1.7)
[![Build Status](https://travis-ci.org/GrowthcraftCE/Growthcraft-1.7.svg?branch=master)](https://travis-ci.org/GrowthcraftCE/Growthcraft-1.7)

This is a community fork of the original GrowthCraft developed by Gwafu.
This is a community fork of the original GrowthCraft developed by Gwafu.
The original forum post can be found on the [Minecraft Forums mod page](http://www.minecraftforum.net/forums/mapping-and-modding/minecraft-mods/1286298-growthcraft-jul-15-2014-proper-1-7-10-release). We have created a [forum post](http://www.minecraftforum.net/forums/mapping-and-modding/minecraft-mods/wip-mods/2505072-growthcraft-community-edition-proper-1-7-10) for [Growthcraft CE](http://www.minecraftforum.net/forums/mapping-and-modding/minecraft-mods/wip-mods/2505072-growthcraft-community-edition-proper-1-7-10) for general discussions, announcements and feedback. Likewise this repository is on [Gitter](https://gitter.im/alatyami/Growthcraft-1.7) and we have an IRC channel on EsperNet (#growthcraft).

## Wiki

We are using the [Gamepedia FTB Wiki](http://ftb.gamepedia.com/GrowthCraft) for publishing how the plugins work and tutorials.
We are using the [Gamepedia FTB Wiki](http://ftb.gamepedia.com/GrowthCraft) for publishing how the plugins work and tutorials.
For technical details please read our [Github Wiki](https://github.com/GrowthcraftCE/Growthcraft-1.7/wiki).
If you need to check the latest [User API](https://github.com/GrowthcraftCE/Growthcraft-1.7/wiki/User-API-(2.5.x))

## Contributing
## Contributing

For any contributions to this project, please refer to our [Contributing to Growthcraft](https://github.com/GrowthcraftCE/Growthcraft-1.7/wiki/Contributing-to-Growthcraft) wiki page and create a branch from our development branch. All pull requests need to be towards our development. Pull requests directly to the master branch will be closed without review.

Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ minecraft_version=1.7.10
# Forge
minecraft_forge_version=1.7.10-10.13.4.1566-1.7.10
# GrowthCraft
growthcraft_version=2.7.0
growthcraft_version=2.7.2
# Depdendencies
applecore_version=1.3.0
bc_version=7.1.17
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -183,11 +183,13 @@ public boolean canInsertItem(int slot, ItemStack stack, int side)
return InventoryProcessor.instance().canInsertItem(this, stack, slot);
}

@Override
public boolean canExtractItem(int slot, ItemStack stack, int side)
{
return InventoryProcessor.instance().canExtractItem(this, stack, slot);
}

@Override
public int[] getAccessibleSlotsFromSide(int side)
{
return NO_SLOTS;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,16 +43,17 @@

public class TileEntityFishTrap extends GrcTileInventoryBase implements IInteractionObject
{
private static final int[] trapSlots = new int[] {0,1,2,3,4,5};
private static final int[] baitSlots = new int[] {6};
private static final int[] TRAP_SLOTS = new int[] {0,1,2,3,4,5};
private static final int[] BAIT_SLOTS = new int[] {6};
private static final int[] ACCESSIBLE_SLOTS = new int[] {0,1,2,3,4,5,6};
public InventorySlice trapInventory;
public InventorySlice baitInventory;

public TileEntityFishTrap()
{
super();
this.trapInventory = new InventorySlice(this, trapSlots);
this.baitInventory = new InventorySlice(this, baitSlots);
this.trapInventory = new InventorySlice(this, TRAP_SLOTS);
this.baitInventory = new InventorySlice(this, BAIT_SLOTS);
}

@Override
Expand All @@ -73,6 +74,34 @@ public GrcInternalInventory createInventory()
return new GrcInternalInventory(this, 7);
}

@Override
public boolean canInsertItem(int slot, ItemStack stack, int facing)
{
// only insert into the bait slot
if (slot == 6) {
return super.canInsertItem(slot, stack, facing);
} else {
return false;
}
}

@Override
public boolean canExtractItem(int slot, ItemStack stack, int facing)
{
// only extract from the loot/trap slots
if (slot < 6) {
return super.canExtractItem(slot, stack, facing);
} else {
return false;
}
}

@Override
public int[] getAccessibleSlotsFromSide(int facing)
{
return ACCESSIBLE_SLOTS;
}

/**
* Called after a successful catch, this will remove an item from the stack
* of provided bait
Expand Down Expand Up @@ -106,17 +135,17 @@ public float applyBaitModifier(float f)

public int getBaitInventoryOffset()
{
return baitSlots[0];
return BAIT_SLOTS[0];
}

public int getTrapInventorySize()
{
return trapSlots.length;
return TRAP_SLOTS.length;
}

public int getBaitInventorySize()
{
return baitSlots.length;
return BAIT_SLOTS.length;
}

/**
Expand Down
Loading

0 comments on commit 9e93ebe

Please # to comment.