SHARE
TWEET

Untitled

a guest Oct 26th, 2015 75 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package kaoticube;
  2.  
  3. import cpw.mods.fml.client.*;
  4. import cpw.mods.fml.client.registry.*;
  5. import cpw.mods.fml.common.*;
  6. import cpw.mods.fml.common.asm.*;
  7. import cpw.mods.fml.common.asm.transformers.*;
  8. import cpw.mods.fml.common.discovery.*;
  9. import cpw.mods.fml.common.discovery.asm.*;
  10. import cpw.mods.fml.common.event.*;
  11. import cpw.mods.fml.common.functions.*;
  12. import cpw.mods.fml.common.network.*;
  13. import cpw.mods.fml.common.registry.*;
  14. import cpw.mods.fml.common.toposort.*;
  15. import cpw.mods.fml.common.versioning.*;
  16. import cpw.mods.fml.relauncher.*;
  17. import cpw.mods.fml.server.*;
  18. import net.minecraft.block.*;
  19. import net.minecraft.block.material.*;
  20. import net.minecraft.client.*;
  21. import net.minecraft.client.audio.*;
  22. import net.minecraft.client.entity.*;
  23. import net.minecraft.client.gui.*;
  24. import net.minecraft.client.gui.achievement.*;
  25. import net.minecraft.client.gui.inventory.*;
  26. import net.minecraft.client.model.*;
  27. import net.minecraft.client.multiplayer.*;
  28. import net.minecraft.client.particle.*;
  29. import net.minecraft.client.renderer.*;
  30. import net.minecraft.client.renderer.culling.*;
  31. import net.minecraft.client.renderer.entity.*;
  32. import net.minecraft.client.renderer.tileentity.*;
  33. import net.minecraft.client.settings.*;
  34. import net.minecraft.command.*;
  35. import net.minecraft.crash.*;
  36. import net.minecraft.creativetab.*;
  37. import net.minecraft.dispenser.*;
  38. import net.minecraft.enchantment.*;
  39. import net.minecraft.entity.*;
  40. import net.minecraft.entity.ai.*;
  41. import net.minecraft.entity.boss.*;
  42. import net.minecraft.entity.effect.*;
  43. import net.minecraft.entity.item.*;
  44. import net.minecraft.entity.monster.*;
  45. import net.minecraft.entity.passive.*;
  46. import net.minecraft.entity.player.*;
  47. import net.minecraft.entity.projectile.*;
  48. import net.minecraft.inventory.*;
  49. import net.minecraft.item.*;
  50. import net.minecraft.item.crafting.*;
  51. import net.minecraft.nbt.*;
  52. import net.minecraft.network.*;
  53. import net.minecraft.network.rcon.*;
  54. import net.minecraft.pathfinding.*;
  55. import net.minecraft.potion.*;
  56. import net.minecraft.profiler.*;
  57. import net.minecraft.server.*;
  58. import net.minecraft.server.dedicated.*;
  59. import net.minecraft.server.gui.*;
  60. import net.minecraft.server.integrated.*;
  61. import net.minecraft.server.management.*;
  62. import net.minecraft.src.*;
  63. import net.minecraft.stats.*;
  64. import net.minecraft.tileentity.*;
  65. import net.minecraft.util.*;
  66. import net.minecraft.village.*;
  67. import net.minecraft.world.*;
  68. import net.minecraft.world.biome.*;
  69. import net.minecraft.world.chunk.*;
  70. import net.minecraft.world.chunk.storage.*;
  71. import net.minecraft.world.demo.*;
  72. import net.minecraft.world.gen.*;
  73. import net.minecraft.world.gen.feature.*;
  74. import net.minecraft.world.gen.layer.*;
  75. import net.minecraft.world.gen.structure.*;
  76. import net.minecraft.world.storage.*;
  77. import net.minecraftforge.classloading.*;
  78. import net.minecraftforge.client.*;
  79. import net.minecraftforge.client.event.*;
  80. import net.minecraftforge.client.event.sound.*;
  81. import net.minecraftforge.common.*;
  82. import net.minecraftforge.event.*;
  83. import net.minecraftforge.event.entity.*;
  84. import net.minecraftforge.event.entity.item.*;
  85. import net.minecraftforge.event.entity.living.*;
  86. import net.minecraftforge.event.entity.minecart.*;
  87. import net.minecraftforge.event.entity.player.*;
  88. import net.minecraftforge.event.terraingen.*;
  89. import net.minecraftforge.event.world.*;
  90. import net.minecraftforge.oredict.*;
  91. import net.minecraftforge.transformers.*;
  92. import net.minecraft.init.*;
  93. import java.util.*;
  94.  
  95. import net.minecraftforge.common.util.*;
  96. import net.minecraft.client.renderer.texture.*;
  97. import org.lwjgl.opengl.GL11;
  98. import org.lwjgl.opengl.GL12;
  99. public class kaoticube_titaniumblock {
  100. public static final String MODID = "kaoticube";
  101. public kaoticube_titaniumblock(){}
  102.  
  103. public static BlockTitaniumblock block;
  104.  
  105. public static Object instance;public int addFuel(ItemStack fuel){return 0;}
  106. public void serverLoad(FMLServerStartingEvent event){}
  107. public void preInit(FMLPreInitializationEvent event){
  108.  
  109. GameRegistry.registerBlock(block, "Titaniumblock");
  110. }
  111. public void registerRenderers(){}
  112. public void load(){
  113. }
  114.  
  115.  
  116. static{
  117.  
  118. block = (BlockTitaniumblock)(new BlockTitaniumblock().setHardness(7.0F)
  119. .setResistance(15.0F)
  120. .setLightLevel(0.0F)
  121. .setBlockName("Titaniumblock")
  122. .setBlockTextureName(MODID + ":Titanium")
  123. .setLightOpacity(0)
  124. .setStepSound(Block.soundTypeStone)
  125. .setCreativeTab(kaoticube_kaoTiCube.tab)
  126. );block.setBlockBounds(0.0F,0.0F,0.0F,1.0F,1.0F,1.0F);
  127. Block.blockRegistry.addObject(182, "Titaniumblock", block);
  128. block.setHarvestLevel("pickaxe", 2);
  129. }
  130.  
  131.  
  132. public void generateSurface(World world, java.util.Random rand, int chunkX, int chunkZ){
  133. for(int i = 0; i < 4; i++){
  134. int randPosX = chunkX + rand.nextInt(16);
  135. int randPosY = rand.nextInt(90)+0;
  136. int randPosZ = chunkZ + rand.nextInt(16);
  137. (new WorldGenMinable(kaoticube_titaniumblock.block, 2)).generate(world, rand, randPosX, randPosY, randPosZ);
  138. }
  139. }
  140.  
  141. public void generateNether(World world, Random random, int chunkX, int chunkZ){}
  142. static class BlockTitaniumblock extends Block
  143. {
  144.  
  145. int a1 = 0,a2 = 0,a3 = 0,a4 = 0,a5 = 0,a6 = 0;
  146.  
  147. IIcon gor = null, dol = null, st1 = null, st2 = null, st3 = null, st4 = null;
  148.  
  149. boolean red = false;
  150.  
  151.  
  152.  
  153.  
  154.  
  155. protected BlockTitaniumblock()
  156. {
  157.         super(Material.ground);
  158.  
  159. }
  160.  
  161. @SideOnly(Side.CLIENT)
  162. public void onBlockAdded(World world, int i, int j, int k){
  163. EntityPlayer entity = Minecraft.getMinecraft().thePlayer;
  164. if(entity!=null&&world!=null){
  165. int le = MathHelper.floor_double((double)(entity.rotationYaw * 4.0F / 360.0F) + 0.5D) & 3;
  166. world.setBlockMetadataWithNotify(i, j, k, le, 2);
  167. }
  168.  
  169. world.scheduleBlockUpdate(i, j, k, this, this.tickRate(world));
  170.  
  171. }
  172. public int isProvidingStrongPower(IBlockAccess par1IBlockAccess, int par2, int par3, int par4, int par5){
  173. return red?1:0;
  174. }
  175. @SideOnly(Side.CLIENT)
  176. @Override
  177. public IIcon getIcon(int i, int par2){
  178.  
  179. if (i == 0)
  180. return gor;
  181.  
  182. else if (i == 1)
  183. return dol;
  184.  
  185. else if (i == 2)
  186. return st1;
  187.  
  188. else if (i == 3)
  189. return st2;
  190.  
  191. else if (i == 4)
  192. return st4;
  193.  
  194. else if (i == 5)
  195. return st3;
  196.  
  197. else
  198. return gor;
  199.  
  200. }
  201.  
  202. @SideOnly(Side.CLIENT)
  203.  
  204. @Override
  205. public void registerBlockIcons(IIconRegister reg){
  206. this.gor = reg.registerIcon("Titanium");
  207. this.dol = reg.registerIcon("Titanium");
  208. this.st1 = reg.registerIcon("Titanium");
  209. this.st2 = reg.registerIcon("Titanium");
  210. this.st3 = reg.registerIcon("Titanium");
  211. this.st4 = reg.registerIcon("Titanium");
  212. }
  213. public int getRenderType(){
  214. return 0;
  215. }
  216. @Override
  217. public int tickRate(World world)
  218. {
  219.     return 10;
  220. }
  221.  
  222. public int quantityDropped(Random par1Random){
  223. return 1;
  224. }
  225.  
  226. public Item getItemDropped(int par1, Random par2Random, int par3){
  227. return Item.getItemFromBlock(kaoticube_titaniumblock.block);
  228. }
  229. }
  230. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top