uranium glass, some seekrit stuff

This commit is contained in:
Bob 2020-07-23 01:08:23 +02:00
parent 81870c4863
commit 854fa0e440
19 changed files with 3505 additions and 3 deletions

View File

@ -972,6 +972,9 @@ tile.barbed_wire_wither.name=Withernder Stacheldraht
tile.barbed_wire_ultradeath.name=Wolken-Stacheldraht
tile.fence_metal.name=Maschendrahtzaun
tile.sand_uranium.name=Uransand
tile.glass_uranium.name=Uranglas
tile.glass_trinitite.name=Trinity-Glas
tile.seal_frame.name=Siloluke (Rahmen)
tile.seal_controller.name=Silolukenöffner

View File

@ -977,6 +977,9 @@ tile.barbed_wire_wither.name=Withered Barbed Wire
tile.barbed_wire_ultradeath.name=Cloud Barbed Wire
tile.fence_metal.name=Chainlink Fence
tile.sand_uranium.name=Uranium Sand
tile.glass_uranium.name=Uranium Glass
tile.glass_trinitite.name=Trinity Glass
tile.seal_frame.name=Silo Hatch Frame
tile.seal_controller.name=Silo Hatch Opener

File diff suppressed because it is too large Load Diff

Binary file not shown.

After

Width:  |  Height:  |  Size: 247 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 247 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 730 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 300 B

After

Width:  |  Height:  |  Size: 264 B

View File

