This commit is contained in:
oitsjustjose 2013-07-07 01:01:22 -05:00
commit 1860655e8b
190 changed files with 562 additions and 0 deletions

View file

@ -0,0 +1,280 @@
package MysticOres.Blocks;
import static net.minecraftforge.common.ForgeDirection.DOWN;
import static net.minecraftforge.common.ForgeDirection.UP;
import java.util.List;
import java.util.Random;
import MysticOres.MysticOres;
import MysticOres.Items.ItemHandler;
import net.minecraft.block.Block;
import net.minecraft.block.BlockBreakable;
import net.minecraft.block.BlockFarmland;
import net.minecraft.block.BlockHalfSlab;
import net.minecraft.block.BlockHopper;
import net.minecraft.block.BlockPoweredOre;
import net.minecraft.block.BlockStairs;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.entity.Entity;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.Icon;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.common.ForgeDirection;
import cpw.mods.fml.common.ModMetadata;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class BlockBase extends BlockBreakable {
Icon[] textures;
private boolean RenderSide = false;
public BlockBase(int ID) {
super(ID, "BlockOres", Material.rock, true);
setCreativeTab(MysticOres.MysticOresTab);
setResistance(2000F);
this.RenderSide = false;
}
@Override
public float getBlockHardness(World world, int x, int y, int z)
{
int damageValue = world.getBlockMetadata(x, y, z);
if(damageValue == 12)
{
return 4.5F;
}
else return 3.0F;
}
@Override
public int getLightOpacity(World world, int x, int y, int z)
{
return 0;
}
@Override
public int getLightValue(IBlockAccess world, int x, int y, int z)
{
int damageValue = world.getBlockMetadata(x, y, z);
if(damageValue == 2 || damageValue == 3)
{
return 7;
}
else return 0;
}
@Override
@SideOnly(Side.CLIENT)
public void registerIcons(IconRegister iconRegister)
{
textures = new Icon[16];
for (int i = 0; i < 13; i++)
{
textures[i] = iconRegister.registerIcon("MysticTextures" + ":" + ItemBlockBase.BLOCK_NAMES[i]);
}
}
@Override
public Icon getIcon(int side, int meta) {
return textures[meta];
}
public int idDropped(int par1, Random par2Random, int par3) {
switch(par1){
case 1:return ItemHandler.Resource.itemID;
case 2:return ItemHandler.Resource.itemID;
case 4:return ItemHandler.Resource.itemID;
case 5:return ItemHandler.Resource.itemID;
case 7:return ItemHandler.Resource.itemID;
case 8:return this.BlackSoulstoneDrops(par1, par2Random, par3);
case 9:return this.BlueSoulstoneDrops(par1, par2Random, par3);
case 10:return this.RedSoulstoneDrops(par1, par2Random, par3);
case 11:return ItemHandler.Resource.itemID;
case 12:return ItemHandler.Resource.itemID;
default:return blockID;
}
}
@Override
public int damageDropped(int j) {
switch(j){
case 1:return 8;
case 2:return 4;
case 4:return 5;
case 5:return 7;
case 7:return 10;
case 8:return 0;
case 9:return 0;
case 10:return 0;
case 11:return 6;
case 12:return 11;
default: return j;
}
}
public int xpDropAmount(int j) {
switch(j){
case 1:return 6;
case 2:return 6;
case 4:return 6;
case 5:return 6;
case 7:return 6;
case 8:return 6;
case 9:return 6;
case 10:return 6;
case 11:return 6;
default: return 0;
}
}
protected boolean canSilkHarvest()
{
return true;
}
public int BlackSoulstoneDrops(int par1, Random par2Random, int par3)
{
int w = par2Random.nextInt(3);
if (w == 0)
{
return Item.coal.itemID;
}
if (w == 1)
{
return Item.gunpowder.itemID;
}
else
{
return Item.sugar.itemID;
}
}
public int RedSoulstoneDrops(int par1, Random par2Random, int par3)
{
for(int i=0;i<3;i++)
{
}
int w = par2Random.nextInt(3);
if (w == 0)
{
return Item.lightStoneDust.itemID;
}
if (w == 1)
{
return Item.gunpowder.itemID;
}
if (w == 2)
{
return Item.redstone.itemID;
}
if (w==3)
{
return Block.obsidian.blockID;
}
else
{
return Item.gunpowder.itemID;
}
}
public int BlueSoulstoneDrops(int par1, Random par2Random, int par3)
{
int w = par2Random.nextInt(5);
if (w == 1)
{
return Item.diamond.itemID;
}
if (w == 2)
{
return Block.obsidian.blockID;
}
if (w == 3)
{
return Item.gunpowder.itemID;
}
if (w==4)
{
return Item.lightStoneDust.itemID;
}
else
{
return Item.emerald.itemID;
}
}
public int idPicked(World par1World, int par2, int par3, int par4)
{
return this.blockID;
}
public ItemStack getPickBlock(MovingObjectPosition target, World world, int x, int y, int z)
{
int meta = world.getBlockMetadata(x, y, z);
return new ItemStack(this, 1, meta);
}
public void getSubBlocks(int i,CreativeTabs tab, List list)
{
for(int meta=0; meta<13; meta++)
{
list.add(new ItemStack(i,1,meta));
}
}
public boolean shouldSideBeRendered(IBlockAccess par1IBlockAccess, int par2, int par3, int par4, int par5)
{
int meta = par1IBlockAccess.getBlockMetadata(par2, par3, par4);
int blockID = par1IBlockAccess.getBlockId(par2, par3, par4);
if(meta == 12 && blockID == this.blockID)
{
return false;
}
else return true;
}
public int getRenderBlockPass()
{
return 0;
}
public boolean renderAsNormalBlock()
{
return false;
}
public boolean isBlockNormalCube(World world, int x, int y, int z)
{
return true;
}
public boolean isBlockSolidOnSide(World world, int x, int y, int z, ForgeDirection side)
{
int meta = world.getBlockMetadata(x, y, z);
if(meta == 12)
{
return false;
}
else return true;
}
}

