polished BOT, some uninteresting cleanup crap

This commit is contained in:
Bob 2020-12-31 03:14:14 +01:00
parent 934c14fb80
commit 759108ba32
45 changed files with 4711 additions and 3764 deletions

View File

@ -283,6 +283,8 @@ entity.entity_mob_nuclear_creeper.name=Nuklearer Creeper
entity.entity_mob_tainted_creeper.name=Verseuchter Creeper
entity.entity_taint_crab.name=Verseuchte Krabbe
entity.entity_tesla_crab.name=Tesla-Krabbe
entity.hbm.entity_balls_o_tron.name=Balls-O-Tron Prime
entity.hbm.entity_balls_o_tron_seg.name=Balls-O-Tron Segment
entity.hbm.entity_bullet.name=Patrone
entity.hbm.entity_rocket.name=Rakete
entity.hbm.entity_schrabnel.name=Schrabnel
@ -413,6 +415,7 @@ item.ammo_44_star.name=.44 Magnum Patrone (Sternenmetall)
item.ammo_4gauge.name=Kaliber 20 Schrot
item.ammo_4gauge_balefire.name=23mm Balefire-Granate
item.ammo_4gauge_canister.name=23mm Rakete (Katusche)
item.ammo_4gauge_vampire.name=Kaliber 4 Shrot (Krallen)
item.ammo_4gauge_explosive.name=23mm Granate
item.ammo_4gauge_flechette.name=Kaliber 4 Flechet
item.ammo_4gauge_flechette_phosphorus.name=Kaliber 4 Flechet (WP)
@ -420,6 +423,8 @@ item.ammo_4gauge_kampf.name=23mm Rakete
item.ammo_4gauge_semtex.name=23mm Bergbauladung
item.ammo_4gauge_sleek.name=Kaliber 4 Schrot (IF-F&E)
item.ammo_4gauge_slug.name=Kaliber 4 Brenneke
item.ammo_4gauge_vampire.name=Kaliber 4 Schrot (Holzpflöcke)
item.ammo_4gauge_void.name=Kaliber 4 Schrot (Leere)
item.ammo_50ae.name=.50 AE Patrone
item.ammo_50ae_ap.name=.50 AE Patrone (Panzerbrechend)
item.ammo_50ae_chlorophyte.name=.50 AE Patrone (Grünalgen)
@ -829,6 +834,7 @@ item.coil_tungsten.name=Heizspirale
item.coin_creeper.name=Nukleare Creeper-Münze
item.coin_maskman.name=Maskenmann-Münze
item.coin_radiation.name=Strahlungs-Münze
item.coin_worm.name=Balls-O-Tron-Münze
item.coke.name=Koks
item.combine_scrap.name=CMB Schrott
item.component_emitter.name=Emitterkomponente
@ -1562,6 +1568,7 @@ item.pellet_buckshot.name=Schrotkugeln
item.pellet_canister.name=Kartuschenkugeln
item.pellet_charged.name=Ionisierte Partikel
item.pellet_chlorophyte.name=Günalgenkugeln
item.pellet_claws.name=Scharfe Metallkrallen
item.pellet_cluster.name=Explosive Pellets
item.pellet_coal.name=Dichter Kohlecluster
item.pellet_coolant.name=Kühlcluster
@ -1876,6 +1883,7 @@ item.solinium_igniter.name=SOL-Impulszünder
item.solinium_kit.name=Solinium Kit
item.solinium_propellant.name=SOL-Verdichtungsladung
item.sopsign.name=Sopschild-Streitaxt
item.spawn_worm.name=Balls-O-Tron Prime
item.sphere_steel.name=Stahlhohlkugel
item.spongebob_macaroni.name=Spongebob Macaroni
item.stamp_357.name=.357 Magnum-Stempel

View File

@ -283,6 +283,8 @@ entity.entity_mob_nuclear_creeper.name=Nuclear Creeper
entity.entity_mob_tainted_creeper.name=Tainted Creeper
entity.entity_taint_crab.name=Taint Crab
entity.entity_tesla_crab.name=Tesla Crab
entity.hbm.entity_balls_o_tron.name=Balls-O-Tron Prime
entity.hbm.entity_balls_o_tron_seg.name=Balls-O-Tron Segment
entity.hbm.entity_bullet.name=Bullet
entity.hbm.entity_rocket.name=Rocket
entity.hbm.entity_schrabnel.name=Schrabnel
@ -413,6 +415,7 @@ item.ammo_44_star.name=.44 Magnum Bullet (Starmetal)
item.ammo_4gauge.name=4 Gauge Buckshot
item.ammo_4gauge_balefire.name=23mm Balefire Grenade
item.ammo_4gauge_canister.name=23mm Rocket (Canister Shot)
item.ammo_4gauge_claw.name=4 Gauge Claw Shell
item.ammo_4gauge_explosive.name=23mm Grenade
item.ammo_4gauge_flechette.name=4 Gauge Flechette Shell
item.ammo_4gauge_flechette_phosphorus.name=4 Gauge Flechette Shell (WP)
@ -420,6 +423,8 @@ item.ammo_4gauge_kampf.name=23mm Rocket
item.ammo_4gauge_semtex.name=23mm Mining Charge
item.ammo_4gauge_sleek.name=4 Gauge Buckshot (IF-R&D)
item.ammo_4gauge_slug.name=4 Gauge Solid Steel Slug
item.ammo_4gauge_vampire.name=4 Gauge Wooden Stake Shell
item.ammo_4gauge_void.name=4 Gauge Void Shell
item.ammo_50ae.name=.50 AE Round
item.ammo_50ae_ap.name=.50 AE Round (Armor Piercing)
item.ammo_50ae_chlorophyte.name=.50 AE Round (Chlorophyte)
@ -829,6 +834,7 @@ item.coil_tungsten.name=Heating Coil
item.coin_creeper.name=Nuclear Creeper Coin
item.coin_maskman.name=Maskman Coin
item.coin_radiation.name=Radiation Coin
item.coin_worm.name=Balls-O-Tron Coin
item.coke.name=Coke
item.combine_scrap.name=CMB Scrap Metal
item.component_emitter.name=Emitter Component
@ -1562,6 +1568,7 @@ item.pellet_buckshot.name=Lead Pellets
item.pellet_canister.name=Canister Shot
item.pellet_charged.name=Ionized Particles
item.pellet_chlorophyte.name=Chlorophyte Rounds
item.pellet_claws.name=Sharp Metal Claws
item.pellet_cluster.name=Explosive Pellets
item.pellet_coal.name=Dense Coal Cluster
item.pellet_coolant.name=Coolant Cluster
@ -1876,6 +1883,7 @@ item.solinium_igniter.name=SOL Pulse Igniter
item.solinium_kit.name=Solinium Kit
item.solinium_propellant.name=SOL Compression Charge
item.sopsign.name=Sop Sign Battle Axe
item.spawn_worm.name=Balls-O-Tron Prime
item.sphere_steel.name=Steel Sphere
item.spongebob_macaroni.name=Spongebob Macaroni
item.stamp_357.name=.357 Magnum Stamp

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -139,6 +139,7 @@
"weapon.whack": {"category": "player", "sounds": [{"name": "weapon/whack", "stream": false}]},
"weapon.chainsaw": {"category": "player", "sounds": [{"name": "weapon/chainsaw", "stream": false}]},
"weapon.rocketFlame": {"category": "block", "sounds": [{"name": "weapon/rocketFlame", "stream": false}]},
"weapon.ballsLaser": {"category": "block", "sounds": [{"name": "weapon/ballsLaser", "stream": false}]},
"weapon.reloadTurret": {"category": "player", "sounds": [{"name": "weapon/reloadTurret", "stream": false}]},
"weapon.switchmode1": {"category": "player", "sounds": [{"name": "weapon/switchmode1", "stream": false}]},

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 830 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 354 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 323 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 326 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 216 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 218 B

View File

@ -1091,7 +1091,7 @@ public class ModBlocks {
brick_jungle_mystic = new BlockOre(Material.rock).setBlockName("brick_jungle_mystic").setCreativeTab(MainRegistry.blockTab).setHardness(15.0F).setResistance(900.0F).setLightLevel(5F/15F).setBlockTextureName(RefStrings.MODID + ":brick_jungle_mystic");
brick_jungle_trap = new TrappedBrick(Material.rock).setBlockName("brick_jungle_trap").setCreativeTab(MainRegistry.blockTab).setHardness(15.0F).setResistance(900.0F).setBlockTextureName(RefStrings.MODID + ":brick_jungle_trap");
brick_jungle_glyph = new BlockGlyph(Material.rock).setBlockName("brick_jungle_glyph").setCreativeTab(MainRegistry.blockTab).setHardness(15.0F).setResistance(900.0F);
brick_jungle_circle = new BlockGeneric(Material.rock).setBlockName("brick_jungle_circle").setCreativeTab(MainRegistry.blockTab).setHardness(15.0F).setResistance(900.0F).setBlockTextureName(RefStrings.MODID + ":brick_jungle_circle");
brick_jungle_circle = new BlockBallsSpawner(Material.rock).setBlockName("brick_jungle_circle").setCreativeTab(MainRegistry.blockTab).setHardness(15.0F).setResistance(900.0F).setBlockTextureName(RefStrings.MODID + ":brick_jungle_circle");
brick_dungeon = new BlockGeneric(Material.rock).setBlockName("brick_dungeon").setCreativeTab(MainRegistry.blockTab).setHardness(15.0F).setResistance(900.0F).setBlockTextureName(RefStrings.MODID + ":brick_dungeon");
brick_dungeon_flat = new BlockGeneric(Material.rock).setBlockName("brick_dungeon_flat").setCreativeTab(MainRegistry.blockTab).setHardness(15.0F).setResistance(900.0F).setBlockTextureName(RefStrings.MODID + ":brick_dungeon_flat");

View File

@ -0,0 +1,38 @@
package com.hbm.blocks.generic;
import com.hbm.blocks.ModBlocks;
import com.hbm.entity.mob.botprime.EntityBOTPrimeHead;
import com.hbm.items.ModItems;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.world.World;
public class BlockBallsSpawner extends Block {
public BlockBallsSpawner(Material mat) {
super(mat);
}
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int i, float fx, float fy, float fz) {
if(player.getHeldItem() != null && player.getHeldItem().getItem() == ModItems.mech_key) {
player.getHeldItem().stackSize--;
if(!world.isRemote) {
EntityBOTPrimeHead bot = new EntityBOTPrimeHead(world);
bot.setPositionAndRotation(x + 0.5, 300, z + 0.5, 0, 0);
bot.motionY = -1.0;
bot.onSpawnWithEgg(null);
world.spawnEntityInWorld(bot);
world.setBlock(x, y, z, ModBlocks.brick_jungle_cracked);
}
}
return false;
}
}