@ -23,9 +23,7 @@ import com.hbm.main.MainRegistry;
import cpw.mods.fml.common.registry.GameRegistry;
import net.minecraft.block.Block;
import net.minecraft.block.BlockFalling;
import net.minecraft.block.material.MapColor;
import net.minecraft.block.material.Material;
import net.minecraft.block.material.MaterialLiquid;
import net.minecraft.block.material.*;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidRegistry;
@ -219,6 +217,10 @@ public class ModBlocks {
public static Block fence_metal;
public static Block sand_uranium;
public static Block glass_uranium;
public static Block glass_trinitite;
public static Block mush;
public static Block mush_block;
public static Block mush_block_stem;
@ -965,6 +967,10 @@ public class ModBlocks {
geiger = new GeigerCounter(Material.rock).setBlockName("geiger").setCreativeTab(MainRegistry.machineTab).setHardness(15.0F).setResistance(0.25F).setBlockTextureName(RefStrings.MODID + ":geiger");
fence_metal = new BlockMetalFence(Material.rock).setBlockName("fence_metal").setCreativeTab(MainRegistry.machineTab).setHardness(15.0F).setResistance(0.25F).setBlockTextureName(RefStrings.MODID + ":fence_metal");
sand_uranium = new BlockFalling(Material.sand).setBlockName("sand_uranium").setStepSound(Block.soundTypeSand).setCreativeTab(MainRegistry.machineTab).setHardness(0.5F).setBlockTextureName(RefStrings.MODID + ":sand_uranium");
glass_uranium = new BlockRadGlass(RefStrings.MODID + ":glass_uranium", Material.glass).setBlockName("glass_uranium").setLightLevel(5F/15F).setStepSound(Block.soundTypeGlass).setCreativeTab(MainRegistry.machineTab).setHardness(0.3F);
glass_trinitite = new BlockRadGlass(RefStrings.MODID + ":glass_trinitite", Material.glass).setBlockName("glass_trinitite").setLightLevel(5F/15F).setStepSound(Block.soundTypeGlass).setCreativeTab(MainRegistry.machineTab).setHardness(0.3F);
mush = new BlockMush(Material.plants).setBlockName("mush").setCreativeTab(MainRegistry.blockTab).setLightLevel(0.5F).setStepSound(Block.soundTypeGrass).setBlockTextureName(RefStrings.MODID + ":mush");
mush_block = new BlockMushHuge(Material.plants).setBlockName("mush_block").setLightLevel(1.0F).setStepSound(Block.soundTypeGrass).setHardness(0.2F).setBlockTextureName(RefStrings.MODID + ":mush_block_skin");
@ -1691,6 +1697,11 @@ public class ModBlocks {
//Chainlink Fence
GameRegistry.registerBlock(fence_metal, fence_metal.getUnlocalizedName());
//Sands, Glass
GameRegistry.registerBlock(sand_uranium, sand_uranium.getUnlocalizedName());
GameRegistry.registerBlock(glass_uranium, glass_uranium.getUnlocalizedName());
GameRegistry.registerBlock(glass_trinitite, glass_trinitite.getUnlocalizedName());
//Silo Hatch
GameRegistry.registerBlock(seal_frame, seal_frame.getUnlocalizedName());
GameRegistry.registerBlock(seal_controller, seal_controller.getUnlocalizedName());

View File

@ -0,0 +1,33 @@
package com.hbm.blocks.generic;
import java.util.Random;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import net.minecraft.block.BlockBreakable;
import net.minecraft.block.material.Material;
public class BlockRadGlass extends BlockBreakable {
public BlockRadGlass(String name, Material material) {
super(name, material, false);
}
public int quantityDropped(Random rand) {
return 0;
}
@SideOnly(Side.CLIENT)
public int getRenderBlockPass() {
return 1;
}
public boolean renderAsNormalBlock() {
return false;
}
protected boolean canSilkHarvest() {
return true;
}
}

View File

@ -0,0 +1,73 @@
package com.hbm.entity.mob;
import com.hbm.entity.projectile.EntityBulletBase;
import com.hbm.handler.BulletConfigSyncingUtil;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.IRangedAttackMob;
import net.minecraft.entity.SharedMonsterAttributes;
import net.minecraft.entity.ai.EntityAIArrowAttack;
import net.minecraft.entity.ai.EntityAIHurtByTarget;
import net.minecraft.entity.ai.EntityAILookIdle;
import net.minecraft.entity.ai.EntityAINearestAttackableTarget;
import net.minecraft.entity.ai.EntityAISwimming;
import net.minecraft.entity.ai.EntityAIWander;
import net.minecraft.entity.boss.IBossDisplayData;
import net.minecraft.entity.monster.EntityMob;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.util.Vec3;
import net.minecraft.world.World;
public class EntityMaskMan extends EntityMob implements IRangedAttackMob, IBossDisplayData {
public EntityMaskMan(World world) {
super(world);
this.tasks.addTask(1, new EntityAISwimming(this));
this.tasks.addTask(2, new EntityAIWander(this, 1.0D));
this.tasks.addTask(3, new EntityAILookIdle(this));
this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, false));
this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityPlayer.class, 0, true));
this.targetTasks.addTask(3, new EntityAIArrowAttack(this, 1.0D, 20, 60, 15.0F));
this.setSize(2F, 5F);
this.isImmuneToFire = true;
}
protected void applyEntityAttributes()
{
super.applyEntityAttributes();
this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(0.25D);
}
public boolean isAIEnabled()
{
return true;
}
protected boolean canDespawn()
{
return false;
}
@Override
public void attackEntityWithRangedAttack(EntityLivingBase target, float dist) {
Vec3 vec = Vec3.createVectorHelper(posX - target.posX, (posY + 3) - (target.posY + target.getEyeHeight()), posZ - target.posZ);
EntityBulletBase rawkett = new EntityBulletBase(worldObj, BulletConfigSyncingUtil.ROCKET_SHRAPNEL);
rawkett.copyLocationAndAnglesFrom(target);
//rawkett.lastTickPosX = rawkett.prevPosX = rawkett.posX = this.posX;
//rawkett.lastTickPosY = rawkett.prevPosY = rawkett.posY = this.posY + 3;
//rawkett.lastTickPosZ = rawkett.prevPosZ = rawkett.posZ = this.posZ;
rawkett.lastTickPosY = rawkett.prevPosY = rawkett.posY = rawkett.posY + 3;
rawkett.setVelocity(vec.xCoord, vec.yCoord, vec.zCoord);
System.out.println("aaaaaa");
worldObj.spawnEntityInWorld(rawkett);
}
}

View File

@ -455,6 +455,7 @@ public class ClientProxy extends ServerProxy
RenderingRegistry.registerEntityRenderingHandler(EntityCyberCrab.class, new RenderCyberCrab());
RenderingRegistry.registerEntityRenderingHandler(EntityTeslaCrab.class, new RenderTeslaCrab());
RenderingRegistry.registerEntityRenderingHandler(EntityTaintCrab.class, new RenderTaintCrab());
RenderingRegistry.registerEntityRenderingHandler(EntityMaskMan.class, new RenderMaskMan());
RenderingRegistry.registerEntityRenderingHandler(EntityChopperMine.class, new RenderChopperMine());
RenderingRegistry.registerEntityRenderingHandler(EntityRubble.class, new RenderRubble());

View File

