Frame and frame support along with a full upload of all previous work and files.
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/AdvancedSatelliteUtilization.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/asuworldgen/WorldGen.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/asuworldgen/oregen/ASUWorldOreGen.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modGUIs/ASUGuiHandler.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modGUIs/GuiAdvancedWasteHandler.java
Normal file → Executable file
2
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modGUIs/GuiEnderCoreGenerator.java
Normal file → Executable file
@ -77,7 +77,7 @@ public class GuiEnderCoreGenerator extends GuiContainer {
|
|||||||
drawTexturedModalRect(guiLeft+7, guiTop+8 + 12 + 3, 100, 149 + 4, currentcooldown, 3);
|
drawTexturedModalRect(guiLeft+7, guiTop+8 + 12 + 3, 100, 149 + 4, currentcooldown, 3);
|
||||||
|
|
||||||
|
|
||||||
drawCenteredString(fontRendererObj, "Ender Core Generator", guiLeft+90, guiTop-10, 0xFFFFFF);
|
drawCenteredString(fontRendererObj, "Ender Core Generator", guiLeft+90, guiTop+7, 0xFFFFFF);
|
||||||
if (currentpower == 0) {
|
if (currentpower == 0) {
|
||||||
percentagefontcolor = 0xFF0000;
|
percentagefontcolor = 0xFF0000;
|
||||||
} else {
|
} else {
|
||||||
|
@ -0,0 +1,18 @@
|
|||||||
|
package org.bitbucket.alltra101ify.advancedsatelliteutilization.modGUIs;
|
||||||
|
|
||||||
|
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||||
|
import net.minecraft.inventory.Container;
|
||||||
|
|
||||||
|
public class GuiFrameProjector extends GuiContainer {
|
||||||
|
|
||||||
|
public GuiFrameProjector(Container p_i1072_1_) {
|
||||||
|
super(p_i1072_1_);
|
||||||
|
this.xSize = 176;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void drawGuiContainerBackgroundLayer(float f, int mx, int my) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modGUIs/GuiNetherCoreGenerator.java
Normal file → Executable file
7
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modGUIs/GuiWrenchOverlay.java
Normal file → Executable file
@ -23,10 +23,6 @@ import net.minecraftforge.client.event.RenderGameOverlayEvent;
|
|||||||
import net.minecraftforge.client.event.RenderGameOverlayEvent.ElementType;
|
import net.minecraftforge.client.event.RenderGameOverlayEvent.ElementType;
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
//
|
|
||||||
// GuiBuffBar implements a simple status bar at the top of the screen which
|
|
||||||
// shows the current buffs/debuffs applied to the character.
|
|
||||||
//
|
|
||||||
public class GuiWrenchOverlay extends Gui
|
public class GuiWrenchOverlay extends Gui
|
||||||
{
|
{
|
||||||
private Minecraft mc;
|
private Minecraft mc;
|
||||||
@ -38,7 +34,6 @@ public class GuiWrenchOverlay extends Gui
|
|||||||
{
|
{
|
||||||
super();
|
super();
|
||||||
|
|
||||||
// We need this to invoke the render engine.
|
|
||||||
this.mc = mc;
|
this.mc = mc;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -83,5 +78,5 @@ public class GuiWrenchOverlay extends Gui
|
|||||||
} else {
|
} else {
|
||||||
this.drawTexturedModalRect(xPos-12, yPos, XSTART - 12, YSTART, XSIZE, YSIZE);
|
this.drawTexturedModalRect(xPos-12, yPos, XSTART - 12, YSTART, XSIZE, YSIZE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modGUIs/ModGUIs.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/ASUPedestal.java
Normal file → Executable file
39
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/AdvancedWasteHandler.java
Normal file → Executable file
@ -6,6 +6,7 @@ import org.bitbucket.alltra101ify.advancedsatelliteutilization.AdvancedSatellite
|
|||||||
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modGUIs.ModGUIs;
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modGUIs.ModGUIs;
|
||||||
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks.tileentities.TileEntityAdvancedWasteHandler;
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks.tileentities.TileEntityAdvancedWasteHandler;
|
||||||
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks.tileentities.TileEntityEnderCoreGenerator;
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks.tileentities.TileEntityEnderCoreGenerator;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks.tileentities.TileEntityNetherCoreGenerator;
|
||||||
import org.bitbucket.alltra101ify.advancedsatelliteutilization.moditems.ModItems;
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.moditems.ModItems;
|
||||||
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.ModCreativeTabs;
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.ModCreativeTabs;
|
||||||
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.ModInfo;
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.ModInfo;
|
||||||
@ -19,10 +20,12 @@ import net.minecraft.block.BlockContainer;
|
|||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
|
import net.minecraft.entity.item.EntityItem;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.init.Blocks;
|
import net.minecraft.init.Blocks;
|
||||||
import net.minecraft.item.Item;
|
import net.minecraft.item.Item;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
import net.minecraft.tileentity.TileEntity;
|
import net.minecraft.tileentity.TileEntity;
|
||||||
import net.minecraft.util.IIcon;
|
import net.minecraft.util.IIcon;
|
||||||
import net.minecraft.util.MathHelper;
|
import net.minecraft.util.MathHelper;
|
||||||
@ -156,5 +159,41 @@ public class AdvancedWasteHandler extends ModMachineBlock {
|
|||||||
}
|
}
|
||||||
super.randomDisplayTick(world, x, y, z, r);
|
super.randomDisplayTick(world, x, y, z, r);
|
||||||
}
|
}
|
||||||
|
@Override
|
||||||
|
public void breakBlock(World world, int x, int y, int z, Block b, int i) {
|
||||||
|
DropItems(world, x, y, z);
|
||||||
|
super.breakBlock(world, x, y, z, b, i);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void DropItems(World world, int x, int y, int z) {
|
||||||
|
Random r = new Random();
|
||||||
|
TileEntityAdvancedWasteHandler tileentity = ((TileEntityAdvancedWasteHandler)world.getTileEntity(x, y, z));
|
||||||
|
for (int i = 0; i < tileentity.getSizeInventory(); i++) {
|
||||||
|
ItemStack itemstack = tileentity.getStackInSlot(i);
|
||||||
|
if (itemstack != null) {
|
||||||
|
float rand[] = new float[3];
|
||||||
|
for (int i1 = 0; i1 < 3; i1++) {
|
||||||
|
rand[i1] = r.nextFloat() * 0.8F + 0.1F;
|
||||||
|
}
|
||||||
|
while (itemstack.stackSize > 0) {
|
||||||
|
int j1 = r.nextInt(21) + 10;
|
||||||
|
|
||||||
|
if (j1 > itemstack.stackSize) {
|
||||||
|
j1 = itemstack.stackSize;
|
||||||
|
}
|
||||||
|
itemstack.stackSize -= j1;
|
||||||
|
EntityItem entityitem = new EntityItem(world, x + rand[0], y + rand[1], z + rand[2], new ItemStack(itemstack.getItem(), j1, itemstack.getItemDamage()));
|
||||||
|
|
||||||
|
if (itemstack.hasTagCompound()) {
|
||||||
|
entityitem.getEntityItem().setTagCompound((NBTTagCompound)itemstack.getTagCompound().copy());
|
||||||
|
}
|
||||||
|
float f3 = 0.05F;
|
||||||
|
entityitem.motionX = r.nextGaussian() * f3;
|
||||||
|
entityitem.motionY = r.nextGaussian() * f3 + 0.2f;
|
||||||
|
entityitem.motionZ = r.nextGaussian() * f3;
|
||||||
|
world.spawnEntityInWorld(entityitem);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/BlockOfASHAD.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/Blocker.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/CoreStabilizer.java
Normal file → Executable file
38
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/EnderCoreGenerator.java
Normal file → Executable file
@ -19,9 +19,11 @@ import net.minecraft.block.BlockContainer;
|
|||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.client.gui.GuiScreen;
|
import net.minecraft.client.gui.GuiScreen;
|
||||||
|
import net.minecraft.entity.item.EntityItem;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.init.Blocks;
|
import net.minecraft.init.Blocks;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
import net.minecraft.potion.Potion;
|
import net.minecraft.potion.Potion;
|
||||||
import net.minecraft.tileentity.TileEntity;
|
import net.minecraft.tileentity.TileEntity;
|
||||||
import net.minecraft.util.ChatComponentText;
|
import net.minecraft.util.ChatComponentText;
|
||||||
@ -121,5 +123,41 @@ public class EnderCoreGenerator extends ModMachineBlock {
|
|||||||
public boolean renderAsNormalBlock() {
|
public boolean renderAsNormalBlock() {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@Override
|
||||||
|
public void breakBlock(World world, int x, int y, int z, Block b, int i) {
|
||||||
|
DropItems(world, x, y, z);
|
||||||
|
super.breakBlock(world, x, y, z, b, i);
|
||||||
|
}
|
||||||
|
public void DropItems(World world, int x, int y, int z) {
|
||||||
|
Random r = new Random();
|
||||||
|
TileEntityEnderCoreGenerator tileentity = ((TileEntityEnderCoreGenerator)world.getTileEntity(x, y, z));
|
||||||
|
for (int i = 0; i < tileentity.getSizeInventory(); i++) {
|
||||||
|
ItemStack itemstack = tileentity.getStackInSlot(i);
|
||||||
|
if (itemstack != null) {
|
||||||
|
float rand[] = new float[3];
|
||||||
|
for (int i1 = 0; i1 < 3; i1++) {
|
||||||
|
rand[i1] = r.nextFloat() * 0.8F + 0.1F;
|
||||||
|
}
|
||||||
|
while (itemstack.stackSize > 0) {
|
||||||
|
int j1 = r.nextInt(21) + 10;
|
||||||
|
|
||||||
|
if (j1 > itemstack.stackSize) {
|
||||||
|
j1 = itemstack.stackSize;
|
||||||
|
}
|
||||||
|
itemstack.stackSize -= j1;
|
||||||
|
EntityItem entityitem = new EntityItem(world, x + rand[0], y + rand[1], z + rand[2], new ItemStack(itemstack.getItem(), j1, itemstack.getItemDamage()));
|
||||||
|
|
||||||
|
if (itemstack.hasTagCompound()) {
|
||||||
|
entityitem.getEntityItem().setTagCompound((NBTTagCompound)itemstack.getTagCompound().copy());
|
||||||
|
}
|
||||||
|
float f3 = 0.05F;
|
||||||
|
entityitem.motionX = r.nextGaussian() * f3;
|
||||||
|
entityitem.motionY = r.nextGaussian() * f3 + 0.2f;
|
||||||
|
entityitem.motionZ = r.nextGaussian() * f3;
|
||||||
|
world.spawnEntityInWorld(entityitem);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,76 @@
|
|||||||
|
package org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks;
|
||||||
|
|
||||||
|
import java.util.Random;
|
||||||
|
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks.tileentities.TileEntityFrameProjector;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.ModCreativeTabs;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.ModInfo;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.moditemblockreference.ModMachineBlock;
|
||||||
|
|
||||||
|
import net.minecraft.block.Block;
|
||||||
|
import net.minecraft.block.material.Material;
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
import net.minecraft.world.IBlockAccess;
|
||||||
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
public class FrameProjector extends ModMachineBlock {
|
||||||
|
|
||||||
|
boolean multiBlock;
|
||||||
|
|
||||||
|
protected FrameProjector(boolean multiBlock) {
|
||||||
|
super(Material.iron);
|
||||||
|
this.multiBlock = multiBlock;
|
||||||
|
if (multiBlock == false) {
|
||||||
|
setCreativeTab(ModCreativeTabs.TabASU);
|
||||||
|
}
|
||||||
|
if (multiBlock == true) {
|
||||||
|
setLightLevel(0.8f);
|
||||||
|
}
|
||||||
|
setBlockName("FrameProjector" + "_" + multiBlock);
|
||||||
|
setBlockTextureName(ModInfo.MODID + ":" + "FrameProjector/" + getUnlocalizedName().substring(5));
|
||||||
|
setResistance(8);
|
||||||
|
setHardness(8);
|
||||||
|
setHarvestLevel("pickaxe", 2);
|
||||||
|
this.isBlockContainer = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public TileEntity createNewTileEntity(World p_149915_1_, int p_149915_2_) {
|
||||||
|
return new TileEntityFrameProjector(multiBlock);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onNeighborBlockChange(World world, int x, int y, int z, Block block) {
|
||||||
|
world.scheduleBlockUpdate(x, y, z, world.getBlock(x, y, z), 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateTick(World world, int x, int y, int z, Random r) {
|
||||||
|
if (isMultiBlock(world, x, y, z)) {
|
||||||
|
world.setBlock(x, y, z, ModBlocks.frameProjector_True);
|
||||||
|
} else {
|
||||||
|
world.setBlock(x, y, z, ModBlocks.frameProjector_False);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
protected boolean isMultiBlock(World world, int x, int y, int z) {
|
||||||
|
byte multiBlockCount = 0;
|
||||||
|
for (int i = -1; i <= 1; i++) {
|
||||||
|
for (int j = -1; j <= 1; j++) {
|
||||||
|
if (world.getBlock(x+i, y, z+j) == ModBlocks.frameSupport) {
|
||||||
|
multiBlockCount++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (multiBlockCount == 8) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isOpaqueCube() {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,57 @@
|
|||||||
|
package org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks;
|
||||||
|
|
||||||
|
import java.util.Random;
|
||||||
|
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks.tileentities.TileEntityFrameSupport;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.ModCreativeTabs;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.ModInfo;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.moditemblockreference.ModBasicMachineBlock;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.moditemblockreference.ModMachineBlock;
|
||||||
|
|
||||||
|
import net.minecraft.block.Block;
|
||||||
|
import net.minecraft.block.material.Material;
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
public class FrameSupport extends ModBasicMachineBlock {
|
||||||
|
|
||||||
|
protected FrameSupport() {
|
||||||
|
super(Material.rock);
|
||||||
|
setCreativeTab(ModCreativeTabs.TabASU);
|
||||||
|
setBlockName("FrameSupport");
|
||||||
|
setBlockTextureName(ModInfo.MODID + ":" + getUnlocalizedName().substring(5));
|
||||||
|
setResistance(8);
|
||||||
|
setHardness(8);
|
||||||
|
setHarvestLevel("pickaxe", 2);
|
||||||
|
setLightLevel(0.4f);
|
||||||
|
this.isBlockContainer = true;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public boolean isOpaqueCube() {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateTick(World world, int x, int y, int z, Random r) {
|
||||||
|
checkSurrounding(world, x, y, z);
|
||||||
|
super.updateTick(world, x, y, z, r);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onNeighborBlockChange(World w, int x, int y, int z, Block p_149695_5_) {
|
||||||
|
w.scheduleBlockUpdate(x, y, z, w.getBlock(x, y, z), 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void checkSurrounding(World world, int x, int y, int z) {
|
||||||
|
for (int i = -1; i <= 1; i++) {
|
||||||
|
for (int j = -1; j <= 1; j++) {
|
||||||
|
if (world.getBlock(x+i, y, z+j) == ModBlocks.frameProjector_False || world.getBlock(x+i, y, z+j) == ModBlocks.frameProjector_True) {
|
||||||
|
world.scheduleBlockUpdate(x+i, y, z+j, world.getBlock(x+i, y, z+j), 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/ModBlockMaterials.java
Normal file → Executable file
6
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/ModBlocks.java
Normal file → Executable file
@ -17,6 +17,9 @@ public class ModBlocks {
|
|||||||
public static Block quaridiumOre = new QuaridiumOre(Material.iron);
|
public static Block quaridiumOre = new QuaridiumOre(Material.iron);
|
||||||
public static Block blockofashadwithquaridium = new blockOfASHADWithQuaridium(Material.iron);
|
public static Block blockofashadwithquaridium = new blockOfASHADWithQuaridium(Material.iron);
|
||||||
public static Block netherCoreGenerator = new NetherCoreGenerator();
|
public static Block netherCoreGenerator = new NetherCoreGenerator();
|
||||||
|
public static Block frameSupport = new FrameSupport();
|
||||||
|
public static Block frameProjector_False = new FrameProjector(false);
|
||||||
|
public static Block frameProjector_True = new FrameProjector(true);
|
||||||
public static void blockInit() {
|
public static void blockInit() {
|
||||||
ASURegistryHelper.registerBlock(blockofashad);
|
ASURegistryHelper.registerBlock(blockofashad);
|
||||||
ASURegistryHelper.registerBlock(transparentblockofashad);
|
ASURegistryHelper.registerBlock(transparentblockofashad);
|
||||||
@ -29,5 +32,8 @@ public class ModBlocks {
|
|||||||
ASURegistryHelper.registerBlock(netherCoreGenerator);
|
ASURegistryHelper.registerBlock(netherCoreGenerator);
|
||||||
ASURegistryHelper.registerBlock(AdvancedWasteHandler);
|
ASURegistryHelper.registerBlock(AdvancedWasteHandler);
|
||||||
ASURegistryHelper.registerBlock(AdvancedWasteHandler_active);
|
ASURegistryHelper.registerBlock(AdvancedWasteHandler_active);
|
||||||
|
ASURegistryHelper.registerBlock(frameSupport);
|
||||||
|
ASURegistryHelper.registerBlock(frameProjector_False);
|
||||||
|
ASURegistryHelper.registerBlock(frameProjector_True);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
39
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/NetherCoreGenerator.java
Normal file → Executable file
@ -4,8 +4,10 @@ import java.util.Random;
|
|||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
|
import net.minecraft.entity.item.EntityItem;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
import net.minecraft.tileentity.TileEntity;
|
import net.minecraft.tileentity.TileEntity;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
@ -110,5 +112,42 @@ public class NetherCoreGenerator extends ModMachineBlock {
|
|||||||
public boolean renderAsNormalBlock() {
|
public boolean renderAsNormalBlock() {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@Override
|
||||||
|
public void breakBlock(World world, int x, int y, int z, Block b, int i) {
|
||||||
|
DropItems(world, x, y, z);
|
||||||
|
super.breakBlock(world, x, y, z, b, i);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void DropItems(World world, int x, int y, int z) {
|
||||||
|
Random r = new Random();
|
||||||
|
TileEntityNetherCoreGenerator tileentity = ((TileEntityNetherCoreGenerator)world.getTileEntity(x, y, z));
|
||||||
|
for (int i = 0; i < tileentity.getSizeInventory(); i++) {
|
||||||
|
ItemStack itemstack = tileentity.getStackInSlot(i);
|
||||||
|
if (itemstack != null) {
|
||||||
|
float rand[] = new float[3];
|
||||||
|
for (int i1 = 0; i1 < 3; i1++) {
|
||||||
|
rand[i1] = r.nextFloat() * 0.8F + 0.1F;
|
||||||
|
}
|
||||||
|
while (itemstack.stackSize > 0) {
|
||||||
|
int j1 = r.nextInt(21) + 10;
|
||||||
|
|
||||||
|
if (j1 > itemstack.stackSize) {
|
||||||
|
j1 = itemstack.stackSize;
|
||||||
|
}
|
||||||
|
itemstack.stackSize -= j1;
|
||||||
|
EntityItem entityitem = new EntityItem(world, x + rand[0], y + rand[1], z + rand[2], new ItemStack(itemstack.getItem(), j1, itemstack.getItemDamage()));
|
||||||
|
|
||||||
|
if (itemstack.hasTagCompound()) {
|
||||||
|
entityitem.getEntityItem().setTagCompound((NBTTagCompound)itemstack.getTagCompound().copy());
|
||||||
|
}
|
||||||
|
float f3 = 0.05F;
|
||||||
|
entityitem.motionX = r.nextGaussian() * f3;
|
||||||
|
entityitem.motionY = r.nextGaussian() * f3 + 0.2f;
|
||||||
|
entityitem.motionZ = r.nextGaussian() * f3;
|
||||||
|
world.spawnEntityInWorld(entityitem);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/QuaridiumOre.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/TransparentBlockOfASHAD.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/blockOfASHADWithQuaridium.java
Normal file → Executable file
2
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/tileentities/ModTileEntities.java
Normal file → Executable file
@ -11,6 +11,8 @@ public class ModTileEntities {
|
|||||||
ASURegistryHelper.registerTileEntity(TileEntityNetherCoreGenerator.class, "NetherCore");
|
ASURegistryHelper.registerTileEntity(TileEntityNetherCoreGenerator.class, "NetherCore");
|
||||||
ASURegistryHelper.registerTileEntity(TileEntityAdvancedWasteHandler.class, "AdvancedWasteHandler_true");
|
ASURegistryHelper.registerTileEntity(TileEntityAdvancedWasteHandler.class, "AdvancedWasteHandler_true");
|
||||||
ASURegistryHelper.registerTileEntity(TileEntityAdvancedWasteHandler.class, "AdvancedWasteHandler_false");
|
ASURegistryHelper.registerTileEntity(TileEntityAdvancedWasteHandler.class, "AdvancedWasteHandler_false");
|
||||||
|
ASURegistryHelper.registerTileEntity(TileEntityFrameProjector.class, "FrameProjector_false");
|
||||||
|
ASURegistryHelper.registerTileEntity(TileEntityFrameProjector.class, "FrameProjector_true");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/tileentities/TileEntityASUPedestal.java
Normal file → Executable file
2
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/tileentities/TileEntityAdvancedWasteHandler.java
Normal file → Executable file
@ -13,7 +13,7 @@ public class TileEntityAdvancedWasteHandler extends TileEntityGenerator implemen
|
|||||||
Item item[] = new Item[6];
|
Item item[] = new Item[6];
|
||||||
public TileEntityAdvancedWasteHandler() {
|
public TileEntityAdvancedWasteHandler() {
|
||||||
for (int i = 0; i < fuelqueue.length; i++) {
|
for (int i = 0; i < fuelqueue.length; i++) {
|
||||||
fuelqueue[i] = 5;
|
fuelqueue[i] = 3;
|
||||||
}
|
}
|
||||||
|
|
||||||
item[0] = Items.bone;
|
item[0] = Items.bone;
|
||||||
|
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/tileentities/TileEntityCoreStabilizer.java
Normal file → Executable file
66
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/tileentities/TileEntityEnderCoreGenerator.java
Normal file → Executable file
@ -21,69 +21,5 @@ public class TileEntityEnderCoreGenerator extends TileEntityGenerator implements
|
|||||||
setUpgradeslotstart(1);
|
setUpgradeslotstart(1);
|
||||||
setFuelConversionSpeed(15F);
|
setFuelConversionSpeed(15F);
|
||||||
}
|
}
|
||||||
|
|
||||||
// @Override
|
|
||||||
// public void readFromNBT(NBTTagCompound var1) {
|
|
||||||
// this.rotationY = var1.getFloat("rotationY");
|
|
||||||
// this.rotationX = var1.getFloat("rotationX");
|
|
||||||
// this.speed = var1.getFloat("speed");
|
|
||||||
// this.toggle = var1.getBoolean("toggle");
|
|
||||||
// this.speedSlower = var1.getFloat("speedSlower");
|
|
||||||
// this.currentPower = var1.getInteger("currentPower");
|
|
||||||
// this.multiblock = var1.getBoolean("multiblock");
|
|
||||||
// this.currentPower = var1.getInteger("currentPower");
|
|
||||||
// this.currentfuelqueue = var1.getInteger("Fuel");
|
|
||||||
// this.currentcooldown = var1.getInteger("currentCooldown");
|
|
||||||
// this.cooldown = var1.getInteger("cooldown");
|
|
||||||
//
|
|
||||||
// NBTTagList slots = var1.getTagList("items", 10);
|
|
||||||
// this.items = new ItemStack[getSizeInventory()];
|
|
||||||
//
|
|
||||||
// for (int i = 0; i < slots.tagCount(); i++) {
|
|
||||||
// NBTTagCompound item = slots.getCompoundTagAt(i);
|
|
||||||
// byte itemPos = item.getByte("itemPos");
|
|
||||||
//
|
|
||||||
// if (itemPos >= 0 && itemPos < this.items.length) {
|
|
||||||
// this.items[itemPos] = ItemStack.loadItemStackFromNBT(item);
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// if (var1.hasKey("customName")) {
|
|
||||||
// this.setCustomInventoryName(var1.getString("customName"));
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// super.readFromNBT(var1);
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// @Override
|
|
||||||
// public void writeToNBT(NBTTagCompound var1) {
|
|
||||||
// var1.setFloat("rotationY", this.rotationY);
|
|
||||||
// var1.setFloat("rotationX", this.rotationX);
|
|
||||||
// var1.setFloat("speed", this.speed);
|
|
||||||
// var1.setBoolean("toggle", this.toggle);
|
|
||||||
// var1.setFloat("speedSlower", this.speedSlower);
|
|
||||||
// var1.setBoolean("multiblock", this.multiblock);
|
|
||||||
// var1.setInteger("currentPower", this.currentPower);
|
|
||||||
// var1.setInteger("Fuel", this.currentfuelqueue);
|
|
||||||
// var1.setInteger("currentCooldown", this.currentcooldown);
|
|
||||||
// var1.setInteger("cooldown", this.cooldown);
|
|
||||||
//
|
|
||||||
// NBTTagList slots = new NBTTagList();
|
|
||||||
// for (int i = 0; i < items.length; i++) {
|
|
||||||
// if (this.items[i] != null) {
|
|
||||||
// NBTTagCompound item = new NBTTagCompound();
|
|
||||||
// item.setByte("itemPos", (byte) i);
|
|
||||||
// this.items[i].writeToNBT(item);
|
|
||||||
// slots.appendTag(item);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// if (this.hasCustomInventoryName()) {
|
|
||||||
// var1.setString("customName", this.customName);
|
|
||||||
// }
|
|
||||||
// var1.setTag("items", slots);
|
|
||||||
// super.writeToNBT(var1);
|
|
||||||
//
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,122 @@
|
|||||||
|
package org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks.tileentities;
|
||||||
|
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.inventory.Container;
|
||||||
|
import net.minecraft.inventory.ISidedInventory;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
|
||||||
|
public class TileEntityFrameProjector extends TileEntity implements ISidedInventory {
|
||||||
|
|
||||||
|
ItemStack items[];
|
||||||
|
|
||||||
|
boolean module[];
|
||||||
|
boolean multiBlock;
|
||||||
|
|
||||||
|
public TileEntityFrameProjector(boolean multiBlock) {
|
||||||
|
this.multiBlock = multiBlock;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean getMultiBlock() {
|
||||||
|
return multiBlock;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setModules(boolean module[]) {
|
||||||
|
this.module = module;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getSizeInventory() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ItemStack getStackInSlot(int p_70301_1_) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ItemStack decrStackSize(int p_70298_1_, int p_70298_2_) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ItemStack getStackInSlotOnClosing(int p_70304_1_) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setInventorySlotContents(int p_70299_1_, ItemStack p_70299_2_) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getInventoryName() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean hasCustomInventoryName() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getInventoryStackLimit() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isUseableByPlayer(EntityPlayer p_70300_1_) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void openInventory() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void closeInventory() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isItemValidForSlot(int p_94041_1_, ItemStack p_94041_2_) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int[] getAccessibleSlotsFromSide(int p_94128_1_) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean canInsertItem(int p_102007_1_, ItemStack p_102007_2_,
|
||||||
|
int p_102007_3_) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean canExtractItem(int p_102008_1_, ItemStack p_102008_2_,
|
||||||
|
int p_102008_3_) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,6 @@
|
|||||||
|
package org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks.tileentities;
|
||||||
|
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
|
||||||
|
public class TileEntityFrameSupport extends TileEntity {
|
||||||
|
}
|
66
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modblocks/tileentities/TileEntityNetherCoreGenerator.java
Normal file → Executable file
@ -17,76 +17,10 @@ public class TileEntityNetherCoreGenerator extends TileEntityGenerator implement
|
|||||||
item = new Item[1];
|
item = new Item[1];
|
||||||
fuel[0] = 110;
|
fuel[0] = 110;
|
||||||
item[0] = Items.blaze_rod;
|
item[0] = Items.blaze_rod;
|
||||||
setParticle("flame");
|
|
||||||
configureVars(fuel, 30000, 125);
|
configureVars(fuel, 30000, 125);
|
||||||
ItemValidityByItem(item);
|
ItemValidityByItem(item);
|
||||||
setItems(new ItemStack[4]);
|
setItems(new ItemStack[4]);
|
||||||
setUpgradeslotstart(1);
|
setUpgradeslotstart(1);
|
||||||
setFuelConversionSpeed(15F);
|
setFuelConversionSpeed(15F);
|
||||||
}
|
}
|
||||||
|
|
||||||
// @Override
|
|
||||||
// public void readFromNBT(NBTTagCompound var1) {
|
|
||||||
// this.rotationY = var1.getFloat("rotationY");
|
|
||||||
// this.rotationX = var1.getFloat("rotationX");
|
|
||||||
// this.speed = var1.getFloat("speed");
|
|
||||||
// this.toggle = var1.getBoolean("toggle");
|
|
||||||
// this.speedSlower = var1.getFloat("speedSlower");
|
|
||||||
// this.currentPower = var1.getInteger("currentPower");
|
|
||||||
// this.multiblock = var1.getBoolean("multiblock");
|
|
||||||
// this.currentPower = var1.getInteger("currentPower");
|
|
||||||
// this.currentfuelqueue = var1.getInteger("Fuel");
|
|
||||||
// this.currentcooldown = var1.getInteger("currentCooldown");
|
|
||||||
// this.cooldown = var1.getInteger("cooldown");
|
|
||||||
//
|
|
||||||
// NBTTagList slots = var1.getTagList("items", 10);
|
|
||||||
// this.items = new ItemStack[getSizeInventory()];
|
|
||||||
//
|
|
||||||
// for (int i = 0; i < slots.tagCount(); i++) {
|
|
||||||
// NBTTagCompound item = slots.getCompoundTagAt(i);
|
|
||||||
// byte itemPos = item.getByte("itemPos");
|
|
||||||
//
|
|
||||||
// if (itemPos >= 0 && itemPos < this.items.length) {
|
|
||||||
// this.items[itemPos] = ItemStack.loadItemStackFromNBT(item);
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// if (var1.hasKey("customName")) {
|
|
||||||
// this.setCustomInventoryName(var1.getString("customName"));
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// super.readFromNBT(var1);
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// @Override
|
|
||||||
// public void writeToNBT(NBTTagCompound var1) {
|
|
||||||
// var1.setFloat("rotationY", this.rotationY);
|
|
||||||
// var1.setFloat("rotationX", this.rotationX);
|
|
||||||
// var1.setFloat("speed", this.speed);
|
|
||||||
// var1.setBoolean("toggle", this.toggle);
|
|
||||||
// var1.setFloat("speedSlower", this.speedSlower);
|
|
||||||
// var1.setBoolean("multiblock", this.multiblock);
|
|
||||||
// var1.setInteger("currentPower", this.currentPower);
|
|
||||||
// var1.setInteger("Fuel", this.currentfuelqueue);
|
|
||||||
// var1.setInteger("currentCooldown", this.currentcooldown);
|
|
||||||
// var1.setInteger("cooldown", this.cooldown);
|
|
||||||
//
|
|
||||||
// NBTTagList slots = new NBTTagList();
|
|
||||||
// for (int i = 0; i < items.length; i++) {
|
|
||||||
// if (this.items[i] != null) {
|
|
||||||
// NBTTagCompound item = new NBTTagCompound();
|
|
||||||
// item.setByte("itemPos", (byte) i);
|
|
||||||
// this.items[i].writeToNBT(item);
|
|
||||||
// slots.appendTag(item);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// if (this.hasCustomInventoryName()) {
|
|
||||||
// var1.setString("customName", this.customName);
|
|
||||||
// }
|
|
||||||
// var1.setTag("items", slots);
|
|
||||||
// super.writeToNBT(var1);
|
|
||||||
//
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modcontainers/ContainerAdvancedWasteHandler.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modcontainers/ContainerEnderCoreGenerator.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modcontainers/ContainerNetherCoreGenerator.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modcontainers/modslots/EnderCoreGeneratorSlot.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/modcontainers/modslots/NetherCoreGeneratorSlot.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/models/blockmodel/ModelASUPedestal.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/models/blockmodel/ModelCoreGenerator.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/models/blockmodel/ModelCoreStabilizer.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/ASHADBrick.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/AdvancedProcessingChip.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/BasicChip.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/ConversionSpeedUpgrade.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/FanModule.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/FocusModule.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/HumanInterfaceGate.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/ModItems.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/PCBTemplate.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/ProcessingChip.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/QuaridiumIngot.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/SolderingIron.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/SpacialFocusingModule.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/moditems/Wrench.java
Normal file → Executable file
@ -0,0 +1,16 @@
|
|||||||
|
package org.bitbucket.alltra101ify.advancedsatelliteutilization.moditems;
|
||||||
|
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.ModInfo;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.moditemblockreference.ModBasicItemTemplate;
|
||||||
|
|
||||||
|
import net.minecraft.item.Item;
|
||||||
|
|
||||||
|
public class satelliteFrame extends ModBasicItemTemplate {
|
||||||
|
byte tier;
|
||||||
|
public satelliteFrame(byte tier) {
|
||||||
|
this.tier = tier;
|
||||||
|
|
||||||
|
setTextureName(ModInfo.MODID + ":" + getUnlocalizedName().substring(5) + "T" + tier);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/packets/ASUCoreTogglePacket.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/proxy/ClientProxy.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/proxy/CommonProxy.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/reference/ASUCrafting.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/reference/ASURegistryHelper.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/reference/ModCreativeTabs.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/reference/ModInfo.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/reference/moditemblockreference/ItemBlockMaterial.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/reference/moditemblockreference/ModBasicItemTemplate.java
Normal file → Executable file
@ -0,0 +1,72 @@
|
|||||||
|
package org.bitbucket.alltra101ify.advancedsatelliteutilization.reference.moditemblockreference;
|
||||||
|
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.AdvancedSatelliteUtilization;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modGUIs.ModGUIs;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks.ModBlocks;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.modblocks.tileentities.TileEntityEnderCoreGenerator;
|
||||||
|
import org.bitbucket.alltra101ify.advancedsatelliteutilization.moditems.ModItems;
|
||||||
|
|
||||||
|
import cpw.mods.fml.common.network.internal.FMLNetworkHandler;
|
||||||
|
import net.minecraft.block.Block;
|
||||||
|
import net.minecraft.block.BlockContainer;
|
||||||
|
import net.minecraft.block.material.Material;
|
||||||
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
import net.minecraft.util.ChatComponentText;
|
||||||
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
|
public abstract class ModBasicMachineBlock extends Block {
|
||||||
|
protected ModBasicMachineBlock(Material material) {
|
||||||
|
super(material);
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param player EntityPlayer
|
||||||
|
* @param world world
|
||||||
|
* @param x x coordinate
|
||||||
|
* @param y y coordinate
|
||||||
|
* @param z z coordinate
|
||||||
|
* @param multiblock if this is a multiblock or not. If does not belong to a multiblock, always true.
|
||||||
|
* @param currentPower current power of the block. For debugging purposes.
|
||||||
|
* @param scale percentage of power
|
||||||
|
* @param itemtogive item to return when using wrench to break
|
||||||
|
* @return returns 1 on array [1] on servers if it is valid for opening gui while 2 is for destroying and giving item to player. array [0] is to set the new power.
|
||||||
|
*/
|
||||||
|
public int[] wrenched(EntityPlayer player, World world, int x, int y, int z, boolean multiblock, int currentPower, byte scale, ItemStack itemtogive) {
|
||||||
|
int[] info = new int[2];
|
||||||
|
info[0] = currentPower;
|
||||||
|
info[1] = 0;
|
||||||
|
|
||||||
|
if (player.getCurrentEquippedItem().stackTagCompound != null) {
|
||||||
|
byte mode = player.getCurrentEquippedItem().stackTagCompound.getByte("Mode");
|
||||||
|
|
||||||
|
switch (mode) {
|
||||||
|
case 0:
|
||||||
|
if (!world.isRemote && multiblock == true && world.getTileEntity(x, y, z) != null) {
|
||||||
|
info[1] = 1;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 1: info[1] = 2; world.setBlockToAir(x, y, z); world.removeTileEntity(x, y, z); player.inventory.addItemStackToInventory(itemtogive);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 2: info[0] += 100; if(world.isRemote) {player.addChatMessage(new ChatComponentText("added 100 power. " + "Current power: " + info[0]));};
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 3: if(world.isRemote) {player.addChatMessage(new ChatComponentText("Current power: " + currentPower));}
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 4: if(world.isRemote) {player.addChatMessage(new ChatComponentText("Current percentage calculation: " + scale));}
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 5: info[0] -= 100; if(world.isRemote) {player.addChatMessage(new ChatComponentText("removed 100 power. " + "Current power: " + info[0]));};
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
return info;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
4
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/reference/moditemblockreference/ModMachineBlock.java
Normal file → Executable file
@ -21,7 +21,6 @@ public abstract class ModMachineBlock extends BlockContainer {
|
|||||||
super(material);
|
super(material);
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @param player EntityPlayer
|
* @param player EntityPlayer
|
||||||
* @param world world
|
* @param world world
|
||||||
* @param x x coordinate
|
* @param x x coordinate
|
||||||
@ -31,7 +30,7 @@ public abstract class ModMachineBlock extends BlockContainer {
|
|||||||
* @param currentPower current power of the block. For debugging purposes.
|
* @param currentPower current power of the block. For debugging purposes.
|
||||||
* @param scale percentage of power
|
* @param scale percentage of power
|
||||||
* @param itemtogive item to return when using wrench to break
|
* @param itemtogive item to return when using wrench to break
|
||||||
* @return returns 1 on array [1] on servers if it is valid for opening gui while 2 is for destroying and giving item to player. array [0] is to set the new power.
|
* @return returns 1 on array [1] on servers if it is valid for opening gui while 2 is for destroying and giving item to player. Array [0] is to set the new power.
|
||||||
*/
|
*/
|
||||||
public int[] wrenched(EntityPlayer player, World world, int x, int y, int z, boolean multiblock, int currentPower, byte scale, ItemStack itemtogive) {
|
public int[] wrenched(EntityPlayer player, World world, int x, int y, int z, boolean multiblock, int currentPower, byte scale, ItemStack itemtogive) {
|
||||||
int[] info = new int[2];
|
int[] info = new int[2];
|
||||||
@ -67,5 +66,4 @@ public abstract class ModMachineBlock extends BlockContainer {
|
|||||||
}
|
}
|
||||||
return info;
|
return info;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
7
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/reference/moditemblockreference/TileEntityGenerator.java
Normal file → Executable file
@ -23,7 +23,7 @@ public class TileEntityGenerator extends TileEntity implements ISidedInventory {
|
|||||||
public float FuelConversionSpeed, currentfuelqueue, currentPower;
|
public float FuelConversionSpeed, currentfuelqueue, currentPower;
|
||||||
public float rotationX, rotationY, speed, speedSlower;
|
public float rotationX, rotationY, speed, speedSlower;
|
||||||
Item[] validItemByItem;
|
Item[] validItemByItem;
|
||||||
String validItemByString, particle;
|
String validItemByString;
|
||||||
protected int x, y, z;
|
protected int x, y, z;
|
||||||
@Override
|
@Override
|
||||||
public void updateEntity() {
|
public void updateEntity() {
|
||||||
@ -333,7 +333,6 @@ public class TileEntityGenerator extends TileEntity implements ISidedInventory {
|
|||||||
this.validItemByItem = item;
|
this.validItemByItem = item;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @param string (should only be used for testing as there is very little control) Sets what is valid by name of item.
|
* @param string (should only be used for testing as there is very little control) Sets what is valid by name of item.
|
||||||
*/
|
*/
|
||||||
public void itemValidityByString(String string) {
|
public void itemValidityByString(String string) {
|
||||||
@ -353,10 +352,6 @@ public class TileEntityGenerator extends TileEntity implements ISidedInventory {
|
|||||||
this.z = z;
|
this.z = z;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setParticle(String particle) {
|
|
||||||
this.particle = particle;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void writeToNBT(NBTTagCompound var1) {
|
public void writeToNBT(NBTTagCompound var1) {
|
||||||
var1.setFloat("rotationY", this.rotationY);
|
var1.setFloat("rotationY", this.rotationY);
|
||||||
|
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/renderer/RenderASUPedestal.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/renderer/RenderCoreStabilizer.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/renderer/RenderEnderCoreGenerator.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/renderer/RenderNetherCoreGenerator.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/renderer/inventoryrender/ItemRenderASUPedestal.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/renderer/inventoryrender/ItemRenderCoreStabilizer.java
Normal file → Executable file
0
src/main/java/org/bitbucket/alltra101ify/advancedsatelliteutilization/renderer/inventoryrender/ItemRenderEnderCoreGenerator.java
Normal file → Executable file
2
src/main/resources/assets/asu/lang/en_US.lang
Normal file → Executable file
@ -27,4 +27,6 @@ tile.BlockOfASHADWithQuaridium.name=Block of ASHAD with Quaridium
|
|||||||
tile.NetherCoreGenerator.name=Nether Core Generator
|
tile.NetherCoreGenerator.name=Nether Core Generator
|
||||||
tile.AdvancedWasteHandler_false.name=Advanced Waste Disposer
|
tile.AdvancedWasteHandler_false.name=Advanced Waste Disposer
|
||||||
tile.AdvancedWasteHandler_true.name=Advanced Waste Disposer
|
tile.AdvancedWasteHandler_true.name=Advanced Waste Disposer
|
||||||
|
tile.FrameSupport.name=Frame Support
|
||||||
|
tile.FrameProjector_false.name=Frame Projector
|
||||||
itemGroup.asu=Advanced Satellite Utilization
|
itemGroup.asu=Advanced Satellite Utilization
|
0
src/main/resources/assets/asu/textures/blocks/ASUPedestal.png
Normal file → Executable file
Before Width: | Height: | Size: 345 B After Width: | Height: | Size: 345 B |
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/AdvancedWasteHandler_false_bottom.png
Normal file → Executable file
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 2.0 KiB |
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/AdvancedWasteHandler_false_front.png
Normal file → Executable file
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 1.9 KiB |
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/AdvancedWasteHandler_false_sides.png
Normal file → Executable file
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 2.1 KiB |
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/AdvancedWasteHandler_false_top.png
Normal file → Executable file
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/AdvancedWasteHandler_true_bottom.png
Normal file → Executable file
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 2.0 KiB |
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/AdvancedWasteHandler_true_front.png
Normal file → Executable file
Before Width: | Height: | Size: 6.8 KiB After Width: | Height: | Size: 6.8 KiB |
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/AdvancedWasteHandler_true_front.png.mcmeta
Normal file → Executable file
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/AdvancedWasteHandler_true_sides.png
Normal file → Executable file
Before Width: | Height: | Size: 7.2 KiB After Width: | Height: | Size: 7.2 KiB |
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/AdvancedWasteHandler_true_sides.png.mcmeta
Normal file → Executable file
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/AdvancedWasteHandler_true_top.png
Normal file → Executable file
Before Width: | Height: | Size: 2.7 KiB After Width: | Height: | Size: 2.7 KiB |
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/AdvancedWasteHandler_true_top.png.mcmeta
Normal file → Executable file
0
src/main/resources/assets/asu/textures/blocks/AdvancedWasteHandler/BlockOfASHAD.png
Normal file → Executable file
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 2.0 KiB |
0
src/main/resources/assets/asu/textures/blocks/B-Lock-er.png
Normal file → Executable file
Before Width: | Height: | Size: 5.1 KiB After Width: | Height: | Size: 5.1 KiB |
0
src/main/resources/assets/asu/textures/blocks/BlockOfASHAD.png
Normal file → Executable file
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 2.0 KiB |
0
src/main/resources/assets/asu/textures/blocks/BlockOfASHADWithQuaridium.png
Normal file → Executable file
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 1.9 KiB |
0
src/main/resources/assets/asu/textures/blocks/CoreStabilizer.png
Normal file → Executable file
Before Width: | Height: | Size: 276 B After Width: | Height: | Size: 276 B |
0
src/main/resources/assets/asu/textures/blocks/EnderCoreGenerator.png
Normal file → Executable file
Before Width: | Height: | Size: 587 B After Width: | Height: | Size: 587 B |
After Width: | Height: | Size: 222 B |
After Width: | Height: | Size: 215 B |
BIN
src/main/resources/assets/asu/textures/blocks/FrameSupport.png
Normal file
After Width: | Height: | Size: 189 B |
0
src/main/resources/assets/asu/textures/blocks/NetherCoreGenerator.png
Normal file → Executable file
Before Width: | Height: | Size: 420 B After Width: | Height: | Size: 420 B |
0
src/main/resources/assets/asu/textures/blocks/QuaridiumOre.png
Normal file → Executable file
Before Width: | Height: | Size: 387 B After Width: | Height: | Size: 387 B |
0
src/main/resources/assets/asu/textures/blocks/TransparentBlockOfASHAD.png
Normal file → Executable file
Before Width: | Height: | Size: 325 B After Width: | Height: | Size: 325 B |