View File

@ -158,6 +158,7 @@ public class WeaponRecipes {
//Ammo assemblies
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.pellet_flechette, 1), new Object[] { " L ", " L ", "LLL", 'L', "nuggetLead" }));
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.pellet_claws, 1), new Object[] { " X ", "X X", " XX", 'X', "plateSteel" }));
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.assembly_iron, 24), new Object[] { " I", "GC", " P", 'I', "ingotIron", 'G', ModItems.cordite, 'C', ModItems.casing_357, 'P', ModItems.primer_357 }));
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.assembly_iron, 24), new Object[] { " I", "GC", " P", 'I', "ingotIron", 'G', ModItems.ballistite, 'C', ModItems.casing_357, 'P', ModItems.primer_357 }));
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.assembly_steel, 24), new Object[] { " I", "GC", " P", 'I', "ingotLead", 'G', ModItems.cordite, 'C', ModItems.casing_357, 'P', ModItems.primer_357 }));
@ -221,6 +222,9 @@ public class WeaponRecipes {
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_4gauge_balefire, 4), new Object[] { " B ", "BAB", " B ", 'B', ModItems.ammo_4gauge_explosive, 'A', ModItems.egg_balefire_shard });
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_4gauge_kampf, 2), new Object[] { "G", "R", 'G', ModItems.ammo_rocket, 'R', ModItems.ammo_4gauge_explosive });
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_4gauge_canister, 4), new Object[] { " B ", "BAB", " B ", 'B', ModItems.ammo_4gauge_kampf, 'A', ModItems.pellet_canister });
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_4gauge_claw, 4), new Object[] { " B ", "BAB", " B ", 'B', ModItems.ammo_4gauge, 'A', ModItems.pellet_claws });
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_4gauge_vampire, 4), new Object[] { "ABA", "BAB", "ABA", 'B', ModItems.ammo_4gauge, 'A', ModItems.toothpicks });
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_4gauge_void, 4), new Object[] { " B ", "BAB", " B ", 'B', ModItems.ammo_4gauge, 'A', ModItems.pellet_charged });
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_4gauge_sleek, 64), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_4gauge, 'A', ModItems.coin_maskman });
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_44_ap, 8), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_44, 'A', ModItems.ingot_dura_steel });
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_44_du, 8), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_44, 'A', ModItems.ingot_u238 });

View File

