mirror of
https://github.com/GTNewHorizons/ThaumicTinkerer.git
synced 2026-11-28 16:06:07 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c762ad9915 | ||
|
|
f8fb442525 | ||
|
|
3bb2edda24 | ||
|
|
587027c24e | ||
|
|
a8259fe5cc |
No files matched your search
+2
-2
@@ -2,7 +2,7 @@
|
||||
|
||||
dependencies {
|
||||
compile('com.github.GTNewHorizons:Baubles:1.0.1.14:dev')
|
||||
compile('com.github.GTNewHorizons:Applied-Energistics-2-Unofficial:rv3-beta-147-GTNH:api')
|
||||
compile('com.github.GTNewHorizons:Applied-Energistics-2-Unofficial:rv3-beta-195-GTNH:api')
|
||||
|
||||
compile('thaumcraft:Thaumcraft:1.7.10-4.2.3.5:dev')
|
||||
|
||||
@@ -14,7 +14,7 @@ dependencies {
|
||||
compileOnly('com.github.GTNewHorizons:TinkersConstruct:1.9.0.13-GTNH:dev') {transitive=false}
|
||||
compileOnly('com.github.GTNewHorizons:ForgeMultipart:1.2.7:dev') {transitive=false}
|
||||
compileOnly('com.github.GTNewHorizons:CodeChickenLib:1.1.5.3:dev') {transitive=false}
|
||||
compileOnly('com.github.GTNewHorizons:OpenComputers:1.7.5.23-GTNH:api') {transitive=false}
|
||||
compileOnly('com.github.GTNewHorizons:OpenComputers:1.9.1-GTNH:api') {transitive=false}
|
||||
|
||||
compileOnly('curse.maven:computercraft-67504:2269339')
|
||||
compileOnly('curse.maven:cofh-lib-220333:2388748')
|
||||
|
||||
+16
-7
@@ -73,22 +73,31 @@ public class ContainerIchorPouch extends ContainerPlayerInv {
|
||||
if (par1 == blockSlot) {
|
||||
return null;
|
||||
}
|
||||
return super.slotClick(par1, par2, par3, par4EntityPlayer);
|
||||
|
||||
ItemStack stack = super.slotClick(par1, par2, par3, par4EntityPlayer);
|
||||
if (!this.player.worldObj.isRemote) {
|
||||
saveInventory();
|
||||
}
|
||||
return stack;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onContainerClosed(EntityPlayer par1EntityPlayer) {
|
||||
super.onContainerClosed(par1EntityPlayer);
|
||||
if (!player.worldObj.isRemote) {
|
||||
((ItemFocusPouch) pouch.getItem()).setInventory(pouch, ((InventoryIchorPouch) inv).stackList);
|
||||
if (player == null) return;
|
||||
if (player.getHeldItem() != null && player.getHeldItem().isItemEqual(pouch))
|
||||
player.setCurrentItemOrArmor(0, pouch);
|
||||
|
||||
player.inventory.markDirty();
|
||||
saveInventory();
|
||||
}
|
||||
}
|
||||
|
||||
private void saveInventory() {
|
||||
((ItemFocusPouch) pouch.getItem()).setInventory(pouch, ((InventoryIchorPouch) inv).stackList);
|
||||
if (player == null) return;
|
||||
if (player.getHeldItem() != null && player.getHeldItem().isItemEqual(pouch))
|
||||
player.setCurrentItemOrArmor(0, pouch);
|
||||
|
||||
player.inventory.markDirty();
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canInteractWith(EntityPlayer entityplayer) {
|
||||
return true;
|
||||
|
||||
@@ -41,10 +41,10 @@ public class AspectCropLootManager {
|
||||
Random rand = new Random();
|
||||
int randInt = rand.nextInt(sum);
|
||||
for (Map.Entry<ItemStack, Integer> pair : aspectHashmap.entrySet()) {
|
||||
randInt -= pair.getValue();
|
||||
if (randInt <= 0) {
|
||||
return pair.getKey().copy();
|
||||
}
|
||||
randInt -= pair.getValue();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
|
||||
Reference in new issue
Block a user