View file

@ -0,0 +1,42 @@
package MysticOres.Blocks;
import java.util.List;
import MysticOres.MysticOres;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
import net.minecraft.util.Icon;
import net.minecraft.util.MathHelper;
public class ItemBlockBase extends ItemBlock {
public static String[] BLOCK_NAMES = new String[] {"Adamantine Ore", "Amethyst Ore", "Iridium Ore", "Mithril Ore", "Tourmaline Ore", "Topaz Ore", "Verdite Ore", "Bloodstone", "Black Soulstone",
"Blue Soulstone", "Red Soulstone", "Agate Ore", "Reinforced Glass"};
public ItemBlockBase(int par1) {
super(par1);
setMaxDamage(0);
setHasSubtypes(true);
}
@Override
public String getUnlocalizedName(ItemStack itemStack) {
int meta = MathHelper.clamp_int(itemStack.getItemDamage(), 0, BLOCK_NAMES.length);
return super.getUnlocalizedName() + BLOCK_NAMES[meta];
}
public int getMetadata(int par1)
{
return par1;
}
@SideOnly(Side.CLIENT)
public Icon getIconFromDamage(int par1)
{
return BlockHandler.BlockBase.getIcon(2, par1);
}
}

View file

@ -0,0 +1,49 @@
package MysticStones;
import net.minecraft.item.ItemStack;
import cpw.mods.fml.common.registry.LanguageRegistry;
public class LanguageManager
{
public static void init()
{
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 0), "Smooth Anorthosite");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 1), "Anorthosite");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 2), "Smooth Limestone");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 3), "Limestone");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 4), "Smooth Marble");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 5), "Marble");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 6), "Smooth Migmatite");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 7), "Migmatite");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 8), "Smooth Orthogneiss");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 9), "Orthogneiss");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 10), "Smooth Slate");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 11), "Slate");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 12), "Smooth Travertine");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Stones, 1, 13), "Travertine");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.StoneBricks, 1, 0), "Anorthosite Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.StoneBricks, 1, 1), "Limestone Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.StoneBricks, 1, 2), "Marble Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.StoneBricks, 1, 3), "Migmatite Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.StoneBricks, 1, 4), "Orthogneiss Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.StoneBricks, 1, 5), "Slate Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.StoneBricks, 1, 6), "Travertine Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Planks, 1, 0), "Purple Planks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Planks, 1, 1), "Green Planks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Planks, 1, 2), "Black Planks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Planks, 1, 3), "Orange Planks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Planks, 1, 4), "Red Planks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Planks, 1, 5), "Blue Planks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.Planks, 1, 6), "Yellow Planks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.ReinforcedBricks, 1, 0), "Reinforced Mithril Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.ReinforcedBricks, 1, 1), "Reinforced Verdite Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.ReinforcedBricks, 1, 2), "Reinforced Iridium Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.ReinforcedBricks, 1, 3), "Reinforced Adamantine Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.ReinforcedBricks, 1, 4), "Reinforced Tourmaline Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.ReinforcedBricks, 1, 5), "Reinforced Topaz Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.ReinforcedBricks, 1, 6), "Reinforced Amethyst Bricks");
LanguageRegistry.instance().addName(new ItemStack(MysticStones.ReinforcedBricks, 1, 7), "Reinforced Agate Bricks");
LanguageRegistry.instance().addStringLocalization("itemGroup.MysticStonesTab", "en_US", "Mystic Stones!");
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 391 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 266 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 346 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 633 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.8 KiB