@ -21,7 +21,7 @@ import net.minecraftforge.common.util.ForgeDirection;
public class EntityEMP extends Entity {
List<int[]> machines;
int life = 2 * 60 * 20;
int life = 10 * 60 * 20;
public EntityEMP(World p_i1582_1_) {
super(p_i1582_1_);

View File

@ -1,7 +1,11 @@
package com.hbm.entity.mob.botprime;
import com.hbm.entity.projectile.EntityBulletBase;
import com.hbm.handler.BulletConfigSyncingUtil;
import net.minecraft.command.IEntitySelector;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.SharedMonsterAttributes;
import net.minecraft.util.Vec3;
import net.minecraft.world.World;
@ -42,7 +46,8 @@ public abstract class EntityBOTPrimeBase extends EntityWormBaseNT {
@Override
protected void applyEntityAttributes() {
super.applyEntityAttributes();
this.getEntityAttribute(SharedMonsterAttributes.maxHealth).setBaseValue(5000.0D);
this.getEntityAttribute(SharedMonsterAttributes.maxHealth).setBaseValue(15000.0D);
this.getEntityAttribute(SharedMonsterAttributes.knockbackResistance).setBaseValue(1.0D);
}
@Override
@ -54,4 +59,28 @@ public abstract class EntityBOTPrimeBase extends EntityWormBaseNT {
protected boolean canDespawn() {
return false;
}
protected void laserAttack(Entity target, boolean head) {
if(!(target instanceof EntityLivingBase))
return;
EntityLivingBase living = (EntityLivingBase) target;
if(head) {
for(int i = 0; i < 5; i++) {
EntityBulletBase bullet = new EntityBulletBase(this.worldObj, BulletConfigSyncingUtil.WORM_LASER, this, living, 1.0F, i * 0.05F);
this.worldObj.spawnEntityInWorld(bullet);
}
this.playSound("hbm:weapon.ballsLaser", 5.0F, 0.75F);
} else {
EntityBulletBase bullet = new EntityBulletBase(this.worldObj, BulletConfigSyncingUtil.WORM_BOLT, this, living, 0.5F, 0.125F);
this.worldObj.spawnEntityInWorld(bullet);
this.playSound("hbm:weapon.ballsLaser", 5.0F, 1.0F);
}
}
}

View File

@ -4,7 +4,9 @@ import com.hbm.entity.mob.EntityAINearestAttackableTargetNT;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.potion.PotionEffect;
import net.minecraft.util.MathHelper;
import net.minecraft.world.World;
@ -18,7 +20,7 @@ public class EntityBOTPrimeBody extends EntityBOTPrimeBase {
this.rangeForParts = 70.0D;
this.segmentDistance = 3.5D;
this.maxBodySpeed = 1.4D;
this.targetTasks.addTask(1, new EntityAINearestAttackableTargetNT(this, EntityLivingBase.class, 0, true, false, this.selector, 128.0D));
this.targetTasks.addTask(1, new EntityAINearestAttackableTargetNT(this, EntityPlayer.class, 0, false, false, this.selector, 128.0D));
}
@Override
@ -36,16 +38,18 @@ public class EntityBOTPrimeBody extends EntityBOTPrimeBase {
return 100;
}
@Override
public boolean isPotionApplicable(PotionEffect potion) {
return false;
}
@Override
protected void updateAITasks() {
this.updateEntityActionState();
this.targetTasks.onUpdateTasks();
this.movement.updateMovement();
if((this.followed != null) && (getPartNumber() == 0)) {
//this.dataWatcher.updateObject(17, Byte.valueOf((byte) (((EntityBallsOTronHead) this.followed).isArmored() ? 1 : 0)));
} else if(this.targetedEntity != null) {
this.dataWatcher.updateObject(17, Byte.valueOf(this.targetedEntity.getDataWatcher().getWatchableObjectByte(17)));
}
if(this.didCheck) {
if(this.targetedEntity == null || !this.targetedEntity.isEntityAlive()) {
setHealth(getHealth() - 1999.0F);
@ -54,11 +58,12 @@ public class EntityBOTPrimeBody extends EntityBOTPrimeBase {
this.worldObj.createExplosion(this, this.posX, this.posY, this.posZ, 2.0F, false);
}
}
if((this.followed != null) && (getAttackTarget() != null)) {
if(this.followed != null && this.followed.isEntityAlive() && getAttackTarget() != null) {
if(canEntityBeSeenThroughNonSolids(getAttackTarget())) {
this.attackCounter += 1;
if(this.attackCounter == 10) {
//useLaser(o(), false);
laserAttack(this.getAttackTarget(), false);
this.attackCounter = -20;
}
@ -69,9 +74,29 @@ public class EntityBOTPrimeBody extends EntityBOTPrimeBase {
this.attackCounter -= 1;
}
float f3 = MathHelper.sqrt_double(motionX * motionX + motionZ * motionZ);
this.prevRotationYaw = this.rotationYaw = (float)(Math.atan2(motionX, motionZ) * 180.0D / Math.PI);
this.prevRotationPitch = this.rotationPitch = (float)(Math.atan2(motionY, f3) * 180.0D / Math.PI);
if(this.targetedEntity != null) {
double dx = targetedEntity.posX - posX;
double dy = targetedEntity.posY - posY;
double dz = targetedEntity.posZ - posZ;
float f3 = MathHelper.sqrt_double(dx * dx + dz * dz);
this.prevRotationYaw = this.rotationYaw = (float)(Math.atan2(dx, dz) * 180.0D / Math.PI);
this.prevRotationPitch = this.rotationPitch = (float)(Math.atan2(dy, f3) * 180.0D / Math.PI);
}
}
@Override
public void onUpdate() {
super.onUpdate();
if(this.targetedEntity != null) {
double dx = targetedEntity.posX - posX;
double dy = targetedEntity.posY - posY;
double dz = targetedEntity.posZ - posZ;
float f3 = MathHelper.sqrt_double(dx * dx + dz * dz);
this.prevRotationYaw = this.rotationYaw = (float) (Math.atan2(dx, dz) * 180.0D / Math.PI);
this.prevRotationPitch = this.rotationPitch = (float) (Math.atan2(dy, f3) * 180.0D / Math.PI);
}
}
public void writeEntityToNBT(NBTTagCompound nbt) {

View File

@ -1,10 +1,8 @@
package com.hbm.entity.mob.botprime;
import com.hbm.entity.mob.EntityAINearestAttackableTargetNT;
import com.hbm.entity.particle.EntityCloudFX;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.IEntityLivingData;
import net.minecraft.entity.SharedMonsterAttributes;
import net.minecraft.entity.ai.EntityAIHurtByTarget;
@ -12,7 +10,6 @@ import net.minecraft.entity.boss.IBossDisplayData;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.util.DamageSource;
import net.minecraft.util.IChatComponent;
import net.minecraft.util.MathHelper;
import net.minecraft.world.World;
@ -24,19 +21,21 @@ public class EntityBOTPrimeHead extends EntityBOTPrimeBase implements IBossDispl
* |___/_/ \_\___|___|___/ |___| |_| |_|\_\___|_|\_| |_| |_|\_\_|_|V|_|___|
*/
//TODO: clean-room implementation of the movement behavior classes (again)
private final WormMovementHeadNT movement = new WormMovementHeadNT(this);
public EntityBOTPrimeHead(World world) {
super(world);
/*this.experienceValue = 1000;
this.experienceValue = 1000;
this.wasNearGround = false;
this.attackRange = 150.0D;
this.setSize(3.0F, 3.0F);
this.maxSpeed = 1.0D;
this.fallSpeed = 0.006D;
this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, false));
this.targetTasks.addTask(2, new EntityAINearestAttackableTargetNT(this, EntityPlayer.class, 0, false, false, null, 128.0D));*/
//this.targetTasks.addTask(3, new EntityAINearestAttackableTargetNT(this, Entity.class, 0, false, false, this.selector, 50.0D));
this.targetTasks.addTask(2, new EntityAINearestAttackableTargetNT(this, EntityPlayer.class, 0, false, false, null, 128.0D));
this.ignoreFrustumCheck = true;
}
@Override
@ -64,13 +63,13 @@ public class EntityBOTPrimeHead extends EntityBOTPrimeBase implements IBossDispl
public IEntityLivingData onSpawnWithEgg(IEntityLivingData data) {
//TODO: check if this is even needed
/*setHeadID(this.getEntityId());
setHeadID(this.getEntityId());
int x = MathHelper.floor_double(this.posX);
int y = MathHelper.floor_double(this.posY);
int z = MathHelper.floor_double(this.posZ);
for (int i = 0; i < 49; i++) {
for (int i = 0; i < 74; i++) {
EntityBOTPrimeBody bodyPart = new EntityBOTPrimeBody(this.worldObj);
bodyPart.setPartNumber(i);
@ -82,80 +81,70 @@ public class EntityBOTPrimeHead extends EntityBOTPrimeBase implements IBossDispl
setPosition(x, y, z);
this.spawnPoint.set(x, y, z);
this.aggroCooldown = 60;*/
return super.onSpawnWithEgg(data);
}
@Override
protected void updateAITasks() {
this.updateEntityActionState();
super.updateAITasks();
this.movement.updateMovement();
if((getHealth() < getMaxHealth()) && (this.ticksExisted % 6 == 0)) {
if(this.targetedEntity != null) {
heal(1.0F);
} else if(this.recentlyHit == 0) {
heal(4.0F);
}
}
if((this.targetedEntity != null) && (this.targetedEntity.getDistanceSqToEntity(this) < this.attackRange * this.attackRange)) {
if(canEntityBeSeenThroughNonSolids(this.targetedEntity)) {
this.attackCounter ++;
if(this.attackCounter == 30) {
laserAttack(this.targetedEntity, true);
this.attackCounter = 0;
}
} else {
this.attackCounter = 0;
}
} else {
this.attackCounter = 0;
}
}
@Override
public void onUpdate() {
/*this.movement.updateMovement();
if(worldObj.isRemote) {
System.out.println(posX + " " + posY + " " + posZ);
}
if ((getHealth() < getMaxHealth()) && (this.ticksExisted % 6 == 0)) {
if (this.targetedEntity != null) {
heal(1.0F);
} else if (this.recentlyHit == 0) {
heal(4.0F);
}
}
if ((this.targetedEntity != null) && (this.targetedEntity.getDistanceSqToEntity(this) < this.attackRange * this.attackRange))
{
if (canEntityBeSeenThroughNonSolids(this.targetedEntity))
{
this.attackCounter += 1;
if (this.attackCounter == 10)
{
//useLaser(this.targetedEntity, true);
this.attackCounter = -20;
}
}
else if (this.attackCounter > 0)
{
this.attackCounter -= 1;
}
}
else if (this.attackCounter > 0) {
this.attackCounter -= 1;
}*/
super.onUpdate();
double dx = motionX;
double dy = motionY;
double dz = motionZ;
float f3 = MathHelper.sqrt_double(dx * dx + dz * dz);
this.prevRotationYaw = this.rotationYaw = (float) (Math.atan2(dx, dz) * 180.0D / Math.PI);
this.prevRotationPitch = this.rotationPitch = (float) (Math.atan2(dy, f3) * 180.0D / Math.PI);
}
@Override
public float getAttackStrength(Entity target) {
if(target instanceof EntityLivingBase) {
return ((EntityLivingBase) target).getHealth() * 0.75F;
}
return 100;
}
@Override
public IChatComponent func_145748_c_() {
return super.func_145748_c_();
return 1000;
}
public void writeEntityToNBT(NBTTagCompound par1NBTTagCompound)
{
super.writeEntityToNBT(par1NBTTagCompound);
par1NBTTagCompound.setInteger("AggroCD", this.aggroCooldown);
par1NBTTagCompound.setInteger("CenterX", this.spawnPoint.posX);
par1NBTTagCompound.setInteger("CenterY", this.spawnPoint.posY);
par1NBTTagCompound.setInteger("CenterZ", this.spawnPoint.posZ);
}
public void readEntityFromNBT(NBTTagCompound par1NBTTagCompound)
{
super.readEntityFromNBT(par1NBTTagCompound);
this.aggroCooldown = par1NBTTagCompound.getInteger("AggroCD");
this.spawnPoint.set(par1NBTTagCompound.getInteger("CenterX"), par1NBTTagCompound.getInteger("CenterY"), par1NBTTagCompound.getInteger("CenterZ"));
}
public void writeEntityToNBT(NBTTagCompound nbt) {
super.writeEntityToNBT(nbt);
nbt.setInteger("spawnX", this.spawnPoint.posX);
nbt.setInteger("spawnY", this.spawnPoint.posY);
nbt.setInteger("spawnZ", this.spawnPoint.posZ);
}
public void readEntityFromNBT(NBTTagCompound nbt) {
super.readEntityFromNBT(nbt);
this.spawnPoint.set(nbt.getInteger("spawnX"), nbt.getInteger("spawnY"), nbt.getInteger("spawnZ"));
}
}

View File

@ -1,5 +1,6 @@
package com.hbm.entity.mob.botprime;
import net.minecraft.block.Block;
import net.minecraft.entity.EntityCreature;
import net.minecraft.world.World;
@ -27,20 +28,22 @@ public abstract class EntityBurrowingNT extends EntityCreature {
public void moveEntityWithHeading(float strafe, float forward) {
float drag = this.dragInGround;
if ((!isEntityInsideOpaqueBlock()) && (!isInWater()) && (!handleLavaMovement()))
{
drag = this.dragInAir;
}
else
{
//TODO: sounds when tunneling
}
if((!isEntityInsideOpaqueBlock()) && (!isInWater()) && (!handleLavaMovement())) {
drag = this.dragInAir;
} else if(this.getRNG().nextInt(100) == 0) {
//Block b = worldObj.getBlock((int)Math.floor(posX), (int)Math.floor(posY), (int)Math.floor(posZ));
//this.playSound(b.stepSound.getStepResourcePath(), 5F, 1F);
}
if (!getIsHead()) {
drag *= 0.9F;
}
moveFlying(strafe, forward, 0.02F);
moveEntity(this.motionX, this.motionY, this.motionZ);
this.motionX *= drag;
this.motionY *= drag;
this.motionZ *= drag;

View File

@ -60,6 +60,10 @@ public abstract class EntityWormBaseNT extends EntityBurrowingNT {
this.partNum = num;
}
public Entity getHead() {
return worldObj.getEntityByID(this.headID);
}
public int getHeadID() {
return this.headID;
}
@ -74,14 +78,26 @@ public abstract class EntityWormBaseNT extends EntityBurrowingNT {
if(this.isEntityInvulnerable() || source == DamageSource.drown || source == DamageSource.inWall || ((source.getEntity() instanceof EntityWormBaseNT) && ((EntityWormBaseNT) source.getEntity()).getHeadID() == this.getHeadID())) {
return false;
} else {
this.setBeenAttacked();
return super.attackEntityFrom(source, amount);
if(this.getIsHead()) {
return super.attackEntityFrom(source, amount);
}
Entity head = this.targetedEntity;
if(head != null) {
return head.attackEntityFrom(source, amount);
} else {
return super.attackEntityFrom(source, amount);
}
}
}
protected void updateEntityActionState() {
if((!this.worldObj.isRemote) && (this.worldObj.difficultySetting == EnumDifficulty.PEACEFUL)) {
if(!this.worldObj.isRemote && this.worldObj.difficultySetting == EnumDifficulty.PEACEFUL) {
setDead();
}
if((this.targetedEntity != null) && (this.targetedEntity.isDead)) {
@ -97,7 +113,7 @@ public abstract class EntityWormBaseNT extends EntityBurrowingNT {
this.motionY = 0.3D;
}
if(this.ticksExisted % 10 == 0) {
if(this.ticksExisted % 5 == 0) {
attackEntitiesInList(this.worldObj.getEntitiesWithinAABBExcludingEntity(this, this.boundingBox.expand(0.5D, 0.5D, 0.5D)));
}
}

View File

@ -13,26 +13,26 @@ public class WormMovementHeadNT {
protected void updateMovement() {
double var1 = this.user.waypointX - this.user.posX;
double var3 = this.user.waypointY - this.user.posY;
double var5 = this.user.waypointZ - this.user.posZ;
double var7 = var1 * var1 + var3 * var3 + var5 * var5;
double deltaX = this.user.waypointX - this.user.posX;
double deltaY = this.user.waypointY - this.user.posY;
double deltaZ = this.user.waypointZ - this.user.posZ;
double deltaSq = deltaX * deltaX + deltaY * deltaY + deltaZ * deltaZ;
if(this.user.courseChangeCooldown-- <= 0) {
this.user.courseChangeCooldown += this.user.getRNG().nextInt(5) + 2;
var7 = MathHelper.sqrt_double(var7);
deltaSq = MathHelper.sqrt_double(deltaSq);
if(this.user.motionX * this.user.motionX + this.user.motionY * this.user.motionY + this.user.motionZ * this.user.motionZ < this.user.maxSpeed) {
if(!this.user.isCourseTraversable()) {
var7 *= 8.0D;
deltaSq *= 8.0D;
}
double moverSpeed = this.user.getEntityAttribute(SharedMonsterAttributes.movementSpeed).getBaseValue();
this.user.motionX += var1 / var7 * moverSpeed;
this.user.motionY += var3 / var7 * moverSpeed;
this.user.motionZ += var5 / var7 * moverSpeed;
this.user.motionX += deltaX / deltaSq * moverSpeed;
this.user.motionY += deltaY / deltaSq * moverSpeed;
this.user.motionZ += deltaZ / deltaSq * moverSpeed;
}
}
@ -59,12 +59,10 @@ public class WormMovementHeadNT {
this.user.waypointZ = (this.user.spawnPoint.posZ - 30 + this.user.getRNG().nextInt(60));
}
this.user.rotationYaw = (-(float) Math.atan2(this.user.motionX, this.user.motionZ) * 180.0F / 3.1415927F);
this.user.rotationPitch = ((float) -(Math.atan2(this.user.motionY,
MathHelper.sqrt_double(this.user.motionX * this.user.motionX + this.user.motionZ * this.user.motionZ))
* 180.0D / 3.141592653589793D));
this.user.rotationYaw = -(float) -(Math.atan2(this.user.motionX, this.user.motionZ) * 180.0F / Math.PI);
this.user.rotationPitch = (float) -(Math.atan2(this.user.motionY, MathHelper.sqrt_double(this.user.motionX * this.user.motionX + this.user.motionZ * this.user.motionZ)) * 180.0D / Math.PI);
if((this.user.targetedEntity != null) && (this.user.targetedEntity .getDistanceSqToEntity(this.user) < this.user.attackRange * this.user.attackRange)) {
if(this.user.targetedEntity != null && this.user.targetedEntity .getDistanceSqToEntity(this.user) < this.user.attackRange * this.user.attackRange) {
if((this.user.wasNearGround) || (this.user.canFly)) {
@ -72,8 +70,7 @@ public class WormMovementHeadNT {
this.user.waypointY = this.user.targetedEntity.posY;
this.user.waypointZ = this.user.targetedEntity.posZ;
if((this.user.getRNG().nextInt(80) == 0) && (this.user.posY > this.user.surfaceY)
&& (!this.user.isCourseTraversable())) {
if((this.user.getRNG().nextInt(80) == 0) && (this.user.posY > this.user.surfaceY) && (!this.user.isCourseTraversable())) {
this.user.wasNearGround = false;
}

View File

@ -120,6 +120,9 @@ public class BulletConfigSyncingUtil {
public static int G4_BALEFIRE = i++;
public static int G4_KAMPF = i++;
public static int G4_CANISTER = i++;
public static int G4_CLAW = i++;
public static int G4_VAMPIRE = i++;
public static int G4_VOID = i++;
public static int G4_SLEEK = i++;
public static int SPECIAL_OSIPR = i++;
@ -198,6 +201,9 @@ public class BulletConfigSyncingUtil {
public static int MASKMAN_ROCKET = i++;
public static int MASKMAN_TRACER = i++;
public static int MASKMAN_METEOR = i++;
public static int WORM_BOLT = i++;
public static int WORM_LASER = i++;
public static void loadConfigsForSync() {
@ -309,6 +315,9 @@ public class BulletConfigSyncingUtil {
configSet.put(G4_BALEFIRE, Gun4GaugeFactory.get4GaugeBalefireConfig());
configSet.put(G4_KAMPF, Gun4GaugeFactory.getGrenadeKampfConfig());
configSet.put(G4_CANISTER, Gun4GaugeFactory.getGrenadeCanisterConfig());
configSet.put(G4_CLAW, Gun4GaugeFactory.get4GaugeClawConfig());
configSet.put(G4_VAMPIRE, Gun4GaugeFactory.get4GaugeVampireConfig());
configSet.put(G4_VOID, Gun4GaugeFactory.get4GaugeVoidConfig());
configSet.put(G4_SLEEK, Gun4GaugeFactory.get4GaugeSleekConfig());
configSet.put(SPECIAL_OSIPR, GunOSIPRFactory.getPulseConfig());
@ -387,6 +396,8 @@ public class BulletConfigSyncingUtil {
configSet.put(MASKMAN_ROCKET, GunNPCFactory.getMaskmanRocket());
configSet.put(MASKMAN_TRACER, GunNPCFactory.getMaskmanTracer());
configSet.put(MASKMAN_METEOR, GunNPCFactory.getMaskmanMeteor());
configSet.put(WORM_BOLT, GunNPCFactory.getWormBolt());
configSet.put(WORM_LASER, GunNPCFactory.getWormHeadBolt());
}
public static BulletConfiguration pullConfig(int key) {

View File

@ -111,6 +111,7 @@ public class BulletConfiguration {
public static final int BOLT_NIGHTMARE = 1;
public static final int BOLT_LASER = 2;
public static final int BOLT_ZOMG = 3;
public static final int BOLT_WORM = 4;
public BulletConfiguration setToBolt(int trail) {

View File

@ -9,9 +9,11 @@ import com.hbm.explosion.ExplosionNT.ExAttrib;
import com.hbm.handler.BulletConfigSyncingUtil;
import com.hbm.handler.BulletConfiguration;
import com.hbm.handler.GunConfiguration;
import com.hbm.interfaces.IBulletHurtBehavior;
import com.hbm.interfaces.IBulletImpactBehavior;
import com.hbm.interfaces.IBulletUpdateBehavior;
import com.hbm.items.ModItems;
import com.hbm.lib.ModDamageSource;
import com.hbm.packet.AuxParticlePacketNT;
import com.hbm.packet.PacketDispatcher;
import com.hbm.potion.HbmPotion;
@ -22,8 +24,12 @@ import com.hbm.render.anim.HbmAnimations.AnimType;
import com.hbm.render.util.RenderScreenOverlay.Crosshair;
import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.potion.PotionEffect;
import net.minecraftforge.common.IExtendedEntityProperties;
public class Gun4GaugeFactory {
@ -69,6 +75,9 @@ public class Gun4GaugeFactory {
config.config.add(BulletConfigSyncingUtil.G4_BALEFIRE);
config.config.add(BulletConfigSyncingUtil.G4_KAMPF);
config.config.add(BulletConfigSyncingUtil.G4_CANISTER);
config.config.add(BulletConfigSyncingUtil.G4_CLAW);
config.config.add(BulletConfigSyncingUtil.G4_VAMPIRE);
config.config.add(BulletConfigSyncingUtil.G4_VOID);
config.config.add(BulletConfigSyncingUtil.G4_SLEEK);
return config;
@ -124,6 +133,9 @@ public class Gun4GaugeFactory {
config.config.add(BulletConfigSyncingUtil.G4_BALEFIRE);
config.config.add(BulletConfigSyncingUtil.G4_KAMPF);
config.config.add(BulletConfigSyncingUtil.G4_CANISTER);
config.config.add(BulletConfigSyncingUtil.G4_CLAW);
config.config.add(BulletConfigSyncingUtil.G4_VAMPIRE);
config.config.add(BulletConfigSyncingUtil.G4_VOID);
config.config.add(BulletConfigSyncingUtil.G4_SLEEK);
return config;
@ -356,4 +368,104 @@ public class Gun4GaugeFactory {
return bullet;
}
public static BulletConfiguration get4GaugeClawConfig() {
BulletConfiguration bullet = get4GaugeConfig();
bullet.ammo = ModItems.ammo_4gauge_claw;
bullet.dmgMin = 6;
bullet.dmgMax = 9;
bullet.bulletsMin *= 2;
bullet.bulletsMax *= 2;
bullet.leadChance = 100;
bullet.bHurt = new IBulletHurtBehavior() {
@Override
public void behaveEntityHurt(EntityBulletBase bullet, Entity hit) {
if(bullet.worldObj.isRemote)
return;
if(hit instanceof EntityLivingBase) {
EntityLivingBase living = (EntityLivingBase) hit;
float f = living.getHealth();
f = Math.max(0, f - 2);
living.setHealth(f);
if(f == 0)
living.onDeath(ModDamageSource.lead);
}
}
};
return bullet;
}
public static BulletConfiguration get4GaugeVampireConfig() {
BulletConfiguration bullet = get4GaugeConfig();
bullet.ammo = ModItems.ammo_4gauge_vampire;
bullet.dmgMin = 6;
bullet.dmgMax = 9;
bullet.bulletsMin *= 2;
bullet.bulletsMax *= 2;
bullet.leadChance = 100;
bullet.style = BulletConfiguration.STYLE_FLECHETTE;
bullet.bHurt = new IBulletHurtBehavior() {
@Override
public void behaveEntityHurt(EntityBulletBase bullet, Entity hit) {
if(bullet.worldObj.isRemote)
return;
if(hit instanceof EntityPlayer) {
EntityPlayer player = (EntityPlayer) hit;
IExtendedEntityProperties prop = player.getExtendedProperties("WitcheryExtendedPlayer");
if(prop != null) {
prop.loadNBTData(new NBTTagCompound());
}
}
}
};
return bullet;
}
public static BulletConfiguration get4GaugeVoidConfig() {
BulletConfiguration bullet = get4GaugeConfig();
bullet.ammo = ModItems.ammo_4gauge_void;
bullet.dmgMin = 6;
bullet.dmgMax = 9;
bullet.bulletsMin *= 2;
bullet.bulletsMax *= 2;
bullet.leadChance = 0;
bullet.bHurt = new IBulletHurtBehavior() {
@Override
public void behaveEntityHurt(EntityBulletBase bullet, Entity hit) {
if(bullet.worldObj.isRemote)
return;
if(hit instanceof EntityPlayer) {
EntityPlayer player = (EntityPlayer) hit;
player.inventory.dropAllItems();
player.worldObj.newExplosion(bullet.shooter, player.posX, player.posY, player.posZ, 5.0F, true, true);
}
}
};
return bullet;
}
}

View File

@ -6,8 +6,10 @@ import com.hbm.entity.projectile.EntityBulletBase;
import com.hbm.handler.BulletConfigSyncingUtil;
import com.hbm.handler.BulletConfiguration;
import com.hbm.handler.GunConfiguration;
import com.hbm.interfaces.IBulletHurtBehavior;
import com.hbm.interfaces.IBulletImpactBehavior;
import com.hbm.items.ModItems;
import com.hbm.lib.ModDamageSource;
import com.hbm.packet.AuxParticlePacketNT;
import com.hbm.packet.PacketDispatcher;
import com.hbm.potion.HbmPotion;
@ -18,6 +20,8 @@ import com.hbm.render.anim.HbmAnimations.AnimType;
import com.hbm.render.util.RenderScreenOverlay.Crosshair;
import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.potion.PotionEffect;
@ -92,6 +96,26 @@ public class Gun75BoltFactory {
bullet.doesRicochet = false;
bullet.explosive = 0.25F;
bullet.bHurt = new IBulletHurtBehavior() {
@Override
public void behaveEntityHurt(EntityBulletBase bullet, Entity hit) {
if(bullet.worldObj.isRemote)
return;
if(hit instanceof EntityLivingBase) {
EntityLivingBase living = (EntityLivingBase) hit;
float f = living.getHealth();
f = Math.max(0, f - 2);
living.setHealth(f);
if(f == 0)
living.onDeath(ModDamageSource.lead);
}
}
};
return bullet;
}

View File

@ -191,4 +191,35 @@ public class GunNPCFactory {
return bullet;
}
public static BulletConfiguration getWormBolt() {
BulletConfiguration bullet = BulletConfigFactory.standardBulletConfig();
bullet.ammo = ModItems.coin_worm;
bullet.spread = 0.0F;
bullet.maxAge = 60;
bullet.dmgMin = 15;
bullet.dmgMax = 25;
bullet.leadChance = 0;
bullet.ricochetAngle = 90D;
bullet.setToBolt(BulletConfiguration.BOLT_WORM);
return bullet;
}
public static BulletConfiguration getWormHeadBolt() {
BulletConfiguration bullet = BulletConfigFactory.standardBulletConfig();
bullet.ammo = ModItems.coin_worm;
bullet.spread = 0.0F;
bullet.maxAge = 100;
bullet.dmgMin = 35;
bullet.dmgMax = 60;
bullet.leadChance = 0;
bullet.ricochetAngle = 90D;
bullet.setToBolt(BulletConfiguration.BOLT_LASER);
return bullet;
}
}

View File

@ -327,7 +327,7 @@ public class AssemblerRecipes {
makeRecipe(new ComparableStack(ModBlocks.therm_endo, 1), new AStack[] {new OreDictStack("plateTitanium", 12), new ComparableStack(ModItems.thermo_unit_endo, 1), new ComparableStack(ModItems.circuit_gold, 2), new ComparableStack(ModItems.wire_gold, 6), },250);
makeRecipe(new ComparableStack(ModBlocks.therm_exo, 1), new AStack[] {new OreDictStack("plateTitanium", 12), new ComparableStack(ModItems.thermo_unit_exo, 1), new ComparableStack(ModItems.circuit_gold, 2), new ComparableStack(ModItems.wire_gold, 6), },250);
makeRecipe(new ComparableStack(ModBlocks.launch_pad, 1), new AStack[] {new OreDictStack("ingotSteel", 4), new ComparableStack(ModItems.ingot_polymer, 2), new OreDictStack("plateSteel", 12), new ComparableStack(ModBlocks.machine_battery, 1), new ComparableStack(ModItems.circuit_gold, 2), },250);
makeRecipe(new ComparableStack(ModItems.chopper, 1), new AStack[] {new ComparableStack(ModItems.chopper_blades, 5), new ComparableStack(ModItems.chopper_gun, 1), new ComparableStack(ModItems.chopper_head, 1), new ComparableStack(ModItems.chopper_tail, 1), new ComparableStack(ModItems.chopper_torso, 1), new ComparableStack(ModItems.chopper_wing, 2), },300);
makeRecipe(new ComparableStack(ModItems.spawn_chopper, 1), new AStack[] {new ComparableStack(ModItems.chopper_blades, 5), new ComparableStack(ModItems.chopper_gun, 1), new ComparableStack(ModItems.chopper_head, 1), new ComparableStack(ModItems.chopper_tail, 1), new ComparableStack(ModItems.chopper_torso, 1), new ComparableStack(ModItems.chopper_wing, 2), },300);
makeRecipe(new ComparableStack(ModBlocks.turret_light, 1), new AStack[] {new OreDictStack("ingotSteel", 6), new ComparableStack(ModItems.pipes_steel, 2), new OreDictStack("ingotRedCopperAlloy", 2), new ComparableStack(ModItems.motor, 2), new ComparableStack(ModItems.circuit_targeting_tier2, 2), },200);
makeRecipe(new ComparableStack(ModBlocks.turret_heavy, 1), new AStack[] {new OreDictStack("ingotSteel", 8), new OreDictStack("ingotAluminum", 4), new ComparableStack(ModItems.pipes_steel, 2), new ComparableStack(ModItems.hull_small_steel, 1), new OreDictStack("ingotRedCopperAlloy", 4), new ComparableStack(ModItems.motor, 2), new ComparableStack(ModItems.circuit_targeting_tier2, 3), },250);
makeRecipe(new ComparableStack(ModBlocks.turret_rocket, 1), new AStack[] {new OreDictStack("ingotSteel", 12), new OreDictStack("ingotTitanium", 4), new ComparableStack(ModItems.hull_small_steel, 8), new OreDictStack("ingotRedCopperAlloy", 6), new ComparableStack(ModItems.motor, 2), new ComparableStack(ModItems.circuit_targeting_tier3, 2), },300);

View File

@ -23,8 +23,10 @@ public class ContainerLeadBox extends Container {
* slots we made? We can just use InventoryItem.INV_SIZE and if we ever
* change it, the Container updates automatically.
*/
private static final int INV_START = InventoryLeadBox.INV_SIZE, INV_END = INV_START + 26,
HOTBAR_START = INV_END + 1, HOTBAR_END = HOTBAR_START + 8;
private static final int INV_START = InventoryLeadBox.INV_SIZE,
INV_END = INV_START + 26,
HOTBAR_START = INV_END + 1,
HOTBAR_END = HOTBAR_START + 8;
// If you're planning to add armor slots, put those first like this:
// ARMOR_START = InventoryItem.INV_SIZE, ARMOR_END = ARMOR_START+3,

View File

@ -747,6 +747,7 @@ public class ModItems {
public static Item coin_creeper;
public static Item coin_radiation;
public static Item coin_maskman;
public static Item coin_worm;
public static Item rod_empty;
public static Item rod_uranium;
@ -910,6 +911,7 @@ public class ModItems {
public static Item pellet_mercury;
public static Item pellet_meteorite;
public static Item pellet_canister;
public static Item pellet_claws;
public static Item pellet_charged;
public static Item designator;
@ -1154,6 +1156,9 @@ public class ModItems {
public static Item ammo_4gauge_balefire;
public static Item ammo_4gauge_kampf;
public static Item ammo_4gauge_canister;
public static Item ammo_4gauge_claw;
public static Item ammo_4gauge_vampire;
public static Item ammo_4gauge_void;
public static Item ammo_4gauge_sleek;
public static Item ammo_357_desh;
public static Item ammo_44;
@ -1872,7 +1877,9 @@ public class ModItems {
public static Item turret_control;
public static Item turret_chip;
public static Item turret_biometry;
public static Item chopper;
public static Item spawn_chopper;
public static Item spawn_worm;
public static Item key;
public static Item key_red;
@ -2708,6 +2715,7 @@ public class ModItems {
coin_creeper = new ItemCustomLore().setUnlocalizedName("coin_creeper").setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":coin_creeper");
coin_radiation = new ItemCustomLore().setUnlocalizedName("coin_radiation").setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":coin_radiation");
coin_maskman = new ItemCustomLore().setUnlocalizedName("coin_maskman").setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":coin_maskman");
coin_worm = new ItemCustomLore().setUnlocalizedName("coin_worm").setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":coin_worm");
recycled_ground = new Item().setUnlocalizedName("recycled_ground").setCreativeTab(null).setTextureName(RefStrings.MODID + ":recycled_ground");
recycled_rock = new Item().setUnlocalizedName("recycled_rock").setCreativeTab(null).setTextureName(RefStrings.MODID + ":recycled_rock");
@ -2862,6 +2870,7 @@ public class ModItems {
pellet_mercury = new Item().setUnlocalizedName("pellet_mercury").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":pellets_mercury");
pellet_meteorite = new Item().setUnlocalizedName("pellet_meteorite").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":pellets_meteorite");
pellet_canister = new Item().setUnlocalizedName("pellet_canister").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":pellets_canister");
pellet_claws = new Item().setUnlocalizedName("pellet_claws").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":pellets_claws");
pellet_charged = new Item().setUnlocalizedName("pellet_charged").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":pellets_charged");
pellet_schrabidium = new WatzFuel(25F, true, 50000, 140000, 0.975F, 200, 1.05F, 1.05F).setUnlocalizedName("pellet_schrabidium").setCreativeTab(MainRegistry.controlTab).setTextureName(RefStrings.MODID + ":pellet_schrabidium").setMaxStackSize(1);
@ -3091,6 +3100,9 @@ public class ModItems {
ammo_4gauge_balefire = new ItemAmmo().setUnlocalizedName("ammo_4gauge_balefire").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_4gauge_balefire");
ammo_4gauge_kampf = new ItemAmmo().setUnlocalizedName("ammo_4gauge_kampf").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_4gauge_kampf");
ammo_4gauge_canister = new ItemAmmo().setUnlocalizedName("ammo_4gauge_canister").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_4gauge_canister");
ammo_4gauge_claw = new ItemAmmo().setUnlocalizedName("ammo_4gauge_claw").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_4gauge_claw");
ammo_4gauge_vampire = new ItemAmmo().setUnlocalizedName("ammo_4gauge_vampire").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_4gauge_vampire");
ammo_4gauge_void = new ItemAmmo().setUnlocalizedName("ammo_4gauge_void").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_4gauge_void");
ammo_4gauge_sleek = new ItemAmmo().setUnlocalizedName("ammo_4gauge_sleek").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_4gauge_sleek");
ammo_5mm = new ItemAmmo().setUnlocalizedName("ammo_5mm").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_5mm");
ammo_5mm_explosive = new ItemAmmo().setUnlocalizedName("ammo_5mm_explosive").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_5mm_explosive");
@ -3600,7 +3612,8 @@ public class ModItems {
crate_caller = new ItemCrateCaller().setUnlocalizedName("crate_caller").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":crate_caller");
bomb_caller = new ItemBombCaller().setUnlocalizedName("bomb_caller").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":bomb_caller");
meteor_remote = new ItemMeteorRemote().setUnlocalizedName("meteor_remote").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":meteor_remote");
chopper = new ItemChopper().setUnlocalizedName("chopper").setMaxStackSize(1).setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":chopper");
spawn_chopper = new ItemChopper().setUnlocalizedName("chopper").setMaxStackSize(1).setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":chopper");
spawn_worm = new ItemChopper().setUnlocalizedName("spawn_worm").setMaxStackSize(1).setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":spawn_worm");
linker = new ItemTeleLink().setUnlocalizedName("linker").setMaxStackSize(1).setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":linker");
reactor_sensor = new ItemReactorSensor().setUnlocalizedName("reactor_sensor").setMaxStackSize(1).setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":reactor_sensor");
oil_detector = new ItemOilDetector().setUnlocalizedName("oil_detector").setMaxStackSize(1).setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":oil_detector");
@ -4743,6 +4756,7 @@ public class ModItems {
GameRegistry.registerItem(pellet_mercury, pellet_mercury.getUnlocalizedName());
GameRegistry.registerItem(pellet_meteorite, pellet_meteorite.getUnlocalizedName());
GameRegistry.registerItem(pellet_canister, pellet_canister.getUnlocalizedName());
GameRegistry.registerItem(pellet_claws, pellet_claws.getUnlocalizedName());
GameRegistry.registerItem(pellet_charged, pellet_charged.getUnlocalizedName());
GameRegistry.registerItem(pellet_gas, pellet_gas.getUnlocalizedName());
@ -5208,8 +5222,9 @@ public class ModItems {
GameRegistry.registerItem(nuclear_waste, nuclear_waste.getUnlocalizedName());
GameRegistry.registerItem(nuclear_waste_tiny, nuclear_waste_tiny.getUnlocalizedName());
//Da Chopper
GameRegistry.registerItem(chopper, chopper.getUnlocalizedName());
//Spawners
GameRegistry.registerItem(spawn_chopper, spawn_chopper.getUnlocalizedName());
GameRegistry.registerItem(spawn_worm, spawn_worm.getUnlocalizedName());
//Computer Tools
GameRegistry.registerItem(designator, designator.getUnlocalizedName());
@ -5553,6 +5568,9 @@ public class ModItems {
GameRegistry.registerItem(ammo_4gauge_balefire, ammo_4gauge_balefire.getUnlocalizedName());
GameRegistry.registerItem(ammo_4gauge_kampf, ammo_4gauge_kampf.getUnlocalizedName());
GameRegistry.registerItem(ammo_4gauge_canister, ammo_4gauge_canister.getUnlocalizedName());
GameRegistry.registerItem(ammo_4gauge_claw, ammo_4gauge_claw.getUnlocalizedName());
GameRegistry.registerItem(ammo_4gauge_vampire, ammo_4gauge_vampire.getUnlocalizedName());
GameRegistry.registerItem(ammo_4gauge_void, ammo_4gauge_void.getUnlocalizedName());
GameRegistry.registerItem(ammo_4gauge_sleek, ammo_4gauge_sleek.getUnlocalizedName());
GameRegistry.registerItem(ammo_44, ammo_44.getUnlocalizedName());
GameRegistry.registerItem(ammo_44_ap, ammo_44_ap.getUnlocalizedName());
@ -5957,6 +5975,7 @@ public class ModItems {
GameRegistry.registerItem(coin_creeper, coin_creeper.getUnlocalizedName());
GameRegistry.registerItem(coin_radiation,coin_radiation.getUnlocalizedName());
GameRegistry.registerItem(coin_maskman, coin_maskman.getUnlocalizedName());
GameRegistry.registerItem(coin_worm, coin_worm.getUnlocalizedName());
//Chaos
GameRegistry.registerItem(chocolate_milk, chocolate_milk.getUnlocalizedName());

View File

@ -1,6 +1,10 @@
package com.hbm.items.special;
import java.util.List;
import com.hbm.entity.mob.EntityHunterChopper;
import com.hbm.entity.mob.botprime.EntityBOTPrimeHead;
import com.hbm.items.ModItems;
import net.minecraft.block.Block;
import net.minecraft.block.BlockLiquid;
@ -17,132 +21,117 @@ import net.minecraft.util.MovingObjectPosition;
import net.minecraft.world.World;
public class ItemChopper extends Item {
@Override
public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float hitX, float hitY, float hitZ) {
if(world.isRemote) {
return true;
} else {
Block block = world.getBlock(x, y, z);
x += Facing.offsetsXForSide[side];
y += Facing.offsetsYForSide[side];
z += Facing.offsetsZForSide[side];
double offset = 0.0D;
if(side == 1 && block.getRenderType() == 11)
offset = 0.5D;
Entity entity = spawnCreature(world, stack.getItemDamage(), x + 0.5D, y + offset, z + 0.5D);
if(entity != null) {
if(entity instanceof EntityLivingBase && stack.hasDisplayName()) {
((EntityLiving) entity).setCustomNameTag(stack.getDisplayName());
}
if(!player.capabilities.isCreativeMode) {
--stack.stackSize;
}
}
return true;
}
}
@Override
public boolean onItemUse(ItemStack p_77648_1_, EntityPlayer p_77648_2_, World p_77648_3_, int p_77648_4_, int p_77648_5_, int p_77648_6_, int p_77648_7_, float p_77648_8_, float p_77648_9_, float p_77648_10_)
{
if (p_77648_3_.isRemote)
{
return true;
}
else
{
Block block = p_77648_3_.getBlock(p_77648_4_, p_77648_5_, p_77648_6_);
p_77648_4_ += Facing.offsetsXForSide[p_77648_7_];
p_77648_5_ += Facing.offsetsYForSide[p_77648_7_];
p_77648_6_ += Facing.offsetsZForSide[p_77648_7_];
double d0 = 0.0D;
@Override
public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player) {
if(world.isRemote) {
return stack;
} else {
MovingObjectPosition movingobjectposition = this.getMovingObjectPositionFromPlayer(world, player, true);
if (p_77648_7_ == 1 && block.getRenderType() == 11)
{
d0 = 0.5D;
}
if(movingobjectposition == null) {
return stack;
} else {
if(movingobjectposition.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK) {
int i = movingobjectposition.blockX;
int j = movingobjectposition.blockY;
int k = movingobjectposition.blockZ;
Entity entity = spawnCreature(p_77648_3_, p_77648_1_.getItemDamage(), p_77648_4_ + 0.5D, p_77648_5_ + d0, p_77648_6_ + 0.5D);
if(!world.canMineBlock(player, i, j, k)) {
return stack;
}
if (entity != null)
{
if (entity instanceof EntityLivingBase && p_77648_1_.hasDisplayName())
{
((EntityLiving)entity).setCustomNameTag(p_77648_1_.getDisplayName());
}
if(!player.canPlayerEdit(i, j, k, movingobjectposition.sideHit, stack)) {
return stack;
}
if (!p_77648_2_.capabilities.isCreativeMode)
{
--p_77648_1_.stackSize;
}
}
if(world.getBlock(i, j, k) instanceof BlockLiquid) {
Entity entity = spawnCreature(world, stack.getItemDamage(), i, j, k);
return true;
}
}
if(entity != null) {
if(entity instanceof EntityLivingBase && stack.hasDisplayName()) {
((EntityLiving) entity).setCustomNameTag(stack.getDisplayName());
}
/**
* Called whenever this item is equipped and the right mouse button is pressed. Args: itemStack, world, entityPlayer
*/
@Override
public ItemStack onItemRightClick(ItemStack p_77659_1_, World p_77659_2_, EntityPlayer p_77659_3_)
{
if (p_77659_2_.isRemote)
{
return p_77659_1_;
}
else
{
MovingObjectPosition movingobjectposition = this.getMovingObjectPositionFromPlayer(p_77659_2_, p_77659_3_, true);
if(!player.capabilities.isCreativeMode) {
--stack.stackSize;
}
}
}
}
if (movingobjectposition == null)
{
return p_77659_1_;
}
else
{
if (movingobjectposition.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK)
{
int i = movingobjectposition.blockX;
int j = movingobjectposition.blockY;
int k = movingobjectposition.blockZ;
return stack;
}
}
}
if (!p_77659_2_.canMineBlock(p_77659_3_, i, j, k))
{
return p_77659_1_;
}
public Entity spawnCreature(World world, int dmg, double x, double y, double z) {
Entity entity = null;
if(this == ModItems.spawn_chopper)
entity = new EntityHunterChopper(world);
if(this == ModItems.spawn_worm)
entity = new EntityBOTPrimeHead(world);
if(entity != null) {
if (!p_77659_3_.canPlayerEdit(i, j, k, movingobjectposition.sideHit, p_77659_1_))
{
return p_77659_1_;
}
EntityLiving entityliving = (EntityLiving) entity;
entity.setLocationAndAngles(x, y, z, MathHelper.wrapAngleTo180_float(world.rand.nextFloat() * 360.0F), 0.0F);
entityliving.rotationYawHead = entityliving.rotationYaw;
entityliving.renderYawOffset = entityliving.rotationYaw;
entityliving.onSpawnWithEgg((IEntityLivingData) null);
world.spawnEntityInWorld(entity);
}
if (p_77659_2_.getBlock(i, j, k) instanceof BlockLiquid)
{
Entity entity = spawnCreature(p_77659_2_, p_77659_1_.getItemDamage(), i, j, k);
return entity;
}
if (entity != null)
{
if (entity instanceof EntityLivingBase && p_77659_1_.hasDisplayName())
{
((EntityLiving)entity).setCustomNameTag(p_77659_1_.getDisplayName());
}
@Override
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool) {
if (!p_77659_3_.capabilities.isCreativeMode)
{
--p_77659_1_.stackSize;
}
}
}
}
return p_77659_1_;
}
}
}
/**
* Spawns the creature specified by the egg's type in the location specified by the last three parameters.
* Parameters: world, entityID, x, y, z.
*/
public static Entity spawnCreature(World p_77840_0_, int p_77840_1_, double p_77840_2_, double p_77840_4_, double p_77840_6_)
{
{
Entity entity = null;
for (int j = 0; j < 1; ++j)
{
entity = new EntityHunterChopper(p_77840_0_);
if (entity != null && entity instanceof EntityLivingBase)
{
EntityLiving entityliving = (EntityLiving)entity;
entity.setLocationAndAngles(p_77840_2_, p_77840_4_, p_77840_6_, MathHelper.wrapAngleTo180_float(p_77840_0_.rand.nextFloat() * 360.0F), 0.0F);
entityliving.rotationYawHead = entityliving.rotationYaw;
entityliving.renderYawOffset = entityliving.rotationYaw;
entityliving.onSpawnWithEgg((IEntityLivingData)null);
p_77840_0_.spawnEntityInWorld(entity);
}
}
return entity;
}
}
if(this == ModItems.spawn_worm) {
list.add("Without a player in survival mode");
list.add("to target, he struggles around a lot.");
list.add("");
list.add("He's doing his best so please show him");
list.add("some consideration.");
}
}
}

View File

@ -1,5 +1,8 @@
package com.hbm.items.tool;
import com.hbm.items.ModItems;
import com.hbm.main.MainRegistry;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;

View File

@ -521,6 +521,14 @@ public class ItemAmmo extends Item {
list.add(EnumChatFormatting.YELLOW + "Gyro-stabilized armor-piercing");
list.add(EnumChatFormatting.YELLOW + "DU round with tandem charge");
}
if(this == ModItems.ammo_75bolt_incendiary) {
list.add(EnumChatFormatting.YELLOW + "Armor-piercing explosive round");
list.add(EnumChatFormatting.YELLOW + "filled with oxy-phosphorous gel");
}
if(this == ModItems.ammo_75bolt_he) {
list.add(EnumChatFormatting.YELLOW + "Armor-piercing penetrator filled");
list.add(EnumChatFormatting.YELLOW + "with a powerful explosive charge");
}
//FOLLY
if(this == ModItems.ammo_folly) {

View File

@ -71,6 +71,7 @@ public class Library {
public static String SweatySwiggs = "5544aa30-b305-4362-b2c1-67349bb499d5";
public static String Drillgon = "41ebd03f-7a12-42f3-b037-0caa4d6f235b";
public static String Doctor17 = "e4ab1199-1c22-4f82-a516-c3238bc2d0d1";
public static String Doctor17PH = "4d0477d7-58da-41a9-a945-e93df8601c5a";
public static String ShimmeringBlaze = "061bc566-ec74-4307-9614-ac3a70d2ef38";
public static String FifeMiner = "37e5eb63-b9a2-4735-9007-1c77d703daa3";
public static String lag_add = "259785a0-20e9-4c63-9286-ac2f93ff528f";

View File

@ -677,7 +677,7 @@ public class CraftingManager {
GameRegistry.addRecipe(new ItemStack(ModItems.plate_armor_hev, 1), new Object[] { "NPN", "PIP", "NPN", 'N', ModItems.wire_tungsten, 'P', ModItems.plate_advanced_alloy, 'I', ModItems.plate_armor_titanium });
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.plate_armor_lunar, 1), new Object[] { "NPN", "PIP", "NPN", 'N', ModItems.wire_magnetized_tungsten, 'P', "plateDenseLead", 'I', ModItems.ingot_starmetal }));
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.mech_key, 1), new Object[] { " GC", "GAG", "AG ", 'G', "nuggetGold", 'A', "ingotAluminum", 'C', ModItems.coin_maskman }));
GameRegistry.addRecipe(new ItemStack(ModItems.mech_key, 1), new Object[] { "MCM", "MKM", "MMM", 'M', ModItems.ingot_meteorite_forged, 'C', ModItems.coin_maskman, 'K', ModItems.key });
GameRegistry.addRecipe(new ItemStack(ModBlocks.hadron_coil_alloy, 1), new Object[] { "WWW", "WCW", "WWW", 'W', ModItems.wire_advanced_alloy, 'C', ModBlocks.fusion_conductor });
GameRegistry.addRecipe(new ItemStack(ModBlocks.hadron_coil_schrabidium, 1), new Object[] { "SCS", "CSC", "SCS", 'S', ModItems.powder_schrabidium, 'C', ModBlocks.hadron_coil_alloy });

View File

@ -48,6 +48,8 @@ import com.hbm.entity.item.*;
import com.hbm.entity.logic.*;
import com.hbm.entity.missile.*;
import com.hbm.entity.mob.*;
import com.hbm.entity.mob.botprime.EntityBOTPrimeBody;
import com.hbm.entity.mob.botprime.EntityBOTPrimeHead;
import com.hbm.entity.particle.*;
import com.hbm.entity.projectile.*;
import com.hbm.handler.*;
@ -591,11 +593,9 @@ public class MainRegistry {
EntityRegistry.registerGlobalEntityID(EntityFBI.class, "entity_ntm_fbi", EntityRegistry.findGlobalUniqueEntityId(), 0x008000, 0x404040);
EntityRegistry.registerGlobalEntityID(EntityRADBeast.class, "entity_ntm_radiation_blaze", EntityRegistry.findGlobalUniqueEntityId(), 0x303030, 0x008000);
// EntityRegistry.registerGlobalEntityID(EntityBOTPrimeHead.class,
// "entity_balls_o_tron_mk0", EntityRegistry.findGlobalUniqueEntityId(),
// 0xAAAAAA, 0xAAAAAA);
// EntityRegistry.registerModEntity(EntityBOTPrimeBody.class,
// "entity_balls_o_tron_mk0_segfault", 148, this, 1000, 1, true);
//EntityRegistry.registerGlobalEntityID(EntityBOTPrimeHead.class, "entity_balls_o_tron", EntityRegistry.findGlobalUniqueEntityId(), 0xAAAAAA, 0xAAAAAA);
EntityRegistry.registerModEntity(EntityBOTPrimeHead.class, "entity_balls_o_tron", 150, this, 1000, 1, true);
EntityRegistry.registerModEntity(EntityBOTPrimeBody.class, "entity_balls_o_tron_seg", 151, this, 1000, 1, true);
ForgeChunkManager.setForcedChunkLoadingCallback(this, new LoadingCallback() {

View File

@ -22,6 +22,7 @@ import com.hbm.entity.mob.EntityDuck;
import com.hbm.entity.mob.EntityNuclearCreeper;
import com.hbm.entity.mob.EntityQuackos;
import com.hbm.entity.mob.EntityTaintedCreeper;
import com.hbm.entity.mob.botprime.EntityBOTPrimeHead;
import com.hbm.entity.projectile.EntityBurningFOEQ;
import com.hbm.entity.projectile.EntityMeteor;
import com.hbm.handler.BossSpawnHandler;
@ -82,6 +83,7 @@ import net.minecraft.world.chunk.Chunk;
import net.minecraftforge.event.AnvilUpdateEvent;
import net.minecraftforge.event.ServerChatEvent;
import net.minecraftforge.event.entity.EntityEvent.EnteringChunk;
import net.minecraftforge.event.entity.EntityJoinWorldEvent;
import net.minecraftforge.event.entity.living.LivingAttackEvent;
import net.minecraftforge.event.entity.living.LivingDeathEvent;
import net.minecraftforge.event.entity.living.LivingEvent.LivingJumpEvent;

View File

@ -3,12 +3,11 @@ package com.hbm.render.entity.mob;
import org.lwjgl.opengl.GL11;
import com.hbm.lib.RefStrings;
import com.hbm.main.ResourceManager;
import com.hbm.render.loader.HFRWavefrontObject;
import net.minecraft.client.renderer.entity.Render;
import net.minecraft.entity.Entity;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.client.model.AdvancedModelLoader;
import net.minecraftforge.client.model.IModelCustom;
public class RenderWormBody extends Render {
@ -16,8 +15,9 @@ public class RenderWormBody extends Render {
public RenderWormBody() {
this.shadowOpaque = 0.0F;
}
public static final IModelCustom body = AdvancedModelLoader.loadModel(new ResourceLocation(RefStrings.MODID, "models/mobs/bot_prime_body.obj"));
public static final IModelCustom body = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/mobs/bot_prime_body.obj"));
public static final ResourceLocation texture = new ResourceLocation(RefStrings.MODID, "textures/entity/mark_zero_body.png");
@Override
public void doRender(Entity entity, double x, double y, double z, float f0, float f1) {
@ -28,13 +28,17 @@ public class RenderWormBody extends Render {
GL11.glRotatef(entity.prevRotationPitch + (entity.rotationPitch - entity.prevRotationPitch) * f1 - 90, 0.0F, 0.0F, 1.0F);
this.bindEntityTexture(entity);
GL11.glShadeModel(GL11.GL_SMOOTH);
GL11.glDisable(GL11.GL_CULL_FACE);
body.renderAll();
GL11.glEnable(GL11.GL_CULL_FACE);
GL11.glShadeModel(GL11.GL_FLAT);
GL11.glPopMatrix();
}
@Override
protected ResourceLocation getEntityTexture(Entity p_110775_1_) {
return ResourceManager.universal;
return texture;
}
}

View File

@ -1,30 +1,48 @@
package com.hbm.render.entity.mob;
import com.hbm.entity.mob.botprime.EntityBOTPrimeHead;
import com.hbm.main.ResourceManager;
import com.hbm.render.model.ModelWormHead;
import org.lwjgl.opengl.GL11;
import net.minecraft.client.renderer.entity.RenderLiving;
import com.hbm.entity.mob.botprime.EntityBOTPrimeHead;
import com.hbm.lib.RefStrings;
import com.hbm.render.loader.HFRWavefrontObject;
import net.minecraft.client.renderer.entity.Render;
import net.minecraft.entity.Entity;
import net.minecraft.entity.boss.BossStatus;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.client.model.IModelCustom;
public class RenderWormHead extends RenderLiving {
public class RenderWormHead extends Render {
public RenderWormHead() {
super(new ModelWormHead(), 1.0F);
this.shadowOpaque = 0.0F;
}
public static final IModelCustom body = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/mobs/bot_prime_head.obj"));
public static final ResourceLocation texture = new ResourceLocation(RefStrings.MODID, "textures/entity/mark_zero_head.png");
@Override
public void doRender(Entity entity, double x, double y, double z, float f0, float f1) {
GL11.glPushMatrix();
BossStatus.setBossStatus((EntityBOTPrimeHead)entity, true);
super.doRender(entity, x, y, z, f0, f1);
GL11.glTranslated(x, y, z);
GL11.glRotatef(entity.prevRotationYaw + (entity.rotationYaw - entity.prevRotationYaw) * f1 - 90.0F, 0.0F, 1.0F, 0.0F);
GL11.glRotatef(entity.prevRotationPitch + (entity.rotationPitch - entity.prevRotationPitch) * f1 - 90, 0.0F, 0.0F, 1.0F);
this.bindEntityTexture(entity);
GL11.glShadeModel(GL11.GL_SMOOTH);
GL11.glDisable(GL11.GL_CULL_FACE);
body.renderAll();
GL11.glEnable(GL11.GL_CULL_FACE);
GL11.glShadeModel(GL11.GL_FLAT);
GL11.glPopMatrix();
}
@Override
protected ResourceLocation getEntityTexture(Entity p_110775_1_) {
return ResourceManager.universal;
return texture;
}
}

View File

@ -320,6 +320,7 @@ public class RenderBullet extends Render {
case BulletConfiguration.BOLT_LASER: red = 1F; green = 0F; blue = 0F; break;
case BulletConfiguration.BOLT_NIGHTMARE: red = 1F; green = 1F; blue = 0F; break;
case BulletConfiguration.BOLT_LACUNAE: red = 0.25F; green = 0F; blue = 0.75F; break;
case BulletConfiguration.BOLT_WORM: red = 0F; green = 1F; blue = 0F; break;
case BulletConfiguration.BOLT_ZOMG:
Random rand = new Random(eID * eID);

View File

@ -18,7 +18,6 @@ public class ModelWormHead extends ModelBase {
public void render(Entity entity, float x, float y, float z, float f3, float f4, float f5) {
super.render(entity, x, y, z, f3, f4, f5);
GL11.glTranslated(x, y, z);
GL11.glRotatef(entity.prevRotationYaw + (entity.rotationYaw - entity.prevRotationYaw) * f5 - 90.0F, 0.0F, 1.0F, 0.0F);
GL11.glRotatef(entity.prevRotationPitch + (entity.rotationPitch - entity.prevRotationPitch) * f5 - 90, 0.0F, 0.0F, 1.0F);

View File

@ -92,7 +92,7 @@ public class RenderAccessoryUtility {
if(uuid.equals(Library.SweatySwiggs)) {
return swiggs;
}
if(uuid.equals(Library.Doctor17)) {
if(uuid.equals(Library.Doctor17) || uuid.equals(Library.Doctor17PH)) {
return doctor17;
}
if(uuid.equals(Library.ShimmeringBlaze)) {

View File

@ -92,8 +92,10 @@ public class RenderScreenOverlay {
public static void renderCustomCrosshairs(ScaledResolution resolution, Gui gui, Crosshair cross) {
if(cross == Crosshair.NONE)
if(cross == Crosshair.NONE) {
Minecraft.getMinecraft().renderEngine.bindTexture(Gui.icons);
return;
}
int size = cross.size;
@ -123,7 +125,7 @@ public class RenderScreenOverlay {
String cap = max == -1 ? ("") : ("" + max);
if(renderCount)
//if(renderCount)
Minecraft.getMinecraft().fontRenderer.drawString(count + " / " + cap, pX + 16, pZ + 6, 0xFFFFFF);
GL11.glDisable(GL11.GL_BLEND);