new radiation mechanics, IF shotgun ammo
@ -317,6 +317,7 @@ item.ammo_12gauge_du.name=Kaliber 12 Schrot (Uranbeschichtung)
|
||||
item.ammo_12gauge_incendiary.name=Kaliber 12 Schrot (Brand)
|
||||
item.ammo_12gauge_marauder.name=Kaliber 12 Taktische Anti-Marauder Schrotpatrone
|
||||
item.ammo_12gauge_shrapnel.name=Kaliber 12 Schrot (Schrapnell)
|
||||
item.ammo_12gauge_sleek.name=Kaliber 12 Schrot (IF-F&E)
|
||||
item.ammo_20gauge.name=Kaliber 20 Schrot
|
||||
item.ammo_20gauge_caustic.name=Kaliber 20 Schrot (Ätzend)
|
||||
item.ammo_20gauge_explosive.name=Kaliber 20 Schrot (Explosiv)
|
||||
@ -324,6 +325,7 @@ item.ammo_20gauge_flechette.name=Kaliber 20 Flechet
|
||||
item.ammo_20gauge_incendiary.name=Kaliber 20 Schrot (Brand)
|
||||
item.ammo_20gauge_shock.name=Kaliber 20 Schrot (Schock)
|
||||
item.ammo_20gauge_shrapnel.name=Kaliber 20 Schrot (Schrapnell)
|
||||
item.ammo_20gauge_sleek.name=Kaliber 20 Schrot (IF-F&E)
|
||||
item.ammo_20gauge_slug.name=Kaliber 20 Brenneke
|
||||
item.ammo_20gauge_wither.name=Kaliber 20 Schrot (Wither)
|
||||
item.ammo_22lr.name=.22 lfB Patrone
|
||||
@ -340,6 +342,7 @@ item.ammo_44_silver.name=.44 Magnum Patrone (Gebäude)
|
||||
item.ammo_44_star.name=.44 Magnum Patrone (Sternenmetall)
|
||||
item.ammo_4gauge.name=Kaliber 20 Schrot
|
||||
item.ammo_4gauge_explosive.name=23mm Granate
|
||||
item.ammo_4gauge_sleek.name=Kaliber 4 Schrot (IF-F&E)
|
||||
item.ammo_4gauge_slug.name=Kaliber 4 Brenneke
|
||||
item.ammo_50ae.name=.50 AE Patrone
|
||||
item.ammo_50ae_ap.name=.50 AE Patrone (Panzerbrechend)
|
||||
|
||||
@ -317,6 +317,7 @@ item.ammo_12gauge_du.name=12 Gauge Buckshot (Uranium Coated)
|
||||
item.ammo_12gauge_incendiary.name=12 Gauge Buckshot (Incendiary)
|
||||
item.ammo_12gauge_marauder.name=12 Gauge Tactical Anti-Marauder Shell
|
||||
item.ammo_12gauge_shrapnel.name=12 Gauge Buckshot (Shrapnel)
|
||||
item.ammo_12gauge_sleek.name=12 Gauge Buckshot (IF-R&D)
|
||||
item.ammo_20gauge.name=20 Gauge Buckshot
|
||||
item.ammo_20gauge_caustic.name=20 Gauge Buckshot (Caustic)
|
||||
item.ammo_20gauge_explosive.name=20 Gauge Buckshot (Explosive)
|
||||
@ -324,6 +325,7 @@ item.ammo_20gauge_flechette.name=20 Gauge Flechette Shell
|
||||
item.ammo_20gauge_incendiary.name=20 Gauge Buckshot (Incendiary)
|
||||
item.ammo_20gauge_shock.name=20 Gauge Buckshot (Shock)
|
||||
item.ammo_20gauge_shrapnel.name=20 Gauge Buckshot (Shrapnel)
|
||||
item.ammo_20gauge_sleek.name=20 Gauge Buckshot (IF-R&D)
|
||||
item.ammo_20gauge_slug.name=20 Gauge Brenneke Slug
|
||||
item.ammo_20gauge_wither.name=20 Gauge Buckshot (Withering)
|
||||
item.ammo_22lr.name=.22 LR Round
|
||||
@ -340,6 +342,7 @@ item.ammo_44_silver.name=.44 Magnum Bullet (Building)
|
||||
item.ammo_44_star.name=.44 Magnum Bullet (Starmetal)
|
||||
item.ammo_4gauge.name=4 Gauge Buckshot
|
||||
item.ammo_4gauge_explosive.name=23mm Grenade
|
||||
item.ammo_4gauge_sleek.name=4 Gauge Buckshot (IF-R&D)
|
||||
item.ammo_4gauge_slug.name=4 Gauge Solid Steel Slug
|
||||
item.ammo_50ae.name=.50 AE Round
|
||||
item.ammo_50ae_ap.name=.50 AE Round (Armor Piercing)
|
||||
|
||||
BIN
src/main/java/assets/hbm/textures/blocks/waste_grass_side.png
Normal file
|
After Width: | Height: | Size: 684 B |
BIN
src/main/java/assets/hbm/textures/blocks/waste_grass_top.png
Normal file
|
After Width: | Height: | Size: 404 B |
BIN
src/main/java/assets/hbm/textures/items/ammo_12gauge_sleek.png
Normal file
|
After Width: | Height: | Size: 357 B |
BIN
src/main/java/assets/hbm/textures/items/ammo_4gauge_sleek.png
Normal file
|
After Width: | Height: | Size: 366 B |
BIN
src/main/java/assets/hbm/textures/items/coin_base.png
Normal file
|
After Width: | Height: | Size: 279 B |
BIN
src/main/java/assets/hbm/textures/items/coin_chopper.png
Normal file
|
After Width: | Height: | Size: 430 B |
BIN
src/main/java/assets/hbm/textures/items/coin_creeper.png
Normal file
|
After Width: | Height: | Size: 389 B |
BIN
src/main/java/assets/hbm/textures/items/coin_maskman.png
Normal file
|
After Width: | Height: | Size: 430 B |
BIN
src/main/java/assets/hbm/textures/items/coin_radiation.png
Normal file
|
After Width: | Height: | Size: 431 B |
@ -1,11 +1,16 @@
|
||||
package com.hbm.entity.mob;
|
||||
|
||||
import com.hbm.entity.mob.ai.EntityAIShootTarget;
|
||||
import com.hbm.items.ModItems;
|
||||
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.EntityAIAttackOnCollide;
|
||||
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.ai.EntityAIWatchClosest;
|
||||
import net.minecraft.entity.boss.IBossDisplayData;
|
||||
import net.minecraft.entity.monster.EntityMob;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
@ -17,18 +22,26 @@ public class EntityMaskMan extends EntityMob implements IBossDisplayData {
|
||||
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.tasks.addTask(2, new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.0D, false));
|
||||
this.tasks.addTask(2, new EntityAIShootTarget(this, true, true, 3));
|
||||
this.tasks.addTask(3, new EntityAIWander(this, 1.0D));
|
||||
this.tasks.addTask(4, new EntityAILookIdle(this));
|
||||
this.tasks.addTask(5, new EntityAIWatchClosest(this, EntityPlayer.class, 8.0F));
|
||||
this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, false));
|
||||
this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityPlayer.class, 0, true));
|
||||
|
||||
this.setSize(2F, 5F);
|
||||
this.isImmuneToFire = true;
|
||||
this.experienceValue = 100;
|
||||
}
|
||||
|
||||
protected void applyEntityAttributes() {
|
||||
super.applyEntityAttributes();
|
||||
this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(0.5D);
|
||||
this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(0.35D);
|
||||
this.getEntityAttribute(SharedMonsterAttributes.followRange).setBaseValue(24.0D);
|
||||
this.getEntityAttribute(SharedMonsterAttributes.attackDamage).setBaseValue(15.0D);
|
||||
this.getEntityAttribute(SharedMonsterAttributes.knockbackResistance).setBaseValue(1.0D);
|
||||
this.getEntityAttribute(SharedMonsterAttributes.maxHealth).setBaseValue(1000.0D);
|
||||
}
|
||||
|
||||
public boolean isAIEnabled() {
|
||||
@ -38,4 +51,9 @@ public class EntityMaskMan extends EntityMob implements IBossDisplayData {
|
||||
protected boolean canDespawn() {
|
||||
return false;
|
||||
}
|
||||
|
||||
protected void dropFewItems(boolean bool, int i) {
|
||||
|
||||
this.dropItem(ModItems.coin_maskman, 1);
|
||||
}
|
||||
}
|
||||
|
||||
@ -4,6 +4,7 @@ import java.util.List;
|
||||
|
||||
import com.hbm.entity.effect.EntityNukeCloudSmall;
|
||||
import com.hbm.entity.logic.EntityNukeExplosionMK4;
|
||||
import com.hbm.entity.mob.ai.EntityAINuclearCreeperSwell;
|
||||
import com.hbm.explosion.ExplosionParticle;
|
||||
import com.hbm.explosion.ExplosionParticleB;
|
||||
import com.hbm.items.ModItems;
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
package com.hbm.entity.mob;
|
||||
|
||||
import com.hbm.blocks.ModBlocks;
|
||||
import com.hbm.entity.mob.ai.EntityAITaintedCreeperSwell;
|
||||
import com.hbm.main.MainRegistry;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
|
||||
@ -1,4 +1,6 @@
|
||||
package com.hbm.entity.mob;
|
||||
package com.hbm.entity.mob.ai;
|
||||
|
||||
import com.hbm.entity.mob.EntityNuclearCreeper;
|
||||
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.ai.EntityAIBase;
|
||||
57
src/main/java/com/hbm/entity/mob/ai/EntityAIShootTarget.java
Normal file
@ -0,0 +1,57 @@
|
||||
package com.hbm.entity.mob.ai;
|
||||
|
||||
import com.hbm.entity.projectile.EntityBulletBase;
|
||||
import com.hbm.handler.BulletConfigSyncingUtil;
|
||||
|
||||
import net.minecraft.entity.EntityCreature;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.ai.EntityAIBase;
|
||||
import net.minecraft.util.Vec3;
|
||||
|
||||
public class EntityAIShootTarget extends EntityAIBase {
|
||||
|
||||
private EntityCreature owner;
|
||||
private EntityLivingBase target;
|
||||
int delay;
|
||||
int timer;
|
||||
|
||||
public EntityAIShootTarget(EntityCreature owner, boolean checkSight, boolean nearbyOnly, int delay) {
|
||||
this.owner = owner;
|
||||
this.delay = delay;
|
||||
timer = delay;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean shouldExecute() {
|
||||
|
||||
EntityLivingBase entity = this.owner.getAttackTarget();
|
||||
|
||||
if(entity == null) {
|
||||
return false;
|
||||
|
||||
} else {
|
||||
this.target = entity;
|
||||
double dist = Vec3.createVectorHelper(target.posX - owner.posX, target.posY - owner.posY, target.posZ - owner.posZ).lengthVector();
|
||||
return dist > 5 && dist < 10;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean continueExecuting() {
|
||||
return this.shouldExecute() || !this.owner.getNavigator().noPath();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateTask() {
|
||||
|
||||
timer--;
|
||||
|
||||
if(timer <= 0) {
|
||||
timer = delay;
|
||||
|
||||
EntityBulletBase bullet = new EntityBulletBase(owner.worldObj, BulletConfigSyncingUtil.G20_SHRAPNEL, owner, target, 1.6F, 0);
|
||||
owner.worldObj.spawnEntityInWorld(bullet);
|
||||
owner.playSound("hbm:weapon.sawShoot", 1.0F, 2.0F);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,4 +1,6 @@
|
||||
package com.hbm.entity.mob;
|
||||
package com.hbm.entity.mob.ai;
|
||||
|
||||
import com.hbm.entity.mob.EntityTaintedCreeper;
|
||||
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.ai.EntityAIBase;
|
||||
@ -58,6 +58,10 @@ public class EntityBulletBase extends Entity implements IProjectile {
|
||||
this.config = BulletConfigSyncingUtil.pullConfig(config);
|
||||
this.dataWatcher.updateObject(18, config);
|
||||
this.renderDistanceWeight = 10.0D;
|
||||
|
||||
this.dataWatcher.updateObject(16, (byte)this.config.style);
|
||||
this.dataWatcher.updateObject(17, (byte)this.config.trail);
|
||||
|
||||
this.setSize(0.5F, 0.5F);
|
||||
}
|
||||
|
||||
@ -87,6 +91,36 @@ public class EntityBulletBase extends Entity implements IProjectile {
|
||||
this.dataWatcher.updateObject(17, (byte)this.config.trail);
|
||||
}
|
||||
|
||||
public EntityBulletBase(World world, int config, EntityLivingBase entity, EntityLivingBase target, float motion, float deviation) {
|
||||
super(world);
|
||||
|
||||
this.config = BulletConfigSyncingUtil.pullConfig(config);
|
||||
this.dataWatcher.updateObject(18, config);
|
||||
this.shooter = entity;
|
||||
|
||||
this.renderDistanceWeight = 10.0D;
|
||||
this.setSize(0.5F, 0.5F);
|
||||
|
||||
this.posY = entity.posY + entity.getEyeHeight() - 0.10000000149011612D;
|
||||
double d0 = target.posX - entity.posX;
|
||||
double d1 = target.boundingBox.minY + target.height / 3.0F - this.posY;
|
||||
double d2 = target.posZ - entity.posZ;
|
||||
double d3 = MathHelper.sqrt_double(d0 * d0 + d2 * d2);
|
||||
|
||||
if (d3 >= 1.0E-7D) {
|
||||
float f2 = (float) (Math.atan2(d2, d0) * 180.0D / Math.PI) - 90.0F;
|
||||
float f3 = (float) (-(Math.atan2(d1, d3) * 180.0D / Math.PI));
|
||||
double d4 = d0 / d3;
|
||||
double d5 = d2 / d3;
|
||||
this.setLocationAndAngles(entity.posX + d4, this.posY, entity.posZ + d5, f2, f3);
|
||||
this.yOffset = 0.0F;
|
||||
this.setThrowableHeading(d0, d1, d2, motion, deviation);
|
||||
}
|
||||
|
||||
this.dataWatcher.updateObject(16, (byte)this.config.style);
|
||||
this.dataWatcher.updateObject(17, (byte)this.config.trail);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setThrowableHeading(double moX, double moY, double moZ, float mult1, float mult2) {
|
||||
|
||||
|
||||
@ -33,6 +33,7 @@ public class BulletConfigSyncingUtil {
|
||||
public static int G20_CAUSTIC = i++;
|
||||
public static int G20_SHOCK = i++;
|
||||
public static int G20_WITHER = i++;
|
||||
public static int G20_SLEEK = i++;
|
||||
|
||||
public static int ROCKET_NORMAL = i++;
|
||||
public static int ROCKET_HE = i++;
|
||||
@ -63,6 +64,7 @@ public class BulletConfigSyncingUtil {
|
||||
public static int G12_SHRAPNEL = i++;
|
||||
public static int G12_DU = i++;
|
||||
public static int G12_AM = i++;
|
||||
public static int G12_SLEEK = i++;
|
||||
|
||||
public static int LR22_NORMAL = i++;
|
||||
public static int LR22_AP = i++;
|
||||
@ -109,6 +111,7 @@ public class BulletConfigSyncingUtil {
|
||||
public static int G4_NORMAL = i++;
|
||||
public static int G4_SLUG = i++;
|
||||
public static int G4_EXPLOSIVE = i++;
|
||||
public static int G4_SLEEK = i++;
|
||||
|
||||
public static int SPECIAL_OSIPR = i++;
|
||||
public static int SPECIAL_OSIPR_CHARGED = i++;
|
||||
@ -185,6 +188,7 @@ public class BulletConfigSyncingUtil {
|
||||
configSet.put(G20_CAUSTIC, Gun20GaugeFactory.get20GaugeCausticConfig());
|
||||
configSet.put(G20_SHOCK, Gun20GaugeFactory.get20GaugeShockConfig());
|
||||
configSet.put(G20_WITHER, Gun20GaugeFactory.get20GaugeWitherConfig());
|
||||
configSet.put(G20_SLEEK, Gun20GaugeFactory.get20GaugeSleekConfig());
|
||||
|
||||
configSet.put(ROCKET_NORMAL, GunRocketFactory.getRocketConfig());
|
||||
configSet.put(ROCKET_HE, GunRocketFactory.getRocketHEConfig());
|
||||
@ -215,6 +219,7 @@ public class BulletConfigSyncingUtil {
|
||||
configSet.put(G12_SHRAPNEL, Gun12GaugeFactory.get12GaugeShrapnelConfig());
|
||||
configSet.put(G12_DU, Gun12GaugeFactory.get12GaugeDUConfig());
|
||||
configSet.put(G12_AM, Gun12GaugeFactory.get12GaugeAMConfig());
|
||||
configSet.put(G12_SLEEK, Gun12GaugeFactory.get12GaugeSleekConfig());
|
||||
|
||||
configSet.put(LR22_NORMAL, Gun22LRFactory.get22LRConfig());
|
||||
configSet.put(LR22_AP, Gun22LRFactory.get22LRAPConfig());
|
||||
@ -261,6 +266,7 @@ public class BulletConfigSyncingUtil {
|
||||
configSet.put(G4_NORMAL, Gun4GaugeFactory.get4GaugeConfig());
|
||||
configSet.put(G4_SLUG, Gun4GaugeFactory.get4GaugeSlugConfig());
|
||||
configSet.put(G4_EXPLOSIVE, Gun4GaugeFactory.get4GaugeExplosiveConfig());
|
||||
configSet.put(G4_SLEEK, Gun4GaugeFactory.get4GaugeSleekConfig());
|
||||
|
||||
configSet.put(SPECIAL_OSIPR, GunOSIPRFactory.getPulseConfig());
|
||||
configSet.put(SPECIAL_OSIPR_CHARGED, GunOSIPRFactory.getPulseChargedConfig());
|
||||
|
||||
73
src/main/java/com/hbm/handler/RadiationWorldHandler.java
Normal file
@ -0,0 +1,73 @@
|
||||
package com.hbm.handler;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map.Entry;
|
||||
|
||||
import com.hbm.saveddata.RadiationSavedData;
|
||||
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.world.ChunkCoordIntPair;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.WorldServer;
|
||||
import net.minecraft.world.chunk.Chunk;
|
||||
import net.minecraft.world.gen.ChunkProviderServer;
|
||||
|
||||
public class RadiationWorldHandler {
|
||||
|
||||
public static void handleWorldDestruction(World world) {
|
||||
|
||||
if(!(world instanceof WorldServer))
|
||||
return;
|
||||
|
||||
WorldServer serv = (WorldServer)world;
|
||||
|
||||
RadiationSavedData data = RadiationSavedData.getData(serv);
|
||||
List<Chunk> loadedChunks = ((ChunkProviderServer) serv.getChunkProvider()).func_152380_a();
|
||||
|
||||
int count = 50;//MainRegistry.worldRad;
|
||||
int threshold = 5;//MainRegistry.worldRadThreshold;
|
||||
|
||||
Object[] entries = data.contamination.entrySet().toArray();
|
||||
|
||||
if(entries.length == 0)
|
||||
return;
|
||||
|
||||
Entry<ChunkCoordIntPair, Float> randEnt = (Entry<ChunkCoordIntPair, Float>) entries[world.rand.nextInt(entries.length)];
|
||||
|
||||
ChunkCoordIntPair coords = randEnt.getKey();
|
||||
Chunk chunk = world.getChunkFromChunkCoords(coords.chunkXPos, coords.chunkZPos);
|
||||
|
||||
for(int i = 0; i < 1; i++) {
|
||||
|
||||
|
||||
if(randEnt == null || randEnt.getValue() < threshold)
|
||||
continue;
|
||||
|
||||
if(chunk != null && loadedChunks.contains(chunk)) {
|
||||
|
||||
for(int a = 0; a < 16; a ++) {
|
||||
for(int b = 0; b < 16; b ++) {
|
||||
|
||||
if(world.rand.nextInt(3) != 0)
|
||||
continue;
|
||||
|
||||
int x = coords.getCenterXPos() - 8 + a;
|
||||
int z = coords.getCenterZPosition() - 8 + b;
|
||||
int y = world.getHeightValue(x, z) - world.rand.nextInt(2);
|
||||
|
||||
if(world.getBlock(x, y, z) == Blocks.grass) {
|
||||
world.setBlock(x, y, z, Blocks.dirt);
|
||||
} else if(world.getBlock(x, y, z) == Blocks.tallgrass) {
|
||||
world.setBlock(x, y, z, Blocks.air);
|
||||
} else if(world.getBlock(x, y, z) == Blocks.leaves) {
|
||||
world.setBlock(x, y, z, Blocks.air);
|
||||
} else if(world.getBlock(x, y, z) == Blocks.leaves2) {
|
||||
world.setBlock(x, y, z, Blocks.air);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@ -1,9 +1,12 @@
|
||||
package com.hbm.handler.guncfg;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.hbm.entity.particle.EntityBSmokeFX;
|
||||
import com.hbm.entity.projectile.EntityBulletBase;
|
||||
import com.hbm.handler.ArmorUtil;
|
||||
import com.hbm.handler.BulletConfigSyncingUtil;
|
||||
import com.hbm.handler.BulletConfiguration;
|
||||
import com.hbm.interfaces.IBulletImpactBehavior;
|
||||
import com.hbm.interfaces.IBulletUpdateBehavior;
|
||||
@ -109,6 +112,61 @@ public class BulletConfigFactory {
|
||||
return bullet;
|
||||
}
|
||||
|
||||
public static BulletConfiguration standardAirstrikeConfig() {
|
||||
|
||||
BulletConfiguration bullet = new BulletConfiguration();
|
||||
|
||||
bullet.velocity = 5.0F;
|
||||
bullet.spread = 0.0F;
|
||||
bullet.wear = 50;
|
||||
bullet.bulletsMin = 1;
|
||||
bullet.bulletsMax = 1;
|
||||
bullet.gravity = 0D;
|
||||
bullet.maxAge = 100;
|
||||
bullet.doesRicochet = false;
|
||||
bullet.doesPenetrate = false;
|
||||
bullet.doesBreakGlass = false;
|
||||
bullet.style = BulletConfiguration.STYLE_BOLT;
|
||||
bullet.leadChance = 0;
|
||||
bullet.vPFX = "reddust";
|
||||
|
||||
bullet.bImpact = new IBulletImpactBehavior() {
|
||||
|
||||
@Override
|
||||
public void behaveBlockHit(EntityBulletBase bullet, int x, int y, int z) {
|
||||
|
||||
if(bullet.worldObj.isRemote)
|
||||
return;
|
||||
|
||||
Random rand = bullet.worldObj.rand;
|
||||
int count = rand.nextInt(11) + 95;
|
||||
|
||||
for(int i = 0; i < count; i++) {
|
||||
|
||||
double dx = bullet.posX + rand.nextGaussian() * 4;
|
||||
double dy = bullet.posY + 25 + rand.nextGaussian() * 5;
|
||||
double dz = bullet.posZ + rand.nextGaussian() * 4;
|
||||
|
||||
Vec3 motion = Vec3.createVectorHelper(bullet.posX - dx, bullet.posY - dy, bullet.posZ - dz);
|
||||
motion = motion.normalize();
|
||||
|
||||
EntityBulletBase bolt = new EntityBulletBase(bullet.worldObj, BulletConfigSyncingUtil.R556_FLECHETTE_DU);
|
||||
bolt.setPosition(dx, dy, dz);
|
||||
bolt.setThrowableHeading(motion.xCoord, motion.yCoord, motion.zCoord, 0.5F, 0.1F);
|
||||
bullet.worldObj.spawnEntityInWorld(bolt);
|
||||
|
||||
if(i < 30) {
|
||||
EntityBSmokeFX bsmoke = new EntityBSmokeFX(bullet.worldObj);
|
||||
bsmoke.setPosition(dx, dy, dz);
|
||||
bullet.worldObj.spawnEntityInWorld(bsmoke);
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
return bullet;
|
||||
}
|
||||
|
||||
public static BulletConfiguration standardRocketConfig() {
|
||||
|
||||
BulletConfiguration bullet = new BulletConfiguration();
|
||||
|
||||
@ -44,6 +44,7 @@ public class Gun12GaugeFactory {
|
||||
config.config.add(BulletConfigSyncingUtil.G12_SHRAPNEL);
|
||||
config.config.add(BulletConfigSyncingUtil.G12_DU);
|
||||
config.config.add(BulletConfigSyncingUtil.G12_AM);
|
||||
config.config.add(BulletConfigSyncingUtil.G12_SLEEK);
|
||||
|
||||
return config;
|
||||
}
|
||||
@ -78,6 +79,7 @@ public class Gun12GaugeFactory {
|
||||
config.config.add(BulletConfigSyncingUtil.G12_SHRAPNEL);
|
||||
config.config.add(BulletConfigSyncingUtil.G12_DU);
|
||||
config.config.add(BulletConfigSyncingUtil.G12_AM);
|
||||
config.config.add(BulletConfigSyncingUtil.G12_SLEEK);
|
||||
|
||||
return config;
|
||||
}
|
||||
@ -158,5 +160,14 @@ public class Gun12GaugeFactory {
|
||||
|
||||
return bullet;
|
||||
}
|
||||
|
||||
public static BulletConfiguration get12GaugeSleekConfig() {
|
||||
|
||||
BulletConfiguration bullet = BulletConfigFactory.standardAirstrikeConfig();
|
||||
|
||||
bullet.ammo = ModItems.ammo_12gauge_sleek;
|
||||
|
||||
return bullet;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -58,6 +58,7 @@ public class Gun20GaugeFactory {
|
||||
config.config.add(BulletConfigSyncingUtil.G20_CAUSTIC);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SHOCK);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_WITHER);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SLEEK);
|
||||
|
||||
return config;
|
||||
}
|
||||
@ -84,6 +85,7 @@ public class Gun20GaugeFactory {
|
||||
config.config.add(BulletConfigSyncingUtil.G20_CAUSTIC);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SHOCK);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_WITHER);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SLEEK);
|
||||
|
||||
return config;
|
||||
}
|
||||
@ -110,6 +112,7 @@ public class Gun20GaugeFactory {
|
||||
config.config.add(BulletConfigSyncingUtil.G20_CAUSTIC);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SHOCK);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_WITHER);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SLEEK);
|
||||
|
||||
return config;
|
||||
}
|
||||
@ -137,6 +140,7 @@ public class Gun20GaugeFactory {
|
||||
config.config.add(BulletConfigSyncingUtil.G20_CAUSTIC);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SHOCK);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_WITHER);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SLEEK);
|
||||
|
||||
return config;
|
||||
}
|
||||
@ -164,6 +168,7 @@ public class Gun20GaugeFactory {
|
||||
config.config.add(BulletConfigSyncingUtil.G20_CAUSTIC);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SHOCK);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_WITHER);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SLEEK);
|
||||
|
||||
return config;
|
||||
}
|
||||
@ -191,6 +196,7 @@ public class Gun20GaugeFactory {
|
||||
config.config.add(BulletConfigSyncingUtil.G20_CAUSTIC_FIRE);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SHOCK_FIRE);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_WITHER_FIRE);
|
||||
config.config.add(BulletConfigSyncingUtil.G20_SLEEK);
|
||||
|
||||
return config;
|
||||
}
|
||||
@ -327,5 +333,14 @@ public class Gun20GaugeFactory {
|
||||
|
||||
return bullet;
|
||||
}
|
||||
|
||||
public static BulletConfiguration get20GaugeSleekConfig() {
|
||||
|
||||
BulletConfiguration bullet = BulletConfigFactory.standardAirstrikeConfig();
|
||||
|
||||
bullet.ammo = ModItems.ammo_20gauge_sleek;
|
||||
|
||||
return bullet;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -50,6 +50,7 @@ public class Gun4GaugeFactory {
|
||||
config.config.add(BulletConfigSyncingUtil.G4_NORMAL);
|
||||
config.config.add(BulletConfigSyncingUtil.G4_SLUG);
|
||||
config.config.add(BulletConfigSyncingUtil.G4_EXPLOSIVE);
|
||||
config.config.add(BulletConfigSyncingUtil.G4_SLEEK);
|
||||
|
||||
return config;
|
||||
}
|
||||
@ -98,6 +99,7 @@ public class Gun4GaugeFactory {
|
||||
config.config.add(BulletConfigSyncingUtil.G4_NORMAL);
|
||||
config.config.add(BulletConfigSyncingUtil.G4_SLUG);
|
||||
config.config.add(BulletConfigSyncingUtil.G4_EXPLOSIVE);
|
||||
config.config.add(BulletConfigSyncingUtil.G4_SLEEK);
|
||||
|
||||
return config;
|
||||
}
|
||||
@ -142,4 +144,13 @@ public class Gun4GaugeFactory {
|
||||
|
||||
return bullet;
|
||||
}
|
||||
|
||||
public static BulletConfiguration get4GaugeSleekConfig() {
|
||||
|
||||
BulletConfiguration bullet = BulletConfigFactory.standardAirstrikeConfig();
|
||||
|
||||
bullet.ammo = ModItems.ammo_4gauge_sleek;
|
||||
|
||||
return bullet;
|
||||
}
|
||||
}
|
||||
|
||||
@ -738,6 +738,8 @@ public class ModItems {
|
||||
public static Item canned_bark;
|
||||
public static Item can_key;
|
||||
|
||||
public static Item coin_maskman;
|
||||
|
||||
public static Item rod_empty;
|
||||
public static Item rod_uranium;
|
||||
public static Item rod_th232;
|
||||
@ -1117,6 +1119,7 @@ public class ModItems {
|
||||
public static Item ammo_12gauge_incendiary;
|
||||
public static Item ammo_12gauge_shrapnel;
|
||||
public static Item ammo_12gauge_du;
|
||||
public static Item ammo_12gauge_sleek;
|
||||
public static Item ammo_12gauge_marauder;
|
||||
public static Item ammo_20gauge;
|
||||
public static Item ammo_20gauge_slug;
|
||||
@ -1127,9 +1130,11 @@ public class ModItems {
|
||||
public static Item ammo_20gauge_caustic;
|
||||
public static Item ammo_20gauge_shock;
|
||||
public static Item ammo_20gauge_wither;
|
||||
public static Item ammo_20gauge_sleek;
|
||||
public static Item ammo_4gauge;
|
||||
public static Item ammo_4gauge_slug;
|
||||
public static Item ammo_4gauge_explosive;
|
||||
public static Item ammo_4gauge_sleek;
|
||||
public static Item ammo_357_desh;
|
||||
public static Item ammo_44;
|
||||
public static Item ammo_44_ap;
|
||||
@ -2576,6 +2581,7 @@ public class ModItems {
|
||||
canned_bark = new ItemLemon(2, 5, false).setUnlocalizedName("canned_bark").setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":canned_bark");
|
||||
can_key = new Item().setUnlocalizedName("can_key").setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":can_key");
|
||||
|
||||
coin_maskman = new ItemCustomLore().setUnlocalizedName("coin_maskman").setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":coin_maskman");
|
||||
|
||||
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");
|
||||
@ -2933,6 +2939,7 @@ public class ModItems {
|
||||
ammo_12gauge_incendiary = new ItemAmmo().setUnlocalizedName("ammo_12gauge_incendiary").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_12gauge_incendiary");
|
||||
ammo_12gauge_shrapnel = new ItemAmmo().setUnlocalizedName("ammo_12gauge_shrapnel").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_12gauge_shrapnel");
|
||||
ammo_12gauge_du = new ItemAmmo().setUnlocalizedName("ammo_12gauge_du").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_12gauge_du");
|
||||
ammo_12gauge_sleek = new ItemAmmo().setUnlocalizedName("ammo_12gauge_sleek").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_12gauge_sleek");
|
||||
ammo_12gauge_marauder = new ItemAmmo().setUnlocalizedName("ammo_12gauge_marauder").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_12gauge_marauder");
|
||||
ammo_20gauge = new ItemAmmo().setUnlocalizedName("ammo_20gauge").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_20gauge");
|
||||
ammo_20gauge_slug = new ItemAmmo().setUnlocalizedName("ammo_20gauge_slug").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_20gauge_slug");
|
||||
@ -2943,9 +2950,11 @@ public class ModItems {
|
||||
ammo_20gauge_caustic = new ItemAmmo().setUnlocalizedName("ammo_20gauge_caustic").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_20gauge_caustic");
|
||||
ammo_20gauge_shock = new ItemAmmo().setUnlocalizedName("ammo_20gauge_shock").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_20gauge_shock");
|
||||
ammo_20gauge_wither = new ItemAmmo().setUnlocalizedName("ammo_20gauge_wither").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_20gauge_wither");
|
||||
ammo_20gauge_sleek = new ItemAmmo().setUnlocalizedName("ammo_20gauge_sleek").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_20gauge_sleek");
|
||||
ammo_4gauge = new ItemAmmo().setUnlocalizedName("ammo_4gauge").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_4gauge");
|
||||
ammo_4gauge_slug = new ItemAmmo().setUnlocalizedName("ammo_4gauge_slug").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_4gauge_slug");
|
||||
ammo_4gauge_explosive = new ItemAmmo().setUnlocalizedName("ammo_4gauge_explosive").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_4gauge_explosive");
|
||||
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");
|
||||
ammo_5mm_du = new ItemAmmo().setUnlocalizedName("ammo_5mm_du").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_5mm_du");
|
||||
@ -5141,6 +5150,7 @@ public class ModItems {
|
||||
GameRegistry.registerItem(ammo_12gauge_incendiary, ammo_12gauge_incendiary.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_12gauge_shrapnel, ammo_12gauge_shrapnel.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_12gauge_du, ammo_12gauge_du.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_12gauge_sleek, ammo_12gauge_sleek.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_12gauge_marauder, ammo_12gauge_marauder.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_20gauge, ammo_20gauge.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_20gauge_slug, ammo_20gauge_slug.getUnlocalizedName());
|
||||
@ -5151,9 +5161,11 @@ public class ModItems {
|
||||
GameRegistry.registerItem(ammo_20gauge_caustic, ammo_20gauge_caustic.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_20gauge_shock, ammo_20gauge_shock.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_20gauge_wither, ammo_20gauge_wither.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_20gauge_sleek, ammo_20gauge_sleek.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_4gauge, ammo_4gauge.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_4gauge_slug, ammo_4gauge_slug.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_4gauge_explosive, ammo_4gauge_explosive.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());
|
||||
GameRegistry.registerItem(ammo_44_du, ammo_44_du.getUnlocalizedName());
|
||||
@ -5519,6 +5531,7 @@ public class ModItems {
|
||||
GameRegistry.registerItem(cap_star, cap_star.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ring_pull, ring_pull.getUnlocalizedName());
|
||||
GameRegistry.registerItem(can_key, can_key.getUnlocalizedName());
|
||||
GameRegistry.registerItem(coin_maskman, coin_maskman.getUnlocalizedName());
|
||||
|
||||
//Chaos
|
||||
GameRegistry.registerItem(chocolate_milk, chocolate_milk.getUnlocalizedName());
|
||||
|
||||
@ -431,7 +431,8 @@ public class ItemCustomLore extends Item {
|
||||
this == ModItems.nugget_daffergon || this == ModItems.nugget_verticium ||
|
||||
this == ModItems.powder_australium || this == ModItems.powder_weidanium ||
|
||||
this == ModItems.powder_reiium || this == ModItems.powder_unobtainium ||
|
||||
this == ModItems.powder_daffergon || this == ModItems.powder_verticium)
|
||||
this == ModItems.powder_daffergon || this == ModItems.powder_verticium ||
|
||||
this == ModItems.coin_maskman)
|
||||
{
|
||||
return EnumRarity.uncommon;
|
||||
}
|
||||
|
||||
@ -34,6 +34,9 @@ public class ItemAmmo extends Item {
|
||||
list.add(EnumChatFormatting.BLUE + "+ Instantly removes annoying and unbalanced enemies");
|
||||
list.add(EnumChatFormatting.YELLOW + "* No drawbacks lole");
|
||||
}
|
||||
if(this == ModItems.ammo_12gauge_sleek) {
|
||||
list.add(EnumChatFormatting.YELLOW + "* Fires a tracer which summons a storm of DU-flechettes");
|
||||
}
|
||||
|
||||
//20 GAUGE
|
||||
if(this == ModItems.ammo_20gauge_flechette) {
|
||||
@ -78,6 +81,9 @@ public class ItemAmmo extends Item {
|
||||
list.add(EnumChatFormatting.BLUE + "+ Increased damage");
|
||||
list.add(EnumChatFormatting.BLUE + "+ Withering");
|
||||
}
|
||||
if(this == ModItems.ammo_20gauge_sleek) {
|
||||
list.add(EnumChatFormatting.YELLOW + "* Fires a tracer which summons a storm of DU-flechettes");
|
||||
}
|
||||
|
||||
//23mm
|
||||
if(this == ModItems.ammo_4gauge_slug) {
|
||||
@ -93,6 +99,9 @@ public class ItemAmmo extends Item {
|
||||
list.add(EnumChatFormatting.RED + "- Highly increased wear");
|
||||
list.add(EnumChatFormatting.RED + "- Single projectile");
|
||||
}
|
||||
if(this == ModItems.ammo_4gauge_sleek) {
|
||||
list.add(EnumChatFormatting.YELLOW + "* Fires a tracer which summons a storm of DU-flechettes");
|
||||
}
|
||||
|
||||
//.357 MAGNUM
|
||||
if(this == ModItems.ammo_357_desh) {
|
||||
|
||||
@ -831,11 +831,14 @@ public class CraftingManager {
|
||||
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_12gauge_incendiary, 8), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_12gauge, 'A', ModItems.powder_fire });
|
||||
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_12gauge_shrapnel, 8), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_12gauge, 'A', ModBlocks.gravel_obsidian });
|
||||
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_12gauge_du, 8), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_12gauge, 'A', ModItems.ingot_u238 });
|
||||
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_12gauge_sleek, 64), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_12gauge, 'A', ModItems.coin_maskman });
|
||||
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_20gauge_incendiary, 8), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_20gauge, 'A', ModItems.powder_fire });
|
||||
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_20gauge_shrapnel, 8), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_20gauge, 'A', ModBlocks.gravel_obsidian });
|
||||
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_20gauge_caustic, 8), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_20gauge, 'A', ModItems.powder_poison });
|
||||
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.ammo_20gauge_shock, 8), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_20gauge, 'A', "dustDiamond" }));
|
||||
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModItems.ammo_20gauge_wither, 4), new Object[] { "BCB", "CAC", "BCB", 'B', ModItems.ammo_20gauge, 'A', Blocks.soul_sand, 'C', "dustCoal" }));
|
||||
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_20gauge_sleek, 64), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_20gauge, 'A', ModItems.coin_maskman });
|
||||
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 });
|
||||
GameRegistry.addRecipe(new ItemStack(ModItems.ammo_44_phosphorus, 8), new Object[] { "BBB", "BAB", "BBB", 'B', ModItems.ammo_44, 'A', ModItems.ingot_phosphorus });
|
||||
|
||||
@ -319,6 +319,8 @@ public class MainRegistry
|
||||
public static int fogRad = 100;
|
||||
public static int fogCh = 20;
|
||||
public static float hellRad = 0.1F;
|
||||
public static int worldRad = 10;
|
||||
public static int worldRadThreshold = 20;
|
||||
|
||||
public static int generalOverride = 0;
|
||||
public static int polaroidID = 1;
|
||||
@ -1532,6 +1534,8 @@ public class MainRegistry
|
||||
Property netherRad = config.get(CATEGORY_NUKE, "6.09_netherRad", 10);
|
||||
netherRad.comment = "RAD/s in the nether in hundredths";
|
||||
hellRad = netherRad.getInt() * 0.01F;
|
||||
worldRad = createConfigInt(config, CATEGORY_NUKE, "6.10_worldRadCount", "How many block operations radiation can perform per tick", 10);
|
||||
worldRadThreshold = createConfigInt(config, CATEGORY_NUKE, "6.11_worldRadThreshold", "The least amount of RADs required for block modification to happen", 20);
|
||||
|
||||
final String CATEGORY_MISSILE = "07_missile_machines";
|
||||
Property propRadarRange = config.get(CATEGORY_MISSILE, "7.00_radarRange", 1000);
|
||||
|
||||
@ -14,6 +14,7 @@ import com.hbm.entity.mob.EntityNuclearCreeper;
|
||||
import com.hbm.entity.projectile.EntityBurningFOEQ;
|
||||
import com.hbm.entity.projectile.EntityMeteor;
|
||||
import com.hbm.handler.ArmorUtil;
|
||||
import com.hbm.handler.RadiationWorldHandler;
|
||||
import com.hbm.handler.VersionChecker;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.armor.ArmorFSB;
|
||||
@ -28,6 +29,7 @@ import com.hbm.saveddata.RadiationSavedData;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.common.gameevent.PlayerEvent;
|
||||
import cpw.mods.fml.common.gameevent.TickEvent;
|
||||
import cpw.mods.fml.common.gameevent.TickEvent.Phase;
|
||||
import cpw.mods.fml.common.gameevent.TickEvent.WorldTickEvent;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.item.EntityItem;
|
||||
@ -217,7 +219,7 @@ public class ModEventHandler
|
||||
}
|
||||
}
|
||||
|
||||
if(event.world.getTotalWorldTime() % 20 == 0) {
|
||||
if(event.world.getTotalWorldTime() % 20 == 0 && event.phase == Phase.START) {
|
||||
data.updateSystem();
|
||||
}
|
||||
|
||||
@ -361,6 +363,9 @@ public class ModEventHandler
|
||||
}
|
||||
}
|
||||
/// RADIATION STUFF END ///
|
||||
|
||||
if(event.phase == Phase.START)
|
||||
RadiationWorldHandler.handleWorldDestruction(event.world);
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
|
||||
@ -68,8 +68,8 @@ public class RadiationSavedData extends WorldSavedData {
|
||||
float rad = struct.getValue();
|
||||
|
||||
//struct.radiation *= 0.999F;
|
||||
rad *= 0.99F;
|
||||
rad -= 0.5F;
|
||||
rad *= 0.999F;
|
||||
rad -= 0.05F;
|
||||
|
||||
if(rad <= 0) {
|
||||
rad = 0;
|
||||
|
||||