View file

@ -0,0 +1,39 @@
0*2
1*2
2*2
3*2
4*2
5*2
6*2
7*2
8*2
9*2
10*2
11*2
12*2
13*2
14*2
15*2
16*2
17*2
18*2
19*2
18*2
17*2
16*2
15*2
14*2
13*2
12*2
11*2
10*2
9*2
8*2
7*2
6*2
5*2
4*2
3*2
2*2
1*2

Binary file not shown.

After

Width:  |  Height:  |  Size: 388 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 571 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 422 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 625 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 230 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 918 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 876 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 245 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 958 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.4 KiB

View file

@ -0,0 +1,38 @@
0*2
1*2
2*2
3*2
4*2
5*2
6*2
7*2
8*2
9*2
10*2
11*2
12*2
13*2
14*2
15*2
16*2
17*2
18*2
19*2
18*2
17*2
16*2
15*2
14*2
13*2
12*2
11*2
10*2
9*2
8*2
7*2
6*2
5*2
4*2
3*2
2*2
1*2

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.8 KiB

View file

@ -0,0 +1,38 @@
0*2
1*2
2*2
3*2
4*2
5*2
6*2
7*2
8*2
9*2
10*2
11*2
12*2
13*2
14*2
15*2
16*2
17*2
18*2
19*2
18*2
17*2
16*2
15*2
14*2
13*2
12*2
11*2
10*2
9*2
8*2
7*2
6*2
5*2
4*2
3*2
2*2
1*2

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.9 KiB

View file

@ -0,0 +1,38 @@
0*2
1*2
2*2
3*2
4*2
5*2
6*2
7*2
8*2
9*2
10*2
11*2
12*2
13*2
14*2
15*2
16*2
17*2
18*2
19*2
18*2
17*2
16*2
15*2
14*2
13*2
12*2
11*2
10*2
9*2
8*2
7*2
6*2
5*2
4*2
3*2
2*2
1*2

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 246 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 676 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 608 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 423 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 607 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 388 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 657 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 438 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 598 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 370 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 288 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 247 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 423 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 597 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 247 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 241 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 957 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 424 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 421 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 617 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 237 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 237 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 225 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 243 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 233 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 239 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 233 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 393 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 626 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 393 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 649 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 409 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 589 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 347 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 369 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.5 KiB

View file

@ -0,0 +1,38 @@
0*2
1*2
2*2
3*2
4*2
5*2
6*2
7*2
8*2
9*2
10*2
11*2
12*2
13*2
14*2
15*2
16*2
17*2
18*2
19*2
18*2
17*2
16*2
15*2
14*2
13*2
12*2
11*2
10*2
9*2
8*2
7*2
6*2
5*2
4*2
3*2
2*2
1*2

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 240 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 290 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 430 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 298 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 314 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 324 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 340 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 325 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 342 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 356 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 436 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 273 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 230 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 263 B

Some files were not shown because too many files have changed in this diff Show more