@ -1498,6 +1498,10 @@ public class CraftingManager {
GameRegistry.addRecipe(new ItemStack(ModBlocks.fence_metal, 6), new Object[] { "BIB", "BIB", 'B', Blocks.iron_bars, 'I', Items.iron_ingot });
GameRegistry.addShapelessRecipe(new ItemStack(ModBlocks.waste_trinitite), new Object[] { new ItemStack(Blocks.sand, 1, 0), ModItems.trinitite });
GameRegistry.addShapelessRecipe(new ItemStack(ModBlocks.waste_trinitite_red), new Object[] { new ItemStack(Blocks.sand, 1, 1), ModItems.trinitite });
GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(ModBlocks.sand_uranium), new Object[] { "sand", "dustUranium" }));
GameRegistry.addRecipe(new ItemStack(ModItems.rune_blank, 1), new Object[] { "PSP", "SDS", "PSP", 'P', ModItems.powder_magic, 'S', ModItems.ingot_starmetal, 'D', ModItems.dynosphere_dineutronium_charged });
GameRegistry.addShapelessRecipe(new ItemStack(ModItems.rune_isa, 1), new Object[] { ModItems.rune_blank, ModItems.powder_spark_mix, ModItems.singularity_counter_resonant });
GameRegistry.addShapelessRecipe(new ItemStack(ModItems.rune_dagaz, 1), new Object[] { ModItems.rune_blank, ModItems.powder_spark_mix, ModItems.singularity });
@ -1621,6 +1625,9 @@ public class CraftingManager {
GameRegistry.addSmelting(new ItemStack(Blocks.gravel, 1), new ItemStack(Blocks.cobblestone, 1), 0.0F);
GameRegistry.addSmelting(new ItemStack(ModBlocks.gravel_obsidian), new ItemStack(Blocks.obsidian), 0.0F);
GameRegistry.addSmelting(new ItemStack(ModBlocks.gravel_diamond), new ItemStack(Items.diamond), 3.0F);
GameRegistry.addSmelting(new ItemStack(ModBlocks.sand_uranium), new ItemStack(ModBlocks.glass_uranium), 0.25F);
GameRegistry.addSmelting(new ItemStack(ModBlocks.waste_trinitite), new ItemStack(ModBlocks.glass_trinitite), 0.25F);
GameRegistry.addSmelting(new ItemStack(ModBlocks.waste_trinitite_red), new ItemStack(ModBlocks.glass_trinitite), 0.25F);
GameRegistry.addSmelting(ModItems.ingot_schraranium, new ItemStack(ModItems.nugget_schrabidium, 1), 2.0F);

View File

@ -727,6 +727,7 @@ public class MainRegistry
EntityRegistry.registerGlobalEntityID(EntityCyberCrab.class, "entity_cyber_crab", EntityRegistry.findGlobalUniqueEntityId(), 0xAAAAAA, 0x444444);
EntityRegistry.registerGlobalEntityID(EntityTeslaCrab.class, "entity_tesla_crab", EntityRegistry.findGlobalUniqueEntityId(), 0xAAAAAA, 0x440000);
EntityRegistry.registerGlobalEntityID(EntityTaintCrab.class, "entity_taint_crab", EntityRegistry.findGlobalUniqueEntityId(), 0xAAAAAA, 0xFF00FF);
EntityRegistry.registerGlobalEntityID(EntityMaskMan.class, "entity_mask_man", EntityRegistry.findGlobalUniqueEntityId(), 0xAAAAAA, 0xAAAAAA);
ForgeChunkManager.setForcedChunkLoadingCallback(this, new LoadingCallback() {

View File

@ -165,6 +165,7 @@ public class ResourceManager {
public static final IModelCustom tesla = AdvancedModelLoader.loadModel(new ResourceLocation(RefStrings.MODID, "models/tesla.obj"));
public static final IModelCustom teslacrab = AdvancedModelLoader.loadModel(new ResourceLocation(RefStrings.MODID, "models/mobs/teslacrab.obj"));
public static final IModelCustom taintcrab = AdvancedModelLoader.loadModel(new ResourceLocation(RefStrings.MODID, "models/mobs/taintcrab.obj"));
public static final IModelCustom maskman = AdvancedModelLoader.loadModel(new ResourceLocation(RefStrings.MODID, "models/mobs/maskman.obj"));
//Belt
public static final IModelCustom arrow = AdvancedModelLoader.loadModel(new ResourceLocation(RefStrings.MODID, "models/blocks/arrow.obj"));
@ -323,6 +324,7 @@ public class ResourceManager {
public static final ResourceLocation tesla_tex = new ResourceLocation(RefStrings.MODID, "textures/models/tesla.png");
public static final ResourceLocation teslacrab_tex = new ResourceLocation(RefStrings.MODID, "textures/entity/teslacrab.png");
public static final ResourceLocation taintcrab_tex = new ResourceLocation(RefStrings.MODID, "textures/entity/taintcrab.png");
public static final ResourceLocation maskman_tex = new ResourceLocation(RefStrings.MODID, "textures/entity/maskman.png");

View File

@ -0,0 +1,27 @@
package com.hbm.render.entity.mob;
import com.hbm.main.ResourceManager;
import com.hbm.render.model.ModelMaskMan;
import net.minecraft.client.renderer.entity.RenderLiving;
import net.minecraft.entity.Entity;
import net.minecraft.util.ResourceLocation;
public class RenderMaskMan extends RenderLiving {
public RenderMaskMan() {
super(new ModelMaskMan(), 1.0F);
this.shadowOpaque = 0.0F;
}
@Override
public void doRender(Entity entity, double x, double y, double z, float f0, float f1) {
super.doRender(entity, x, y, z, f0, f1);
}
@Override
protected ResourceLocation getEntityTexture(Entity p_110775_1_) {
return ResourceManager.maskman_tex;
}
}

View File

@ -0,0 +1,66 @@
package com.hbm.render.model;
import org.lwjgl.opengl.GL11;
import com.hbm.entity.mob.EntityMaskMan;
import com.hbm.main.ResourceManager;
import net.minecraft.client.model.ModelBase;
import net.minecraft.entity.Entity;
import net.minecraft.util.MathHelper;
public class ModelMaskMan extends ModelBase {
@Override
public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5) {
super.render(entity, f, f1, f2, f3, f4, f5);
GL11.glPushMatrix();
GL11.glRotatef(180, 1, 0, 0);
GL11.glTranslatef(0, -1.5F, 0);
GL11.glRotatef(-90, 0, 1, 0);
EntityMaskMan man = (EntityMaskMan)entity;
float f7 = man.limbSwing - man.limbSwingAmount * (1.0F - f5);
float f6 = (man.prevLimbSwingAmount + (man.limbSwingAmount - man.prevLimbSwingAmount) * f5) * 0.5F;
GL11.glRotated(Math.toDegrees(MathHelper.cos(f7 * 0.6662F + (float)Math.PI) * 1.4F * f6) * -0.1, 1, 0, 0);
ResourceManager.maskman.renderPart("Torso");
GL11.glPushMatrix();
GL11.glTranslatef(0.5F, 4F, 0);
//GL11.glRotated(f3, 1, 0, 0);
GL11.glRotated(f3, 0, 1, 0);
ResourceManager.maskman.renderPart("Head");
GL11.glPopMatrix();
GL11.glPushMatrix();
GL11.glTranslatef(-0.5F, 1.75F, -0.5F);
GL11.glRotated(Math.toDegrees(MathHelper.cos(f7 * 0.6662F + (float)Math.PI) * 1.4F * f6), 0, 0, 1);
ResourceManager.maskman.renderPart("LLeg");
GL11.glPopMatrix();
GL11.glPushMatrix();
GL11.glTranslatef(-0.5F, 1.75F, 0.5F);
GL11.glRotated(Math.toDegrees(MathHelper.cos(f7 * 0.6662F) * 1.4F * f6), 0, 0, 1);
ResourceManager.maskman.renderPart("RLeg");
GL11.glPopMatrix();
GL11.glPushMatrix();
GL11.glTranslatef(-0.5F, 3.75F, -1.5F);
GL11.glRotated(Math.toDegrees(MathHelper.cos(f7 * 0.6662F) * 1.4F * f6), 0, 0, 1);
ResourceManager.maskman.renderPart("LArm");
GL11.glPopMatrix();
GL11.glPushMatrix();
GL11.glTranslatef(-0.5F, 3.75F, 1.5F);
GL11.glRotated(Math.toDegrees(MathHelper.cos(f7 * 0.6662F + (float)Math.PI) * 1.4F * f6), 0, 0, 1);
ResourceManager.maskman.renderPart("RArm");
GL11.glPopMatrix();
GL11.glPopMatrix();
}
}

View File

@ -0,0 +1,18 @@
package com.hbm.util;
public class BobMathUtil {
public static double getAngleFrom2DVecs(double x1, double z1, double x2, double z2) {
double upper = x1 * x2 + z1 * z2;
double lower = Math.sqrt(x1 * x1 + z1 * z1) * Math.sqrt(x2 * x2 + z2 * z2);
double result = Math.toDegrees(Math.cos(upper / lower));
if(result <= 180)
result -= 180;
return result;
}
}