mirror of
https://github.com/HbmMods/Hbm-s-Nuclear-Tech-GIT.git
synced 2026-01-25 10:32:49 +00:00
Merge remote-tracking branch 'main/master' into Optimization
# Conflicts: # src/main/java/com/hbm/blocks/ModBlocks.java # src/main/java/com/hbm/handler/EntityEffectHandler.java # src/main/java/com/hbm/main/ClientProxy.java # src/main/java/com/hbm/main/CraftingManager.java # src/main/java/com/hbm/main/MainRegistry.java # src/main/java/com/hbm/main/ModEventHandlerClient.java # src/main/java/com/hbm/main/ModEventHandlerRenderer.java # src/main/java/com/hbm/main/ResourceManager.java # src/main/java/com/hbm/tileentity/turret/TileEntityTurretBaseNT.java # src/main/java/com/hbm/tileentity/turret/TileEntityTurretRichard.java # src/main/java/com/hbm/tileentity/turret/TileEntityTurretSentry.java # src/main/java/com/hbm/tileentity/turret/TileEntityTurretTauon.java # src/main/java/com/hbm/util/EntityDamageUtil.java
This commit is contained in:
commit
99705897ed
10
changelog
10
changelog
@ -54,6 +54,13 @@
|
||||
* Microwave explosions no longer destroy blocks, only the microwave and nearby players
|
||||
* Wings can now be used like armor mods
|
||||
* At higher pollution levels, skeletons can now spawn with guns
|
||||
* Logistic drones now move at 0.625 blocks/t instead of 0.6. There is no balancing reason for this, I just hate weird numbers like 0.6
|
||||
* Fallout effects now remove snow layers in the same area where they would remove things like small plants and leaves
|
||||
* Adjusted damage values to many swords and some tools
|
||||
* Unsats and aromatics can now be filled into gas canisters
|
||||
* Basalt asbestos ore no longer creates asbestos particles every block update, meaning volcanoes no longer cause massive delays with chunk rendering due to constant block changes
|
||||
* Rockets shot by the rocket turret are no longer subject to gravity and lock onto the intended target
|
||||
* Updated the anti-personell mine's model, it also now has 4 different textures which are automatically applied depending on whether the mine is placed underground or what biome it is in
|
||||
|
||||
## Fixed
|
||||
* The conveyor grabber should no longer skip over items when used in long lines
|
||||
@ -72,3 +79,6 @@
|
||||
* Fixed the wood burner destroying container items like buckets when using lava as fuel
|
||||
* Fixed pollution serialization for the fluid trait config being wrong
|
||||
* Fixed slag crashing the game when trying to flow into the void
|
||||
* Fixed issue where drones that are too fast may skip waypoints
|
||||
* Fixed the electrolyzer speed upgrades not increasing energy consumption as advertised
|
||||
* Fixed giblets rendering in fullbright even in the dark
|
||||
|
||||
@ -605,6 +605,7 @@ public class ModBlocks {
|
||||
public static Block sat_dock;
|
||||
|
||||
public static Block soyuz_capsule;
|
||||
public static Block crate_supply;
|
||||
|
||||
public static Block crate_iron;
|
||||
public static Block crate_steel;
|
||||
@ -2067,6 +2068,7 @@ public class ModBlocks {
|
||||
|
||||
sat_dock = new MachineSatDock(Material.iron).setBlockName("sat_dock").setHardness(5.0F).setResistance(10.0F).setCreativeTab(MainRegistry.missileTab).setBlockTextureName(RefStrings.MODID + ":sat_dock");
|
||||
soyuz_capsule = new SoyuzCapsule(Material.iron).setBlockName("soyuz_capsule").setHardness(5.0F).setResistance(10.0F).setCreativeTab(MainRegistry.missileTab).setBlockTextureName(RefStrings.MODID + ":soyuz_capsule");
|
||||
crate_supply = new BlockSupplyCrate(Material.wood).setBlockName("crate_supply").setStepSound(Block.soundTypeWood).setHardness(1.0F).setResistance(2.5F).setCreativeTab(MainRegistry.missileTab).setBlockTextureName(RefStrings.MODID + ":crate_can");
|
||||
|
||||
turret_chekhov = new TurretChekhov(Material.iron).setBlockName("turret_chekhov").setHardness(5.0F).setResistance(10.0F).setCreativeTab(MainRegistry.weaponTab).setBlockTextureName(RefStrings.MODID + ":block_steel");
|
||||
turret_friendly = new TurretFriendly(Material.iron).setBlockName("turret_friendly").setHardness(5.0F).setResistance(10.0F).setCreativeTab(MainRegistry.weaponTab).setBlockTextureName(RefStrings.MODID + ":block_steel");
|
||||
@ -2852,8 +2854,8 @@ public class ModBlocks {
|
||||
|
||||
//Mines
|
||||
GameRegistry.registerBlock(mine_ap, mine_ap.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(mine_he, mine_he.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(mine_shrap, mine_shrap.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(mine_he, mine_he.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(mine_fat, mine_fat.getUnlocalizedName());
|
||||
|
||||
//Block Bombs
|
||||
@ -3343,6 +3345,7 @@ public class ModBlocks {
|
||||
GameRegistry.registerBlock(soyuz_launcher, soyuz_launcher.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(sat_dock, sat_dock.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(soyuz_capsule, soyuz_capsule.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(crate_supply, crate_supply.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(machine_radar, machine_radar.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(machine_radar_large, machine_radar_large.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(radar_screen, radar_screen.getUnlocalizedName());
|
||||
|
||||
@ -37,7 +37,6 @@ public class Landmine extends BlockContainer implements IBomb {
|
||||
|
||||
public Landmine(Material mat, double range, double height) {
|
||||
super(mat);
|
||||
|
||||
this.range = range;
|
||||
this.height = height;
|
||||
}
|
||||
@ -47,20 +46,9 @@ public class Landmine extends BlockContainer implements IBomb {
|
||||
return new TileEntityLandmine();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getRenderType() {
|
||||
return -1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isOpaqueCube() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean renderAsNormalBlock() {
|
||||
return false;
|
||||
}
|
||||
@Override public int getRenderType() { return -1; }
|
||||
@Override public boolean isOpaqueCube() { return false; }
|
||||
@Override public boolean renderAsNormalBlock() { return false; }
|
||||
|
||||
@Override
|
||||
public Item getItemDropped(int i, Random rand, int j) {
|
||||
@ -70,14 +58,10 @@ public class Landmine extends BlockContainer implements IBomb {
|
||||
@Override
|
||||
public void setBlockBoundsBasedOnState(IBlockAccess world, int x, int y, int z) {
|
||||
float f = 0.0625F;
|
||||
if(this == ModBlocks.mine_ap)
|
||||
this.setBlockBounds(6 * f, 0.0F, 6 * f, 10 * f, 2 * f, 10 * f);
|
||||
if(this == ModBlocks.mine_he)
|
||||
this.setBlockBounds(4 * f, 0.0F, 4 * f, 12 * f, 2 * f, 12 * f);
|
||||
if(this == ModBlocks.mine_shrap)
|
||||
this.setBlockBounds(4 * f, 0.0F, 4 * f, 12 * f, 2 * f, 12 * f);
|
||||
if(this == ModBlocks.mine_fat)
|
||||
this.setBlockBounds(5 * f, 0.0F, 4 * f, 11 * f, 6 * f, 12 * f);
|
||||
if(this == ModBlocks.mine_ap) this.setBlockBounds(5 * f, 0.0F, 5 * f, 11 * f, 1 * f, 11 * f);
|
||||
if(this == ModBlocks.mine_he) this.setBlockBounds(4 * f, 0.0F, 4 * f, 12 * f, 2 * f, 12 * f);
|
||||
if(this == ModBlocks.mine_shrap) this.setBlockBounds(5 * f, 0.0F, 5 * f, 11 * f, 1 * f, 11 * f);
|
||||
if(this == ModBlocks.mine_fat) this.setBlockBounds(5 * f, 0.0F, 4 * f, 11 * f, 6 * f, 12 * f);
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -154,7 +138,7 @@ public class Landmine extends BlockContainer implements IBomb {
|
||||
|
||||
if(this == ModBlocks.mine_ap) {
|
||||
ExplosionVNT vnt = new ExplosionVNT(world, x + 0.5, y + 0.5, z + 0.5, 3F);
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(0.5, 10F));
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(0.5, 10F).setupPiercing(5F, 0.2F));
|
||||
vnt.setPlayerProcessor(new PlayerProcessorStandard());
|
||||
vnt.setSFX(new ExplosionEffectWeapon(5, 1F, 0.5F));
|
||||
vnt.explode();
|
||||
@ -162,7 +146,7 @@ public class Landmine extends BlockContainer implements IBomb {
|
||||
ExplosionVNT vnt = new ExplosionVNT(world, x + 0.5, y + 0.5, z + 0.5, 4F);
|
||||
vnt.setBlockAllocator(new BlockAllocatorStandard());
|
||||
vnt.setBlockProcessor(new BlockProcessorStandard());
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(1, 35));
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(1, 35).setupPiercing(15F, 0.2F));
|
||||
vnt.setPlayerProcessor(new PlayerProcessorStandard());
|
||||
vnt.setSFX(new ExplosionEffectWeapon(15, 3.5F, 1.25F));
|
||||
vnt.explode();
|
||||
@ -182,5 +166,4 @@ public class Landmine extends BlockContainer implements IBomb {
|
||||
|
||||
return BombReturnCode.DETONATED;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -52,18 +52,6 @@ public class BlockCrate extends BlockFalling {
|
||||
// Supply Crate
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.syringe_metal_stimpak, 10);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.syringe_antidote, 5);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_revolver_iron, 9);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_revolver, 7);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_revolver_gold, 4);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_revolver_lead, 6);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_revolver_cursed, 5);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_rpg, 5);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_fatman, 1);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_mp40, 7);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_uzi, 7);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_uboinik, 7);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_lever_action, 5);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.clip_bolt_action, 5);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.grenade_generic, 8);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.grenade_strong, 6);
|
||||
BlockCrate.addToListWithWeight(crateList, ModItems.grenade_mk2, 4);
|
||||
|
||||
@ -19,7 +19,6 @@ import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
public class BlockOreBasalt extends BlockEnumMulti {
|
||||
|
||||
@ -65,14 +64,7 @@ public class BlockOreBasalt extends BlockEnumMulti {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onNeighborBlockChange(World world, int x, int y, int z, Block block) {
|
||||
int meta = world.getBlockMetadata(x, y, z);
|
||||
if(meta == EnumBasaltOreType.ASBESTOS.ordinal()) for(ForgeDirection dir : ForgeDirection.VALID_DIRECTIONS) {
|
||||
if(world.getBlock(x + dir.offsetX, y + dir.offsetY, z + dir.offsetZ) == Blocks.air) {
|
||||
world.setBlock(x + dir.offsetX, y + dir.offsetY, z + dir.offsetZ, ModBlocks.gas_asbestos);
|
||||
}
|
||||
}
|
||||
}
|
||||
public void onNeighborBlockChange(World world, int x, int y, int z, Block block) { } //no more BUD outgassing for you, mister
|
||||
|
||||
@Override
|
||||
public void dropBlockAsItemWithChance(World world, int x, int y, int z, int meta, float chance, int fortune) {
|
||||
|
||||
130
src/main/java/com/hbm/blocks/generic/BlockSupplyCrate.java
Normal file
130
src/main/java/com/hbm/blocks/generic/BlockSupplyCrate.java
Normal file
@ -0,0 +1,130 @@
|
||||
package com.hbm.blocks.generic;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.hbm.items.ModItems;
|
||||
|
||||
import net.minecraft.block.BlockContainer;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.item.EntityItem;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class BlockSupplyCrate extends BlockContainer {
|
||||
|
||||
public BlockSupplyCrate(Material mat) {
|
||||
super(mat);
|
||||
}
|
||||
|
||||
@Override
|
||||
public TileEntity createNewTileEntity(World world, int meta) {
|
||||
return new TileEntitySupplyCrate();
|
||||
}
|
||||
|
||||
@Override public int getRenderType() { return BlockCanCrate.renderID; }
|
||||
@Override public boolean isOpaqueCube() { return false; }
|
||||
@Override public boolean renderAsNormalBlock() { return false; }
|
||||
|
||||
@Override public Item getItemDropped(int i, Random rand, int j) { return null; }
|
||||
|
||||
@Override
|
||||
public boolean removedByPlayer(World world, EntityPlayer player, int x, int y, int z, boolean willHarvest) {
|
||||
|
||||
if(!player.capabilities.isCreativeMode && !world.isRemote && willHarvest) {
|
||||
|
||||
ItemStack drop = new ItemStack(this);
|
||||
TileEntitySupplyCrate inv = (TileEntitySupplyCrate) world.getTileEntity(x, y, z);
|
||||
NBTTagCompound nbt = new NBTTagCompound();
|
||||
|
||||
if(inv != null) {
|
||||
for(int i = 0; i < inv.items.size(); i++) {
|
||||
ItemStack stack = inv.items.get(i);
|
||||
if(stack == null) continue;
|
||||
NBTTagCompound slot = new NBTTagCompound();
|
||||
stack.writeToNBT(slot);
|
||||
nbt.setTag("slot" + i, slot);
|
||||
}
|
||||
nbt.setInteger("amount", inv.items.size());
|
||||
}
|
||||
|
||||
if(!nbt.hasNoTags()) drop.stackTagCompound = nbt;
|
||||
world.spawnEntityInWorld(new EntityItem(world, x + 0.5, y + 0.5, z + 0.5, drop));
|
||||
}
|
||||
return world.setBlockToAir(x, y, z);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBlockPlacedBy(World world, int x, int y, int z, EntityLivingBase player, ItemStack stack) {
|
||||
|
||||
TileEntitySupplyCrate inv = (TileEntitySupplyCrate) world.getTileEntity(x, y, z);
|
||||
|
||||
if(inv != null && stack.hasTagCompound()) {
|
||||
int amount = stack.stackTagCompound.getInteger("amount");
|
||||
for(int i = 0; i < amount; i++) {
|
||||
inv.items.add(ItemStack.loadItemStackFromNBT(stack.stackTagCompound.getCompoundTag("slot" + i)));
|
||||
}
|
||||
}
|
||||
|
||||
super.onBlockPlacedBy(world, x, y, z, player, stack);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int p_149727_6_, float p_149727_7_, float p_149727_8_, float p_149727_9_) {
|
||||
if(player.getHeldItem() != null && player.getHeldItem().getItem().equals(ModItems.crowbar)) {
|
||||
if(!world.isRemote) {
|
||||
dropContents(world, x, y, z);
|
||||
world.func_147480_a(x, y, z, false);
|
||||
world.playSoundEffect(x, y, z, "hbm:block.crateBreak", 0.5F, 1.0F);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
public void dropContents(World world, int x, int y, int z) {
|
||||
TileEntity tile = world.getTileEntity(x, y, z);
|
||||
if(tile instanceof TileEntitySupplyCrate) {
|
||||
TileEntitySupplyCrate crate = (TileEntitySupplyCrate) tile;
|
||||
|
||||
for(ItemStack item : crate.items) {
|
||||
this.dropBlockAsItem(world, x, y, z, item);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static class TileEntitySupplyCrate extends TileEntity {
|
||||
|
||||
public List<ItemStack> items = new ArrayList();
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound nbt) {
|
||||
super.readFromNBT(nbt);
|
||||
items.clear();
|
||||
NBTTagList list = nbt.getTagList("items", 10);
|
||||
for(int i = 0; i < list.tagCount(); i++) {
|
||||
NBTTagCompound nbt1 = list.getCompoundTagAt(i);
|
||||
items.add(ItemStack.loadItemStackFromNBT(nbt1));
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeToNBT(NBTTagCompound nbt) {
|
||||
super.writeToNBT(nbt);
|
||||
NBTTagList list = new NBTTagList();
|
||||
for(int i = 0; i < items.size(); i++) {
|
||||
NBTTagCompound nbt1 = new NBTTagCompound();
|
||||
items.get(i).writeToNBT(nbt1);
|
||||
list.appendTag(nbt1);
|
||||
}
|
||||
nbt.setTag("items", list);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,16 +1,15 @@
|
||||
package com.hbm.blocks.machine;
|
||||
|
||||
import com.hbm.main.MainRegistry;
|
||||
import com.hbm.blocks.BlockDummyable;
|
||||
import com.hbm.tileentity.TileEntityProxyCombo;
|
||||
import com.hbm.tileentity.machine.TileEntityMachineAmmoPress;
|
||||
|
||||
import cpw.mods.fml.common.network.internal.FMLNetworkHandler;
|
||||
import net.minecraft.block.BlockContainer;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class MachineAmmoPress extends BlockContainer {
|
||||
public class MachineAmmoPress extends BlockDummyable {
|
||||
|
||||
public MachineAmmoPress() {
|
||||
super(Material.iron);
|
||||
@ -18,19 +17,14 @@ public class MachineAmmoPress extends BlockContainer {
|
||||
|
||||
@Override
|
||||
public TileEntity createNewTileEntity(World world, int meta) {
|
||||
return new TileEntityMachineAmmoPress();
|
||||
return meta >= 12 ? new TileEntityMachineAmmoPress() : new TileEntityProxyCombo().inventory();
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int side, float hitX, float hitY, float hitZ) {
|
||||
|
||||
if(world.isRemote) {
|
||||
return true;
|
||||
} else if(!player.isSneaking()) {
|
||||
FMLNetworkHandler.openGui(player, MainRegistry.instance, 0, world, x, y, z);
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
return this.standardOpenBehavior(world, x, y, z, player, 0);
|
||||
}
|
||||
|
||||
@Override public int[] getDimensions() { return new int[] {1, 0, 0, 0, 1, 1}; }
|
||||
@Override public int getOffset() { return 0; }
|
||||
}
|
||||
|
||||
@ -3,6 +3,7 @@ package com.hbm.commands;
|
||||
import com.hbm.config.ItemPoolConfigJSON;
|
||||
import com.hbm.inventory.recipes.loader.SerializableRecipe;
|
||||
import com.hbm.util.ChatBuilder;
|
||||
import com.hbm.util.DamageResistanceHandler;
|
||||
|
||||
import net.minecraft.command.CommandBase;
|
||||
import net.minecraft.command.ICommandSender;
|
||||
@ -26,6 +27,7 @@ public class CommandReloadRecipes extends CommandBase {
|
||||
try {
|
||||
SerializableRecipe.initialize();
|
||||
ItemPoolConfigJSON.initialize();
|
||||
DamageResistanceHandler.init();
|
||||
sender.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW + "Reload complete :)"));
|
||||
} catch(Exception ex) {
|
||||
sender.addChatMessage(ChatBuilder.start("----------------------------------").color(EnumChatFormatting.GRAY).flush());
|
||||
|
||||
@ -62,6 +62,7 @@ public class FalloutConfigJSON {
|
||||
entries.add(new FalloutEntry() .mB(Blocks.brown_mushroom_block).mM(10) .prim(new Triplet(ModBlocks.waste_log, 0, 1)) .max(woodEffectRange));
|
||||
entries.add(new FalloutEntry() .mB(Blocks.red_mushroom_block) .prim(new Triplet(Blocks.air, 0, 1)) .max(woodEffectRange));
|
||||
entries.add(new FalloutEntry() .mB(Blocks.brown_mushroom_block) .prim(new Triplet(Blocks.air, 0, 1)) .max(woodEffectRange));
|
||||
entries.add(new FalloutEntry() .mB(Blocks.snow_layer) .prim(new Triplet(Blocks.air, 0, 1)) .max(woodEffectRange));
|
||||
entries.add(new FalloutEntry() .mB(Blocks.planks) .prim(new Triplet(ModBlocks.waste_planks, 0, 1)) .max(woodEffectRange));
|
||||
/* if it can't be petrified, destroy it */
|
||||
entries.add(new FalloutEntry() .mMa(Material.wood) .prim(new Triplet(Blocks.air, 0, 1)) .max(woodEffectRange));
|
||||
|
||||
@ -33,6 +33,14 @@ public class WeaponRecipes {
|
||||
//SEDNA Parts
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.part_stock, 1, Mats.MAT_WOOD.id), new Object[] { "WWW", " W", 'W', KEY_PLANKS });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.part_grip, 1, Mats.MAT_WOOD.id), new Object[] { "W ", " W", " W", 'W', KEY_PLANKS });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.part_stock, 1, Mats.MAT_POLYMER.id), new Object[] { "WWW", " W", 'W', POLYMER.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.part_grip, 1, Mats.MAT_POLYMER.id), new Object[] { "W ", " W", " W", 'W', POLYMER.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.part_stock, 1, Mats.MAT_BAKELITE.id), new Object[] { "WWW", " W", 'W', BAKELITE.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.part_grip, 1, Mats.MAT_BAKELITE.id), new Object[] { "W ", " W", " W", 'W', BAKELITE.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.part_stock, 1, Mats.MAT_HARDPLASTIC.id), new Object[] { "WWW", " W", 'W', PC.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.part_grip, 1, Mats.MAT_HARDPLASTIC.id), new Object[] { "W ", " W", " W", 'W', PC.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.part_stock, 1, Mats.MAT_PVC.id), new Object[] { "WWW", " W", 'W', PVC.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.part_grip, 1, Mats.MAT_PVC.id), new Object[] { "W ", " W", " W", 'W', PVC.ingot() });
|
||||
|
||||
CraftingManager.addRecipeAuto(DictFrame.fromOne(ModItems.casing, EnumCasingType.SHOTSHELL, 2), new Object[] { "P", "C", 'P', GUNMETAL.plate(), 'C', DictFrame.fromOne(ModItems.casing, EnumCasingType.LARGE) });
|
||||
CraftingManager.addRecipeAuto(DictFrame.fromOne(ModItems.casing, EnumCasingType.BUCKSHOT, 2), new Object[] { "P", "C", 'P', ANY_PLASTIC.ingot(), 'C', DictFrame.fromOne(ModItems.casing, EnumCasingType.LARGE) });
|
||||
@ -41,16 +49,37 @@ public class WeaponRecipes {
|
||||
//SEDNA Guns
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_pepperbox, 1), new Object[] { "IIW", " C", 'I', IRON.ingot(), 'W', KEY_PLANKS, 'C', CU.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_light_revolver, 1), new Object[] { "BRM", " G", 'B', STEEL.lightBarrel(), 'R', STEEL.lightReceiver(), 'M', GUNMETAL.mechanism(), 'G', WOOD.grip() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_light_revolver_atlas, 1), new Object[] { " M ", "MAM", " M ", 'M', WEAPONSTEEL.mechanism(), 'A', ModItems.gun_light_revolver });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_henry, 1), new Object[] { "BRP", "BMS", 'B', STEEL.lightBarrel(), 'R', GUNMETAL.lightReceiver(), 'M', GUNMETAL.mechanism(), 'S', WOOD.stock(), 'P', GUNMETAL.plate() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_greasegun, 1), new Object[] { "BRS", "SMG", 'B', STEEL.lightBarrel(), 'R', STEEL.lightReceiver(), 'S', STEEL.bolt(), 'M', GUNMETAL.mechanism(), 'G', STEEL.grip() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_maresleg, 1), new Object[] { "BRM", "BGS", 'B', STEEL.lightBarrel(), 'R', STEEL.lightReceiver(), 'M', GUNMETAL.mechanism(), 'G', STEEL.bolt(), 'S', WOOD.stock() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_maresleg_akimbo, 1), new Object[] { "SMS", 'S', ModItems.gun_maresleg, 'M', WEAPONSTEEL.mechanism() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_flaregun, 1), new Object[] { "BRM", " G", 'B', STEEL.heavyBarrel(), 'R', STEEL.lightReceiver(), 'M', GUNMETAL.mechanism(), 'G', STEEL.grip() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_heavy_revolver, 1), new Object[] { "BRM", " G", 'B', DURA.lightBarrel(), 'R', DURA.lightReceiver(), 'M', GUNMETAL.mechanism(), 'G', WOOD.grip() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_carbine, 1), new Object[] { "BRM", "G S", 'B', DURA.lightBarrel(), 'R', DURA.lightReceiver(), 'M', GUNMETAL.mechanism(), 'G', WOOD.grip(), 'S', WOOD.stock() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_am180, 1), new Object[] { "BBR", "GMS", 'B', DURA.lightBarrel(), 'R', DURA.lightReceiver(), 'M', GUNMETAL.mechanism(), 'G', WOOD.grip(), 'S', WOOD.stock() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_liberator, 1), new Object[] { "BB ", "BBM", "G G", 'B', DURA.lightBarrel(), 'M', GUNMETAL.mechanism(), 'G', WOOD.grip() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_congolake, 1), new Object[] { "BM ", "BRS", "G ", 'B', DURA.heavyBarrel(), 'M', GUNMETAL.mechanism(), 'R', DURA.lightReceiver(), 'S', WOOD.stock(), 'G', WOOD.grip() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_flamer, 1), new Object[] { " MG", "BBR", " GM", 'M', GUNMETAL.mechanism(), 'G', DURA.grip(), 'B', DURA.heavyBarrel(), 'R', DURA.heavyReceiver() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_flamer_topaz, 1), new Object[] { " M ", "MFM", " M ", 'M', WEAPONSTEEL.mechanism(), 'F', ModItems.gun_flamer });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_heavy_revolver, 1), new Object[] { "BRM", " G", 'B', DESH.lightBarrel(), 'R', DESH.lightReceiver(), 'M', GUNMETAL.mechanism(), 'G', WOOD.grip() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_carbine, 1), new Object[] { "BRM", "G S", 'B', DESH.lightBarrel(), 'R',DESH.lightReceiver(), 'M', GUNMETAL.mechanism(), 'G', WOOD.grip(), 'S', WOOD.stock() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_uzi, 1), new Object[] { "BRS", " GM", 'B', DESH.lightBarrel(), 'R', DESH.lightReceiver(), 'S', ANY_PLASTIC.stock(), 'G', ANY_PLASTIC.grip(), 'M', GUNMETAL.mechanism() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_uzi_akimbo, 1), new Object[] { "UMU", 'U', ModItems.gun_uzi, 'M', WEAPONSTEEL.mechanism() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_spas12, 1), new Object[] { "BRM", "BGS", 'B', DESH.lightBarrel(), 'R', DESH.lightReceiver(), 'M', GUNMETAL.mechanism(), 'G', ANY_PLASTIC.grip(), 'S', DESH.stock() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_panzerschreck, 1), new Object[] { "BBB", "PGM", 'B', DESH.heavyBarrel(), 'P', STEEL.plateCast(), 'G', DESH.grip(), 'M', GUNMETAL.mechanism() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_g3, 1), new Object[] { "BRM", "WGS", 'B', WEAPONSTEEL.lightBarrel(), 'R', WEAPONSTEEL.lightReceiver(), 'M', WEAPONSTEEL.mechanism(), 'W', WOOD.grip(), 'G', RUBBER.grip(), 'S', WOOD.stock() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_stinger, 1), new Object[] { "BBB", "PGM", 'B', WEAPONSTEEL.heavyBarrel(), 'P', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.ADVANCED), 'G', WEAPONSTEEL.grip(), 'M', WEAPONSTEEL.mechanism() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_chemthrower, 1), new Object[] { "MHW", "PSS", 'M', WEAPONSTEEL.mechanism(), 'H', RUBBER.pipe(), 'W', ModItems.wrench, 'P', WEAPONSTEEL.heavyBarrel(), 'S', WEAPONSTEEL.shell() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_m2, 1), new Object[] { " G", "BRM", " G", 'G', WOOD.grip(), 'B', FERRO.heavyBarrel(), 'R', FERRO.heavyReceiver(), 'M', WEAPONSTEEL.mechanism() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_autoshotgun, 1), new Object[] { "BRM", "G G", 'B', FERRO.heavyBarrel(), 'R', FERRO.heavyReceiver(), 'M', WEAPONSTEEL.mechanism(), 'G', ANY_PLASTIC.grip() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_quadro, 1), new Object[] { "BCB", "BMB", "GG ", 'B', FERRO.heavyBarrel(), 'C', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.ADVANCED), 'M', WEAPONSTEEL.mechanism(), 'G', ANY_PLASTIC.grip() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_lag, 1), new Object[] { "BRM", " G", 'B', ANY_RESISTANTALLOY.lightBarrel(), 'R', ANY_RESISTANTALLOY.lightReceiver(), 'M', WEAPONSTEEL.mechanism(), 'G', ANY_PLASTIC.grip() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_minigun, 1), new Object[] { "BMG", "BRE", "BGM", 'B', ANY_RESISTANTALLOY.lightBarrel(), 'M', WEAPONSTEEL.mechanism(), 'G', ANY_PLASTIC.grip(), 'R', ANY_RESISTANTALLOY.heavyReceiver(), 'E', ModItems.motor_desh });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_missile_launcher, 1), new Object[] { " CM", "BBB", "G ", 'C', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.ADVANCED), 'M', WEAPONSTEEL.mechanism(), 'B', ANY_RESISTANTALLOY.heavyBarrel(), 'G', ANY_PLASTIC.grip() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_tesla_cannon, 1), new Object[] { "CCC", "BRB", "MGE", 'C', ModItems.coil_advanced_alloy, 'B', ANY_RESISTANTALLOY.heavyBarrel(), 'R', ANY_RESISTANTALLOY.heavyReceiver(), 'M', WEAPONSTEEL.mechanism(), 'G', ANY_PLASTIC.grip(), 'E', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.ADVANCED) });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_stg77, 1), new Object[] { " D ", "BRS", "GM ", 'D', DIAMOND.gem(), 'B', BIGMT.lightBarrel(), 'R', BIGMT.lightReceiver(), 'S', ANY_HARDPLASTIC.stock(), 'G', ANY_HARDPLASTIC.grip(), 'M', BIGMT.mechanism() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_fatman, 1), new Object[] { "PPP", "BSR", "G M", 'P', BIGMT.plate(), 'B', BIGMT.heavyBarrel(), 'S', BIGMT.shell(), 'R', BIGMT.heavyReceiver(), 'G', ANY_HARDPLASTIC.grip(), 'M', BIGMT.mechanism() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_tau, 1), new Object[] { " RD", "CTT", "GMS", 'D', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.BISMOID), 'C', CU.pipe(), 'T', ModItems.coil_advanced_torus, 'G', ANY_HARDPLASTIC.grip(), 'R', BIGMT.lightReceiver(), 'M', BIGMT.mechanism(), 'S', ANY_HARDPLASTIC.stock() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_lasrifle, 1), new Object[] { "LC ", "BRS", "MG ", 'L', ModItems.crystal_redstone, 'C', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.BISMOID), 'B', ANY_BISMOIDBRONZE.lightBarrel(), 'R', ANY_BISMOIDBRONZE.lightReceiver(), 'S', ANY_HARDPLASTIC.stock(), 'M', BIGMT.mechanism(), 'G', ANY_HARDPLASTIC.grip() });
|
||||
|
||||
//SEDNA Ammo
|
||||
CraftingManager.addRecipeAuto(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.STONE, 6), new Object[] { "C", "P", "G", 'C', KEY_COBBLESTONE, 'P', Items.paper, 'G', Items.gunpowder });
|
||||
@ -101,87 +130,10 @@ public class WeaponRecipes {
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModBlocks.turret_sentry, 1), new Object[] { "PPL", " MD", " SC", 'P', STEEL.plate(), 'M', ModItems.motor, 'L', ModItems.mechanism_rifle_1, 'S', ModBlocks.steel_scaffold, 'C', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.BASIC), 'D', ModItems.crt_display });
|
||||
|
||||
//Guns
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_rpg, 1), new Object[] { "SSW", " MW", 'S', STEEL.shell(), 'W', IRON.plate(), 'M', ModItems.mechanism_launcher_1 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_karl, 1), new Object[] { "SSW", " MW", 'S', STEEL.shell(), 'W', ALLOY.plate(), 'M', ModItems.mechanism_launcher_2 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_hk69, 1), new Object[] { "SSI", " MB", 'S', STEEL.shell(), 'I', IRON.ingot(), 'M', ModItems.mechanism_launcher_1, 'B', STEEL.bolt() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver, 1), new Object[] { "SSM", " RW", 'S', STEEL.plate(), 'W', KEY_PLANKS, 'R', AL.wireFine(), 'M', ModItems.mechanism_revolver_1 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver_saturnite, 1), new Object[] { "SSM", " RW", 'S', BIGMT.plate(), 'W', KEY_PLANKS, 'R', W.wireFine(), 'M', ModItems.mechanism_revolver_2 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver_gold, 1), new Object[] { "SSM", " RW", 'S', GOLD.plate(), 'W', W.ingot(), 'R', GOLD.wireFine(), 'M', ModItems.mechanism_revolver_1 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver_schrabidium, 1), new Object[] { "SSM", " RW", 'S', SA326.block(), 'W', W.ingot(), 'R', SA326.wireFine(), 'M', ModItems.mechanism_special });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver_pip, 1), new Object[] { " G ", "SSP", " TI", 'G', KEY_ANYPANE, 'S', STEEL.plate(), 'P', ModItems.mechanism_revolver_2, 'T', W.wireFine(), 'I', ANY_PLASTIC.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver_nopip, 1), new Object[] { "SSP", " TI", 'S', STEEL.plate(), 'P', ModItems.mechanism_revolver_2, 'T', W.wireFine(), 'I', ANY_PLASTIC.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver_blackjack, 1), new Object[] { "SSP", " TI", 'S', STEEL.plate(), 'P', ModItems.mechanism_revolver_2, 'T', W.wireFine(), 'I', KEY_PLANKS });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver_silver, 1), new Object[] { "SSP", " TI", 'S', AL.plate(), 'P', ModItems.mechanism_revolver_2, 'T', W.wireFine(), 'I', KEY_PLANKS });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver_red, 1), new Object[] { "R ", " B", 'R', ModItems.key_red, 'B', ModItems.gun_revolver_blackjack });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_deagle, 1), new Object[] { "PPM", " BI", 'P', STEEL.plate(), 'B', STEEL.bolt(), 'I', ANY_PLASTIC.ingot(), 'M', ModItems.mechanism_rifle_1 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_uac_pistol, 1), new Object[] { "IIM", " BI", 'B', DURA.bolt(), 'I', ANY_PLASTIC.ingot(), 'M', ModItems.mechanism_rifle_1 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver_cursed, 1), new Object[] { "TTM", "SRI", 'S', STEEL.plate(), 'I', STEEL.ingot(), 'R', MINGRADE.wireFine(), 'T', TI.plate(), 'M', ModItems.mechanism_revolver_2 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver_nightmare, 1), new Object[] { "SEM", " RW", 'S', STEEL.plate(), 'W', KEY_PLANKS, 'R', AL.wireFine(), 'E', ModItems.powder_power, 'M', ModItems.mechanism_revolver_2 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_revolver_nightmare2, 1), new Object[] { "SSM", "RRW", 'S', OreDictManager.getReflector(), 'W', W.ingot(), 'R', GOLD.wireFine(), 'M', ModItems.mechanism_special });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_bio_revolver, 1), new Object[] { "SSM", "BTW", 'S', STEEL.plate(), 'M', ModItems.mechanism_revolver_2, 'B', B.ingot(), 'T', W.bolt(), 'W', KEY_LOG });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_chemthrower, 1), new Object[] { "RWC", "HHT", "RLC", 'R', RUBBER.ingot(), 'W', ModItems.wrench, 'C', CU.plate(), 'H', STEEL.shell(), 'T', ModItems.tank_steel, 'L', ModItems.mechanism_launcher_2 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_mirv, 1), new Object[] { "LLL", "WFW", "SSS", 'S', STEEL.plate(), 'L', PB.plate(), 'W', GOLD.wireFine(), 'F', ModItems.gun_fatman });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_proto, 1), new Object[] { "LLL", "WFW", "SSS", 'S', ANY_RUBBER.ingot(), 'L', ModItems.plate_desh, 'W', W.wireFine(), 'F', ModItems.gun_fatman });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.ammo_nuke, 1, AmmoFatman.BALEFIRE.ordinal()), new Object[] { " S ", "EBE", " S ", 'S', STEEL.shell(), 'E', ModItems.powder_power, 'B', ModItems.egg_balefire_shard });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_mp40, 1), new Object[] { "IIM", " SW", " S ", 'S', STEEL.plate(), 'I', STEEL.ingot(), 'W', KEY_PLANKS, 'M', ModItems.mechanism_rifle_1 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_thompson, 1), new Object[] { "IIM", " SW", " S ", 'S', IRON.plate(), 'I', STEEL.plate(), 'W', KEY_PLANKS, 'M', ModItems.mechanism_rifle_2 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_flechette, 1), new Object[] { "PPM", "TIS", "G ", 'P', STEEL.plate(), 'M', ModItems.mechanism_rifle_2, 'T', STEEL.shell(), 'I', STEEL.ingot(), 'S', ANY_PLASTIC.ingot(), 'G', ModItems.mechanism_launcher_1 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_uboinik, 1), new Object[] { "IIM", "SPW", 'P', STEEL.plate(), 'I', STEEL.ingot(), 'W', KEY_PLANKS, 'S', KEY_STICK, 'M', ModItems.mechanism_revolver_2 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_supershotgun, 1), new Object[] { "BBM", "BBM", "AWL", 'B', STEEL.pipe(), 'M', ModItems.mechanism_rifle_2, 'A', ModItems.plate_dalekanium, 'W', GOLD.wireFine(), 'L', KEY_LOG });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_ks23, 1), new Object[] { "PPM", "SWL", 'P', STEEL.plate(), 'M', ModItems.mechanism_rifle_1, 'S', KEY_STICK, 'W', W.wireFine(), 'L', KEY_LOG });
|
||||
CraftingManager.addShapelessAuto(new ItemStack(ModItems.gun_sauer, 1), new Object[] { ModItems.ducttape, ModItems.gun_ks23, Blocks.lever, ModItems.gun_ks23 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_xvl1456, 1), new Object[] { "PBB", "ACC", "PRY", 'P', STEEL.plate(), 'R', ModItems.redcoil_capacitor, 'A', ModItems.coil_advanced_alloy, 'B', ModItems.battery_generic, 'C', ModItems.coil_advanced_torus, 'Y', ModItems.mechanism_special });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_xvl1456_ammo, 16), new Object[] { " S ", "SRS", " S ", 'S', STEEL.plate(), 'R', ModItems.waste_natural_uranium });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_xvl1456_ammo, 16), new Object[] { " S ", "SRS", " S ", 'S', STEEL.plate(), 'R', ModItems.waste_uranium });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_xvl1456_ammo, 20), new Object[] { " S ", " R ", " S ", 'S', STEEL.plate(), 'R', ModItems.waste_plate_u235 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_xvl1456_ammo, 16), new Object[] { "SRS", 'S', STEEL.plate(), 'R', ModItems.waste_u235 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_xvl1456_ammo, 16), new Object[] { " S ", " R ", " S ", 'S', STEEL.plate(), 'R', U238.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_xvl1456_ammo, 16), new Object[] { "SRS", 'S', STEEL.plate(), 'R', U238.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_osipr, 1), new Object[] { "CCT", "WWI", "MCC", 'C', CMB.plate(), 'T', W.ingot(), 'W', MAGTUNG.wireFine(), 'I', ModItems.mechanism_rifle_2, 'M', ModItems.coil_magnetized_tungsten });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_immolator, 1), new Object[] { "WCC", "PMT", "WAA", 'W', GOLD.wireFine(), 'C', CU.plate(), 'P', ALLOY.plate(), 'M', ModItems.mechanism_launcher_1, 'T', ModItems.tank_steel, 'A', STEEL.plate() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_immolator_ammo, 16), new Object[] { "SPS", "PCP", "SPS", 'S', STEEL.plate(), 'C', COAL.dust(), 'P', P_RED.dust() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_immolator_ammo, 16), new Object[] { " F ", "SFS", " F ", 'S', STEEL.plate(), 'F', Fluids.DIESEL.getDict(1000) });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_immolator_ammo, 24), new Object[] { " F ", "SFS", " F ", 'S', STEEL.plate(), 'F', ModItems.canister_napalm });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_cryolator, 1), new Object[] { "SSS", "IWL", "LMI", 'S', STEEL.plate(), 'I', IRON.plate(), 'L', Items.leather, 'M', ModItems.mechanism_launcher_1, 'W', AL.wireFine() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_cryolator_ammo, 16), new Object[] { "SPS", "PCP", "SPS", 'S', STEEL.plate(), 'C', KNO.dust(), 'P', Items.snowball });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_cryolator_ammo, 16), new Object[] { " F ", "SFS", " F ", 'S', STEEL.plate(), 'F', ModItems.powder_ice });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_mp, 1), new Object[] { "EEE", "SSM", "III", 'E', EUPH.ingot(), 'S', STEEL.plate(), 'I', STEEL.ingot(), 'M', ModItems.mechanism_rifle_2 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_emp, 1), new Object[] { "CPG", "CMF", "CPI", 'C', ModItems.coil_copper, 'P', PB.plate(), 'G', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.ADVANCED), 'M', ModItems.magnetron, 'I', W.ingot(), 'F', ModItems.mechanism_special });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_emp_ammo, 8), new Object[] { "IGI", "IPI", "IPI", 'G', GOLD.plate(), 'I', IRON.plate(), 'P', ModItems.powder_power });
|
||||
//CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_jack, 1), new Object[] { "WW ", "TSD", " TT", 'W', "ingotWeidanium", 'T', ModItems.toothpicks, 'S', ModItems.gun_uboinik, 'D', ModItems.ducttape });
|
||||
CraftingManager.addShapelessAuto(new ItemStack(ModItems.gun_jack_ammo, 1), new Object[] { ModItems.ammo_12gauge, ModItems.ammo_12gauge, ModItems.ammo_12gauge, ModItems.ammo_12gauge });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_euthanasia, 1), new Object[] { "TDT", "AAS", " T ", 'A', AUSTRALIUM.ingot(), 'T', ModItems.toothpicks, 'S', ModItems.gun_mp40, 'D', ModItems.ducttape });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_euthanasia_ammo, 12), new Object[] { "P", "S", "N", 'P', ModItems.powder_poison, 'N', KNO.dust(), 'S', ModItems.syringe_metal_empty });
|
||||
//CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_spark, 1), new Object[] { "TTD", "AAS", " T", 'A', "ingotDaffergon", 'T', ModItems.toothpicks, 'S', ModItems.gun_rpg, 'D', ModItems.ducttape });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_spark_ammo, 4), new Object[] { "PCP", "DDD", "PCP", 'P', PB.plate(), 'C', ModItems.coil_gold, 'D', ModItems.powder_power });
|
||||
//CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_skystinger, 1), new Object[] { "TTT", "AAS", " D ", 'A', "ingotUnobtainium", 'T', ModItems.toothpicks, 'S', ModItems.gun_stinger, 'D', ModItems.ducttape });
|
||||
//CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_hp, 1), new Object[] { "TDT", "ASA", " T ", 'A', "ingotReiium", 'T', ModItems.toothpicks, 'S', ModItems.gun_xvl1456, 'D', ModItems.ducttape });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_hp_ammo, 8), new Object[] { " R ", "BSK", " Y ", 'S', STEEL.plate(), 'K', KEY_BLACK, 'R', KEY_RED, 'B', KEY_BLUE, 'Y', KEY_YELLOW });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_defabricator_ammo, 16), new Object[] { "PCP", "DDD", "PCP", 'P', STEEL.plate(), 'C', ModItems.coil_copper, 'D', LI.dust() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_lever_action, 1), new Object[] { "PPI", "SWD", 'P', IRON.plate(), 'I', ModItems.mechanism_rifle_1, 'S', KEY_STICK, 'D', KEY_PLANKS, 'W', STEEL.wireFine() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_lever_action_dark, 1), new Object[] { "PPI", "SWD", 'P', STEEL.plate(), 'I', ModItems.mechanism_rifle_1, 'S', KEY_STICK, 'D', KEY_PLANKS, 'W', STEEL.wireFine() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_bolt_action, 1), new Object[] { "PPI", "SWD", 'P', STEEL.plate(), 'I', ModItems.mechanism_rifle_1, 'S', KEY_STICK, 'D', KEY_PLANKS, 'W', CU.wireFine() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_bolt_action_green, 1), new Object[] { "PPI", "SWD", 'P', IRON.plate(), 'I', ModItems.mechanism_rifle_1, 'S', KEY_STICK, 'D', KEY_PLANKS, 'W', CU.wireFine() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_bolt_action_saturnite, 1), new Object[] { "PPI", "SWD", 'P', BIGMT.plate(), 'I', ModItems.mechanism_rifle_1, 'S', KEY_STICK, 'D', KEY_PLANKS, 'W', W.wireFine() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_b92), new Object[] { "DDD", "SSC", " R", 'D', ModItems.plate_dineutronium, 'S', STAR.ingot(), 'C', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.BISMOID), 'R', ModItems.gun_revolver_schrabidium });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_b93), new Object[] { "PCE", "SEB", "PCE", 'P', ModItems.plate_dineutronium, 'C', ModItems.weaponized_starblaster_cell, 'E', ModItems.component_emitter, 'B', ModItems.gun_b92, 'S', ModItems.singularity_spark });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_b92), new Object[] { "DDD", "SSC", " R", 'D', ModItems.plate_dineutronium, 'S', STAR.ingot(), 'C', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.BISMOID), 'R', ModItems.gun_lasrifle });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_b92_ammo, 1), new Object[] { "PSP", "ESE", "PSP", 'P', STEEL.plate(), 'S', STAR.ingot(), 'E', ModItems.powder_spark_mix });
|
||||
CraftingManager.addShapelessAuto(new ItemStack(ModItems.weaponized_starblaster_cell, 1), new Object[] { new ItemStack(ModItems.fluid_tank_full, 1, Fluids.PEROXIDE.getID()), GunB92Cell.getFullCell(), CU.wireFine() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_uzi_silencer, 1), new Object[] { "P ", " P ", " U", 'P', ANY_PLASTIC.ingot(), 'U', ModItems.gun_uzi });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_uzi_saturnite, 1), new Object[] { "SMS", " PB", " P ", 'S', BIGMT.ingot(), 'M', ModItems.mechanism_rifle_2, 'P', BIGMT.plate(), 'B', W.bolt() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_uzi_saturnite_silencer, 1), new Object[] { "P ", " P ", " U", 'P', ANY_PLASTIC.ingot(), 'U', ModItems.gun_uzi_saturnite });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_bolter, 1), new Object[] { "SSM", "PIP", " I ", 'S', BIGMT.plate(), 'I', BIGMT.ingot(), 'M', ModItems.mechanism_special, 'P', ANY_PLASTIC.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_calamity, 1), new Object[] { " PI", "BBM", " PI", 'P', IRON.plate(), 'B', STEEL.pipe(), 'M', ModItems.mechanism_rifle_1, 'I', STEEL.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_m2, 1), new Object[] { " PI", "BBM", " PI", 'P', STEEL.plate(), 'B', STEEL.pipe(), 'M', ModItems.mechanism_rifle_2, 'I', STEEL.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_lacunae, 1), new Object[] { "TIT", "ILI", "PRP", 'T', ModItems.syringe_taint, 'I', STAR.ingot(), 'L', ModItems.gun_minigun, 'P', ModItems.pellet_rtg, 'R', ModBlocks.machine_rtg_grey });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_mymy, 1), new Object[] { "PP ", " WP", 'P', ANY_RUBBER.ingot(), 'W', STEEL.wireFine() });
|
||||
//CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_darter, 1), new Object[] { "SST", " P", 'S', STEEL.plate(), 'T', ModItems.gas_empty, 'P', ANY_PLASTIC.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_fireext, 1), new Object[] { "HB", " T", 'H', STEEL.pipe(), 'B', STEEL.bolt(), 'T', ModItems.tank_steel });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_spas12, 1), new Object[] { "TPS", "HHR", " L", 'T', STEEL.bolt(), 'P', STEEL.plate(), 'S', STEEL.ingot(), 'H', STEEL.pipe(), 'R', ModItems.mechanism_rifle_1, 'L', ANY_PLASTIC.ingot()});
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_glass_cannon, 1), new Object[] { "GGC", "GTM", 'G', Item.getItemFromBlock(ModBlocks.glass_quartz), 'C', ModItems.battery_lithium_cell, 'T', ModItems.crt_display, 'M', ModItems.mechanism_special });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_remington, 1), new Object[] { "PPM", "S L", 'P', STEEL.plate(), 'M', ModItems.mechanism_rifle_1, 'S', KEY_SLAB, 'L', KEY_LOG });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_benelli), new Object[] { "HHP", "SSM", "AAP", 'H', ModItems.ingot_dura_steel, 'S', STEEL.pipe(), 'A', AL.pipe(), 'P', ANY_PLASTIC.ingot(), 'M', ModItems.mechanism_rifle_2 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_lunatic_marksman), new Object[] { " GN", "SSM", " A", 'G', KEY_ANYPANE, 'N', ModItems.powder_nitan_mix, 'S', BIGMT.plate(), 'M', ModItems.mechanism_special, 'A', ANY_RESISTANTALLOY.plateCast() });
|
||||
|
||||
//TODO: somehow add more variance, 4 gauge is still missing
|
||||
CraftingManager.addShapelessAuto(new ItemStack(ModItems.ammo_22lr, 16), new Object[] { ModItems.nitra_small });
|
||||
@ -200,54 +152,8 @@ public class WeaponRecipes {
|
||||
//Ammo assemblies
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.pellet_flechette, 1), new Object[] { " L ", " L ", "LLL", 'L', PB.nugget() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.pellet_claws, 1), new Object[] { " X ", "X X", " XX", 'X', STEEL.plate() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_iron, 1), new Object[] { " I", "GC", 'I', IRON.ingot(), 'G', ANY_GUNPOWDER.dust(), 'C', ModItems.casing_357 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_steel, 1), new Object[] { " I", "GC", 'I', PB.ingot(), 'G', ANY_GUNPOWDER.dust(), 'C', ModItems.casing_357 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_lead, 1), new Object[] { " I", "GC", 'I', U235.ingot(), 'G', ModItems.cordite, 'C', KEY_CLEARGLASS });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_lead, 1), new Object[] { " I", "GC", 'I', PU239.ingot(), 'G', ModItems.cordite, 'C', KEY_CLEARGLASS });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_lead, 1), new Object[] { " I", "GC", 'I', ModItems.trinitite, 'G', ModItems.cordite, 'C', KEY_CLEARGLASS });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_lead, 1), new Object[] { " I", "GC", 'I', ModItems.nuclear_waste_tiny, 'G', ModItems.cordite, 'C', KEY_CLEARGLASS });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_gold, 1), new Object[] { " I", "GC", 'I', GOLD.ingot(), 'G', ModItems.cordite, 'C', ModItems.casing_357 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_schrabidium, 1), new Object[] { " I ", "GCN", 'I', SA326.ingot(), 'G', ModItems.cordite, 'C', ModItems.casing_357, 'N', ModItems.billet_yharonite });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_nightmare, 1), new Object[] { " I", "GC", 'I', W.ingot(), 'G', ModItems.cordite, 'C', ModItems.casing_357 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_desh, 1), new Object[] { " I", "GC", 'I', DESH.ingot(), 'G', ModItems.cordite, 'C', ModItems.casing_357 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_smg, 1), new Object[] { " I", "GC", 'I', PB.ingot(), 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_9 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_556, 1), new Object[] { " I", "GC", 'I', STEEL.ingot(), 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_9 });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_556.stackFromEnum(30, Ammo556mm.K), new Object[] { "G", "C", 'G', ANY_GUNPOWDER.dust(), 'C', ModItems.casing_9 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_uzi, 1), new Object[] { " I", "GC", 'I', IRON.ingot(), 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_9 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_lacunae, 1), new Object[] { " I", "GC", 'I', CU.ingot(), 'G', ModItems.cordite, 'C', ModItems.casing_9 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_nopip, 1), new Object[] { " I", "GC", 'I', PB.ingot(), 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_44 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.ammo_12gauge, 12), new Object[] { " I ", "GCL", 'I', ModItems.pellet_buckshot, 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_buckshot, 'L', ANY_RUBBER.ingot() });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_12gauge.stackFromEnum(12, Ammo12Gauge.PERCUSSION), new Object[] { "G", "C", 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_buckshot });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.ammo_4gauge, 12), new Object[] { " I ", "GCL", 'I', ModItems.pellet_buckshot, 'G', ModItems.cordite, 'C', ModItems.casing_50, 'L', ANY_RUBBER.ingot() });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_4gauge.stackFromEnum(12, Ammo4Gauge.SLUG), new Object[] { " I ", "GCL", 'I', STEEL.ingot(), 'G', ModItems.cordite, 'C', ModItems.casing_50, 'L', ANY_RUBBER.ingot() });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_4gauge.stackFromEnum(12, Ammo4Gauge.FLECHETTE), new Object[] { " I ", "GCL", 'I', ModItems.pellet_flechette, 'G', ModItems.cordite, 'C', ModItems.casing_50, 'L', ANY_RUBBER.ingot() });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_4gauge.stackFromEnum(4, Ammo4Gauge.EXPLOSIVE), new Object[] { " I ", "GCL", 'I', ModBlocks.tnt, 'G', ModItems.cordite, 'C', ModItems.casing_50, 'L', ANY_RUBBER.ingot() });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_4gauge.stackFromEnum(6, Ammo4Gauge.EXPLOSIVE), new Object[] { " I ", "GCL", 'I', ANY_PLASTICEXPLOSIVE.ingot(), 'G', ModItems.cordite, 'C', ModItems.casing_50, 'L', ANY_RUBBER.ingot() });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_4gauge.stackFromEnum(4, Ammo4Gauge.MINING), new Object[] { " I ", "GCL", 'I', ModBlocks.det_miner, 'G', ModItems.cordite, 'C', ModItems.casing_50, 'L', ANY_RUBBER.ingot() });
|
||||
CraftingManager.addShapelessAuto(ModItems.ammo_4gauge.stackFromEnum(Ammo4Gauge.QUACK), new Object[] { ModItems.ammo_4gauge, ModItems.nugget_bismuth, ModItems.nugget_tantalium, ModItems.ball_dynamite });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.STOCK), new Object[] { " I ", "GCL", 'I', ModItems.pellet_buckshot, 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_buckshot, 'L', CU.plate() });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.SLUG), new Object[] { " I ", "GCL", 'I', PB.ingot(), 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_buckshot, 'L', CU.plate() });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.EXPLOSIVE), new Object[] { " I ", "GCL", 'I', ModItems.pellet_cluster, 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_buckshot, 'L', CU.plate() });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_20gauge.stackFromEnum(20, Ammo20Gauge.FLECHETTE), new Object[] { " I ", "GCL", 'I', ModItems.pellet_flechette, 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_buckshot, 'L', CU.plate() });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_357.stackFromEnum(6, Ammo357Magnum.NIGHTMARE2), new Object[] { "I", "C", 'I', ModItems.powder_power, 'C', ModItems.casing_buckshot });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_calamity, 1), new Object[] { " I ", "GCG", 'I', PB.ingot(), 'G', ModItems.cordite, 'C', ModItems.casing_50 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_actionexpress, 1), new Object[] { " I", "GC", 'I', PB.ingot(), 'G', ModItems.cordite, 'C', ModItems.casing_50 });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_nuke, 1), new Object[] { " WP", "SEP", " WP", 'W', STEEL.wireFine(), 'P', STEEL.plate(), 'S', STEEL.shell(), 'E', ANY_HIGHEXPLOSIVE.ingot() });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_dart.stackFromEnum(16, AmmoDart.GPS), new Object[] { "IPI", "ICI", "IPI", 'I', ANY_RUBBER.ingot(), 'P', IRON.plate(), 'C', new ItemStack(ModItems.fluid_tank_lead_full, 1, Fluids.WATZ.getID()) });
|
||||
CraftingManager.addRecipeAuto(ModItems.ammo_dart.stackFromEnum(16, AmmoDart.NERF), new Object[] { "I", "I", 'I', ANY_RUBBER.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_45, 1), " I", "GC", 'I', CU.ingot(), 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_44);
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_762, 1), " I", "GC", 'I', CU.ingot(), 'G', ANY_SMOKELESS.dust(), 'C', ModItems.casing_50);
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_luna, 1), new Object[] { " B ", "GCG", "GPG", 'B', FERRO.ingot(), 'G', ModItems.powder_nitan_mix, 'C', ModItems.casing_50, 'P', ModItems.powder_power});
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.assembly_nuke, 1), new Object[] { " WP", "SEP", " WP", 'W', GOLD.wireFine(), 'P', STEEL.plate(), 'S', STEEL.shell(), 'E', ModItems.ball_tatb });
|
||||
|
||||
//Folly shells
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.folly_bullet, 1), new Object[] { " S ", "STS", "SMS", 'S', STAR.ingot(), 'T', ModItems.powder_magic, 'M', ModBlocks.block_meteor });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.folly_bullet_nuclear, 1), new Object[] { " N ", "UTU", "UTU", 'N', ModItems.ammo_nuke, 'U', IRON.ingot(), 'T', W.block() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.folly_bullet_du, 1), new Object[] { " U ", "UDU", "UTU", 'U', U238.block(), 'D', DESH.block(), 'T', W.block() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.folly_shell, 1), new Object[] { "IPI", "IPI", "IMI", 'I', IRON.ingot(), 'P', IRON.plate(), 'M', ANY_SMOKELESS.dust() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.ammo_folly, 1), new Object[] { " B ", "MEM", " S ", 'B', ModItems.folly_bullet, 'M', ModItems.powder_magic, 'E', ModItems.powder_power, 'S', ModItems.folly_shell });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.ammo_folly_nuclear, 1), new Object[] { " B ", "EEE", " S ", 'B', ModItems.folly_bullet_nuclear, 'E', ModBlocks.det_charge, 'S', ModItems.folly_shell });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.ammo_folly_du, 1), new Object[] { " B ", "EEE", " S ", 'B', ModItems.folly_bullet_du, 'E', ModBlocks.det_charge, 'S', ModItems.folly_shell });
|
||||
|
||||
//Rockets
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.ammo_rocket, 1), new Object[] { "T", "C", "G", 'T', ModItems.ball_dynamite, 'G', ModItems.rocket_fuel, 'C', STEEL.shell() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.ammo_rocket, 2), new Object[] { "T", "C", "G", 'T', ANY_PLASTICEXPLOSIVE.ingot(), 'G', ModItems.rocket_fuel, 'C', STEEL.shell() });
|
||||
@ -406,9 +312,9 @@ public class WeaponRecipes {
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.grenade_if_null, 1), new Object[] { "BAB", "AGA", "BAB", 'G', ModItems.grenade_if_generic, 'A', ModItems.undefined, 'B', BIGMT.ingot() });
|
||||
|
||||
//Mines
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModBlocks.mine_ap, 4), new Object[] { "C", "P", "T", 'C', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.BASIC), 'P', IRON.plate(), 'T', ANY_PLASTICEXPLOSIVE.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModBlocks.mine_ap, 4), new Object[] { "I", "C", "S", 'I', ModItems.plate_polymer, 'C', ANY_SMOKELESS.dust(), 'S', STEEL.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModBlocks.mine_shrap, 1), new Object[] { "L", "M", 'M', ModBlocks.mine_ap, 'L', ModItems.pellet_buckshot });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModBlocks.mine_he, 1), new Object[] { " C ", "PTP", 'C', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.BASIC), 'P', STEEL.plate(), 'T', ANY_HIGHEXPLOSIVE.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModBlocks.mine_shrap, 2), new Object[] { "LLL", " C ", "PTP", 'C', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.BASIC), 'P', STEEL.plate(), 'T', ModBlocks.det_cord, 'L', ModItems.pellet_buckshot });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModBlocks.mine_fat, 1), new Object[] { "CDN", 'C', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.ANALOG), 'D', ModItems.ducttape, 'N', ModItems.ammo_nuke });
|
||||
|
||||
//Nuke parts
|
||||
|
||||
@ -124,6 +124,7 @@ public class EntityMappings {
|
||||
addEntity(EntityGrenadePC.class, "entity_grenade_pink_cloud", 250);
|
||||
addEntity(EntityGrenadeCloud.class, "entity_grenade_cloud", 250);
|
||||
addEntity(EntityBomber.class, "entity_bomber", 1000);
|
||||
addEntity(EntityC130.class, "entity_c130", 1000);
|
||||
addEntity(EntityBombletZeta.class, "entity_zeta", 1000);
|
||||
addEntity(EntityOrangeFX.class, "entity_agent_orange", 1000);
|
||||
addEntity(EntityDeathBlast.class, "entity_laser_blast", 1000);
|
||||
@ -148,6 +149,7 @@ public class EntityMappings {
|
||||
addEntity(EntityFallingNuke.class, "entity_falling_bomb", 1000);
|
||||
addEntity(EntityBulletBaseNT.class, "entity_bullet_mk3", 250, false);
|
||||
addEntity(EntityBulletBaseMK4.class, "entity_bullet_mk4", 250, false);
|
||||
addEntity(EntityBulletBaseMK4CL.class, "entity_bullet_mk4_cl", 250, false);
|
||||
addEntity(EntityBulletBeamBase.class, "entity_beam_mk4", 250, false);
|
||||
addEntity(EntityMinerRocket.class, "entity_miner_lander", 1000);
|
||||
addEntity(EntityFogFX.class, "entity_nuclear_fog", 1000);
|
||||
@ -163,6 +165,7 @@ public class EntityMappings {
|
||||
addEntity(EntityBuilding.class, "entity_falling_building", 1000);
|
||||
addEntity(EntitySoyuz.class, "entity_soyuz", 1000);
|
||||
addEntity(EntitySoyuzCapsule.class, "entity_soyuz_capsule", 1000);
|
||||
addEntity(EntityParachuteCrate.class, "entity_parachute_crate", 1000);
|
||||
addEntity(EntityMovingItem.class, "entity_c_item", 1000);
|
||||
addEntity(EntityMovingPackage.class, "entity_c_package", 1000);
|
||||
addEntity(EntityDeliveryDrone.class, "entity_delivery_drone", 250, false);
|
||||
@ -251,6 +254,7 @@ public class EntityMappings {
|
||||
addMob(EntityGlyphidDigger.class, "entity_glyphid_digger", 0x273038, 0x724A21);
|
||||
addMob(EntityPlasticBag.class, "entity_plastic_bag", 0xd0d0d0, 0x808080);
|
||||
addMob(EntityParasiteMaggot.class, "entity_parasite_maggot", 0xd0d0d0, 0x808080);
|
||||
addMob(EntityDummy.class, "entity_ntm_test_dummy", 0xffffff, 0x000000);
|
||||
|
||||
addSpawn(EntityCreeperPhosgene.class, 5, 1, 1, EnumCreatureType.monster, BiomeGenBase.getBiomeGenArray());
|
||||
addSpawn(EntityCreeperVolatile.class, 10, 1, 1, EnumCreatureType.monster, BiomeGenBase.getBiomeGenArray());
|
||||
|
||||
@ -19,6 +19,7 @@ public class EntityFireLingering extends Entity {
|
||||
|
||||
public static int TYPE_DIESEL = 0;
|
||||
public static int TYPE_BALEFIRE = 1;
|
||||
public static int TYPE_PHOSPHORUS = 2;
|
||||
public int maxAge = 150;
|
||||
|
||||
public EntityFireLingering(World world) {
|
||||
@ -72,6 +73,7 @@ public class EntityFireLingering extends Entity {
|
||||
EntityLivingBase livng = (EntityLivingBase) e;
|
||||
HbmLivingProps props = HbmLivingProps.getData(livng);
|
||||
if(this.getType() == this.TYPE_DIESEL) if(props.fire < 60) props.fire = 60;
|
||||
if(this.getType() == this.TYPE_PHOSPHORUS) if(props.fire < 300) props.fire = 300;
|
||||
if(this.getType() == this.TYPE_BALEFIRE) if(props.balefire < 100) props.balefire = 100;
|
||||
} else {
|
||||
e.setFire(4);
|
||||
@ -88,6 +90,7 @@ public class EntityFireLingering extends Entity {
|
||||
MovingObjectPosition mop = worldObj.func_147447_a(up, down, false, true, true);
|
||||
if(mop != null && mop.typeOfHit == mop.typeOfHit.BLOCK) down = mop.hitVec;
|
||||
if(this.getType() == this.TYPE_DIESEL) FlameCreator.composeEffectClient(worldObj, x, down.yCoord, z, FlameCreator.META_FIRE);
|
||||
if(this.getType() == this.TYPE_PHOSPHORUS) FlameCreator.composeEffectClient(worldObj, x, down.yCoord, z, FlameCreator.META_FIRE);
|
||||
if(this.getType() == this.TYPE_BALEFIRE) FlameCreator.composeEffectClient(worldObj, x, down.yCoord, z, FlameCreator.META_BALEFIRE);
|
||||
}
|
||||
}
|
||||
|
||||
@ -103,14 +103,12 @@ public abstract class EntityDroneBase extends Entity {
|
||||
if(this.targetY != -1) {
|
||||
|
||||
Vec3 dist = Vec3.createVectorHelper(targetX - posX, targetY - posY, targetZ - posZ);
|
||||
double speed = getSpeed();
|
||||
double speed = Math.min(getSpeed(), dist.lengthVector());
|
||||
|
||||
if(dist.lengthVector() >= speed) {
|
||||
dist = dist.normalize();
|
||||
this.motionX = dist.xCoord * speed;
|
||||
this.motionY = dist.yCoord * speed;
|
||||
this.motionZ = dist.zCoord * speed;
|
||||
}
|
||||
dist = dist.normalize();
|
||||
this.motionX = dist.xCoord * speed;
|
||||
this.motionY = dist.yCoord * speed;
|
||||
this.motionZ = dist.zCoord * speed;
|
||||
}
|
||||
if(isCollidedHorizontally){
|
||||
motionY += 1;
|
||||
|
||||
75
src/main/java/com/hbm/entity/item/EntityParachuteCrate.java
Normal file
75
src/main/java/com/hbm/entity/item/EntityParachuteCrate.java
Normal file
@ -0,0 +1,75 @@
|
||||
package com.hbm.entity.item;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import com.hbm.blocks.ModBlocks;
|
||||
import com.hbm.blocks.generic.BlockSupplyCrate.TileEntitySupplyCrate;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class EntityParachuteCrate extends Entity {
|
||||
|
||||
public List<ItemStack> items = new ArrayList();
|
||||
|
||||
public EntityParachuteCrate(World world) {
|
||||
super(world);
|
||||
this.ignoreFrustumCheck = true;
|
||||
this.isImmuneToFire = true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUpdate() {
|
||||
|
||||
this.lastTickPosX = this.prevPosX = posX;
|
||||
this.lastTickPosY = this.prevPosY = posY;
|
||||
this.lastTickPosZ = this.prevPosZ = posZ;
|
||||
this.setPosition(posX + this.motionX, posY + this.motionY, posZ + this.motionZ);
|
||||
|
||||
if(this.motionY > -0.2) this.motionY -= 0.02;
|
||||
if(posY > 600) posY = 600;
|
||||
|
||||
if(this.worldObj.getBlock((int) Math.floor(this.posX), (int) Math.floor(this.posY), (int) Math.floor(this.posZ)) != Blocks.air) {
|
||||
|
||||
this.setDead();
|
||||
|
||||
if(!worldObj.isRemote) {
|
||||
|
||||
worldObj.setBlock((int) Math.floor(this.posX), (int) Math.floor(this.posY + 1), (int) Math.floor(this.posZ), ModBlocks.crate_supply);
|
||||
TileEntitySupplyCrate crate = (TileEntitySupplyCrate) worldObj.getTileEntity((int) Math.floor(this.posX), (int) Math.floor(this.posY + 1), (int) Math.floor(this.posZ));
|
||||
if(crate != null) crate.items.addAll(this.items);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override protected void entityInit() { }
|
||||
@Override @SideOnly(Side.CLIENT) public boolean isInRangeToRenderDist(double distance) { return true; }
|
||||
|
||||
@Override
|
||||
public void readEntityFromNBT(NBTTagCompound nbt) {
|
||||
items.clear();
|
||||
NBTTagList list = nbt.getTagList("items", 10);
|
||||
for(int i = 0; i < list.tagCount(); i++) {
|
||||
NBTTagCompound nbt1 = list.getCompoundTagAt(i);
|
||||
items.add(ItemStack.loadItemStackFromNBT(nbt1));
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeEntityToNBT(NBTTagCompound nbt) {
|
||||
NBTTagList list = new NBTTagList();
|
||||
for(int i = 0; i < items.size(); i++) {
|
||||
NBTTagCompound nbt1 = new NBTTagCompound();
|
||||
items.get(i).writeToNBT(nbt1);
|
||||
list.appendTag(nbt1);
|
||||
}
|
||||
nbt.setTag("items", list);
|
||||
}
|
||||
}
|
||||
@ -199,7 +199,7 @@ public class EntityRequestDrone extends EntityDroneBase {
|
||||
|
||||
@Override
|
||||
public double getSpeed() {
|
||||
return 0.6D;
|
||||
return 0.625D;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@ -1,516 +1,275 @@
|
||||
package com.hbm.entity.logic;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import com.hbm.config.GeneralConfig;
|
||||
import com.hbm.entity.projectile.EntityBombletZeta;
|
||||
import com.hbm.entity.projectile.EntityBoxcar;
|
||||
import com.hbm.entity.projectile.EntityRocketHoming;
|
||||
import com.hbm.explosion.ExplosionChaos;
|
||||
import com.hbm.explosion.ExplosionLarge;
|
||||
import com.hbm.lib.ModDamageSource;
|
||||
import com.hbm.interfaces.NotableComments;
|
||||
import com.hbm.main.MainRegistry;
|
||||
import com.hbm.packet.PacketDispatcher;
|
||||
import com.hbm.packet.toclient.LoopedEntitySoundPacket;
|
||||
import com.hbm.util.ParticleUtil;
|
||||
import com.hbm.sound.AudioWrapper;
|
||||
|
||||
import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.util.Vec3;
|
||||
import net.minecraft.world.ChunkCoordIntPair;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeChunkManager;
|
||||
import net.minecraftforge.common.ForgeChunkManager.Ticket;
|
||||
import net.minecraftforge.common.ForgeChunkManager.Type;
|
||||
|
||||
public class EntityBomber extends Entity implements IChunkLoader {
|
||||
@NotableComments
|
||||
public class EntityBomber extends EntityPlaneBase {
|
||||
|
||||
int timer = 200;
|
||||
/* This was probably the dumbest fucking way that I could have handled this. Not gonna change it now, be glad I made a superclass at all. */
|
||||
int bombStart = 75;
|
||||
int bombStop = 125;
|
||||
int bombRate = 3;
|
||||
int type = 0;
|
||||
|
||||
public int health = 50;
|
||||
|
||||
public EntityBomber(World p_i1582_1_) {
|
||||
super(p_i1582_1_);
|
||||
protected AudioWrapper audio;
|
||||
|
||||
public EntityBomber(World world) {
|
||||
super(world);
|
||||
this.ignoreFrustumCheck = true;
|
||||
this.setSize(8.0F, 4.0F);
|
||||
this.setSize(8.0F, 4.0F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void entityInit() {
|
||||
super.entityInit();
|
||||
this.dataWatcher.addObject(16, Byte.valueOf((byte) 0));
|
||||
}
|
||||
|
||||
public boolean canBeCollidedWith()
|
||||
{
|
||||
return this.health > 0;
|
||||
}
|
||||
|
||||
public boolean attackEntityFrom(DamageSource p_70097_1_, float p_70097_2_)
|
||||
{
|
||||
if(p_70097_1_ == ModDamageSource.nuclearBlast)
|
||||
return false;
|
||||
|
||||
if (this.isEntityInvulnerable())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!this.isDead && !this.worldObj.isRemote && this.health > 0)
|
||||
{
|
||||
health -= p_70097_2_;
|
||||
|
||||
if (this.health <= 0)
|
||||
{
|
||||
this.killBomber();
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
private void killBomber() {
|
||||
ExplosionLarge.explode(worldObj, posX, posY, posZ, 5, true, false, true);
|
||||
worldObj.playSoundEffect((double)(posX + 0.5F), (double)(posY + 0.5F), (double)(posZ + 0.5F), "hbm:entity.planeShotDown", 25.0F, 1.0F);
|
||||
}
|
||||
|
||||
/** This sucks balls. Too bad! */
|
||||
@Override
|
||||
public void onUpdate() {
|
||||
super.onUpdate();
|
||||
|
||||
//super.onUpdate();
|
||||
|
||||
this.lastTickPosX = this.prevPosX = posX;
|
||||
this.lastTickPosY = this.prevPosY = posY;
|
||||
this.lastTickPosZ = this.prevPosZ = posZ;
|
||||
|
||||
this.setPosition(posX + motionX, posY + motionY, posZ + motionZ);
|
||||
|
||||
if(!worldObj.isRemote) {
|
||||
|
||||
this.dataWatcher.updateObject(17, health);
|
||||
|
||||
if(health > 0)
|
||||
PacketDispatcher.wrapper.sendToAllAround(new LoopedEntitySoundPacket(this.getEntityId()), new TargetPoint(worldObj.provider.dimensionId, posX, posY, posZ, 250));
|
||||
} else {
|
||||
health = this.dataWatcher.getWatchableObjectInt(17);
|
||||
}
|
||||
|
||||
this.rotation();
|
||||
|
||||
if(this.health <= 0) {
|
||||
motionY -= 0.025;
|
||||
|
||||
for(int i = 0; i < 10; i++)
|
||||
ParticleUtil.spawnGasFlame(this.worldObj, this.posX + rand.nextGaussian() * 0.5 - motionX * 2, this.posY + rand.nextGaussian() * 0.5 - motionY * 2, this.posZ + rand.nextGaussian() * 0.5 - motionZ * 2, 0.0, 0.1, 0.0);
|
||||
|
||||
if(worldObj.getBlock((int)posX, (int)posY, (int)posZ).isNormalCube() && !worldObj.isRemote) {
|
||||
this.setDead();
|
||||
|
||||
/*worldObj.setBlock((int)posX, (int)posY, (int)posZ, ModBlocks.bomber);
|
||||
TileEntityBomber te = (TileEntityBomber)worldObj.getTileEntity((int)posX, (int)posY, (int)posZ);
|
||||
|
||||
if(te != null) {
|
||||
te.yaw = (int)(this.rotationYaw);
|
||||
te.pitch = (int)(this.rotationPitch);
|
||||
|
||||
te.type = this.getDataWatcher().getWatchableObjectByte(16);
|
||||
}*/
|
||||
|
||||
ExplosionLarge.explodeFire(worldObj, posX, posY, posZ, 25, true, false, true);
|
||||
worldObj.playSoundEffect((double)(posX + 0.5F), (double)(posY + 0.5F), (double)(posZ + 0.5F), "hbm:entity.planeCrash", 10.0F, 1.0F);
|
||||
|
||||
return;
|
||||
if(worldObj.isRemote) {
|
||||
if(this.getDataWatcher().getWatchableObjectFloat(17) > 0) {
|
||||
if(audio == null || !audio.isPlaying()) {
|
||||
int bomberType = this.dataWatcher.getWatchableObjectByte(16);
|
||||
audio = MainRegistry.proxy.getLoopedSound(bomberType <= 4 ? "hbm:entity.bomberSmallLoop" : "hbm:entity.bomberLoop", (float) posX, (float) posY, (float) posZ, 2F, 250F, 1F, 20);
|
||||
audio.startSound();
|
||||
}
|
||||
audio.keepAlive();
|
||||
audio.updatePosition((float) posX, (float) posY, (float) posZ);
|
||||
} else {
|
||||
if(audio != null && audio.isPlaying()) {
|
||||
audio.stopSound();
|
||||
audio = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(this.ticksExisted > timer)
|
||||
this.setDead();
|
||||
|
||||
if(!worldObj.isRemote && this.health > 0 && this.ticksExisted > bombStart && this.ticksExisted < bombStop && this.ticksExisted % bombRate == 0) {
|
||||
|
||||
if(type == 3) {
|
||||
|
||||
worldObj.playSoundEffect((double)(posX + 0.5F), (double)(posY + 0.5F), (double)(posZ + 0.5F), "random.fizz", 5.0F, 2.6F + (rand.nextFloat() - rand.nextFloat()) * 0.8F);
|
||||
worldObj.playSoundEffect((double) (posX + 0.5F), (double) (posY + 0.5F), (double) (posZ + 0.5F), "random.fizz", 5.0F, 2.6F + (rand.nextFloat() - rand.nextFloat()) * 0.8F);
|
||||
ExplosionChaos.spawnChlorine(worldObj, this.posX, this.posY - 1F, this.posZ, 10, 0.5, 3);
|
||||
|
||||
} else if(type == 5) {
|
||||
|
||||
worldObj.playSoundEffect((double)(posX + 0.5F), (double)(posY + 0.5F), (double)(posZ + 0.5F), "hbm:weapon.missileTakeOff", 10.0F, 0.9F + rand.nextFloat() * 0.2F);
|
||||
EntityRocketHoming rocket = new EntityRocketHoming(worldObj);
|
||||
rocket.setIsCritical(true);
|
||||
//rocket.motionX = motionX;
|
||||
//rocket.motionZ = motionZ;
|
||||
rocket.motionY = -1;
|
||||
rocket.shootingEntity = this;
|
||||
rocket.homingRadius = 50;
|
||||
rocket.homingMod = 5;
|
||||
|
||||
rocket.posX = posX + rand.nextDouble() - 0.5;
|
||||
rocket.posY = posY - rand.nextDouble();
|
||||
rocket.posZ = posZ + rand.nextDouble() - 0.5;
|
||||
|
||||
worldObj.spawnEntityInWorld(rocket);
|
||||
|
||||
} else if(type == 6) {
|
||||
|
||||
worldObj.playSoundEffect((double)(posX + 0.5F), (double)(posY + 0.5F), (double)(posZ + 0.5F), "hbm:weapon.missileTakeOff", 10.0F, 0.9F + rand.nextFloat() * 0.2F);
|
||||
EntityBoxcar rocket = new EntityBoxcar(worldObj);
|
||||
|
||||
rocket.posX = posX + rand.nextDouble() - 0.5;
|
||||
rocket.posY = posY - rand.nextDouble();
|
||||
rocket.posZ = posZ + rand.nextDouble() - 0.5;
|
||||
|
||||
worldObj.spawnEntityInWorld(rocket);
|
||||
|
||||
} else if(type == 7) {
|
||||
|
||||
worldObj.playSoundEffect((double)(posX + 0.5F), (double)(posY + 0.5F), (double)(posZ + 0.5F), "random.fizz", 5.0F, 2.6F + (rand.nextFloat() - rand.nextFloat()) * 0.8F);
|
||||
ExplosionChaos.spawnChlorine(worldObj, this.posX, worldObj.getHeightValue((int)this.posX, (int)this.posZ) + 2, this.posZ, 10, 1, 2);
|
||||
|
||||
} else if(type == 5) {
|
||||
worldObj.playSoundEffect((double) (posX + 0.5F), (double) (posY + 0.5F), (double) (posZ + 0.5F), "hbm:weapon.missileTakeOff", 10.0F, 0.9F + rand.nextFloat() * 0.2F);
|
||||
EntityRocketHoming rocket = new EntityRocketHoming(worldObj);
|
||||
rocket.setIsCritical(true);
|
||||
rocket.motionY = -1;
|
||||
rocket.shootingEntity = this;
|
||||
rocket.homingRadius = 50;
|
||||
rocket.homingMod = 5;
|
||||
rocket.posX = posX + rand.nextDouble() - 0.5;
|
||||
rocket.posY = posY - rand.nextDouble();
|
||||
rocket.posZ = posZ + rand.nextDouble() - 0.5;
|
||||
worldObj.spawnEntityInWorld(rocket);
|
||||
|
||||
} else if(type == 6) {
|
||||
worldObj.playSoundEffect((double) (posX + 0.5F), (double) (posY + 0.5F), (double) (posZ + 0.5F), "hbm:weapon.missileTakeOff", 10.0F, 0.9F + rand.nextFloat() * 0.2F);
|
||||
EntityBoxcar rocket = new EntityBoxcar(worldObj);
|
||||
rocket.posX = posX + rand.nextDouble() - 0.5;
|
||||
rocket.posY = posY - rand.nextDouble();
|
||||
rocket.posZ = posZ + rand.nextDouble() - 0.5;
|
||||
worldObj.spawnEntityInWorld(rocket);
|
||||
|
||||
} else if(type == 7) {
|
||||
worldObj.playSoundEffect((double) (posX + 0.5F), (double) (posY + 0.5F), (double) (posZ + 0.5F), "random.fizz", 5.0F, 2.6F + (rand.nextFloat() - rand.nextFloat()) * 0.8F);
|
||||
ExplosionChaos.spawnChlorine(worldObj, this.posX, worldObj.getHeightValue((int) this.posX, (int) this.posZ) + 2, this.posZ, 10, 1, 2);
|
||||
|
||||
} else {
|
||||
|
||||
worldObj.playSoundEffect((double)(posX + 0.5F), (double)(posY + 0.5F), (double)(posZ + 0.5F), "hbm:entity.bombWhistle", 10.0F, 0.9F + rand.nextFloat() * 0.2F);
|
||||
|
||||
worldObj.playSoundEffect((double) (posX + 0.5F), (double) (posY + 0.5F), (double) (posZ + 0.5F), "hbm:entity.bombWhistle", 10.0F, 0.9F + rand.nextFloat() * 0.2F);
|
||||
EntityBombletZeta zeta = new EntityBombletZeta(worldObj);
|
||||
/*zeta.prevRotationYaw = zeta.rotationYaw = this.rotationYaw;
|
||||
zeta.prevRotationPitch = zeta.rotationPitch = this.rotationPitch;*/
|
||||
|
||||
zeta.rotation();
|
||||
|
||||
zeta.type = type;
|
||||
|
||||
zeta.posX = posX + rand.nextDouble() - 0.5;
|
||||
zeta.posY = posY - rand.nextDouble();
|
||||
zeta.posZ = posZ + rand.nextDouble() - 0.5;
|
||||
|
||||
if(type == 0) {
|
||||
zeta.motionX = motionX + rand.nextGaussian() * 0.15;
|
||||
zeta.motionZ = motionZ + rand.nextGaussian() * 0.15;
|
||||
zeta.motionX = motionX + rand.nextGaussian() * 0.15; zeta.motionZ = motionZ + rand.nextGaussian() * 0.15;
|
||||
} else {
|
||||
zeta.motionX = motionX;
|
||||
zeta.motionZ = motionZ;
|
||||
zeta.motionX = motionX; zeta.motionZ = motionZ;
|
||||
}
|
||||
|
||||
worldObj.spawnEntityInWorld(zeta);
|
||||
}
|
||||
}
|
||||
|
||||
if(!worldObj.isRemote)
|
||||
loadNeighboringChunks((int)(posX / 16), (int)(posZ / 16));
|
||||
|
||||
}
|
||||
|
||||
public void fac(World world, double x, double y, double z) {
|
||||
|
||||
Vec3 vector = Vec3.createVectorHelper(world.rand.nextDouble() - 0.5, 0, world.rand.nextDouble() - 0.5);
|
||||
vector = vector.normalize();
|
||||
vector.xCoord *= GeneralConfig.enableBomberShortMode ? 1 : 2;
|
||||
vector.zCoord *= GeneralConfig.enableBomberShortMode ? 1 : 2;
|
||||
|
||||
this.setLocationAndAngles(x - vector.xCoord * 100, y + 50, z - vector.zCoord * 100, 0.0F, 0.0F);
|
||||
this.loadNeighboringChunks((int)(x / 16), (int)(z / 16));
|
||||
|
||||
this.motionX = vector.xCoord;
|
||||
this.motionZ = vector.zCoord;
|
||||
this.motionY = 0.0D;
|
||||
|
||||
this.rotation();
|
||||
|
||||
int i = 1;
|
||||
|
||||
int rand = world.rand.nextInt(7);
|
||||
|
||||
switch(rand) {
|
||||
case 0:
|
||||
case 1: i = 1; break;
|
||||
case 2:
|
||||
case 3: i = 2; break;
|
||||
case 4: i = 5; break;
|
||||
case 5: i = 6; break;
|
||||
case 6: i = 7; break;
|
||||
}
|
||||
|
||||
if(world.rand.nextInt(100) == 0) {
|
||||
rand = world.rand.nextInt(4);
|
||||
|
||||
switch(rand) {
|
||||
case 0: i = 0; break;
|
||||
case 1: i = 3; break;
|
||||
case 2: i = 4; break;
|
||||
case 3: i = 8; break;
|
||||
}
|
||||
}
|
||||
|
||||
this.getDataWatcher().updateObject(16, (byte)i);
|
||||
this.setSize(8.0F, 4.0F);
|
||||
}
|
||||
|
||||
public static EntityBomber statFacCarpet(World world, double x, double y, double z) {
|
||||
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 50;
|
||||
bomber.bombStop = 100;
|
||||
bomber.bombRate = 2;
|
||||
public void fac(World world, double x, double y, double z) {
|
||||
|
||||
bomber.fac(world, x, y, z);
|
||||
|
||||
bomber.type = 0;
|
||||
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacNapalm(World world, double x, double y, double z) {
|
||||
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 50;
|
||||
bomber.bombStop = 100;
|
||||
bomber.bombRate = 5;
|
||||
Vec3 vector = Vec3.createVectorHelper(world.rand.nextDouble() - 0.5, 0, world.rand.nextDouble() - 0.5);
|
||||
vector = vector.normalize();
|
||||
vector.xCoord *= GeneralConfig.enableBomberShortMode ? 1 : 2;
|
||||
vector.zCoord *= GeneralConfig.enableBomberShortMode ? 1 : 2;
|
||||
|
||||
bomber.fac(world, x, y, z);
|
||||
|
||||
bomber.type = 1;
|
||||
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacChlorine(World world, double x, double y, double z) {
|
||||
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 50;
|
||||
bomber.bombStop = 100;
|
||||
bomber.bombRate = 4;
|
||||
this.setLocationAndAngles(x - vector.xCoord * 100, y + 50, z - vector.zCoord * 100, 0.0F, 0.0F);
|
||||
this.loadNeighboringChunks((int) (x / 16), (int) (z / 16));
|
||||
|
||||
bomber.fac(world, x, y, z);
|
||||
|
||||
bomber.type = 2;
|
||||
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacOrange(World world, double x, double y, double z) {
|
||||
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 75;
|
||||
bomber.bombStop = 125;
|
||||
bomber.bombRate = 1;
|
||||
this.motionX = vector.xCoord;
|
||||
this.motionZ = vector.zCoord;
|
||||
this.motionY = 0.0D;
|
||||
|
||||
bomber.fac(world, x, y, z);
|
||||
|
||||
bomber.type = 3;
|
||||
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacABomb(World world, double x, double y, double z) {
|
||||
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 60;
|
||||
bomber.bombStop = 70;
|
||||
bomber.bombRate = 65;
|
||||
this.rotation();
|
||||
|
||||
bomber.fac(world, x, y, z);
|
||||
|
||||
int i = 1;
|
||||
|
||||
int rand = world.rand.nextInt(3);
|
||||
|
||||
switch(rand) {
|
||||
case 0: i = 5; break;
|
||||
case 1: i = 6; break;
|
||||
case 2: i = 7; break;
|
||||
}
|
||||
|
||||
if(world.rand.nextInt(100) == 0) {
|
||||
i = 8;
|
||||
}
|
||||
|
||||
bomber.getDataWatcher().updateObject(16, (byte)i);
|
||||
|
||||
bomber.type = 4;
|
||||
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacStinger(World world, double x, double y, double z) {
|
||||
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 50;
|
||||
bomber.bombStop = 150;
|
||||
bomber.bombRate = 10;
|
||||
int i = 1;
|
||||
|
||||
bomber.fac(world, x, y, z);
|
||||
|
||||
bomber.getDataWatcher().updateObject(16, (byte)4);
|
||||
|
||||
bomber.type = 5;
|
||||
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacBoxcar(World world, double x, double y, double z) {
|
||||
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 50;
|
||||
bomber.bombStop = 150;
|
||||
bomber.bombRate = 10;
|
||||
int rand = world.rand.nextInt(7);
|
||||
|
||||
bomber.fac(world, x, y, z);
|
||||
|
||||
bomber.getDataWatcher().updateObject(16, (byte)6);
|
||||
|
||||
bomber.type = 6;
|
||||
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacPC(World world, double x, double y, double z) {
|
||||
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 75;
|
||||
bomber.bombStop = 125;
|
||||
bomber.bombRate = 1;
|
||||
switch(rand) {
|
||||
case 0: case 1: i = 1; break;
|
||||
case 2: case 3: i = 2; break;
|
||||
case 4: i = 5; break;
|
||||
case 5: i = 6; break;
|
||||
case 6: i = 7; break;
|
||||
}
|
||||
|
||||
bomber.fac(world, x, y, z);
|
||||
|
||||
bomber.getDataWatcher().updateObject(16, (byte)6);
|
||||
|
||||
bomber.type = 7;
|
||||
|
||||
return bomber;
|
||||
}
|
||||
if(world.rand.nextInt(100) == 0) {
|
||||
rand = world.rand.nextInt(4);
|
||||
switch(rand) {
|
||||
case 0: i = 0; break;
|
||||
case 1: i = 3; break;
|
||||
case 2: i = 4; break;
|
||||
case 3: i = 8; break;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void entityInit() {
|
||||
init(ForgeChunkManager.requestTicket(MainRegistry.instance, worldObj, Type.ENTITY));
|
||||
this.dataWatcher.addObject(16, Byte.valueOf((byte)0));
|
||||
this.dataWatcher.addObject(17, Integer.valueOf((int)50));
|
||||
}
|
||||
this.getDataWatcher().updateObject(16, (byte) i);
|
||||
this.setSize(8.0F, 4.0F);
|
||||
}
|
||||
|
||||
public static EntityBomber statFacCarpet(World world, double x, double y, double z) {
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 50;
|
||||
bomber.bombStop = 100;
|
||||
bomber.bombRate = 2;
|
||||
bomber.fac(world, x, y, z);
|
||||
bomber.type = 0;
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacNapalm(World world, double x, double y, double z) {
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 50;
|
||||
bomber.bombStop = 100;
|
||||
bomber.bombRate = 5;
|
||||
bomber.fac(world, x, y, z);
|
||||
bomber.type = 1;
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacChlorine(World world, double x, double y, double z) {
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 50;
|
||||
bomber.bombStop = 100;
|
||||
bomber.bombRate = 4;
|
||||
bomber.fac(world, x, y, z);
|
||||
bomber.type = 2;
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacOrange(World world, double x, double y, double z) {
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 75;
|
||||
bomber.bombStop = 125;
|
||||
bomber.bombRate = 1;
|
||||
bomber.fac(world, x, y, z);
|
||||
bomber.type = 3;
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacABomb(World world, double x, double y, double z) {
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 60;
|
||||
bomber.bombStop = 70;
|
||||
bomber.bombRate = 65;
|
||||
bomber.fac(world, x, y, z);
|
||||
int i = 1;
|
||||
|
||||
int rand = world.rand.nextInt(3);
|
||||
|
||||
switch(rand) {
|
||||
case 0: i = 5; break;
|
||||
case 1: i = 6; break;
|
||||
case 2: i = 7; break;
|
||||
}
|
||||
if(world.rand.nextInt(100) == 0) i = 8;
|
||||
|
||||
bomber.getDataWatcher().updateObject(16, (byte) i);
|
||||
bomber.type = 4;
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacStinger(World world, double x, double y, double z) {
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 50;
|
||||
bomber.bombStop = 150;
|
||||
bomber.bombRate = 10;
|
||||
bomber.fac(world, x, y, z);
|
||||
bomber.getDataWatcher().updateObject(16, (byte) 4);
|
||||
bomber.type = 5;
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacBoxcar(World world, double x, double y, double z) {
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 50;
|
||||
bomber.bombStop = 150;
|
||||
bomber.bombRate = 10;
|
||||
bomber.fac(world, x, y, z);
|
||||
bomber.getDataWatcher().updateObject(16, (byte) 6);
|
||||
bomber.type = 6;
|
||||
return bomber;
|
||||
}
|
||||
|
||||
public static EntityBomber statFacPC(World world, double x, double y, double z) {
|
||||
EntityBomber bomber = new EntityBomber(world);
|
||||
bomber.timer = 200;
|
||||
bomber.bombStart = 75;
|
||||
bomber.bombStop = 125;
|
||||
bomber.bombRate = 1;
|
||||
bomber.fac(world, x, y, z);
|
||||
bomber.getDataWatcher().updateObject(16, (byte) 6);
|
||||
bomber.type = 7;
|
||||
return bomber;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void readEntityFromNBT(NBTTagCompound nbt) {
|
||||
ticksExisted = nbt.getInteger("ticksExisted");
|
||||
super.readEntityFromNBT(nbt);
|
||||
bombStart = nbt.getInteger("bombStart");
|
||||
bombStop = nbt.getInteger("bombStop");
|
||||
bombRate = nbt.getInteger("bombRate");
|
||||
type = nbt.getInteger("type");
|
||||
|
||||
this.getDataWatcher().updateObject(16, nbt.getByte("style"));
|
||||
this.getDataWatcher().updateObject(17, nbt.getInteger("health"));
|
||||
this.setSize(8.0F, 4.0F);
|
||||
this.getDataWatcher().updateObject(16, nbt.getByte("style"));
|
||||
this.setSize(8.0F, 4.0F);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void writeEntityToNBT(NBTTagCompound nbt) {
|
||||
nbt.setInteger("ticksExisted", ticksExisted);
|
||||
super.writeEntityToNBT(nbt);
|
||||
nbt.setInteger("bombStart", bombStart);
|
||||
nbt.setInteger("bombStop", bombStop);
|
||||
nbt.setInteger("bombRate", bombRate);
|
||||
nbt.setInteger("type", type);
|
||||
nbt.setByte("style", this.getDataWatcher().getWatchableObjectByte(16));
|
||||
nbt.setInteger("health", this.getDataWatcher().getWatchableObjectInt(17));
|
||||
}
|
||||
|
||||
protected void rotation() {
|
||||
float f2 = MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ);
|
||||
this.rotationYaw = (float)(Math.atan2(this.motionX, this.motionZ) * 180.0D / Math.PI);
|
||||
|
||||
for (this.rotationPitch = (float)(Math.atan2(this.motionY, f2) * 180.0D / Math.PI) - 90; this.rotationPitch - this.prevRotationPitch < -180.0F; this.prevRotationPitch -= 360.0F)
|
||||
{
|
||||
;
|
||||
}
|
||||
|
||||
while (this.rotationPitch - this.prevRotationPitch >= 180.0F)
|
||||
{
|
||||
this.prevRotationPitch += 360.0F;
|
||||
}
|
||||
|
||||
while (this.rotationYaw - this.prevRotationYaw < -180.0F)
|
||||
{
|
||||
this.prevRotationYaw -= 360.0F;
|
||||
}
|
||||
|
||||
while (this.rotationYaw - this.prevRotationYaw >= 180.0F)
|
||||
{
|
||||
this.prevRotationYaw += 360.0F;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public boolean isInRangeToRenderDist(double distance)
|
||||
{
|
||||
return distance < 500000;
|
||||
}
|
||||
|
||||
private Ticket loaderTicket;
|
||||
|
||||
public void init(Ticket ticket) {
|
||||
|
||||
if(!worldObj.isRemote) {
|
||||
|
||||
if(ticket != null) {
|
||||
|
||||
if(loaderTicket == null) {
|
||||
|
||||
loaderTicket = ticket;
|
||||
loaderTicket.bindEntity(this);
|
||||
loaderTicket.getModData();
|
||||
}
|
||||
|
||||
|
||||
ForgeChunkManager.forceChunk(loaderTicket, new ChunkCoordIntPair(chunkCoordX, chunkCoordZ));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
List<ChunkCoordIntPair> loadedChunks = new ArrayList<ChunkCoordIntPair>();
|
||||
|
||||
public void loadNeighboringChunks(int newChunkX, int newChunkZ)
|
||||
{
|
||||
if(!worldObj.isRemote && loaderTicket != null)
|
||||
{
|
||||
for(ChunkCoordIntPair chunk : loadedChunks)
|
||||
{
|
||||
ForgeChunkManager.unforceChunk(loaderTicket, chunk);
|
||||
}
|
||||
|
||||
loadedChunks.clear();
|
||||
loadedChunks.add(new ChunkCoordIntPair(newChunkX, newChunkZ));
|
||||
loadedChunks.add(new ChunkCoordIntPair(newChunkX + 1, newChunkZ + 1));
|
||||
loadedChunks.add(new ChunkCoordIntPair(newChunkX - 1, newChunkZ - 1));
|
||||
loadedChunks.add(new ChunkCoordIntPair(newChunkX + 1, newChunkZ - 1));
|
||||
loadedChunks.add(new ChunkCoordIntPair(newChunkX - 1, newChunkZ + 1));
|
||||
loadedChunks.add(new ChunkCoordIntPair(newChunkX + 1, newChunkZ));
|
||||
loadedChunks.add(new ChunkCoordIntPair(newChunkX, newChunkZ + 1));
|
||||
loadedChunks.add(new ChunkCoordIntPair(newChunkX - 1, newChunkZ));
|
||||
loadedChunks.add(new ChunkCoordIntPair(newChunkX, newChunkZ - 1));
|
||||
|
||||
for(ChunkCoordIntPair chunk : loadedChunks)
|
||||
{
|
||||
ForgeChunkManager.forceChunk(loaderTicket, chunk);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
98
src/main/java/com/hbm/entity/logic/EntityC130.java
Normal file
98
src/main/java/com/hbm/entity/logic/EntityC130.java
Normal file
@ -0,0 +1,98 @@
|
||||
package com.hbm.entity.logic;
|
||||
|
||||
import com.hbm.entity.item.EntityParachuteCrate;
|
||||
import com.hbm.itempool.ItemPool;
|
||||
import com.hbm.itempool.ItemPoolsC130;
|
||||
import com.hbm.main.MainRegistry;
|
||||
import com.hbm.sound.AudioWrapper;
|
||||
import com.hbm.util.EnumUtil;
|
||||
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.Vec3;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class EntityC130 extends EntityPlaneBase {
|
||||
|
||||
protected AudioWrapper audio;
|
||||
public C130PayloadType payload = C130PayloadType.SUPPLIES;
|
||||
|
||||
public EntityC130(World world) {
|
||||
super(world);
|
||||
this.ignoreFrustumCheck = true;
|
||||
this.setSize(8.0F, 4.0F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUpdate() {
|
||||
super.onUpdate();
|
||||
|
||||
if(worldObj.isRemote) {
|
||||
if(this.getDataWatcher().getWatchableObjectFloat(17) > 0) {
|
||||
if(audio == null || !audio.isPlaying()) {
|
||||
audio = MainRegistry.proxy.getLoopedSound("hbm:entity.bomberLoop", (float) posX, (float) posY, (float) posZ, 2F, 250F, 1F, 20);
|
||||
audio.startSound();
|
||||
}
|
||||
audio.keepAlive();
|
||||
audio.updatePosition((float) posX, (float) posY, (float) posZ);
|
||||
} else {
|
||||
if(audio != null && audio.isPlaying()) {
|
||||
audio.stopSound();
|
||||
audio = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(!worldObj.isRemote && this.ticksExisted == this.getLifetime() / 2 && this.health > 0) {
|
||||
EntityParachuteCrate crate = new EntityParachuteCrate(worldObj);
|
||||
crate.setPosition(posX - motionX * 7, posY - 10, posZ - motionZ * 7);
|
||||
|
||||
if(this.payload == C130PayloadType.SUPPLIES) {
|
||||
for(int i = 0; i < 5; i++) crate.items.add(ItemPool.getStack(ItemPoolsC130.POOL_SUPPLIES, this.rand));
|
||||
}
|
||||
if(this.payload == C130PayloadType.WEAPONS) {
|
||||
int amount = 1 + rand.nextInt(2);
|
||||
for(int i = 0; i < amount; i++) crate.items.add(ItemPool.getStack(ItemPoolsC130.POOL_WEAPONS, this.rand));
|
||||
for(int i = 0; i < 6; i++) crate.items.add(ItemPool.getStack(ItemPoolsC130.POOL_AMMO, this.rand));
|
||||
}
|
||||
|
||||
worldObj.spawnEntityInWorld(crate);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void readEntityFromNBT(NBTTagCompound nbt) {
|
||||
super.readEntityFromNBT(nbt);
|
||||
this.payload = EnumUtil.grabEnumSafely(C130PayloadType.class, nbt.getInteger("payload"));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void writeEntityToNBT(NBTTagCompound nbt) {
|
||||
super.writeEntityToNBT(nbt);
|
||||
nbt.setInteger("payload", this.payload.ordinal());
|
||||
}
|
||||
|
||||
public void fac(World world, double x, double y, double z, C130PayloadType payload) {
|
||||
|
||||
Vec3 vector = Vec3.createVectorHelper(world.rand.nextDouble() - 0.5, 0, world.rand.nextDouble() - 0.5);
|
||||
vector = vector.normalize();
|
||||
vector.xCoord *= 2;
|
||||
vector.zCoord *= 2;
|
||||
|
||||
this.payload = payload;
|
||||
|
||||
this.setLocationAndAngles(x - vector.xCoord * 100, y + 100, z - vector.zCoord * 100, 0.0F, 0.0F);
|
||||
this.loadNeighboringChunks((int) (x / 16), (int) (z / 16));
|
||||
|
||||
this.motionX = vector.xCoord;
|
||||
this.motionZ = vector.zCoord;
|
||||
this.motionY = 0.0D;
|
||||
|
||||
this.rotation();
|
||||
}
|
||||
|
||||
public static enum C130PayloadType {
|
||||
SUPPLIES,
|
||||
WEAPONS,
|
||||
A_FUCKING_FUEL_TRUCK
|
||||
}
|
||||
}
|
||||
151
src/main/java/com/hbm/entity/logic/EntityPlaneBase.java
Normal file
151
src/main/java/com/hbm/entity/logic/EntityPlaneBase.java
Normal file
@ -0,0 +1,151 @@
|
||||
package com.hbm.entity.logic;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import com.hbm.explosion.vanillant.ExplosionVNT;
|
||||
import com.hbm.lib.ModDamageSource;
|
||||
import com.hbm.main.MainRegistry;
|
||||
import com.hbm.particle.helper.ExplosionSmallCreator;
|
||||
import com.hbm.util.ParticleUtil;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.world.ChunkCoordIntPair;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeChunkManager;
|
||||
import net.minecraftforge.common.ForgeChunkManager.Ticket;
|
||||
import net.minecraftforge.common.ForgeChunkManager.Type;
|
||||
|
||||
public abstract class EntityPlaneBase extends Entity implements IChunkLoader {
|
||||
|
||||
private Ticket loaderTicket;
|
||||
private List<ChunkCoordIntPair> loadedChunks = new ArrayList<ChunkCoordIntPair>();
|
||||
|
||||
public float health = getMaxHealth();
|
||||
public int timer = getLifetime();
|
||||
|
||||
public EntityPlaneBase(World world) { super(world); }
|
||||
|
||||
public float getMaxHealth() { return 50F; }
|
||||
public int getLifetime() { return 200; }
|
||||
|
||||
@Override public boolean canBeCollidedWith() { return this.health > 0; }
|
||||
|
||||
@Override
|
||||
public boolean attackEntityFrom(DamageSource source, float amount) {
|
||||
if(source == ModDamageSource.nuclearBlast) return false;
|
||||
if(this.isEntityInvulnerable()) return false;
|
||||
if(!this.isDead && !this.worldObj.isRemote && this.health > 0) {
|
||||
health -= amount;
|
||||
if(this.health <= 0) this.killPlane();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
protected void killPlane() {
|
||||
ExplosionSmallCreator.composeEffect(worldObj, posX, posY, posZ, 25, 3.5F, 2F);
|
||||
worldObj.playSoundEffect(posX, posY, posZ, "hbm:entity.planeShotDown", 25.0F, 1.0F);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void entityInit() {
|
||||
init(ForgeChunkManager.requestTicket(MainRegistry.instance, worldObj, Type.ENTITY));
|
||||
this.dataWatcher.addObject(17, new Float(50F));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void init(Ticket ticket) {
|
||||
if(!worldObj.isRemote && ticket != null) {
|
||||
if(loaderTicket == null) {
|
||||
loaderTicket = ticket;
|
||||
loaderTicket.bindEntity(this);
|
||||
loaderTicket.getModData();
|
||||
}
|
||||
ForgeChunkManager.forceChunk(loaderTicket, new ChunkCoordIntPair(chunkCoordX, chunkCoordZ));
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUpdate() {
|
||||
|
||||
this.lastTickPosX = this.prevPosX = posX;
|
||||
this.lastTickPosY = this.prevPosY = posY;
|
||||
this.lastTickPosZ = this.prevPosZ = posZ;
|
||||
this.setPosition(posX + motionX, posY + motionY, posZ + motionZ);
|
||||
|
||||
if(!worldObj.isRemote) {
|
||||
this.dataWatcher.updateObject(17, health);
|
||||
} else {
|
||||
health = this.dataWatcher.getWatchableObjectFloat(17);
|
||||
}
|
||||
|
||||
this.rotation();
|
||||
|
||||
if(this.health <= 0) {
|
||||
motionY -= 0.025;
|
||||
|
||||
for(int i = 0; i < 10; i++) ParticleUtil.spawnGasFlame(this.worldObj, this.posX + rand.nextGaussian() * 0.5 - motionX * 2, this.posY + rand.nextGaussian() * 0.5 - motionY * 2, this.posZ + rand.nextGaussian() * 0.5 - motionZ * 2, 0.0, 0.1, 0.0);
|
||||
|
||||
if((!worldObj.getBlock((int) posX, (int) posY, (int) posZ).isAir(worldObj, (int) posX, (int) posY, (int) posZ) || posY < 0) && !worldObj.isRemote) {
|
||||
this.setDead();
|
||||
new ExplosionVNT(worldObj, posX, posY, posZ, 15F).makeStandard().explode();
|
||||
worldObj.playSoundEffect(posX, posY, posZ, "hbm:entity.planeCrash", 25.0F, 1.0F);
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
this.motionY = 0F;
|
||||
}
|
||||
|
||||
if(this.ticksExisted > timer) this.setDead();
|
||||
if(!worldObj.isRemote) loadNeighboringChunks((int)Math.floor(posX / 16D), (int)Math.floor(posZ / 16D));
|
||||
}
|
||||
|
||||
protected void rotation() {
|
||||
float motionHorizontal = MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ);
|
||||
this.rotationYaw = (float) (Math.atan2(this.motionX, this.motionZ) * 180.0D / Math.PI);
|
||||
for(this.rotationPitch = (float) (Math.atan2(this.motionY, motionHorizontal) * 180.0D / Math.PI) - 90; this.rotationPitch - this.prevRotationPitch < -180.0F; this.prevRotationPitch -= 360.0F);
|
||||
while(this.rotationPitch - this.prevRotationPitch >= 180.0F) this.prevRotationPitch += 360.0F;
|
||||
while(this.rotationYaw - this.prevRotationYaw < -180.0F) this.prevRotationYaw -= 360.0F;
|
||||
while(this.rotationYaw - this.prevRotationYaw >= 180.0F) this.prevRotationYaw += 360.0F;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setDead() {
|
||||
super.setDead();
|
||||
this.clearChunkLoader();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void readEntityFromNBT(NBTTagCompound nbt) {
|
||||
ticksExisted = nbt.getInteger("ticksExisted");
|
||||
this.getDataWatcher().updateObject(17, nbt.getFloat("health"));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void writeEntityToNBT(NBTTagCompound nbt) {
|
||||
nbt.setInteger("ticksExisted", ticksExisted);
|
||||
nbt.setFloat("health", this.getDataWatcher().getWatchableObjectFloat(17));
|
||||
}
|
||||
|
||||
public void clearChunkLoader() {
|
||||
if(!worldObj.isRemote && loaderTicket != null) {
|
||||
for(ChunkCoordIntPair chunk : loadedChunks) ForgeChunkManager.unforceChunk(loaderTicket, chunk);
|
||||
}
|
||||
}
|
||||
|
||||
public void loadNeighboringChunks(int newChunkX, int newChunkZ) {
|
||||
if(!worldObj.isRemote && loaderTicket != null) {
|
||||
clearChunkLoader();
|
||||
loadedChunks.clear();
|
||||
loadedChunks.add(new ChunkCoordIntPair(newChunkX, newChunkZ));
|
||||
for(ChunkCoordIntPair chunk : loadedChunks) ForgeChunkManager.forceChunk(loaderTicket, chunk);
|
||||
}
|
||||
}
|
||||
|
||||
@Override @SideOnly(Side.CLIENT) public boolean isInRangeToRenderDist(double distance) { return true; }
|
||||
}
|
||||
34
src/main/java/com/hbm/entity/mob/EntityDummy.java
Normal file
34
src/main/java/com/hbm/entity/mob/EntityDummy.java
Normal file
@ -0,0 +1,34 @@
|
||||
package com.hbm.entity.mob;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.entity.EntityLiving;
|
||||
import net.minecraft.entity.passive.IAnimals;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemArmor;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class EntityDummy extends EntityLiving implements IAnimals {
|
||||
|
||||
public EntityDummy(World world) {
|
||||
super(world);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean interact(EntityPlayer player) {
|
||||
|
||||
if(player.getHeldItem() != null && player.getHeldItem().getItem() instanceof ItemArmor) {
|
||||
ItemArmor armor = (ItemArmor) player.getHeldItem().getItem();
|
||||
this.setCurrentItemOrArmor(4 - armor.armorType, player.getHeldItem().copy());
|
||||
}
|
||||
|
||||
return super.interact(player);
|
||||
}
|
||||
|
||||
@Override @SideOnly(Side.CLIENT) public boolean getAlwaysRenderNameTagForRender() { return true; }
|
||||
@Override public String getCommandSenderName() {
|
||||
return (int) (this.getHealth() * 10) / 10F + " / " + (int) (this.getMaxHealth() * 10) / 10F; }
|
||||
//return (int) this.rotationYaw + " " + (int) this.renderYawOffset + " " + (int) this.rotationYawHead + " " + (int) this.newRotationYaw; }
|
||||
|
||||
@Override protected void dropEquipment(boolean b, int i) { }
|
||||
}
|
||||
@ -5,6 +5,8 @@ import com.hbm.util.BobMathUtil;
|
||||
import com.hbm.util.TrackerUtil;
|
||||
import com.hbm.util.Vec3NT;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.EntityTrackerEntry;
|
||||
@ -29,6 +31,7 @@ public class EntityBulletBaseMK4 extends EntityThrowableInterp {
|
||||
super(world);
|
||||
this.renderDistanceWeight = 10.0D;
|
||||
this.setSize(0.5F, 0.5F);
|
||||
this.isImmuneToFire = true;
|
||||
}
|
||||
|
||||
public EntityBulletBaseMK4(EntityLivingBase entity, BulletConfig config, float baseDamage, float gunSpread, double sideOffset, double heightOffset, double frontOffset) {
|
||||
@ -61,6 +64,22 @@ public class EntityBulletBaseMK4 extends EntityThrowableInterp {
|
||||
|
||||
this.setThrowableHeading(this.motionX, this.motionY, this.motionZ, 1.0F, this.config.spread + gunSpread);
|
||||
}
|
||||
|
||||
/** For turrets - angles are in radians, andp itch is negative! */
|
||||
public EntityBulletBaseMK4(World world, BulletConfig config, float baseDamage, float gunSpread, float yaw, float pitch) {
|
||||
this(world);
|
||||
|
||||
this.setBulletConfig(config);
|
||||
this.damage = baseDamage * this.config.damageMult;
|
||||
|
||||
this.prevRotationYaw = this.rotationYaw = yaw * 180F / (float) Math.PI;
|
||||
this.prevRotationPitch = this.rotationPitch = -pitch * 180F / (float) Math.PI;
|
||||
|
||||
this.motionX = -MathHelper.sin(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI);
|
||||
this.motionZ = MathHelper.cos(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI);
|
||||
this.motionY = (-MathHelper.sin(this.rotationPitch / 180.0F * (float) Math.PI));
|
||||
this.setThrowableHeading(this.motionX, this.motionY, this.motionZ, 1.0F, this.config.spread + gunSpread);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void entityInit() {
|
||||
@ -165,4 +184,6 @@ public class EntityBulletBaseMK4 extends EntityThrowableInterp {
|
||||
@Override public boolean doesPenetrate() { return this.config.doesPenetrate; }
|
||||
@Override public boolean isSpectral() { return this.config.isSpectral; }
|
||||
@Override public int selfDamageDelay() { return this.config.selfDamageDelay; }
|
||||
|
||||
@Override @SideOnly(Side.CLIENT) public boolean canRenderOnFire() { return false; }
|
||||
}
|
||||
|
||||
@ -0,0 +1,81 @@
|
||||
package com.hbm.entity.projectile;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import com.hbm.entity.logic.IChunkLoader;
|
||||
import com.hbm.items.weapon.sedna.BulletConfig;
|
||||
import com.hbm.main.MainRegistry;
|
||||
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.world.ChunkCoordIntPair;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeChunkManager;
|
||||
import net.minecraftforge.common.ForgeChunkManager.Ticket;
|
||||
import net.minecraftforge.common.ForgeChunkManager.Type;
|
||||
|
||||
public class EntityBulletBaseMK4CL extends EntityBulletBaseMK4 implements IChunkLoader {
|
||||
|
||||
private Ticket loaderTicket;
|
||||
private List<ChunkCoordIntPair> loadedChunks = new ArrayList<ChunkCoordIntPair>();
|
||||
|
||||
public EntityBulletBaseMK4CL(World world) {
|
||||
super(world);
|
||||
}
|
||||
|
||||
public EntityBulletBaseMK4CL(EntityLivingBase entity, BulletConfig config, float damage, float spread, double sideOffset, double heightOffset, double forwardOffset) {
|
||||
super(entity, config, damage, spread, sideOffset, heightOffset, forwardOffset);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void entityInit() {
|
||||
super.entityInit();
|
||||
init(ForgeChunkManager.requestTicket(MainRegistry.instance, worldObj, Type.ENTITY));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void init(Ticket ticket) {
|
||||
if(!worldObj.isRemote && ticket != null) {
|
||||
if(loaderTicket == null) {
|
||||
loaderTicket = ticket;
|
||||
loaderTicket.bindEntity(this);
|
||||
loaderTicket.getModData();
|
||||
}
|
||||
ForgeChunkManager.forceChunk(loaderTicket, new ChunkCoordIntPair(chunkCoordX, chunkCoordZ));
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUpdate() {
|
||||
super.onUpdate();
|
||||
|
||||
if(!worldObj.isRemote) loadNeighboringChunks((int)Math.floor(posX / 16D), (int)Math.floor(posZ / 16D));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setDead() {
|
||||
super.setDead();
|
||||
clearChunkLoader();
|
||||
}
|
||||
|
||||
public void clearChunkLoader() {
|
||||
if(!worldObj.isRemote && loaderTicket != null) {
|
||||
for(ChunkCoordIntPair chunk : loadedChunks) {
|
||||
ForgeChunkManager.unforceChunk(loaderTicket, chunk);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void loadNeighboringChunks(int newChunkX, int newChunkZ) {
|
||||
if(!worldObj.isRemote && loaderTicket != null) {
|
||||
|
||||
clearChunkLoader();
|
||||
loadedChunks.clear();
|
||||
loadedChunks.add(new ChunkCoordIntPair(newChunkX, newChunkZ));
|
||||
|
||||
for(ChunkCoordIntPair chunk : loadedChunks) {
|
||||
ForgeChunkManager.forceChunk(loaderTicket, chunk);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -33,6 +33,7 @@ public class EntityBulletBeamBase extends Entity implements IEntityAdditionalSpa
|
||||
this.ignoreFrustumCheck = true;
|
||||
this.renderDistanceWeight = 10.0D;
|
||||
this.setSize(0.5F, 0.5F);
|
||||
this.isImmuneToFire = true;
|
||||
}
|
||||
|
||||
public EntityLivingBase getThrower() { return this.thrower; }
|
||||
@ -61,7 +62,7 @@ public class EntityBulletBeamBase extends Entity implements IEntityAdditionalSpa
|
||||
this.headingZ = (double) (MathHelper.cos(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI));
|
||||
this.headingY = (double) (-MathHelper.sin((this.rotationPitch) / 180.0F * (float) Math.PI));
|
||||
|
||||
double range = 150D;
|
||||
double range = 250D;
|
||||
this.headingX *= range;
|
||||
this.headingY *= range;
|
||||
this.headingZ *= range;
|
||||
@ -95,6 +96,8 @@ public class EntityBulletBeamBase extends Entity implements IEntityAdditionalSpa
|
||||
return;
|
||||
}
|
||||
|
||||
if(config.onUpdate != null) config.onUpdate.accept(this);
|
||||
|
||||
super.onUpdate();
|
||||
|
||||
if(!worldObj.isRemote && this.ticksExisted > config.expires) this.setDead();
|
||||
@ -196,4 +199,6 @@ public class EntityBulletBeamBase extends Entity implements IEntityAdditionalSpa
|
||||
this.rotationYaw = buf.readFloat();
|
||||
this.rotationPitch = buf.readFloat();
|
||||
}
|
||||
|
||||
@Override @SideOnly(Side.CLIENT) public boolean canRenderOnFire() { return false; }
|
||||
}
|
||||
|
||||
@ -193,7 +193,7 @@ public abstract class EntityThrowableNT extends Entity implements IProjectile {
|
||||
for(int j = 0; j < list.size(); ++j) {
|
||||
Entity entity = (Entity) list.get(j);
|
||||
|
||||
if(entity.canBeCollidedWith() && (entity != thrower || this.ticksInAir >= this.selfDamageDelay())) {
|
||||
if(entity.canBeCollidedWith() && (entity != thrower || this.ticksInAir >= this.selfDamageDelay()) && entity.isEntityAlive()) {
|
||||
double hitbox = 0.3F;
|
||||
AxisAlignedBB aabb = entity.boundingBox.expand(hitbox, hitbox, hitbox);
|
||||
MovingObjectPosition hitMop = aabb.calculateIntercept(pos, nextPos);
|
||||
|
||||
@ -4,6 +4,7 @@ import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map.Entry;
|
||||
|
||||
import com.hbm.entity.projectile.EntityBulletBaseMK4;
|
||||
import com.hbm.explosion.vanillant.ExplosionVNT;
|
||||
import com.hbm.explosion.vanillant.interfaces.ICustomDamageHandler;
|
||||
import com.hbm.explosion.vanillant.interfaces.IEntityProcessor;
|
||||
@ -96,9 +97,11 @@ public class EntityProcessorCross implements IEntityProcessor {
|
||||
if(!damageMap.containsKey(entity) || damageMap.get(entity) < dmg) damageMap.put(entity, dmg);
|
||||
double enchKnockback = EnchantmentProtection.func_92092_a(entity, knockback);
|
||||
|
||||
entity.motionX += deltaX * enchKnockback;
|
||||
entity.motionY += deltaY * enchKnockback;
|
||||
entity.motionZ += deltaZ * enchKnockback;
|
||||
if(!(entity instanceof EntityBulletBaseMK4)) {
|
||||
entity.motionX += deltaX * enchKnockback;
|
||||
entity.motionY += deltaY * enchKnockback;
|
||||
entity.motionZ += deltaZ * enchKnockback;
|
||||
}
|
||||
|
||||
if(entity instanceof EntityPlayer) {
|
||||
affectedPlayers.put((EntityPlayer) entity, Vec3.createVectorHelper(deltaX * knockback, deltaY * knockback, deltaZ * knockback));
|
||||
@ -110,7 +113,7 @@ public class EntityProcessorCross implements IEntityProcessor {
|
||||
for(Entry<Entity, Float> entry : damageMap.entrySet()) {
|
||||
|
||||
Entity entity = entry.getKey();
|
||||
entity.attackEntityFrom(setExplosionSource(explosion.compat), entry.getValue());
|
||||
attackEntity(entity, explosion, entry.getValue());
|
||||
|
||||
if(damage != null) {
|
||||
double distanceScaled = entity.getDistance(x, y, z) / size;
|
||||
@ -121,6 +124,10 @@ public class EntityProcessorCross implements IEntityProcessor {
|
||||
return affectedPlayers;
|
||||
}
|
||||
|
||||
public void attackEntity(Entity entity, ExplosionVNT source, float amount) {
|
||||
entity.attackEntityFrom(setExplosionSource(source.compat), amount);
|
||||
}
|
||||
|
||||
public float calculateDamage(double distanceScaled, double density, double knockback, float size) {
|
||||
return (float) ((int) ((knockback * knockback + knockback) / 2.0D * 8.0D * size + 1.0D));
|
||||
}
|
||||
|
||||
@ -1,14 +1,51 @@
|
||||
package com.hbm.explosion.vanillant.standard;
|
||||
|
||||
import com.hbm.explosion.vanillant.ExplosionVNT;
|
||||
import com.hbm.items.weapon.sedna.BulletConfig;
|
||||
import com.hbm.items.weapon.sedna.factory.ConfettiUtil;
|
||||
import com.hbm.util.EntityDamageUtil;
|
||||
import com.hbm.util.DamageResistanceHandler.DamageClass;
|
||||
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.util.DamageSource;
|
||||
|
||||
public class EntityProcessorCrossSmooth extends EntityProcessorCross {
|
||||
|
||||
protected float fixedDamage;
|
||||
protected float pierceDT = 0;
|
||||
protected float pierceDR = 0;
|
||||
protected DamageClass clazz = DamageClass.EXPLOSIVE;
|
||||
|
||||
public EntityProcessorCrossSmooth(double nodeDist, float fixedDamage) {
|
||||
super(nodeDist);
|
||||
this.fixedDamage = fixedDamage;
|
||||
}
|
||||
|
||||
public EntityProcessorCrossSmooth setupPiercing(float pierceDT, float pierceDR) {
|
||||
this.pierceDT = pierceDT;
|
||||
this.pierceDR = pierceDR;
|
||||
return this;
|
||||
}
|
||||
|
||||
public EntityProcessorCrossSmooth setDamageClass(DamageClass clazz) {
|
||||
this.clazz = clazz;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void attackEntity(Entity entity, ExplosionVNT source, float amount) {
|
||||
if(!entity.isEntityAlive()) return;
|
||||
DamageSource dmg = BulletConfig.getDamage(null, source.exploder instanceof EntityLivingBase ? (EntityLivingBase) source.exploder : null, clazz);
|
||||
if(!(entity instanceof EntityLivingBase)) {
|
||||
entity.attackEntityFrom(dmg, amount);
|
||||
} else {
|
||||
EntityDamageUtil.attackEntityFromNT((EntityLivingBase) entity, dmg, amount, true, false, 0F, pierceDT, pierceDR);
|
||||
if(!entity.isEntityAlive()) ConfettiUtil.decideConfetti((EntityLivingBase) entity, dmg);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public float calculateDamage(double distanceScaled, double density, double knockback, float size) {
|
||||
return (float) (fixedDamage * (1 - distanceScaled));
|
||||
}
|
||||
|
||||
@ -48,6 +48,7 @@ public class HbmLivingProps implements IExtendedEntityProperties {
|
||||
private int contagion;
|
||||
private int oil;
|
||||
public int fire;
|
||||
public int phosphorus;
|
||||
public int balefire;
|
||||
private List<ContaminationEffect> contamination = new ArrayList();
|
||||
|
||||
@ -316,6 +317,7 @@ public class HbmLivingProps implements IExtendedEntityProperties {
|
||||
props.setInteger("hfr_blacklung", blacklung);
|
||||
props.setInteger("hfr_oil", oil);
|
||||
props.setInteger("hfr_fire", fire);
|
||||
props.setInteger("hfr_phosphorus", phosphorus);
|
||||
props.setInteger("hfr_balefire", balefire);
|
||||
|
||||
props.setInteger("hfr_cont_count", this.contamination.size());
|
||||
@ -342,6 +344,7 @@ public class HbmLivingProps implements IExtendedEntityProperties {
|
||||
blacklung = props.getInteger("hfr_blacklung");
|
||||
oil = props.getInteger("hfr_oil");
|
||||
fire = props.getInteger("hfr_fire");
|
||||
phosphorus = props.getInteger("hfr_phosphorus");
|
||||
balefire = props.getInteger("hfr_balefire");
|
||||
|
||||
int cont = props.getInteger("hfr_cont_count");
|
||||
|
||||
@ -18,6 +18,7 @@ import com.hbm.handler.pollution.PollutionHandler.PollutionType;
|
||||
import com.hbm.handler.radiation.ChunkRadiationManager;
|
||||
import com.hbm.interfaces.IArmorModDash;
|
||||
import com.hbm.items.armor.ArmorFSB;
|
||||
import com.hbm.items.weapon.sedna.factory.ConfettiUtil;
|
||||
import com.hbm.lib.ModDamageSource;
|
||||
import com.hbm.main.MainRegistry;
|
||||
import com.hbm.packet.PacketDispatcher;
|
||||
@ -574,7 +575,12 @@ public class EntityEffectHandler {
|
||||
HbmLivingProps props = HbmLivingProps.getData(living);
|
||||
Random rand = living.getRNG();
|
||||
|
||||
if(living.isImmuneToFire()) props.fire = 0;
|
||||
if(!entity.isEntityAlive()) return;
|
||||
|
||||
if(living.isImmuneToFire()) {
|
||||
props.fire = 0;
|
||||
props.phosphorus = 0;
|
||||
}
|
||||
|
||||
double x = living.posX;
|
||||
double y = living.posY;
|
||||
@ -589,6 +595,13 @@ public class EntityEffectHandler {
|
||||
FlameCreator.composeEffect(entity.worldObj, x - living.width / 2 + living.width * rand.nextDouble(), y + rand.nextDouble() * living.height, z - living.width / 2 + living.width * rand.nextDouble(), FlameCreator.META_FIRE);
|
||||
}
|
||||
|
||||
if(props.phosphorus > 0) {
|
||||
props.phosphorus--;
|
||||
if((living.ticksExisted + living.getEntityId()) % 15 == 0) living.worldObj.playSoundEffect(living.posX, living.posY + living.height / 2, living.posZ, "random.fizz", 1F, 1.5F + rand.nextFloat() * 0.5F);
|
||||
if((living.ticksExisted + living.getEntityId()) % 40 == 0) living.attackEntityFrom(DamageSource.onFire, 5F);
|
||||
FlameCreator.composeEffect(entity.worldObj, x - living.width / 2 + living.width * rand.nextDouble(), y + rand.nextDouble() * living.height, z - living.width / 2 + living.width * rand.nextDouble(), FlameCreator.META_FIRE);
|
||||
}
|
||||
|
||||
if(props.balefire > 0) {
|
||||
props.balefire--;
|
||||
if((living.ticksExisted + living.getEntityId()) % 15 == 0) living.worldObj.playSoundEffect(living.posX, living.posY + living.height / 2, living.posZ, "random.fizz", 1F, 1.5F + rand.nextFloat() * 0.5F);
|
||||
@ -596,6 +609,8 @@ public class EntityEffectHandler {
|
||||
if((living.ticksExisted + living.getEntityId()) % 20 == 0) living.attackEntityFrom(DamageSource.onFire, 5F);
|
||||
FlameCreator.composeEffect(entity.worldObj, x - living.width / 2 + living.width * rand.nextDouble(), y + rand.nextDouble() * living.height, z - living.width / 2 + living.width * rand.nextDouble(), FlameCreator.META_BALEFIRE);
|
||||
}
|
||||
|
||||
if(props.fire > 0 || props.phosphorus > 0 || props.balefire > 0) if(!entity.isEntityAlive()) ConfettiUtil.decideConfetti(living, DamageSource.onFire);
|
||||
}
|
||||
|
||||
private static void handleDashing(Entity entity) {
|
||||
|
||||
@ -9,13 +9,11 @@ import com.hbm.handler.GunConfiguration;
|
||||
import com.hbm.inventory.RecipesCommon.ComparableStack;
|
||||
import com.hbm.items.ItemAmmoEnums.AmmoDart;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.weapon.ItemGunDart;
|
||||
import com.hbm.items.weapon.sedna.Crosshair;
|
||||
import com.hbm.lib.HbmCollection.EnumGunManufacturer;
|
||||
import com.hbm.main.MainRegistry;
|
||||
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.potion.Potion;
|
||||
import net.minecraft.potion.PotionEffect;
|
||||
|
||||
@ -100,28 +98,6 @@ public class GunDartFactory {
|
||||
bullet.effects = new ArrayList();
|
||||
bullet.effects.add(new PotionEffect(Potion.wither.id, 60 * 20, 2));
|
||||
|
||||
bullet.bntHurt = (bulletnt, hit) -> {
|
||||
|
||||
if(bulletnt.worldObj.isRemote)
|
||||
return;
|
||||
|
||||
if(hit instanceof EntityPlayer) {
|
||||
|
||||
if(((EntityPlayer) hit).inventory.hasItem(ModItems.ingot_meteorite_forged))
|
||||
return;
|
||||
|
||||
if(bulletnt.getThrower() instanceof EntityPlayer) {
|
||||
|
||||
EntityPlayer shooter = (EntityPlayer) bulletnt.getThrower();
|
||||
|
||||
if(shooter.getHeldItem() != null && shooter.getHeldItem().getItem() == ModItems.gun_darter) {
|
||||
ItemGunDart.writePlayer(shooter.getHeldItem(), (EntityPlayer) hit);
|
||||
shooter.playSound("random.orb", 1.0F, 1.0F);
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
return bullet;
|
||||
}
|
||||
|
||||
|
||||
16
src/main/java/com/hbm/handler/nei/AmmoPressHandler.java
Normal file
16
src/main/java/com/hbm/handler/nei/AmmoPressHandler.java
Normal file
@ -0,0 +1,16 @@
|
||||
package com.hbm.handler.nei;
|
||||
|
||||
import com.hbm.blocks.ModBlocks;
|
||||
import com.hbm.inventory.recipes.AmmoPressRecipes;
|
||||
|
||||
public class AmmoPressHandler extends NEIUniversalHandler {
|
||||
|
||||
public AmmoPressHandler() {
|
||||
super(ModBlocks.machine_ammo_press.getLocalizedName(), ModBlocks.machine_ammo_press, AmmoPressRecipes.getRecipes());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getKey() {
|
||||
return "ntmAmmoPress";
|
||||
}
|
||||
}
|
||||
@ -546,15 +546,15 @@ public class OreDictManager {
|
||||
|
||||
for(NTMMaterial mat : Mats.orderedList) {
|
||||
if(mat.smeltable == SmeltingBehavior.SMELTABLE) {
|
||||
if(mat.autogen.contains(MaterialShapes.BOLT)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.BOLT.name() + name, new ItemStack(ModItems.bolt, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.INGOT)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.INGOT.name() + name, new ItemStack(ModItems.ingot_raw, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.CASTPLATE)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.CASTPLATE.name() + name, new ItemStack(ModItems.plate_cast, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.WELDEDPLATE)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.WELDEDPLATE.name() + name, new ItemStack(ModItems.plate_welded, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.HEAVY_COMPONENT)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.HEAVY_COMPONENT.name() + name, new ItemStack(ModItems.heavy_component, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.DENSEWIRE)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.DENSEWIRE.name() + name, new ItemStack(ModItems.wire_dense, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.SHELL)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.SHELL.name() + name, new ItemStack(ModItems.shell, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.PIPE)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.PIPE.name() + name, new ItemStack(ModItems.pipe, 1, mat.id));
|
||||
}
|
||||
if(mat.autogen.contains(MaterialShapes.BOLT)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.BOLT.name() + name, new ItemStack(ModItems.bolt, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.INGOT)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.INGOT.name() + name, new ItemStack(ModItems.ingot_raw, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.SHELL)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.SHELL.name() + name, new ItemStack(ModItems.shell, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.PIPE)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.PIPE.name() + name, new ItemStack(ModItems.pipe, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.FRAGMENT)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.FRAGMENT.name() + name, new ItemStack(ModItems.bedrock_ore_fragment, 1, mat.id));
|
||||
if(mat.autogen.contains(MaterialShapes.WIRE)) for(String name : mat.names) OreDictionary.registerOre(MaterialShapes.WIRE.name() + name, new ItemStack(ModItems.wire_fine, 1, mat.id));
|
||||
|
||||
@ -674,10 +674,11 @@ public class OreDictManager {
|
||||
|
||||
public static void registerGroups() {
|
||||
ANY_RUBBER.addPrefix(INGOT, true);
|
||||
ANY_PLASTIC.addPrefix(INGOT, true).addPrefix(DUST, true).addPrefix(BLOCK, true);
|
||||
ANY_HARDPLASTIC.addPrefix(INGOT, true);
|
||||
ANY_RESISTANTALLOY.addPrefix(INGOT, true).addPrefix(DUST, true).addPrefix(CASTPLATE, true).addPrefix(WELDEDPLATE, true).addPrefix(HEAVY_COMPONENT, true).addPrefix(BLOCK, true);
|
||||
ANY_BISMOIDBRONZE.addPrefix(INGOT, true).addPrefix(CASTPLATE, true);
|
||||
ANY_PLASTIC.addPrefix(INGOT, true).addPrefix(DUST, true).addPrefix(BLOCK, true).addPrefix(GRIP, true).addPrefix(STOCK, true);
|
||||
ANY_HARDPLASTIC.addPrefix(INGOT, true).addPrefix(STOCK, true).addPrefix(GRIP, true);
|
||||
ANY_RESISTANTALLOY.addPrefix(INGOT, true).addPrefix(DUST, true).addPrefix(CASTPLATE, true).addPrefix(WELDEDPLATE, true).addPrefix(HEAVY_COMPONENT, true).addPrefix(BLOCK, true)
|
||||
.addPrefix(LIGHTBARREL, true).addPrefix(HEAVYBARREL, true).addPrefix(LIGHTRECEIVER, true).addPrefix(HEAVYRECEIVER, true);
|
||||
ANY_BISMOIDBRONZE.addPrefix(INGOT, true).addPrefix(CASTPLATE, true).addPrefix(LIGHTBARREL, true).addPrefix(HEAVYBARREL, true).addPrefix(LIGHTRECEIVER, true).addPrefix(HEAVYRECEIVER, true);
|
||||
ANY_TAR.addPrefix(ANY, false);
|
||||
}
|
||||
|
||||
@ -685,9 +686,7 @@ public class OreDictManager {
|
||||
|
||||
@SubscribeEvent
|
||||
public void onRegisterOre(OreRegisterEvent event) {
|
||||
|
||||
if(recursionBrake)
|
||||
return;
|
||||
if(recursionBrake) return;
|
||||
|
||||
recursionBrake = true;
|
||||
|
||||
@ -1016,6 +1015,13 @@ public class OreDictManager {
|
||||
public String billet() { return BILLET.name() + groupName; }
|
||||
public String block() { return BLOCK.name() + groupName; }
|
||||
public String ore() { return ORE.name() + groupName; }
|
||||
public String lightBarrel() { return LIGHTBARREL.name() + groupName; }
|
||||
public String heavyBarrel() { return HEAVYBARREL.name() + groupName; }
|
||||
public String lightReceiver() { return LIGHTRECEIVER.name() + groupName; }
|
||||
public String heavyReceiver() { return HEAVYRECEIVER.name() + groupName; }
|
||||
public String mechanism() { return MECHANISM.name() + groupName; }
|
||||
public String stock() { return STOCK.name() + groupName; }
|
||||
public String grip() { return GRIP.name() + groupName; }
|
||||
}
|
||||
|
||||
private static void addReRegistration(String original, String additional) {
|
||||
|
||||
@ -307,8 +307,8 @@ public class Fluids {
|
||||
NAPHTHA_CRACK = new FluidType("NAPHTHA_CRACK", 0x595744, 2, 1, 0, EnumSymbol.NONE).addContainers(new CD_Canister(0x5F6D44)).addTraits(new FT_Flammable(125_000), new FT_Combustible(FuelGrade.MEDIUM, 200_000), LIQUID, VISCOUS, P_FUEL);
|
||||
LIGHTOIL_CRACK = new FluidType("LIGHTOIL_CRACK", 0x8c7451, 1, 2, 0, EnumSymbol.NONE).addContainers(new CD_Canister(0xB46B52)).addTraits(new FT_Flammable(200_000), new FT_Combustible(FuelGrade.MEDIUM, 500_000), LIQUID, P_FUEL);
|
||||
DIESEL_CRACK = new FluidType("DIESEL_CRACK", 0xf2eed5, 1, 2, 0, EnumSymbol.NONE).addContainers(new CD_Canister(0xFF2C2C)).addTraits(new FT_Flammable(200_000), new FT_Combustible(FuelGrade.HIGH, 450_000), LIQUID, P_FUEL);
|
||||
AROMATICS = new FluidType("AROMATICS", 0x68A09A, 1, 4, 1, EnumSymbol.NONE).addTraits(new FT_Flammable(25_000), LIQUID, VISCOUS, P_GAS);
|
||||
UNSATURATEDS = new FluidType("UNSATURATEDS", 0x628FAE, 1, 4, 1, EnumSymbol.NONE).addTraits(new FT_Flammable(1_000_000), GASEOUS, P_GAS); //acetylene burns as hot as satan's asshole
|
||||
AROMATICS = new FluidType("AROMATICS", 0x68A09A, 1, 4, 1, EnumSymbol.NONE).addContainers(new CD_Gastank(0x68A09A, 0xEDCF27)).addTraits(new FT_Flammable(25_000), LIQUID, VISCOUS, P_GAS);
|
||||
UNSATURATEDS = new FluidType("UNSATURATEDS", 0x628FAE, 1, 4, 1, EnumSymbol.NONE).addContainers(new CD_Gastank(0x628FAE, 0xEDCF27)).addTraits(new FT_Flammable(1_000_000), GASEOUS, P_GAS); //acetylene burns as hot as satan's asshole
|
||||
SALIENT = new FluidType("SALIENT", 0x457F2D, 0, 0, 0, EnumSymbol.NONE).addTraits(DELICIOUS, LIQUID, VISCOUS);
|
||||
XPJUICE = new FluidType("XPJUICE", 0xBBFF09, 0, 0, 0, EnumSymbol.NONE).addTraits(LIQUID, VISCOUS);
|
||||
ENDERJUICE = new FluidType("ENDERJUICE", 0x127766, 0, 0, 0, EnumSymbol.NONE).addTraits(LIQUID);
|
||||
|
||||
@ -282,7 +282,9 @@ public class GUIMachineAmmoPress extends GuiInfoContainer {
|
||||
GL11.glDisable(GL11.GL_BLEND);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
RenderHelper.disableStandardItemLighting();
|
||||
GL11.glColor4f(1F, 1F, 1F, 1F);
|
||||
this.search.drawTextBox();
|
||||
}
|
||||
|
||||
|
||||
@ -137,13 +137,13 @@ public class Mats {
|
||||
public static final NTMMaterial MAT_MINGRADE = makeSmeltable(_AS + 1, MINGRADE, 0xFFBA7D, 0xAF1700, 0xE44C0F).setAutogen(WIRE, DUST, BLOCK).m();
|
||||
public static final NTMMaterial MAT_ALLOY = makeSmeltable(_AS + 2, ALLOY, 0xFF8330, 0x700000, 0xFF7318).setAutogen(WIRE, DUST, DENSEWIRE, PLATE, CASTPLATE, BLOCK, HEAVY_COMPONENT).m();
|
||||
public static final NTMMaterial MAT_DURA = makeSmeltable(_AS + 3, DURA, 0x183039, 0x030B0B, 0x376373).setAutogen(BOLT, DUST, PIPE, BLOCK, LIGHTBARREL, HEAVYBARREL, LIGHTRECEIVER, HEAVYRECEIVER, GRIP).m();
|
||||
public static final NTMMaterial MAT_DESH = makeSmeltable(_AS + 12, DESH, 0xFF6D6D, 0x720000, 0xF22929).setAutogen(DUST, CASTPLATE, BLOCK, HEAVY_COMPONENT).m();
|
||||
public static final NTMMaterial MAT_DESH = makeSmeltable(_AS + 12, DESH, 0xFF6D6D, 0x720000, 0xF22929).setAutogen(DUST, CASTPLATE, BLOCK, HEAVY_COMPONENT, LIGHTBARREL, HEAVYBARREL, LIGHTRECEIVER, STOCK, GRIP).m();
|
||||
public static final NTMMaterial MAT_STAR = makeSmeltable(_AS + 5, STAR, 0xCCCCEA, 0x11111A, 0xA5A5D3).setAutogen(DUST, DENSEWIRE, BLOCK).m();
|
||||
public static final NTMMaterial MAT_FERRO = makeSmeltable(_AS + 7, FERRO, 0xB7B7C9, 0x101022, 0x6B6B8B).m();
|
||||
public static final NTMMaterial MAT_TCALLOY = makeSmeltable(_AS + 6, TCALLOY, 0xD4D6D6, 0x323D3D, 0x9CA6A6).setAutogen(DUST, CASTPLATE, WELDEDPLATE, HEAVY_COMPONENT).m();
|
||||
public static final NTMMaterial MAT_CDALLOY = makeSmeltable(_AS + 13, CDALLOY, 0xF7DF8F, 0x604308, 0xFBD368).setAutogen(CASTPLATE, WELDEDPLATE, HEAVY_COMPONENT).m();
|
||||
public static final NTMMaterial MAT_BBRONZE = makeSmeltable(_AS + 16, BBRONZE, 0xE19A69, 0x485353, 0x987D65).setAutogen(CASTPLATE).m();
|
||||
public static final NTMMaterial MAT_ABRONZE = makeSmeltable(_AS + 17, ABRONZE, 0xDB9462, 0x203331, 0x77644D).setAutogen(CASTPLATE).m();
|
||||
public static final NTMMaterial MAT_FERRO = makeSmeltable(_AS + 7, FERRO, 0xB7B7C9, 0x101022, 0x6B6B8B).setAutogen(HEAVYBARREL, HEAVYRECEIVER).m();
|
||||
public static final NTMMaterial MAT_TCALLOY = makeSmeltable(_AS + 6, TCALLOY, 0xD4D6D6, 0x323D3D, 0x9CA6A6).setAutogen(DUST, CASTPLATE, WELDEDPLATE, HEAVY_COMPONENT, LIGHTBARREL, HEAVYBARREL, LIGHTRECEIVER, HEAVYRECEIVER).m();
|
||||
public static final NTMMaterial MAT_CDALLOY = makeSmeltable(_AS + 13, CDALLOY, 0xF7DF8F, 0x604308, 0xFBD368).setAutogen(CASTPLATE, WELDEDPLATE, HEAVY_COMPONENT, LIGHTBARREL, HEAVYBARREL, LIGHTRECEIVER, HEAVYRECEIVER).m();
|
||||
public static final NTMMaterial MAT_BBRONZE = makeSmeltable(_AS + 16, BBRONZE, 0xE19A69, 0x485353, 0x987D65).setAutogen(CASTPLATE, LIGHTBARREL, LIGHTRECEIVER).m();
|
||||
public static final NTMMaterial MAT_ABRONZE = makeSmeltable(_AS + 17, ABRONZE, 0xDB9462, 0x203331, 0x77644D).setAutogen(CASTPLATE, LIGHTBARREL, LIGHTRECEIVER).m();
|
||||
public static final NTMMaterial MAT_BSCCO = makeSmeltable(_AS + 18, BSCCO, 0x767BF1, 0x000000, 0x5E62C0).setAutogen(DENSEWIRE).m();
|
||||
public static final NTMMaterial MAT_MAGTUNG = makeSmeltable(_AS + 8, MAGTUNG, 0x22A2A2, 0x0F0F0F, 0x22A2A2).setAutogen(WIRE, DUST, DENSEWIRE, BLOCK).m();
|
||||
public static final NTMMaterial MAT_CMB = makeSmeltable(_AS + 9, CMB, 0x6F6FB4, 0x000011, 0x6F6FB4).setAutogen(DUST, PLATE, CASTPLATE, WELDEDPLATE, BLOCK).m();
|
||||
@ -152,11 +152,16 @@ public class Mats {
|
||||
public static final NTMMaterial MAT_SLAG = makeSmeltable(_AS + 11, SLAG, 0x554940, 0x34281F, 0x6C6562).setAutogen(BLOCK).n();
|
||||
public static final NTMMaterial MAT_MUD = makeSmeltable(_AS + 14, MUD, 0xBCB5A9, 0x481213, 0x96783B).n();
|
||||
public static final NTMMaterial MAT_GUNMETAL = makeSmeltable(_AS + 19, GUNMETAL, 0xFFEF3F, 0xAD3600, 0xF9C62C).setAutogen(LIGHTBARREL, HEAVYBARREL, LIGHTRECEIVER, HEAVYRECEIVER, MECHANISM, STOCK, GRIP).n();
|
||||
public static final NTMMaterial MAT_WEAPONSTEEL = makeSmeltable(_AS + 20, WEAPONSTEEL, 0xA0A0A0, 0x000000, 0x808080).setAutogen(LIGHTBARREL, HEAVYBARREL, LIGHTRECEIVER, HEAVYRECEIVER, MECHANISM, STOCK, GRIP).n();
|
||||
public static final NTMMaterial MAT_SATURN = makeSmeltable(_AS + 4, BIGMT, 0x3AC4DA, 0x09282C, 0x30A4B7).setAutogen(PLATE, CASTPLATE, BLOCK, LIGHTBARREL, HEAVYBARREL, LIGHTRECEIVER, HEAVYRECEIVER, MECHANISM, STOCK, GRIP).m();
|
||||
public static final NTMMaterial MAT_WEAPONSTEEL = makeSmeltable(_AS + 20, WEAPONSTEEL, 0xA0A0A0, 0x000000, 0x808080).setAutogen(SHELL, LIGHTBARREL, HEAVYBARREL, LIGHTRECEIVER, HEAVYRECEIVER, MECHANISM, STOCK, GRIP).n();
|
||||
public static final NTMMaterial MAT_SATURN = makeSmeltable(_AS + 4, BIGMT, 0x3AC4DA, 0x09282C, 0x30A4B7).setAutogen(PLATE, CASTPLATE, SHELL, BLOCK, LIGHTBARREL, HEAVYBARREL, LIGHTRECEIVER, HEAVYRECEIVER, MECHANISM, STOCK, GRIP).m();
|
||||
|
||||
//Extension
|
||||
public static final NTMMaterial MAT_RAREEARTH = makeNonSmeltable(_ES + 00, RAREEARTH, 0xC1BDBD, 0x384646, 0x7B7F7F).setAutogen(FRAGMENT).n();
|
||||
public static final NTMMaterial MAT_POLYMER = makeNonSmeltable(_ES + 01, POLYMER, 0x363636, 0x040404, 0x272727).setAutogen(STOCK, GRIP).n();
|
||||
public static final NTMMaterial MAT_BAKELITE = makeNonSmeltable(_ES + 02, BAKELITE, 0xF28086, 0x2B0608, 0xC93940).setAutogen(STOCK, GRIP).n();
|
||||
public static final NTMMaterial MAT_RUBBER = makeNonSmeltable(_ES + 03, RUBBER, 0x817F75, 0x0F0D03, 0x4B4A3F).setAutogen(PIPE, GRIP).n();
|
||||
public static final NTMMaterial MAT_HARDPLASTIC = makeNonSmeltable(_ES + 04, PC, 0xEDE7C4, 0x908A67, 0xE1DBB8).setAutogen(STOCK, GRIP).n();
|
||||
public static final NTMMaterial MAT_PVC = makeNonSmeltable(_ES + 05, PVC, 0xFCFCFC, 0x9F9F9F, 0xF0F0F0).setAutogen(STOCK, GRIP).n();
|
||||
|
||||
public static NTMMaterial makeSmeltable(int id, DictFrame dict, int color) { return makeSmeltable(id, dict, color, color, color); }
|
||||
|
||||
|
||||
@ -2,6 +2,7 @@ package com.hbm.inventory.recipes;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import static com.hbm.inventory.OreDictManager.*;
|
||||
@ -14,6 +15,7 @@ import com.hbm.inventory.OreDictManager.DictFrame;
|
||||
import com.hbm.inventory.RecipesCommon.AStack;
|
||||
import com.hbm.inventory.RecipesCommon.ComparableStack;
|
||||
import com.hbm.inventory.RecipesCommon.OreDictStack;
|
||||
import com.hbm.inventory.fluid.Fluids;
|
||||
import com.hbm.inventory.recipes.loader.SerializableRecipe;
|
||||
import com.hbm.items.ItemEnums.EnumCasingType;
|
||||
import com.hbm.items.ModItems;
|
||||
@ -41,6 +43,7 @@ public class AmmoPressRecipes extends SerializableRecipe {
|
||||
OreDictStack smokeless = new OreDictStack(ANY_SMOKELESS.dust());
|
||||
OreDictStack he = new OreDictStack(ANY_HIGHEXPLOSIVE.ingot());
|
||||
OreDictStack wp = new OreDictStack(P_WHITE.ingot());
|
||||
OreDictStack rp = new OreDictStack(P_RED.dust());
|
||||
ComparableStack cSmall = new ComparableStack(ModItems.casing, 1, EnumCasingType.SMALL);
|
||||
ComparableStack cBig = new ComparableStack(ModItems.casing, 1, EnumCasingType.LARGE);
|
||||
ComparableStack sSmall = new ComparableStack(ModItems.casing, 1, EnumCasingType.SMALL_STEEL);
|
||||
@ -229,6 +232,144 @@ public class AmmoPressRecipes extends SerializableRecipe {
|
||||
null, wp, null,
|
||||
null, smokeless, null,
|
||||
null, sShell, null));
|
||||
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.G26_FLARE, 4),
|
||||
null, rp, null,
|
||||
null, smokeless, null,
|
||||
null, cBig, null));
|
||||
|
||||
ComparableStack dyn = new ComparableStack(ModItems.ball_dynamite);
|
||||
OreDictStack coplate = new OreDictStack(CU.plate());
|
||||
OreDictStack diesel = new OreDictStack(Fluids.DIESEL.getDict(1_000));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.G40_HE, 4),
|
||||
null, dyn, null,
|
||||
null, smokeless, null,
|
||||
null, cBig, null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.G40_HEAT, 4),
|
||||
coplate, he, null,
|
||||
null, smokeless, null,
|
||||
null, cBig, null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.G40_DEMO, 4),
|
||||
null, he.copy(2), null,
|
||||
null, smokeless, null,
|
||||
null, cBig, null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.G40_INC, 4),
|
||||
diesel, dyn, null,
|
||||
null, smokeless, null,
|
||||
null, cBig, null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.G40_PHOSPHORUS, 4),
|
||||
wp, he, null,
|
||||
null, smokeless, null,
|
||||
null, cBig, null));
|
||||
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.ROCKET_HE, 2),
|
||||
null, dyn, null,
|
||||
null, cBig, null,
|
||||
null, smokeless.copy(2), null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.ROCKET_HEAT, 2),
|
||||
coplate, he, null,
|
||||
null, cBig, null,
|
||||
null, smokeless.copy(2), null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.ROCKET_DEMO, 2),
|
||||
null, he.copy(2), null,
|
||||
null, cBig, null,
|
||||
null, smokeless.copy(2), null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.ROCKET_INC, 2),
|
||||
diesel, dyn, null,
|
||||
null, cBig, null,
|
||||
null, smokeless.copy(2), null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.ROCKET_PHOSPHORUS, 2),
|
||||
wp, he, null,
|
||||
null, cBig, null,
|
||||
null, smokeless.copy(2), null));
|
||||
|
||||
OreDictStack sPlate = new OreDictStack(STEEL.plate());
|
||||
ComparableStack napalm = new ComparableStack(ModItems.canister_napalm);
|
||||
OreDictStack gas = new OreDictStack(Fluids.GAS.getDict(1000));
|
||||
OreDictStack bf = new OreDictStack(Fluids.BALEFIRE.getDict(1000));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.FLAME_DIESEL, 1),
|
||||
null, sPlate, null,
|
||||
null, diesel, null,
|
||||
null, sPlate, null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.FLAME_NAPALM, 1),
|
||||
null, sPlate, null,
|
||||
null, napalm, null,
|
||||
null, sPlate, null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.FLAME_GAS, 1),
|
||||
null, sPlate, null,
|
||||
null, gas, null,
|
||||
null, sPlate, null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.FLAME_BALEFIRE, 1),
|
||||
null, sPlate, null,
|
||||
null, bf, null,
|
||||
null, sPlate, null));
|
||||
|
||||
OreDictStack silicon = new OreDictStack(SI.billet());
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.CAPACITOR, 4),
|
||||
null, plastic, null,
|
||||
null, silicon.copy(4), null,
|
||||
null, plastic, null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.CAPACITOR_OVERCHARGE, 4),
|
||||
null, plastic, null,
|
||||
null, silicon.copy(6), null,
|
||||
null, plastic, null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.CAPACITOR_IR, 4),
|
||||
null, plastic, null,
|
||||
null, silicon.copy(4), null,
|
||||
null, plastic, null));
|
||||
|
||||
OreDictStack lPlate = new OreDictStack(PB.plate());
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.TAU_URANIUM, 16),
|
||||
null, lPlate, null,
|
||||
null, uranium, null,
|
||||
null, lPlate , null));
|
||||
|
||||
OreDictStack tungsten = new OreDictStack(W.ingot());
|
||||
OreDictStack ferro = new OreDictStack(FERRO.ingot());
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.COIL_TUNGSTEN, 4),
|
||||
null, null, null,
|
||||
null, tungsten, null,
|
||||
null, null , null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.COIL_FERROURANIUM, 4),
|
||||
null, null, null,
|
||||
null, ferro, null,
|
||||
null, null , null));
|
||||
|
||||
ComparableStack shell = new ComparableStack(ModItems.assembly_nuke);
|
||||
ComparableStack tatb = new ComparableStack(ModItems.ball_tatb);
|
||||
OreDictStack plutonium = new OreDictStack(PU239.nugget());
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.NUKE_STANDARD, 1),
|
||||
null, plutonium, null,
|
||||
null, shell, null,
|
||||
null, null , null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.NUKE_DEMO, 1),
|
||||
null, plutonium.copy(2), null,
|
||||
null, shell, null,
|
||||
null, null , null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.NUKE_HIGH, 1),
|
||||
null, plutonium.copy(4), null,
|
||||
null, shell, null,
|
||||
null, null , null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.NUKE_TOTS, 1),
|
||||
null, plutonium.copy(2), null,
|
||||
null, tatb.copy(2), null,
|
||||
null, sPlate.copy(4) , null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.NUKE_HIVE, 1),
|
||||
null, he.copy(8), null,
|
||||
null, sBig.copy(2), null,
|
||||
null, sPlate.copy(4), null));
|
||||
}
|
||||
|
||||
public static HashMap getRecipes() {
|
||||
HashMap<Object, Object> recipes = new HashMap<Object, Object>();
|
||||
|
||||
for(AmmoPressRecipe recipe : AmmoPressRecipes.recipes) {
|
||||
List<AStack> inputs = new ArrayList();
|
||||
for(AStack stack : recipe.input) if(stack != null) inputs.add(stack);
|
||||
recipes.put(inputs.toArray(new AStack[0]), recipe.output.copy());
|
||||
}
|
||||
|
||||
return recipes;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@ -20,9 +20,6 @@ import com.hbm.inventory.recipes.loader.SerializableRecipe;
|
||||
import com.hbm.items.ItemEnums.EnumBriquetteType;
|
||||
import com.hbm.items.ItemEnums.EnumCasingType;
|
||||
import com.hbm.items.ItemEnums.EnumPages;
|
||||
import com.hbm.items.ItemAmmoEnums.Ammo357Magnum;
|
||||
import com.hbm.items.ItemAmmoEnums.Ammo556mm;
|
||||
import com.hbm.items.ItemAmmoEnums.AmmoLunaticSniper;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.machine.ItemStamp;
|
||||
import com.hbm.items.machine.ItemCircuit.EnumCircuitType;
|
||||
@ -102,29 +99,6 @@ public class PressRecipes extends SerializableRecipe {
|
||||
|
||||
makeRecipe(StampType.CIRCUIT, new OreDictStack(SI.billet()), DictFrame.fromOne(ModItems.circuit, EnumCircuitType.SILICON));
|
||||
|
||||
makeRecipe(StampType.C357, new ComparableStack(ModItems.assembly_iron), ModItems.ammo_357.stackFromEnum(24, Ammo357Magnum.IRON));
|
||||
makeRecipe(StampType.C357, new ComparableStack(ModItems.assembly_steel), ModItems.ammo_357.stackFromEnum(24, Ammo357Magnum.LEAD));
|
||||
makeRecipe(StampType.C357, new ComparableStack(ModItems.assembly_lead), ModItems.ammo_357.stackFromEnum(24, Ammo357Magnum.NUCLEAR));
|
||||
makeRecipe(StampType.C357, new ComparableStack(ModItems.assembly_gold), ModItems.ammo_357.stackFromEnum(24, Ammo357Magnum.GOLD));
|
||||
makeRecipe(StampType.C357, new ComparableStack(ModItems.assembly_schrabidium), ModItems.ammo_357.stackFromEnum(6, Ammo357Magnum.SCHRABIDIUM));
|
||||
makeRecipe(StampType.C357, new ComparableStack(ModItems.assembly_nightmare), ModItems.ammo_357.stackFromEnum(24, Ammo357Magnum.NIGHTMARE1));
|
||||
makeRecipe(StampType.C357, new ComparableStack(ModItems.assembly_desh), ModItems.ammo_357.stackFromEnum(24, Ammo357Magnum.DESH));
|
||||
makeRecipe(StampType.C357, new OreDictStack(STEEL.ingot()), ModItems.ammo_357.stackFromEnum(24, Ammo357Magnum.STEEL));
|
||||
|
||||
makeRecipe(StampType.C44, new ComparableStack(ModItems.assembly_nopip), new ItemStack(ModItems.ammo_44, 24));
|
||||
makeRecipe(StampType.C44, new ComparableStack(ModItems.assembly_45), new ItemStack(ModItems.ammo_45, 32));
|
||||
|
||||
makeRecipe(StampType.C9, new ComparableStack(ModItems.assembly_smg), new ItemStack(ModItems.ammo_9mm, 32));
|
||||
makeRecipe(StampType.C9, new ComparableStack(ModItems.assembly_uzi), new ItemStack(ModItems.ammo_22lr, 32));
|
||||
makeRecipe(StampType.C9, new OreDictStack(GOLD.ingot()), ModItems.ammo_556.stackFromEnum(32, Ammo556mm.GOLD));
|
||||
makeRecipe(StampType.C9, new ComparableStack(ModItems.assembly_lacunae), new ItemStack(ModItems.ammo_5mm, 64));
|
||||
makeRecipe(StampType.C9, new ComparableStack(ModItems.assembly_556), new ItemStack(ModItems.ammo_556, 32));
|
||||
|
||||
makeRecipe(StampType.C50, new ComparableStack(ModItems.assembly_calamity), new ItemStack(ModItems.ammo_50bmg, 12));
|
||||
makeRecipe(StampType.C50, new ComparableStack(ModItems.assembly_actionexpress), new ItemStack(ModItems.ammo_50ae, 12));
|
||||
makeRecipe(StampType.C50, new ComparableStack(ModItems.assembly_luna), ModItems.ammo_luna_sniper.stackFromEnum(4, AmmoLunaticSniper.SABOT));
|
||||
makeRecipe(StampType.C50, new ComparableStack(ModItems.assembly_762), new ItemStack(ModItems.ammo_762, 32));
|
||||
|
||||
makeRecipe(StampType.PRINTING1, new ComparableStack(Items.paper), DictFrame.fromOne(ModItems.page_of_, EnumPages.PAGE1));
|
||||
makeRecipe(StampType.PRINTING2, new ComparableStack(Items.paper), DictFrame.fromOne(ModItems.page_of_, EnumPages.PAGE2));
|
||||
makeRecipe(StampType.PRINTING3, new ComparableStack(Items.paper), DictFrame.fromOne(ModItems.page_of_, EnumPages.PAGE3));
|
||||
|
||||
@ -18,7 +18,6 @@ import com.hbm.inventory.material.Mats;
|
||||
import com.hbm.inventory.material.NTMMaterial;
|
||||
import com.hbm.inventory.recipes.AssemblerRecipes;
|
||||
import com.hbm.inventory.recipes.AssemblerRecipes.AssemblerRecipe;
|
||||
import com.hbm.items.ItemAmmoEnums.*;
|
||||
import com.hbm.items.ItemEnums.EnumChunkType;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.food.ItemFlask.EnumInfusion;
|
||||
@ -27,7 +26,6 @@ import com.hbm.items.machine.ItemCircuit.EnumCircuitType;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.oredict.OreDictionary;
|
||||
|
||||
@ -83,10 +81,11 @@ public class AnvilRecipes {
|
||||
smithingRecipes.add(new AnvilSmithingHotRecipe(3, new ItemStack(ModItems.cobalt_decorated_shovel, 1), new ComparableStack(ModItems.cobalt_shovel), new ComparableStack(ModItems.ingot_meteorite)));
|
||||
smithingRecipes.add(new AnvilSmithingHotRecipe(3, new ItemStack(ModItems.cobalt_decorated_hoe, 1), new ComparableStack(ModItems.cobalt_hoe), new ComparableStack(ModItems.ingot_meteorite)));
|
||||
|
||||
smithingRecipes.add(new AnvilSmithingRecipe(1, new ItemStack(ModItems.gun_ar15, 1), new ComparableStack(ModItems.gun_thompson), new ComparableStack(ModItems.pipe_lead)));
|
||||
smithingRecipes.add(new AnvilSmithingRecipe(1916169, new ItemStack(ModItems.wings_murk, 1), new ComparableStack(ModItems.wings_limp), new ComparableStack(ModItems.particle_tachyon)));
|
||||
smithingRecipes.add(new AnvilSmithingRecipe(4, new ItemStack(ModItems.flask_infusion, 1, EnumInfusion.SHIELD.ordinal()), new ComparableStack(ModItems.gem_alexandrite), new ComparableStack(ModItems.bottle_nuka)));
|
||||
|
||||
smithingRecipes.add(new AnvilSmithingRecipe(1, new ItemStack(ModItems.ingot_gunmetal, 1), new OreDictStack(CU.ingot()), new OreDictStack(AL.ingot())));
|
||||
|
||||
smithingRecipes.add(new AnvilSmithingMold(0, new OreDictStack(GOLD.nugget()), new OreDictStack("nugget")));
|
||||
smithingRecipes.add(new AnvilSmithingMold(1, new OreDictStack(U.billet()), new OreDictStack("billet")));
|
||||
smithingRecipes.add(new AnvilSmithingMold(2, new OreDictStack(IRON.ingot()), new OreDictStack("ingot")));
|
||||
@ -184,9 +183,13 @@ public class AnvilRecipes {
|
||||
for(NTMMaterial mat : Mats.orderedList) if(mat.autogen.contains(MaterialShapes.SHELL)) constructionRecipes.add(new AnvilConstructionRecipe(
|
||||
new OreDictStack(MaterialShapes.PLATE.name() + mat.names[0], 4),
|
||||
new AnvilOutput(new ItemStack(ModItems.shell, 1, mat.id))).setTier(1));
|
||||
for(NTMMaterial mat : Mats.orderedList) if(mat.autogen.contains(MaterialShapes.PIPE)) constructionRecipes.add(new AnvilConstructionRecipe(
|
||||
new OreDictStack(MaterialShapes.PLATE.name() + mat.names[0], 3),
|
||||
new AnvilOutput(new ItemStack(ModItems.pipe, 1, mat.id))).setTier(1));
|
||||
for(NTMMaterial mat : Mats.orderedList) if(mat.autogen.contains(MaterialShapes.PIPE)) {
|
||||
String key = (OreDictionary.doesOreNameExist(MaterialShapes.PLATE.name() + mat.names[0]) ?
|
||||
MaterialShapes.PLATE.name() + mat.names[0] : MaterialShapes.INGOT.name() + mat.names[0]);
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(
|
||||
new OreDictStack(key, 3),
|
||||
new AnvilOutput(new ItemStack(ModItems.pipe, 1, mat.id))).setTier(1));
|
||||
}
|
||||
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(
|
||||
new ComparableStack(ModItems.coil_copper, 2),
|
||||
@ -570,6 +573,11 @@ public class AnvilRecipes {
|
||||
|
||||
public static void registerConstructionAmmo() {
|
||||
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new AStack[]{new ComparableStack(ModItems.stamp_iron_flat), new OreDictStack(GUNMETAL.ingot(), 2)}, new AnvilOutput(new ItemStack(ModItems.stamp_9))).setTier(2));
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new AStack[]{new ComparableStack(ModItems.stamp_iron_flat), new OreDictStack(GUNMETAL.ingot(), 2)}, new AnvilOutput(new ItemStack(ModItems.stamp_50))).setTier(2));
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new AStack[]{new ComparableStack(ModItems.stamp_desh_flat), new OreDictStack(WEAPONSTEEL.ingot(), 4)}, new AnvilOutput(new ItemStack(ModItems.stamp_desh_9))).setTier(4));
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new AStack[]{new ComparableStack(ModItems.stamp_desh_flat), new OreDictStack(WEAPONSTEEL.ingot(), 4)}, new AnvilOutput(new ItemStack(ModItems.stamp_desh_50))).setTier(4));
|
||||
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new AStack[]{new ComparableStack(ModItems.mold_base), new OreDictStack(STEEL.ingot(), 4)}, new AnvilOutput(new ItemStack(ModItems.mold, 1, 22))).setTier(2));
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new AStack[]{new ComparableStack(ModItems.mold_base), new OreDictStack(STEEL.ingot(), 4)}, new AnvilOutput(new ItemStack(ModItems.mold, 1, 23))).setTier(2));
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new AStack[]{new ComparableStack(ModItems.mold_base), new OreDictStack(STEEL.ingot(), 4)}, new AnvilOutput(new ItemStack(ModItems.mold, 1, 24))).setTier(2));
|
||||
@ -578,112 +586,8 @@ public class AnvilRecipes {
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new AStack[]{new ComparableStack(ModItems.mold_base), new OreDictStack(STEEL.ingot(), 4)}, new AnvilOutput(new ItemStack(ModItems.mold, 1, 27))).setTier(2));
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new AStack[]{new ComparableStack(ModItems.mold_base), new OreDictStack(STEEL.ingot(), 4)}, new AnvilOutput(new ItemStack(ModItems.mold, 1, 28))).setTier(2));
|
||||
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new OreDictStack(CU.plate()), new AnvilOutput(new ItemStack(ModItems.casing_357))).setTier(1));
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new OreDictStack(CU.plate()), new AnvilOutput(new ItemStack(ModItems.casing_44))).setTier(1));
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new OreDictStack(CU.plate()), new AnvilOutput(new ItemStack(ModItems.casing_9))).setTier(1));
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new OreDictStack(CU.plate()), new AnvilOutput(new ItemStack(ModItems.casing_50))).setTier(1));
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new OreDictStack(CU.plate()), new AnvilOutput(new ItemStack(ModItems.casing_buckshot))).setTier(1));
|
||||
|
||||
pullFromAssembler(new ComparableStack(ModItems.pellet_buckshot), 1);
|
||||
pullFromAssembler(new ComparableStack(ModItems.pellet_canister), 1);
|
||||
|
||||
constructionRecipes.add(new AnvilConstructionRecipe( new AStack[]{
|
||||
new ComparableStack(ModItems.powder_chlorophyte, 1),
|
||||
new OreDictStack(PB.nugget(), 12),},
|
||||
new AnvilOutput(new ItemStack(ModItems.pellet_chlorophyte, 2))).setTier(1));
|
||||
|
||||
Object[][] recs = new Object[][] {
|
||||
{ModItems.ammo_12gauge.stackFromEnum(12, Ammo12Gauge.STOCK), P_RED.dust(), ModItems.ammo_12gauge.stackFromEnum(12, Ammo12Gauge.INCENDIARY), 2},
|
||||
{ModItems.ammo_12gauge.stackFromEnum(12, Ammo12Gauge.STOCK), Item.getItemFromBlock(ModBlocks.gravel_obsidian), ModItems.ammo_12gauge.stackFromEnum(12, Ammo12Gauge.SHRAPNEL), 2},
|
||||
{ModItems.ammo_12gauge.stackFromEnum(12, Ammo12Gauge.STOCK), U238.ingot(), ModItems.ammo_12gauge.stackFromEnum(12, Ammo12Gauge.DU), 3},
|
||||
{ModItems.ammo_12gauge.stackFromEnum(120, Ammo12Gauge.STOCK), ModItems.coin_maskman, ModItems.ammo_12gauge.stackFromEnum(120, Ammo12Gauge.SLEEK), 4},
|
||||
|
||||
{ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.STOCK), P_RED.dust(), ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.INCENDIARY), 2},
|
||||
{ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.STOCK), Item.getItemFromBlock(ModBlocks.gravel_obsidian), ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.SHRAPNEL), 2},
|
||||
{ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.STOCK), ModItems.powder_poison, ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.CAUSTIC), 2},
|
||||
{ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.STOCK), DIAMOND.dust(), ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.SHOCK), 2},
|
||||
{ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.STOCK), Item.getItemFromBlock(Blocks.soul_sand), ModItems.ammo_20gauge.stackFromEnum(12, Ammo20Gauge.WITHER), 3},
|
||||
{ModItems.ammo_20gauge.stackFromEnum(120, Ammo20Gauge.STOCK), ModItems.coin_maskman, ModItems.ammo_20gauge.stackFromEnum(120, Ammo20Gauge.SLEEK), 4},
|
||||
|
||||
{ModItems.ammo_4gauge.stackFromEnum(12, Ammo4Gauge.FLECHETTE), P_WHITE.ingot(), ModItems.ammo_4gauge.stackFromEnum(12, Ammo4Gauge.FLECHETTE_PHOSPHORUS), 2},
|
||||
{ModItems.ammo_4gauge.stackFromEnum(12, Ammo4Gauge.EXPLOSIVE), ModItems.egg_balefire_shard, ModItems.ammo_4gauge.stackFromEnum(12, Ammo4Gauge.BALEFIRE), 4},
|
||||
{ModItems.ammo_4gauge.stackFromEnum(4, Ammo4Gauge.EXPLOSIVE), ModItems.ammo_rocket, ModItems.ammo_4gauge.stackFromEnum(4, Ammo4Gauge.KAMPF), 2},
|
||||
{ModItems.ammo_4gauge.stackFromEnum(12, Ammo4Gauge.KAMPF), ModItems.pellet_canister, ModItems.ammo_4gauge.stackFromEnum(12, Ammo4Gauge.CANISTER), 3},
|
||||
{ModItems.ammo_4gauge.stackFromEnum(4, Ammo4Gauge.STOCK), ModItems.pellet_claws, ModItems.ammo_4gauge.stackFromEnum(4, Ammo4Gauge.CLAW), 5},
|
||||
{ModItems.ammo_4gauge.stackFromEnum(4, Ammo4Gauge.STOCK), ModItems.toothpicks, ModItems.ammo_4gauge.stackFromEnum(4, Ammo4Gauge.VAMPIRE), 5},
|
||||
{ModItems.ammo_4gauge.stackFromEnum(Ammo4Gauge.STOCK), ModItems.pellet_charged, ModItems.ammo_4gauge.stackFromEnum(Ammo4Gauge.VOID), 5},
|
||||
{ModItems.ammo_4gauge.stackFromEnum(120, Ammo4Gauge.STOCK), ModItems.coin_maskman, ModItems.ammo_4gauge.stackFromEnum(120, Ammo4Gauge.SLEEK), 4},
|
||||
|
||||
{ModItems.ammo_44.stackFromEnum(24, Ammo44Magnum.STOCK), DURA.ingot(), ModItems.ammo_44.stackFromEnum(24, Ammo44Magnum.AP), 2},
|
||||
{ModItems.ammo_44.stackFromEnum(24, Ammo44Magnum.STOCK), U238.ingot(), ModItems.ammo_44.stackFromEnum(24, Ammo44Magnum.DU), 2},
|
||||
{ModItems.ammo_44.stackFromEnum(24, Ammo44Magnum.STOCK), P_WHITE.ingot(), ModItems.ammo_44.stackFromEnum(24, Ammo44Magnum.PHOSPHORUS), 2},
|
||||
{ModItems.ammo_44.stackFromEnum(12, Ammo44Magnum.DU), STAR.ingot(), ModItems.ammo_44.stackFromEnum(12, Ammo44Magnum.STAR), 3},
|
||||
{ModItems.ammo_44.stackFromEnum(24, Ammo44Magnum.STOCK), ModItems.pellet_chlorophyte, ModItems.ammo_44.stackFromEnum(24, Ammo44Magnum.CHLOROPHYTE), 3},
|
||||
|
||||
{ModItems.ammo_45.stackFromEnum(32, Ammo45ACP.STOCK), DURA.ingot(), ModItems.ammo_45.stackFromEnum(32, Ammo45ACP.AP), 3},
|
||||
{ModItems.ammo_45.stackFromEnum(32, Ammo45ACP.STOCK), U238.ingot(), ModItems.ammo_45.stackFromEnum(32, Ammo45ACP.DU), 3},
|
||||
|
||||
{ModItems.ammo_5mm.stackFromEnum(128, Ammo5mm.STOCK), ModItems.ingot_semtex, ModItems.ammo_5mm.stackFromEnum(128, Ammo5mm.EXPLOSIVE), 2},
|
||||
{ModItems.ammo_5mm.stackFromEnum(128, Ammo5mm.STOCK), U238.ingot(), ModItems.ammo_5mm.stackFromEnum(128, Ammo5mm.DU), 2},
|
||||
{ModItems.ammo_5mm.stackFromEnum(32, Ammo5mm.DU), STAR.ingot(), ModItems.ammo_5mm.stackFromEnum(32, Ammo5mm.STAR), 3},
|
||||
{ModItems.ammo_5mm.stackFromEnum(128, Ammo5mm.STOCK), ModItems.pellet_chlorophyte, ModItems.ammo_5mm.stackFromEnum(128, Ammo5mm.CHLOROPHYTE), 3},
|
||||
|
||||
{ModItems.ammo_9mm.stackFromEnum(32, Ammo9mm.STOCK), DURA.ingot(), ModItems.ammo_9mm.stackFromEnum(32, Ammo9mm.AP), 2},
|
||||
{ModItems.ammo_9mm.stackFromEnum(32, Ammo9mm.STOCK), U238.ingot(), ModItems.ammo_9mm.stackFromEnum(32, Ammo9mm.DU), 2},
|
||||
{ModItems.ammo_9mm.stackFromEnum(32, Ammo9mm.STOCK), ModItems.pellet_chlorophyte, ModItems.ammo_9mm.stackFromEnum(32, Ammo9mm.CHLOROPHYTE), 3},
|
||||
|
||||
{ModItems.ammo_22lr.stackFromEnum(32, Ammo22LR.STOCK), DURA.ingot(), ModItems.ammo_22lr.stackFromEnum(32, Ammo22LR.AP), 2},
|
||||
{ModItems.ammo_22lr.stackFromEnum(32, Ammo22LR.STOCK), ModItems.pellet_chlorophyte, ModItems.ammo_22lr.stackFromEnum(32, Ammo22LR.CHLOROPHYTE), 3},
|
||||
|
||||
{ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.STOCK), P_RED.dust(), ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.INCENDIARY), 2},
|
||||
{ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.STOCK), P_WHITE.ingot(), ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.PHOSPHORUS), 2},
|
||||
{ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.STOCK), ModItems.ingot_semtex, ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.EXPLOSIVE), 2},
|
||||
{ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.STOCK), DURA.ingot(), ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.AP), 2},
|
||||
{ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.STOCK), U238.ingot(), ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.DU), 2},
|
||||
{ModItems.ammo_50bmg.stackFromEnum(8, Ammo50BMG.DU), STAR.ingot(), ModItems.ammo_50bmg.stackFromEnum(8, Ammo50BMG.STAR), 3},
|
||||
{ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.STOCK), ModItems.pellet_chlorophyte, ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.CHLOROPHYTE), 3},
|
||||
{ModItems.ammo_50bmg.stackFromEnum(128, Ammo50BMG.STOCK), ModItems.coin_maskman, ModItems.ammo_50bmg.stackFromEnum(128, Ammo50BMG.SLEEK), 4},
|
||||
{ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.STOCK), ModItems.pellet_flechette, ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.FLECHETTE), 2},
|
||||
{ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.FLECHETTE), ModItems.nugget_am_mix, ModItems.ammo_50bmg.stackFromEnum(16, Ammo50BMG.FLECHETTE_AM), 3},
|
||||
{ModItems.ammo_50bmg.stackFromEnum(32, Ammo50BMG.FLECHETTE), ModItems.powder_polonium, ModItems.ammo_50bmg.stackFromEnum(32, Ammo50BMG.FLECHETTE_PO), 3},
|
||||
|
||||
{ModItems.ammo_50ae.stackFromEnum(32, Ammo50AE.STOCK), DURA.ingot(), ModItems.ammo_50ae.stackFromEnum(32, Ammo50AE.AP), 2},
|
||||
{ModItems.ammo_50ae.stackFromEnum(32, Ammo50AE.STOCK), U238.ingot(), ModItems.ammo_50ae.stackFromEnum(32, Ammo50AE.DU), 2},
|
||||
{ModItems.ammo_50ae.stackFromEnum(16, Ammo50AE.DU), STAR.ingot(), ModItems.ammo_50ae.stackFromEnum(16, Ammo50AE.STAR), 3},
|
||||
{ModItems.ammo_50ae.stackFromEnum(32, Ammo50AE.STOCK), ModItems.pellet_chlorophyte, ModItems.ammo_50ae.stackFromEnum(32, Ammo50AE.CHLOROPHYTE), 3},
|
||||
|
||||
{ModItems.ammo_556.stackFromEnum(32, Ammo556mm.STOCK), P_WHITE.ingot(), ModItems.ammo_556.stackFromEnum(32, Ammo556mm.PHOSPHORUS), 2},
|
||||
{ModItems.ammo_556.stackFromEnum(32, Ammo556mm.STOCK), DURA.ingot(), ModItems.ammo_556.stackFromEnum(32, Ammo556mm.AP), 2},
|
||||
{ModItems.ammo_556.stackFromEnum(32, Ammo556mm.STOCK), U238.ingot(), ModItems.ammo_556.stackFromEnum(32, Ammo556mm.DU), 2},
|
||||
{ModItems.ammo_556.stackFromEnum(16, Ammo556mm.DU), STAR.ingot(), ModItems.ammo_556.stackFromEnum(16, Ammo556mm.STAR), 3},
|
||||
{ModItems.ammo_556.stackFromEnum(32, Ammo556mm.STOCK), ModItems.pellet_chlorophyte, ModItems.ammo_556.stackFromEnum(32, Ammo556mm.CHLOROPHYTE), 3},
|
||||
{ModItems.ammo_556.stackFromEnum(128, Ammo556mm.STOCK), ModItems.coin_maskman, ModItems.ammo_556.stackFromEnum(128, Ammo556mm.SLEEK), 4},
|
||||
{ModItems.ammo_556.stackFromEnum(32, Ammo556mm.STOCK), Items.redstone, ModItems.ammo_556.stackFromEnum(32, Ammo556mm.TRACER), 2},
|
||||
{ModItems.ammo_556.stackFromEnum(32, Ammo556mm.STOCK), ModItems.pellet_flechette, ModItems.ammo_556.stackFromEnum(32, Ammo556mm.FLECHETTE), 2},
|
||||
{ModItems.ammo_556.stackFromEnum(32, Ammo556mm.FLECHETTE), P_RED.dust(), ModItems.ammo_556.stackFromEnum(32, Ammo556mm.FLECHETTE_INCENDIARY), 2},
|
||||
{ModItems.ammo_556.stackFromEnum(32, Ammo556mm.FLECHETTE), P_WHITE.ingot(), ModItems.ammo_556.stackFromEnum(32, Ammo556mm.FLECHETTE_PHOSPHORUS), 2},
|
||||
{ModItems.ammo_556.stackFromEnum(32, Ammo556mm.FLECHETTE), U238.ingot(), ModItems.ammo_556.stackFromEnum(32, Ammo556mm.FLECHETTE_DU), 2},
|
||||
{ModItems.ammo_556.stackFromEnum(100, Ammo556mm.FLECHETTE), ModItems.coin_maskman, ModItems.ammo_556.stackFromEnum(128, Ammo556mm.FLECHETTE_SLEEK), 4},
|
||||
{ModItems.ammo_556.stackFromEnum(32, Ammo556mm.FLECHETTE), ModItems.pellet_chlorophyte, ModItems.ammo_556.stackFromEnum(32, Ammo556mm.FLECHETTE_CHLOROPHYTE), 3},
|
||||
|
||||
{ModItems.ammo_762.stackFromEnum(32, Ammo762NATO.STOCK), Items.redstone, ModItems.ammo_762.stackFromEnum(32, Ammo762NATO.TRACER), 2},
|
||||
{ModItems.ammo_762.stackFromEnum(32, Ammo762NATO.STOCK), DURA.ingot(), ModItems.ammo_762.stackFromEnum(32, Ammo762NATO.AP), 2},
|
||||
{ModItems.ammo_762.stackFromEnum(32, Ammo762NATO.STOCK), P_WHITE.ingot(), ModItems.ammo_762.stackFromEnum(32, Ammo762NATO.PHOSPHORUS), 2},
|
||||
{ModItems.ammo_762.stackFromEnum(32, Ammo762NATO.STOCK), U238.ingot(), ModItems.ammo_762.stackFromEnum(32, Ammo762NATO.DU), 2}
|
||||
};
|
||||
|
||||
for(Object[] objs : recs) {
|
||||
|
||||
ComparableStack ammoIn = new ComparableStack((ItemStack) objs[0]);
|
||||
ItemStack out = (ItemStack) objs[2];
|
||||
|
||||
if(objs[1] instanceof Item) {
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new AStack[] { ammoIn, new ComparableStack((Item)objs[1], 1) }, new AnvilOutput(out)).setTier((int)objs[3]));
|
||||
|
||||
} else if(objs[1] instanceof String) {
|
||||
constructionRecipes.add(new AnvilConstructionRecipe(new AStack[] { ammoIn, new OreDictStack((String)objs[1], 1) }, new AnvilOutput(out)).setTier((int)objs[3]));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static void registerConstructionUpgrades() {
|
||||
|
||||
@ -25,6 +25,7 @@ public class ItemPool {
|
||||
ItemPoolsRedRoom.init();
|
||||
ItemPoolsSatellite.init();
|
||||
ItemPoolsPile.init();
|
||||
ItemPoolsC130.init();
|
||||
}
|
||||
|
||||
public static HashMap<String, ItemPool> pools = new HashMap();
|
||||
|
||||
60
src/main/java/com/hbm/itempool/ItemPoolsC130.java
Normal file
60
src/main/java/com/hbm/itempool/ItemPoolsC130.java
Normal file
@ -0,0 +1,60 @@
|
||||
package com.hbm.itempool;
|
||||
|
||||
import static com.hbm.lib.HbmChestContents.weighted;
|
||||
|
||||
import com.hbm.blocks.ModBlocks;
|
||||
import com.hbm.inventory.fluid.Fluids;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmo;
|
||||
|
||||
import net.minecraft.util.WeightedRandomChestContent;
|
||||
|
||||
public class ItemPoolsC130 {
|
||||
|
||||
public static final String POOL_SUPPLIES = "POOL_SUPPLIES";
|
||||
public static final String POOL_WEAPONS = "POOL_WEAPONS";
|
||||
public static final String POOL_AMMO = "POOL_AMMO";
|
||||
|
||||
|
||||
public static void init() {
|
||||
|
||||
new ItemPool(POOL_SUPPLIES) {{
|
||||
this.pool = new WeightedRandomChestContent[] {
|
||||
weighted(ModItems.definitelyfood, 0, 3, 10, 25),
|
||||
weighted(ModItems.syringe_metal_stimpak, 0, 1, 3, 10),
|
||||
weighted(ModItems.pill_iodine, 0, 1, 2, 2),
|
||||
weighted(ModItems.canister_full, Fluids.DIESEL.getID(), 1, 4, 5),
|
||||
weighted(ModBlocks.machine_diesel, 0, 1, 1, 1),
|
||||
weighted(ModItems.geiger_counter, 0, 1, 1, 2),
|
||||
weighted(ModItems.med_bag, 0, 1, 1, 3),
|
||||
weighted(ModItems.radaway, 0, 1, 5, 10),
|
||||
};
|
||||
}};
|
||||
|
||||
new ItemPool(POOL_WEAPONS) {{
|
||||
this.pool = new WeightedRandomChestContent[] {
|
||||
weighted(ModItems.gun_light_revolver, 0, 1, 1, 10),
|
||||
weighted(ModItems.gun_henry, 0, 1, 1, 10),
|
||||
weighted(ModItems.gun_maresleg, 0, 1, 1, 10),
|
||||
weighted(ModItems.gun_greasegun, 0, 1, 1, 10),
|
||||
weighted(ModItems.gun_carbine, 0, 1, 1, 5),
|
||||
weighted(ModItems.gun_heavy_revolver, 0, 1, 1, 5),
|
||||
weighted(ModItems.gun_panzerschreck, 0, 1, 1, 2),
|
||||
};
|
||||
}};
|
||||
|
||||
new ItemPool(POOL_AMMO) {{
|
||||
this.pool = new WeightedRandomChestContent[] {
|
||||
weighted(ModItems.ammo_standard, EnumAmmo.M357_SP.ordinal(), 12, 12, 10),
|
||||
weighted(ModItems.ammo_standard, EnumAmmo.M357_FMJ.ordinal(), 6, 6, 10),
|
||||
weighted(ModItems.ammo_standard, EnumAmmo.M44_SP.ordinal(), 12, 12, 5),
|
||||
weighted(ModItems.ammo_standard, EnumAmmo.M44_FMJ.ordinal(), 6, 6, 5),
|
||||
weighted(ModItems.ammo_standard, EnumAmmo.P9_SP.ordinal(), 12, 12, 10),
|
||||
weighted(ModItems.ammo_standard, EnumAmmo.P9_FMJ.ordinal(), 6, 6, 10),
|
||||
weighted(ModItems.ammo_standard, EnumAmmo.R762_SP.ordinal(), 6, 6, 5),
|
||||
weighted(ModItems.ammo_standard, EnumAmmo.G12_BP.ordinal(), 6, 6, 10),
|
||||
weighted(ModItems.ammo_standard, EnumAmmo.ROCKET_HE.ordinal(), 1, 1, 3),
|
||||
};
|
||||
}};
|
||||
}
|
||||
}
|
||||
@ -77,7 +77,6 @@ public class ItemPoolsComponent {
|
||||
weighted(ModItems.gas_mask_m65, 0, 1, 1, 5),
|
||||
weighted(ModItems.battery_advanced, 0, 1, 1, 5),
|
||||
weighted(ModItems.designator, 0, 1, 1, 5),
|
||||
weighted(ModItems.crate_caller, 0, 1, 1, 1),
|
||||
weighted(ModItems.thruster_small, 0, 1, 1, 5),
|
||||
weighted(ModItems.thruster_medium, 0, 1, 1, 4),
|
||||
weighted(ModItems.fuel_tank_small, 0, 1, 1, 5),
|
||||
|
||||
@ -119,7 +119,6 @@ public class ItemPoolsLegacy {
|
||||
weighted(ModItems.battery_advanced_cell, 0, 1, 1, 2),
|
||||
weighted(ModItems.battery_schrabidium, 0, 1, 1, 1),
|
||||
weighted(ModItems.syringe_awesome, 0, 1, 1, 1),
|
||||
weighted(ModItems.crate_caller, 0, 1, 1, 3),
|
||||
weighted(ModItems.fusion_core, 0, 1, 1, 4),
|
||||
weighted(ModItems.bottle_nuka, 0, 1, 3, 6),
|
||||
weighted(ModItems.bottle_quantum, 0, 1, 1, 3),
|
||||
@ -205,7 +204,6 @@ public class ItemPoolsLegacy {
|
||||
weighted(ModItems.bottle_nuka, 0, 1, 3, 6),
|
||||
weighted(ModItems.bottle_quantum, 0, 1, 1, 3),
|
||||
weighted(ModItems.stealth_boy, 0, 1, 1, 7),
|
||||
weighted(ModItems.crate_caller, 0, 1, 1, 3),
|
||||
weighted(ModItems.gas_mask_m65, 0, 1, 1, 5),
|
||||
weighted(ModItems.gas_mask_filter, 0, 1, 1, 5),
|
||||
weighted(ModItems.grenade_nuclear, 0, 1, 2, 2),
|
||||
|
||||
@ -70,7 +70,6 @@ public class ItemPoolsSingle {
|
||||
weighted(ModItems.powder_yellowcake, 0, 16, 24, 1),
|
||||
weighted(ModItems.gun_uzi, 0, 1, 1, 1),
|
||||
weighted(ModItems.gun_uzi_silencer, 0, 1, 1, 1),
|
||||
weighted(ModItems.clip_uzi, 0, 1, 3, 1),
|
||||
weighted(ModItems.circuit, EnumCircuitType.VACUUM_TUBE.ordinal(), 12, 16, 1),
|
||||
weighted(ModItems.circuit, EnumCircuitType.CHIP.ordinal(), 2, 6, 1)
|
||||
};
|
||||
@ -91,7 +90,6 @@ public class ItemPoolsSingle {
|
||||
weighted(ModItems.powder_yellowcake, 0, 26, 42, 1),
|
||||
weighted(ModItems.ingot_u235, 0, 3, 6, 1),
|
||||
weighted(ModItems.gun_revolver_pip, 0, 1, 1, 1),
|
||||
weighted(ModItems.clip_revolver_pip, 0, 2, 4, 1),
|
||||
weighted(ModItems.circuit, EnumCircuitType.CHIP.ordinal(), 18, 32, 1),
|
||||
weighted(ModItems.circuit, EnumCircuitType.BASIC.ordinal(), 6, 12, 1)
|
||||
};
|
||||
@ -100,7 +98,6 @@ public class ItemPoolsSingle {
|
||||
new ItemPool(POOL_VAULT_UNBREAKABLE) {{
|
||||
this.pool = new WeightedRandomChestContent[] {
|
||||
weighted(ModItems.ammo_container, 0, 3, 6, 1),
|
||||
weighted(ModItems.clip_fatman, 0, 2, 3, 1),
|
||||
weighted(ModItems.ammo_nuke, AmmoFatman.MIRV.ordinal(), 2, 3, 1),
|
||||
weighted(ModItems.gun_mirv, 0, 1, 1, 1),
|
||||
weighted(ModItems.gun_proto, 0, 1, 1, 1),
|
||||
|
||||
@ -622,11 +622,6 @@ public class ModItems {
|
||||
|
||||
public static Item casing;
|
||||
|
||||
public static Item folly_shell;
|
||||
public static Item folly_bullet;
|
||||
public static Item folly_bullet_nuclear;
|
||||
public static Item folly_bullet_du;
|
||||
|
||||
public static Item wiring_red_copper;
|
||||
public static Item shell;
|
||||
public static Item pipe;
|
||||
@ -786,7 +781,6 @@ public class ModItems {
|
||||
public static Item pellet_rtg_actinium;
|
||||
public static Item pellet_rtg_polonium;
|
||||
public static Item pellet_rtg_americium;
|
||||
public static Item pellet_rtg_berkelium;
|
||||
public static Item pellet_rtg_gold;
|
||||
public static Item pellet_rtg_lead;
|
||||
|
||||
@ -1497,9 +1491,6 @@ public class ModItems {
|
||||
|
||||
public static Item ammo_cell;
|
||||
|
||||
public static Item ammo_folly;
|
||||
public static Item ammo_folly_nuclear;
|
||||
public static Item ammo_folly_du;
|
||||
public static Item ammo_dgk;
|
||||
public static Item ammo_arty;
|
||||
public static Item ammo_himars;
|
||||
@ -1526,7 +1517,6 @@ public class ModItems {
|
||||
public static Item gun_ar15;
|
||||
public static Item gun_calamity;
|
||||
public static Item gun_lacunae;
|
||||
public static Item gun_folly;
|
||||
public static Item gun_proto;
|
||||
public static Item gun_mirv;
|
||||
public static Item gun_bf;
|
||||
@ -1592,6 +1582,7 @@ public class ModItems {
|
||||
|
||||
public static Item gun_pepperbox;
|
||||
public static Item gun_light_revolver;
|
||||
public static Item gun_light_revolver_atlas;
|
||||
public static Item gun_light_revolver_dani;
|
||||
public static Item gun_henry;
|
||||
public static Item gun_greasegun;
|
||||
@ -1606,7 +1597,10 @@ public class ModItems {
|
||||
public static Item gun_liberator;
|
||||
public static Item gun_congolake;
|
||||
public static Item gun_flamer;
|
||||
public static Item gun_flamer_topaz;
|
||||
public static Item gun_flamer_daybreaker;
|
||||
public static Item gun_uzi;
|
||||
public static Item gun_uzi_akimbo;
|
||||
public static Item gun_spas12;
|
||||
public static Item gun_panzerschreck;
|
||||
public static Item gun_g3;
|
||||
@ -1618,6 +1612,7 @@ public class ModItems {
|
||||
public static Item gun_quadro;
|
||||
public static Item gun_lag;
|
||||
public static Item gun_minigun;
|
||||
public static Item gun_minigun_lacunae;
|
||||
public static Item gun_missile_launcher;
|
||||
public static Item gun_tesla_cannon;
|
||||
public static Item gun_stg77;
|
||||
@ -1627,8 +1622,10 @@ public class ModItems {
|
||||
public static Item gun_coilgun;
|
||||
public static Item gun_hangman;
|
||||
public static Item gun_bolter;
|
||||
|
||||
public static Item gun_folly;
|
||||
|
||||
public static Item ammo_standard;
|
||||
public static Item ammo_secret;
|
||||
|
||||
public static Item crucible;
|
||||
|
||||
@ -2261,38 +2258,6 @@ public class ModItems {
|
||||
public static Item loot_10;
|
||||
public static Item loot_15;
|
||||
public static Item loot_misc;
|
||||
|
||||
public static Item clip_revolver_iron;
|
||||
public static Item clip_revolver;
|
||||
public static Item clip_revolver_gold;
|
||||
public static Item clip_revolver_lead;
|
||||
public static Item clip_revolver_schrabidium;
|
||||
public static Item clip_revolver_cursed;
|
||||
public static Item clip_revolver_nightmare;
|
||||
public static Item clip_revolver_nightmare2;
|
||||
public static Item clip_revolver_pip;
|
||||
public static Item clip_revolver_nopip;
|
||||
public static Item clip_rpg;
|
||||
public static Item clip_stinger;
|
||||
public static Item clip_fatman;
|
||||
public static Item clip_mirv;
|
||||
public static Item clip_bf;
|
||||
public static Item clip_mp40;
|
||||
public static Item clip_uzi;
|
||||
public static Item clip_uboinik;
|
||||
public static Item clip_lever_action;
|
||||
public static Item clip_bolt_action;
|
||||
public static Item clip_osipr;
|
||||
public static Item clip_immolator;
|
||||
public static Item clip_cryolator;
|
||||
public static Item clip_mp;
|
||||
public static Item clip_xvl1456;
|
||||
public static Item clip_emp;
|
||||
public static Item clip_jack;
|
||||
public static Item clip_spark;
|
||||
public static Item clip_hp;
|
||||
public static Item clip_euthanasia;
|
||||
public static Item clip_defabricator;
|
||||
|
||||
public static Item ammo_container;
|
||||
|
||||
@ -2302,7 +2267,6 @@ public class ModItems {
|
||||
public static Item detonator_laser;
|
||||
public static Item detonator_deadman;
|
||||
public static Item detonator_de;
|
||||
public static Item crate_caller;
|
||||
public static Item bomb_caller;
|
||||
public static Item meteor_remote;
|
||||
public static Item anchor_remote;
|
||||
@ -3030,10 +2994,6 @@ public class ModItems {
|
||||
assembly_lacunae = new Item().setUnlocalizedName("assembly_lacunae").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":assembly_lacunae");
|
||||
assembly_nuke = new Item().setUnlocalizedName("assembly_nuke").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":assembly_nuke");
|
||||
assembly_luna = new Item().setUnlocalizedName("assembly_luna").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":assembly_luna");
|
||||
folly_shell = new Item().setUnlocalizedName("folly_shell").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":folly_shell");
|
||||
folly_bullet = new Item().setUnlocalizedName("folly_bullet").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":folly_bullet");
|
||||
folly_bullet_nuclear = new Item().setUnlocalizedName("folly_bullet_nuclear").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":folly_bullet_nuclear");
|
||||
folly_bullet_du = new Item().setUnlocalizedName("folly_bullet_du").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":folly_bullet_du");
|
||||
casing = new ItemEnumMulti(ItemEnums.EnumCasingType.class, true, true).setUnlocalizedName("casing").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":casing");
|
||||
|
||||
wiring_red_copper = new ItemWiring().setUnlocalizedName("wiring_red_copper").setCreativeTab(MainRegistry.partsTab).setTextureName(RefStrings.MODID + ":wiring_red_copper");
|
||||
@ -3047,7 +3007,6 @@ public class ModItems {
|
||||
pellet_rtg_cobalt = new ItemRTGPellet(15).setDecays(DepletedRTGMaterial.NICKEL, (long) (RTGUtil.getLifespan(5.3F, HalfLifeType.MEDIUM, false) * 1.5)).setUnlocalizedName("pellet_rtg_cobalt").setCreativeTab(MainRegistry.controlTab).setTextureName(RefStrings.MODID + ":pellet_rtg_cobalt");
|
||||
pellet_rtg_actinium = new ItemRTGPellet(20).setDecays(DepletedRTGMaterial.LEAD, (long) (RTGUtil.getLifespan(21.8F, HalfLifeType.MEDIUM, false) * 1.5)).setUnlocalizedName("pellet_rtg_actinium").setCreativeTab(MainRegistry.controlTab).setTextureName(RefStrings.MODID + ":pellet_rtg_actinium");
|
||||
pellet_rtg_americium = new ItemRTGPellet(20).setDecays(DepletedRTGMaterial.NEPTUNIUM, (long) (RTGUtil.getLifespan(4.7F, HalfLifeType.LONG, false) * 1.5)).setUnlocalizedName("pellet_rtg_americium").setCreativeTab(MainRegistry.controlTab).setMaxStackSize(1).setTextureName(RefStrings.MODID + ":pellet_rtg_americium");
|
||||
pellet_rtg_berkelium = new ItemRTGPellet(20).setUnlocalizedName("pellet_rtg_berkelium").setCreativeTab(MainRegistry.controlTab).setMaxStackSize(1).setTextureName(RefStrings.MODID + ":pellet_rtg_berkelium");
|
||||
pellet_rtg_polonium = new ItemRTGPellet(50).setDecays(DepletedRTGMaterial.LEAD, (long) (RTGUtil.getLifespan(138.0F, HalfLifeType.SHORT, false) * 1.5)).setUnlocalizedName("pellet_rtg_polonium").setCreativeTab(MainRegistry.controlTab).setMaxStackSize(1).setTextureName(RefStrings.MODID + ":pellet_rtg_polonium");
|
||||
pellet_rtg_gold = new ItemRTGPellet(VersatileConfig.rtgDecay() ? 200 : 100).setDecays(DepletedRTGMaterial.MERCURY, (long) (RTGUtil.getLifespan(2.7F, HalfLifeType.SHORT, false) * 1.5)).setUnlocalizedName("pellet_rtg_gold").setCreativeTab(MainRegistry.controlTab).setMaxStackSize(1).setTextureName(RefStrings.MODID + ":pellet_rtg_gold");
|
||||
pellet_rtg_lead = new ItemRTGPellet(VersatileConfig.rtgDecay() ? 600 : 200).setDecays(DepletedRTGMaterial.BISMUTH, (long) (RTGUtil.getLifespan(0.3F, HalfLifeType.SHORT, false) * 1.5)).setUnlocalizedName("pellet_rtg_lead").setCreativeTab(MainRegistry.controlTab).setTextureName(RefStrings.MODID + ":pellet_rtg_lead");
|
||||
@ -4049,95 +4008,89 @@ public class ModItems {
|
||||
ammo_stinger_rocket = new ItemAmmo(AmmoStinger.class).setUnlocalizedName("ammo_stinger_rocket");
|
||||
ammo_luna_sniper = new ItemAmmo(AmmoLunaticSniper.class).setUnlocalizedName("ammo_luna_sniper");
|
||||
ammo_misc = new ItemAmmo(AmmoMisc.class).setUnlocalizedName("ammo_misc");
|
||||
ammo_folly = new ItemCustomLore().setUnlocalizedName("ammo_folly");
|
||||
ammo_folly_nuclear = new ItemCustomLore().setUnlocalizedName("ammo_folly_nuclear");
|
||||
ammo_folly_du = new ItemCustomLore().setUnlocalizedName("ammo_folly_du");
|
||||
ammo_arty = new ItemAmmoArty().setUnlocalizedName("ammo_arty");
|
||||
ammo_himars = new ItemAmmoHIMARS().setUnlocalizedName("ammo_himars");
|
||||
|
||||
gun_rpg = new ItemGunBase(GunRocketFactory.getGustavConfig()).setUnlocalizedName("gun_rpg").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_rpg");
|
||||
gun_karl = new ItemGunBase(GunRocketFactory.getKarlConfig()).setUnlocalizedName("gun_karl").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_karl");
|
||||
gun_panzerschreck = new ItemGunBase(GunRocketFactory.getPanzConfig()).setUnlocalizedName("gun_panzerschreck").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_panzerschreck");
|
||||
gun_hk69 = new ItemGunBase(GunGrenadeFactory.getHK69Config()).setUnlocalizedName("gun_hk69").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_hk69");
|
||||
//gun_congolake = new ItemGunBase(GunGrenadeFactory.getCongoConfig()).setUnlocalizedName("gun_congolake").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_congolake");
|
||||
gun_skystinger = new ItemGunBase(GunRocketHomingFactory.getSkyStingerConfig()).setUnlocalizedName("gun_skystinger").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_skystinger");
|
||||
gun_revolver = new ItemGunBase(Gun357MagnumFactory.getRevolverConfig()).setUnlocalizedName("gun_revolver").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver");
|
||||
gun_revolver_saturnite = new ItemGunBase(Gun357MagnumFactory.getRevolverSaturniteConfig()).setUnlocalizedName("gun_revolver_saturnite").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_saturnite");
|
||||
gun_revolver_gold = new ItemGunBase(Gun357MagnumFactory.getRevolverGoldConfig()).setUnlocalizedName("gun_revolver_gold").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_gold");
|
||||
gun_revolver_schrabidium = new ItemGunBase(Gun357MagnumFactory.getRevolverSchrabidiumConfig()).setUnlocalizedName("gun_revolver_schrabidium").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_schrabidium");
|
||||
gun_revolver_cursed = new ItemGunBase(Gun357MagnumFactory.getRevolverCursedConfig()).setUnlocalizedName("gun_revolver_cursed").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_cursed");
|
||||
gun_revolver_nightmare = new ItemGunBase(Gun357MagnumFactory.getRevolverNightmareConfig()).setUnlocalizedName("gun_revolver_nightmare").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_nightmare");
|
||||
gun_revolver_nightmare2 = new ItemGunBase(Gun357MagnumFactory.getRevolverNightmare2Config()).setUnlocalizedName("gun_revolver_nightmare2").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_nightmare2");
|
||||
gun_revolver_pip = new ItemGunPip(Gun44MagnumFactory.getMacintoshConfig()).setUnlocalizedName("gun_revolver_pip").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_pip");
|
||||
gun_revolver_nopip = new ItemGunBase(Gun44MagnumFactory.getNovacConfig()).setUnlocalizedName("gun_revolver_nopip").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_nopip");
|
||||
gun_revolver_blackjack = new ItemGunBase(Gun44MagnumFactory.getBlackjackConfig()).setUnlocalizedName("gun_revolver_blackjack").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_blackjack");
|
||||
gun_revolver_silver = new ItemGunBase(Gun44MagnumFactory.getSilverConfig()).setUnlocalizedName("gun_revolver_silver").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_silver");
|
||||
gun_revolver_red = new ItemGunBase(Gun44MagnumFactory.getRedConfig()).setUnlocalizedName("gun_revolver_red").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_red");
|
||||
gun_deagle = new ItemGunBase(Gun50AEFactory.getDeagleConfig()).setUnlocalizedName("gun_deagle").setFull3D().setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_deagle");
|
||||
gun_bio_revolver = new ItemGunBio(Gun357MagnumFactory.getRevolverBioConfig()).setUnlocalizedName("gun_bio_revolver").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_bio_revolver");
|
||||
gun_flechette = new ItemGunBase(Gun556mmFactory.getSPIWConfig(), Gun556mmFactory.getGLauncherConfig()).setUnlocalizedName("gun_flechette").setFull3D().setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_flechette");
|
||||
gun_ar15 = new ItemGunBase(Gun50BMGFactory.getAR15Config(), Gun50BMGFactory.getAR15BurstConfig()).setUnlocalizedName("gun_ar15").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_ar15");
|
||||
gun_calamity = new ItemGunBase(Gun762mmFactory.getCalamityConfig()).setUnlocalizedName("gun_calamity").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_calamity");
|
||||
gun_lacunae = new ItemGunLacunae(Gun5mmFactory.getLacunaeConfig()).setUnlocalizedName("gun_lacunae").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_lacunae");
|
||||
gun_folly = new GunFolly().setUnlocalizedName("gun_folly").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_folly");
|
||||
gun_proto = new ItemGunBase(GunFatmanFactory.getProtoConfig()).setUnlocalizedName("gun_proto").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_fatman");
|
||||
gun_mirv = new ItemGunBase(GunFatmanFactory.getMIRVConfig()).setUnlocalizedName("gun_mirv").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_mirv");
|
||||
gun_bf = new ItemGunBase(GunFatmanFactory.getBELConfig()).setUnlocalizedName("gun_bf").setCreativeTab(null).setTextureName(RefStrings.MODID + ":gun_bf");
|
||||
gun_mp40 = new ItemGunBase(Gun9mmFactory.getMP40Config()).setUnlocalizedName("gun_mp40").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_mp40");
|
||||
gun_thompson = new ItemGunBase(Gun45ACPFactory.getThompsonConfig()).setUnlocalizedName("gun_thompson").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_thompson");
|
||||
gun_uzi_silencer = new ItemGunBase(Gun22LRFactory.getUziConfig().silenced()).setUnlocalizedName("gun_uzi_silencer").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uzi_silencer");
|
||||
gun_uzi_saturnite = new ItemGunBase(Gun22LRFactory.getSaturniteConfig()).setUnlocalizedName("gun_uzi_saturnite").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uzi_saturnite");
|
||||
gun_uzi_saturnite_silencer = new ItemGunBase(Gun22LRFactory.getSaturniteConfig().silenced()).setUnlocalizedName("gun_uzi_saturnite_silencer").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uzi_saturnite_silencer");
|
||||
gun_uboinik = new ItemGunBase(Gun12GaugeFactory.getUboinikConfig()).setUnlocalizedName("gun_uboinik").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uboinik");
|
||||
gun_remington = new ItemGunBase(Gun12GaugeFactory.getRemington870Config()).setUnlocalizedName("gun_remington").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_spas12");
|
||||
gun_benelli = new ItemGunBase(Gun12GaugeFactory.getBenelliModConfig()).setUnlocalizedName("gun_benelli").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_spas12");
|
||||
gun_supershotgun = new ItemGunShotty(Gun12GaugeFactory.getShottyConfig()).setUnlocalizedName("gun_supershotgun").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uboinik");
|
||||
gun_ks23 = new ItemGunBase(Gun4GaugeFactory.getKS23Config()).setUnlocalizedName("gun_ks23").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uboinik");
|
||||
gun_sauer = new ItemGunBase(Gun4GaugeFactory.getSauerConfig()).setUnlocalizedName("gun_sauer").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uboinik");
|
||||
gun_lever_action = new ItemGunBase(Gun20GaugeFactory.getMareConfig()).setUnlocalizedName("gun_lever_action").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_lever_action");
|
||||
gun_lever_action_dark = new ItemGunBase(Gun20GaugeFactory.getMareDarkConfig()).setUnlocalizedName("gun_lever_action_dark").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_lever_action_dark");
|
||||
gun_lever_action_sonata = new GunLeverActionS().setUnlocalizedName("gun_lever_action_sonata").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_lever_action_sonata");
|
||||
gun_bolt_action = new ItemGunBase(Gun762mmFactory.getBoltConfig()).setUnlocalizedName("gun_bolt_action").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_bolt_action");
|
||||
gun_bolt_action_green = new ItemGunBase(Gun762mmFactory.getBoltGreenConfig()).setUnlocalizedName("gun_bolt_action_green").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_bolt_action_green");
|
||||
gun_bolt_action_saturnite = new ItemGunBase(Gun762mmFactory.getBoltSaturniteConfig()).setUnlocalizedName("gun_bolt_action_saturnite").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_bolt_action_saturnite");
|
||||
gun_mymy = new ItemGunBase(GunDartFactory.getMymyConfig()).setUnlocalizedName("gun_mymy").setFull3D().setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_mymy");
|
||||
gun_rpg = new Item().setUnlocalizedName("gun_rpg").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_rpg");
|
||||
gun_karl = new Item().setUnlocalizedName("gun_karl").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_karl");
|
||||
gun_hk69 = new Item().setUnlocalizedName("gun_hk69").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_hk69");
|
||||
gun_skystinger = new Item().setUnlocalizedName("gun_skystinger").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_skystinger");
|
||||
gun_revolver = new Item().setUnlocalizedName("gun_revolver").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver");
|
||||
gun_revolver_saturnite = new Item().setUnlocalizedName("gun_revolver_saturnite").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_saturnite");
|
||||
gun_revolver_gold = new Item().setUnlocalizedName("gun_revolver_gold").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_gold");
|
||||
gun_revolver_schrabidium = new Item().setUnlocalizedName("gun_revolver_schrabidium").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_schrabidium");
|
||||
gun_revolver_cursed = new Item().setUnlocalizedName("gun_revolver_cursed").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_cursed");
|
||||
gun_revolver_nightmare = new Item().setUnlocalizedName("gun_revolver_nightmare").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_nightmare");
|
||||
gun_revolver_nightmare2 = new Item().setUnlocalizedName("gun_revolver_nightmare2").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_nightmare2");
|
||||
gun_revolver_pip = new Item().setUnlocalizedName("gun_revolver_pip").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_pip");
|
||||
gun_revolver_nopip = new Item().setUnlocalizedName("gun_revolver_nopip").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_nopip");
|
||||
gun_revolver_blackjack = new Item().setUnlocalizedName("gun_revolver_blackjack").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_blackjack");
|
||||
gun_revolver_silver = new Item().setUnlocalizedName("gun_revolver_silver").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_silver");
|
||||
gun_revolver_red = new Item().setUnlocalizedName("gun_revolver_red").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_red");
|
||||
gun_deagle = new Item().setUnlocalizedName("gun_deagle").setFull3D().setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_deagle");
|
||||
gun_bio_revolver = new Item().setUnlocalizedName("gun_bio_revolver").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_bio_revolver");
|
||||
gun_flechette = new Item().setUnlocalizedName("gun_flechette").setFull3D().setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_flechette");
|
||||
gun_ar15 = new Item().setUnlocalizedName("gun_ar15").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_ar15");
|
||||
gun_calamity = new Item().setUnlocalizedName("gun_calamity").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_calamity");
|
||||
gun_lacunae = new Item().setUnlocalizedName("gun_lacunae").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_lacunae");
|
||||
gun_proto = new Item().setUnlocalizedName("gun_proto").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_fatman");
|
||||
gun_mirv = new Item().setUnlocalizedName("gun_mirv").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_mirv");
|
||||
gun_bf = new Item().setUnlocalizedName("gun_bf").setCreativeTab(null).setTextureName(RefStrings.MODID + ":gun_bf");
|
||||
gun_mp40 = new Item().setUnlocalizedName("gun_mp40").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_mp40");
|
||||
gun_thompson = new Item().setUnlocalizedName("gun_thompson").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_thompson");
|
||||
gun_uzi_silencer = new Item().setUnlocalizedName("gun_uzi_silencer").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uzi_silencer");
|
||||
gun_uzi_saturnite = new Item().setUnlocalizedName("gun_uzi_saturnite").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uzi_saturnite");
|
||||
gun_uzi_saturnite_silencer = new Item().setUnlocalizedName("gun_uzi_saturnite_silencer").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uzi_saturnite_silencer");
|
||||
gun_uboinik = new Item().setUnlocalizedName("gun_uboinik").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uboinik");
|
||||
gun_remington = new Item().setUnlocalizedName("gun_remington").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_spas12");
|
||||
gun_benelli = new Item().setUnlocalizedName("gun_benelli").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_spas12");
|
||||
gun_supershotgun = new Item().setUnlocalizedName("gun_supershotgun").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uboinik");
|
||||
gun_ks23 = new Item().setUnlocalizedName("gun_ks23").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uboinik");
|
||||
gun_sauer = new Item().setUnlocalizedName("gun_sauer").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_uboinik");
|
||||
gun_lever_action = new Item().setUnlocalizedName("gun_lever_action").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_lever_action");
|
||||
gun_lever_action_dark = new Item().setUnlocalizedName("gun_lever_action_dark").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_lever_action_dark");
|
||||
gun_lever_action_sonata = new Item().setUnlocalizedName("gun_lever_action_sonata").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_lever_action_sonata");
|
||||
gun_bolt_action = new Item().setUnlocalizedName("gun_bolt_action").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_bolt_action");
|
||||
gun_bolt_action_green = new Item().setUnlocalizedName("gun_bolt_action_green").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_bolt_action_green");
|
||||
gun_bolt_action_saturnite = new Item().setUnlocalizedName("gun_bolt_action_saturnite").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_bolt_action_saturnite");
|
||||
gun_mymy = new Item().setUnlocalizedName("gun_mymy").setFull3D().setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_mymy");
|
||||
gun_b92_ammo = new GunB92Cell().setUnlocalizedName("gun_b92_ammo").setMaxStackSize(1).setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_b92_ammo_alt");
|
||||
gun_b92 = new GunB92().setUnlocalizedName("gun_b92").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_b92");
|
||||
gun_b93 = new GunB93().setUnlocalizedName("gun_b93").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_b93");
|
||||
gun_b93 = new Item().setUnlocalizedName("gun_b93").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_b93");
|
||||
gun_xvl1456_ammo = new Item().setUnlocalizedName("gun_xvl1456_ammo").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_xvl1456_ammo");
|
||||
gun_xvl1456 = new ItemGunGauss(GunGaussFactory.getXVLConfig(), GunGaussFactory.getChargedConfig()).setUnlocalizedName("gun_xvl1456").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_xvl1456");
|
||||
gun_xvl1456 = new Item().setUnlocalizedName("gun_xvl1456").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_xvl1456");
|
||||
gun_osipr_ammo = new Item().setUnlocalizedName("gun_osipr_ammo").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_osipr_ammo");
|
||||
gun_osipr_ammo2 = new Item().setUnlocalizedName("gun_osipr_ammo2").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_osipr_ammo2");
|
||||
gun_osipr = new ItemGunOSIPR(GunOSIPRFactory.getOSIPRConfig(), GunOSIPRFactory.getAltConfig()).setUnlocalizedName("gun_osipr").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_osipr");
|
||||
gun_osipr = new Item().setUnlocalizedName("gun_osipr").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_osipr");
|
||||
gun_immolator_ammo = new Item().setUnlocalizedName("gun_immolator_ammo").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_immolator_ammo");
|
||||
gun_immolator = new Item().setUnlocalizedName("gun_immolator").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_immolator");
|
||||
gun_cryolator_ammo = new Item().setUnlocalizedName("gun_cryolator_ammo").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_cryolator_ammo");
|
||||
gun_cryolator = new GunCryolator().setUnlocalizedName("gun_cryolator").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_cryolator");
|
||||
gun_cryolator = new Item().setUnlocalizedName("gun_cryolator").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_cryolator");
|
||||
gun_cryocannon = new ItemCryoCannon(GunEnergyFactory.getCryoCannonConfig()).setUnlocalizedName("gun_cryocannon").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_cryocannon");
|
||||
gun_fireext = new ItemGunBase(GunEnergyFactory.getExtConfig()).setUnlocalizedName("gun_fireext").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_fireext");
|
||||
gun_mp = new ItemGunBase(Gun556mmFactory.getEuphieConfig()).setUnlocalizedName("gun_mp").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_pm");
|
||||
gun_bolter_digamma = new ItemGunBase(Gun75BoltFactory.getBolterConfig()).setUnlocalizedName("gun_bolter_digamma").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_bolter_digamma");
|
||||
gun_zomg = new ItemGunBase(GunEnergyFactory.getZOMGConfig()).setUnlocalizedName("gun_zomg").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_zomg");
|
||||
gun_revolver_inverted = new GunSuicide().setUnlocalizedName("gun_revolver_inverted").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_inverted");
|
||||
gun_mp = new Item().setUnlocalizedName("gun_mp").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_pm");
|
||||
gun_bolter_digamma = new Item().setUnlocalizedName("gun_bolter_digamma").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_bolter_digamma");
|
||||
gun_zomg = new Item().setUnlocalizedName("gun_zomg").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_zomg");
|
||||
gun_revolver_inverted = new Item().setUnlocalizedName("gun_revolver_inverted").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_revolver_inverted");
|
||||
gun_emp_ammo = new Item().setUnlocalizedName("gun_emp_ammo").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_emp_ammo");
|
||||
gun_emp = new ItemGunBase(GunEnergyFactory.getEMPConfig()).setUnlocalizedName("gun_emp").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_emp");
|
||||
gun_emp = new Item().setUnlocalizedName("gun_emp").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_emp");
|
||||
gun_jack_ammo = new Item().setUnlocalizedName("gun_jack_ammo").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_jack_ammo");
|
||||
gun_jack = new GunJack().setUnlocalizedName("gun_jack").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_jack");
|
||||
gun_jack = new Item().setUnlocalizedName("gun_jack").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_jack");
|
||||
gun_spark_ammo = new Item().setUnlocalizedName("gun_spark_ammo").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_spark_ammo");
|
||||
gun_spark = new GunSpark().setUnlocalizedName("gun_spark").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_spark");
|
||||
gun_spark = new Item().setUnlocalizedName("gun_spark").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_spark");
|
||||
gun_hp_ammo = new Item().setUnlocalizedName("gun_hp_ammo").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_hp_ammo");
|
||||
gun_hp = new GunHP().setUnlocalizedName("gun_hp").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_hp");
|
||||
gun_hp = new Item().setUnlocalizedName("gun_hp").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_hp");
|
||||
gun_euthanasia_ammo = new Item().setUnlocalizedName("gun_euthanasia_ammo").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_euthanasia_ammo");
|
||||
gun_euthanasia = new GunEuthanasia().setUnlocalizedName("gun_euthanasia").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_euthanasia");
|
||||
gun_euthanasia = new Item().setUnlocalizedName("gun_euthanasia").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_euthanasia");
|
||||
gun_defabricator_ammo = new Item().setUnlocalizedName("gun_defabricator_ammo").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_defabricator_ammo");
|
||||
gun_defabricator = new GunDefabricator().setUnlocalizedName("gun_defabricator").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_defabricator");
|
||||
gun_vortex = new ItemGunBase(Gun556mmFactory.getEuphieConfig()).setUnlocalizedName("gun_vortex").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_vortex");
|
||||
gun_super_shotgun = new ItemCustomLore().setUnlocalizedName("gun_super_shotgun").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_super_shotgun");
|
||||
gun_moist_nugget = new ItemNugget(3, false).setUnlocalizedName("gun_moist_nugget").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_moist_nugget");
|
||||
gun_darter = new ItemGunDart(GunDartFactory.getDarterConfig()).setFull3D().setUnlocalizedName("gun_darter").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_darter");
|
||||
gun_glass_cannon = new ItemEnergyGunBase(GunPoweredFactory.getGlassCannonConfig()).setFull3D().setUnlocalizedName("gun_glass_cannon").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_darter");
|
||||
gun_lunatic_marksman = new ItemGunBase(Gun50BMGFactory.getLunaticMarksman()).setFull3D().setUnlocalizedName("gun_lunatic_marksman").setCreativeTab(MainRegistry.weaponTab);
|
||||
gun_uac_pistol = new ItemGunBase(Gun45ACPFactory.getUACPistolConfig(), Gun45ACPFactory.getUACPistolBurstConfig()).setFull3D().setUnlocalizedName("gun_uac_pistol").setCreativeTab(MainRegistry.weaponTab);
|
||||
gun_defabricator = new Item().setUnlocalizedName("gun_defabricator").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_defabricator");
|
||||
gun_vortex = new Item().setUnlocalizedName("gun_vortex").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_vortex");
|
||||
gun_super_shotgun = new Item().setUnlocalizedName("gun_super_shotgun").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_super_shotgun");
|
||||
gun_moist_nugget = new Item().setUnlocalizedName("gun_moist_nugget").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_moist_nugget");
|
||||
gun_darter = new Item().setFull3D().setUnlocalizedName("gun_darter").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_darter");
|
||||
gun_glass_cannon = new Item().setFull3D().setUnlocalizedName("gun_glass_cannon").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_darter");
|
||||
gun_lunatic_marksman = new Item().setFull3D().setUnlocalizedName("gun_lunatic_marksman").setCreativeTab(MainRegistry.weaponTab);
|
||||
gun_uac_pistol = new Item().setFull3D().setUnlocalizedName("gun_uac_pistol").setCreativeTab(MainRegistry.weaponTab);
|
||||
|
||||
ToolMaterial matCrucible = EnumHelper.addToolMaterial("CRUCIBLE", 10, 3, 50.0F, 100.0F, 0);
|
||||
crucible = new ItemCrucible(5000, 1F, matCrucible).setUnlocalizedName("crucible").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":crucible");
|
||||
@ -4434,38 +4387,6 @@ public class ModItems {
|
||||
loot_10 = new ItemLootCrate().setUnlocalizedName("loot_10").setMaxStackSize(1).setCreativeTab(MainRegistry.missileTab).setTextureName(RefStrings.MODID + ":loot_10");
|
||||
loot_15 = new ItemLootCrate().setUnlocalizedName("loot_15").setMaxStackSize(1).setCreativeTab(MainRegistry.missileTab).setTextureName(RefStrings.MODID + ":loot_15");
|
||||
loot_misc = new ItemLootCrate().setUnlocalizedName("loot_misc").setMaxStackSize(1).setCreativeTab(MainRegistry.missileTab).setTextureName(RefStrings.MODID + ":loot_misc");
|
||||
|
||||
clip_revolver_iron = new ItemClip(ammo_357.stackFromEnum(20, Ammo357Magnum.IRON)).setUnlocalizedName("clip_revolver_iron").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_revolver_iron");
|
||||
clip_revolver = new ItemClip(ammo_357.stackFromEnum(12, Ammo357Magnum.LEAD)).setUnlocalizedName("clip_revolver").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_revolver");
|
||||
clip_revolver_gold = new ItemClip(ammo_357.stackFromEnum(6, Ammo357Magnum.GOLD)).setUnlocalizedName("clip_revolver_gold").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_revolver_gold");
|
||||
clip_revolver_lead = new ItemClip(ammo_357.stackFromEnum(6, Ammo357Magnum.NUCLEAR)).setUnlocalizedName("clip_revolver_lead").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_revolver_lead");
|
||||
clip_revolver_schrabidium = new ItemClip(ammo_357.stackFromEnum(2, Ammo357Magnum.SCHRABIDIUM)).setUnlocalizedName("clip_revolver_schrabidium").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_revolver_schrabidium");
|
||||
clip_revolver_cursed = new ItemClip(ammo_357.stackFromEnum(17, Ammo357Magnum.STEEL)).setUnlocalizedName("clip_revolver_cursed").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_revolver_cursed");
|
||||
clip_revolver_nightmare = new ItemClip(ammo_357.stackFromEnum(6, Ammo357Magnum.NIGHTMARE1)).setUnlocalizedName("clip_revolver_nightmare").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_revolver_nightmare");
|
||||
clip_revolver_nightmare2 = new ItemClip(ammo_357.stackFromEnum(6, Ammo357Magnum.NIGHTMARE2)).setUnlocalizedName("clip_revolver_nightmare2").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_revolver_nightmare2");
|
||||
clip_revolver_pip = new ItemClip(ammo_44.stackFromEnum(6, Ammo44Magnum.PIP)).setUnlocalizedName("clip_revolver_pip").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_revolver_pip");
|
||||
clip_revolver_nopip = new ItemClip(ammo_44.stackFromEnum(6, Ammo44Magnum.STOCK)).setUnlocalizedName("clip_revolver_nopip").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_revolver_nopip");
|
||||
clip_rpg = new ItemClip(ammo_rocket.stackFromEnum(4, AmmoRocket.STOCK)).setUnlocalizedName("clip_rpg").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_rpg_alt");
|
||||
clip_stinger = new ItemClip(ammo_stinger_rocket.stackFromEnum(4, AmmoStinger.STOCK)).setUnlocalizedName("clip_stinger").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_stinger");
|
||||
clip_fatman = new ItemClip(ammo_nuke.stackFromEnum(6, AmmoFatman.STOCK)).setUnlocalizedName("clip_fatman").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_fatman");
|
||||
clip_mirv = new ItemClip(ammo_nuke.stackFromEnum(3, AmmoFatman.MIRV)).setUnlocalizedName("clip_mirv").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_mirv");
|
||||
clip_bf = new ItemClip(ammo_nuke.stackFromEnum(2, AmmoFatman.BALEFIRE)).setUnlocalizedName("clip_bf").setCreativeTab(null).setTextureName(RefStrings.MODID + ":clip_bf");
|
||||
clip_mp40 = new ItemClip(ammo_9mm.stackFromEnum(32, Ammo9mm.STOCK)).setUnlocalizedName("clip_mp40").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_mp40");
|
||||
clip_uzi = new ItemClip(ammo_22lr.stackFromEnum(32, Ammo22LR.STOCK)).setUnlocalizedName("clip_uzi").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_uzi");
|
||||
clip_uboinik = new ItemClip(ammo_12gauge.stackFromEnum(12, Ammo12Gauge.STOCK)).setUnlocalizedName("clip_uboinik").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_uboinik");
|
||||
clip_lever_action = new ItemClip(ammo_20gauge.stackFromEnum(12, Ammo20Gauge.STOCK)).setUnlocalizedName("clip_lever_action").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_lever_action");
|
||||
clip_bolt_action = new ItemClip(ammo_20gauge.stackFromEnum(12, Ammo20Gauge.SLUG)).setUnlocalizedName("clip_bolt_action").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_bolt_action");
|
||||
clip_osipr = new ItemClip(new ItemStack(gun_osipr_ammo, 3)).setUnlocalizedName("clip_osipr").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_osipr");
|
||||
clip_immolator = new ItemClip(new ItemStack(gun_immolator_ammo, 60)).setUnlocalizedName("clip_immolator").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_immolator");
|
||||
clip_cryolator = new ItemClip(new ItemStack(gun_cryolator_ammo, 60)).setUnlocalizedName("clip_cryolator").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_cryolator");
|
||||
clip_mp = new ItemClip(ammo_556.stackFromEnum(2, Ammo556mm.GOLD)).setUnlocalizedName("clip_mp").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_mp");
|
||||
clip_xvl1456 = new ItemClip(new ItemStack(gun_xvl1456_ammo, 50)).setUnlocalizedName("clip_xvl1456").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_xvl1456");
|
||||
clip_emp = new ItemClip(new ItemStack(gun_emp_ammo, 12)).setUnlocalizedName("clip_emp").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_emp");
|
||||
clip_jack = new ItemClip(new ItemStack(gun_jack_ammo, 12)).setUnlocalizedName("clip_jack").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_jack");
|
||||
clip_spark = new ItemClip(new ItemStack(gun_spark_ammo, 12)).setUnlocalizedName("clip_spark").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_spark");
|
||||
clip_hp = new ItemClip(new ItemStack(gun_hp_ammo, 24)).setUnlocalizedName("clip_hp").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_hp");
|
||||
clip_euthanasia = new ItemClip(new ItemStack(gun_euthanasia_ammo, 32)).setUnlocalizedName("clip_euthanasia").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_euthanasia");
|
||||
clip_defabricator = new ItemClip(new ItemStack(gun_defabricator_ammo, 50)).setUnlocalizedName("clip_defabricator").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":clip_defabricator");
|
||||
|
||||
ammo_container = new ItemAmmoContainer().setUnlocalizedName("ammo_container").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_container");
|
||||
|
||||
@ -4480,7 +4401,6 @@ public class ModItems {
|
||||
detonator_laser = new ItemLaserDetonator().setUnlocalizedName("detonator_laser").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.nukeTab).setTextureName(RefStrings.MODID + ":detonator_laser");
|
||||
detonator_deadman = new ItemDrop().setUnlocalizedName("detonator_deadman").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.nukeTab).setTextureName(RefStrings.MODID + ":detonator_deadman");
|
||||
detonator_de = new ItemDrop().setUnlocalizedName("detonator_de").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.nukeTab).setTextureName(RefStrings.MODID + ":detonator_de");
|
||||
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");
|
||||
anchor_remote = new ItemAnchorRemote().setUnlocalizedName("anchor_remote").setMaxStackSize(1).setFull3D().setCreativeTab(MainRegistry.consumableTab).setTextureName(RefStrings.MODID + ":anchor_remote");
|
||||
@ -4588,69 +4508,68 @@ public class ModItems {
|
||||
beta = new ItemDrop().setUnlocalizedName("beta").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":beta");
|
||||
//oxy_mask = new ArmorModel(ArmorMaterial.IRON, 7, 0).setUnlocalizedName("oxy_mask").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":oxy_mask");
|
||||
|
||||
schrabidium_helmet = new ArmorFSB(MainRegistry.aMatSchrab, 0, RefStrings.MODID + ":textures/armor/schrabidium_1.png").setCap(4F).setMod(0.1F)
|
||||
schrabidium_helmet = new ArmorFSB(MainRegistry.aMatSchrab, 0, RefStrings.MODID + ":textures/armor/schrabidium_1.png")
|
||||
.addEffect(new PotionEffect(Potion.digSpeed.id, 20, 2))
|
||||
.addEffect(new PotionEffect(Potion.damageBoost.id, 20, 2))
|
||||
.addEffect(new PotionEffect(Potion.jump.id, 20, 1))
|
||||
.addEffect(new PotionEffect(Potion.moveSpeed.id, 20, 2))
|
||||
.setFireproof(true).setUnlocalizedName("schrabidium_helmet").setTextureName(RefStrings.MODID + ":schrabidium_helmet");
|
||||
.setUnlocalizedName("schrabidium_helmet").setTextureName(RefStrings.MODID + ":schrabidium_helmet");
|
||||
schrabidium_plate = new ArmorFSB(MainRegistry.aMatSchrab, 1, RefStrings.MODID + ":textures/armor/schrabidium_1.png").cloneStats((ArmorFSB) schrabidium_helmet).setUnlocalizedName("schrabidium_plate").setTextureName(RefStrings.MODID + ":schrabidium_plate");
|
||||
schrabidium_legs = new ArmorFSB(MainRegistry.aMatSchrab, 2, RefStrings.MODID + ":textures/armor/schrabidium_2.png").cloneStats((ArmorFSB) schrabidium_helmet).setCap(4F).setMod(0.1F).setUnlocalizedName("schrabidium_legs").setTextureName(RefStrings.MODID + ":schrabidium_legs");
|
||||
schrabidium_boots = new ArmorFSB(MainRegistry.aMatSchrab, 3, RefStrings.MODID + ":textures/armor/schrabidium_1.png").cloneStats((ArmorFSB) schrabidium_helmet).setCap(4F).setMod(0.1F).setUnlocalizedName("schrabidium_boots").setTextureName(RefStrings.MODID + ":schrabidium_boots");
|
||||
bismuth_helmet = new ArmorBismuth(MainRegistry.aMatBismuth, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png").setCap(8F).setMod(0.3F)
|
||||
.addResistance("fall", 0)
|
||||
schrabidium_legs = new ArmorFSB(MainRegistry.aMatSchrab, 2, RefStrings.MODID + ":textures/armor/schrabidium_2.png").cloneStats((ArmorFSB) schrabidium_helmet).setUnlocalizedName("schrabidium_legs").setTextureName(RefStrings.MODID + ":schrabidium_legs");
|
||||
schrabidium_boots = new ArmorFSB(MainRegistry.aMatSchrab, 3, RefStrings.MODID + ":textures/armor/schrabidium_1.png").cloneStats((ArmorFSB) schrabidium_helmet).setUnlocalizedName("schrabidium_boots").setTextureName(RefStrings.MODID + ":schrabidium_boots");
|
||||
bismuth_helmet = new ArmorBismuth(MainRegistry.aMatBismuth, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png")
|
||||
.addEffect(new PotionEffect(Potion.jump.id, 20, 6))
|
||||
.addEffect(new PotionEffect(Potion.moveSpeed.id, 20, 6))
|
||||
.addEffect(new PotionEffect(Potion.regeneration.id, 20, 1))
|
||||
.addEffect(new PotionEffect(Potion.nightVision.id, 15 * 20, 0))
|
||||
.setDashCount(3)
|
||||
.setUnlocalizedName("bismuth_helmet").setTextureName(RefStrings.MODID + ":bismuth_helmet");
|
||||
bismuth_plate = new ArmorBismuth(MainRegistry.aMatBismuth, 1, RefStrings.MODID + ":textures/armor/starmetal_2.png").cloneStats((ArmorFSB) bismuth_helmet).setCap(8F).setMod(0.3F).setUnlocalizedName("bismuth_plate").setTextureName(RefStrings.MODID + ":bismuth_plate");
|
||||
bismuth_legs = new ArmorBismuth(MainRegistry.aMatBismuth, 2, RefStrings.MODID + ":textures/armor/starmetal_1.png").cloneStats((ArmorFSB) bismuth_helmet).setCap(8F).setMod(0.3F).setUnlocalizedName("bismuth_legs").setTextureName(RefStrings.MODID + ":bismuth_legs");
|
||||
bismuth_boots = new ArmorBismuth(MainRegistry.aMatBismuth, 3, RefStrings.MODID + ":textures/armor/starmetal_1.png").cloneStats((ArmorFSB) bismuth_helmet).setCap(8F).setMod(0.3F).setUnlocalizedName("bismuth_boots").setTextureName(RefStrings.MODID + ":bismuth_boots");
|
||||
titanium_helmet = new ArmorFSB(MainRegistry.aMatTitan, 0, RefStrings.MODID + ":textures/armor/titanium_1.png").setMod(0.85F).setUnlocalizedName("titanium_helmet").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":titanium_helmet");
|
||||
bismuth_plate = new ArmorBismuth(MainRegistry.aMatBismuth, 1, RefStrings.MODID + ":textures/armor/starmetal_2.png").cloneStats((ArmorFSB) bismuth_helmet).setUnlocalizedName("bismuth_plate").setTextureName(RefStrings.MODID + ":bismuth_plate");
|
||||
bismuth_legs = new ArmorBismuth(MainRegistry.aMatBismuth, 2, RefStrings.MODID + ":textures/armor/starmetal_1.png").cloneStats((ArmorFSB) bismuth_helmet).setUnlocalizedName("bismuth_legs").setTextureName(RefStrings.MODID + ":bismuth_legs");
|
||||
bismuth_boots = new ArmorBismuth(MainRegistry.aMatBismuth, 3, RefStrings.MODID + ":textures/armor/starmetal_1.png").cloneStats((ArmorFSB) bismuth_helmet).setUnlocalizedName("bismuth_boots").setTextureName(RefStrings.MODID + ":bismuth_boots");
|
||||
titanium_helmet = new ArmorFSB(MainRegistry.aMatTitan, 0, RefStrings.MODID + ":textures/armor/titanium_1.png").setUnlocalizedName("titanium_helmet").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":titanium_helmet");
|
||||
titanium_plate = new ArmorFSB(MainRegistry.aMatTitan, 1, RefStrings.MODID + ":textures/armor/titanium_1.png").cloneStats((ArmorFSB) titanium_helmet).setUnlocalizedName("titanium_plate").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":titanium_plate");
|
||||
titanium_legs = new ArmorFSB(MainRegistry.aMatTitan, 2, RefStrings.MODID + ":textures/armor/titanium_2.png").cloneStats((ArmorFSB) titanium_helmet).setUnlocalizedName("titanium_legs").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":titanium_legs");
|
||||
titanium_boots = new ArmorFSB(MainRegistry.aMatTitan, 3, RefStrings.MODID + ":textures/armor/titanium_1.png").cloneStats((ArmorFSB) titanium_helmet).setUnlocalizedName("titanium_boots").setTextureName(RefStrings.MODID + ":titanium_boots");
|
||||
steel_helmet = new ArmorFSB(MainRegistry.aMatSteel, 0, RefStrings.MODID + ":textures/armor/steel_1.png").setMod(0.9F).setUnlocalizedName("steel_helmet").setTextureName(RefStrings.MODID + ":steel_helmet");
|
||||
steel_helmet = new ArmorFSB(MainRegistry.aMatSteel, 0, RefStrings.MODID + ":textures/armor/steel_1.png").setUnlocalizedName("steel_helmet").setTextureName(RefStrings.MODID + ":steel_helmet");
|
||||
steel_plate = new ArmorFSB(MainRegistry.aMatSteel, 1, RefStrings.MODID + ":textures/armor/steel_1.png").cloneStats((ArmorFSB) steel_helmet).setUnlocalizedName("steel_plate").setTextureName(RefStrings.MODID + ":steel_plate");
|
||||
steel_legs = new ArmorFSB(MainRegistry.aMatSteel, 2, RefStrings.MODID + ":textures/armor/steel_2.png").cloneStats((ArmorFSB) steel_helmet).setUnlocalizedName("steel_legs").setTextureName(RefStrings.MODID + ":steel_legs");
|
||||
steel_boots = new ArmorFSB(MainRegistry.aMatSteel, 3, RefStrings.MODID + ":textures/armor/steel_1.png").cloneStats((ArmorFSB) steel_helmet).setUnlocalizedName("steel_boots").setTextureName(RefStrings.MODID + ":steel_boots");
|
||||
alloy_helmet = new ArmorFSB(MainRegistry.aMatAlloy, 0, RefStrings.MODID + ":textures/armor/alloy_1.png").setMod(0.75F).setUnlocalizedName("alloy_helmet").setTextureName(RefStrings.MODID + ":alloy_helmet");
|
||||
alloy_helmet = new ArmorFSB(MainRegistry.aMatAlloy, 0, RefStrings.MODID + ":textures/armor/alloy_1.png").setUnlocalizedName("alloy_helmet").setTextureName(RefStrings.MODID + ":alloy_helmet");
|
||||
alloy_plate = new ArmorFSB(MainRegistry.aMatAlloy, 1, RefStrings.MODID + ":textures/armor/alloy_1.png").cloneStats((ArmorFSB) alloy_helmet).setUnlocalizedName("alloy_plate").setTextureName(RefStrings.MODID + ":alloy_plate");
|
||||
alloy_legs = new ArmorFSB(MainRegistry.aMatAlloy, 2, RefStrings.MODID + ":textures/armor/alloy_2.png").cloneStats((ArmorFSB) alloy_helmet).setUnlocalizedName("alloy_legs").setTextureName(RefStrings.MODID + ":alloy_legs");
|
||||
alloy_boots = new ArmorFSB(MainRegistry.aMatAlloy, 3, RefStrings.MODID + ":textures/armor/alloy_1.png").cloneStats((ArmorFSB) alloy_helmet).setUnlocalizedName("alloy_boots").setTextureName(RefStrings.MODID + ":alloy_boots");
|
||||
cmb_helmet = new ArmorFSB(MainRegistry.aMatCMB, 0, RefStrings.MODID + ":textures/armor/cmb_1.png").setCap(2F).setThreshold(2F).setMod(0.05F)
|
||||
cmb_helmet = new ArmorFSB(MainRegistry.aMatCMB, 0, RefStrings.MODID + ":textures/armor/cmb_1.png")
|
||||
.addEffect(new PotionEffect(Potion.moveSpeed.id, 20, 2))
|
||||
.addEffect(new PotionEffect(Potion.digSpeed.id, 20, 2))
|
||||
.addEffect(new PotionEffect(Potion.damageBoost.id, 20, 4))
|
||||
.setFireproof(true).setUnlocalizedName("cmb_helmet").setTextureName(RefStrings.MODID + ":cmb_helmet");
|
||||
.setUnlocalizedName("cmb_helmet").setTextureName(RefStrings.MODID + ":cmb_helmet");
|
||||
cmb_plate = new ArmorFSB(MainRegistry.aMatCMB, 1, RefStrings.MODID + ":textures/armor/cmb_1.png").cloneStats((ArmorFSB) cmb_helmet).setUnlocalizedName("cmb_plate").setTextureName(RefStrings.MODID + ":cmb_plate");
|
||||
cmb_legs = new ArmorFSB(MainRegistry.aMatCMB, 2, RefStrings.MODID + ":textures/armor/cmb_2.png").cloneStats((ArmorFSB) cmb_helmet).setUnlocalizedName("cmb_legs").setTextureName(RefStrings.MODID + ":cmb_legs");
|
||||
cmb_boots = new ArmorFSB(MainRegistry.aMatCMB, 3, RefStrings.MODID + ":textures/armor/cmb_1.png").cloneStats((ArmorFSB) cmb_helmet).setUnlocalizedName("cmb_boots").setTextureName(RefStrings.MODID + ":cmb_boots");
|
||||
paa_plate = new ArmorFSB(MainRegistry.aMatPaa, 1, RefStrings.MODID + ":textures/armor/paa_1.png").setCap(6F).setMod(0.3F).setNoHelmet(true)
|
||||
paa_plate = new ArmorFSB(MainRegistry.aMatPaa, 1, RefStrings.MODID + ":textures/armor/paa_1.png").setNoHelmet(true)
|
||||
.addEffect(new PotionEffect(Potion.digSpeed.id, 20, 0)).setUnlocalizedName("paa_plate").setTextureName(RefStrings.MODID + ":paa_plate");
|
||||
paa_legs = new ArmorFSB(MainRegistry.aMatPaa, 2, RefStrings.MODID + ":textures/armor/paa_2.png").cloneStats((ArmorFSB) paa_plate).setUnlocalizedName("paa_legs").setTextureName(RefStrings.MODID + ":paa_legs");
|
||||
paa_boots = new ArmorFSB(MainRegistry.aMatPaa, 3, RefStrings.MODID + ":textures/armor/paa_1.png").cloneStats((ArmorFSB) paa_plate).setUnlocalizedName("paa_boots").setTextureName(RefStrings.MODID + ":paa_boots");
|
||||
asbestos_helmet = new ArmorFSB(MainRegistry.aMatAsbestos, 0, RefStrings.MODID + ":textures/armor/asbestos_1.png").setFireproof(true).setOverlay(RefStrings.MODID + ":textures/misc/overlay_asbestos.png").setUnlocalizedName("asbestos_helmet").setTextureName(RefStrings.MODID + ":asbestos_helmet");
|
||||
asbestos_plate = new ArmorFSB(MainRegistry.aMatAsbestos, 1, RefStrings.MODID + ":textures/armor/asbestos_1.png").setFireproof(true).setUnlocalizedName("asbestos_plate").setTextureName(RefStrings.MODID + ":asbestos_plate");
|
||||
asbestos_legs = new ArmorFSB(MainRegistry.aMatAsbestos, 2, RefStrings.MODID + ":textures/armor/asbestos_2.png").setFireproof(true).setUnlocalizedName("asbestos_legs").setTextureName(RefStrings.MODID + ":asbestos_legs");
|
||||
asbestos_boots = new ArmorFSB(MainRegistry.aMatAsbestos, 3, RefStrings.MODID + ":textures/armor/asbestos_1.png").setFireproof(true).setUnlocalizedName("asbestos_boots").setTextureName(RefStrings.MODID + ":asbestos_boots");
|
||||
security_helmet = new ArmorFSB(MainRegistry.aMatSecurity, 0, RefStrings.MODID + ":textures/armor/security_1.png").setMod(0.65F).setProjectileProtection(0.5F).setUnlocalizedName("security_helmet").setTextureName(RefStrings.MODID + ":security_helmet");
|
||||
asbestos_helmet = new ArmorFSB(MainRegistry.aMatAsbestos, 0, RefStrings.MODID + ":textures/armor/asbestos_1.png").setOverlay(RefStrings.MODID + ":textures/misc/overlay_asbestos.png").setUnlocalizedName("asbestos_helmet").setTextureName(RefStrings.MODID + ":asbestos_helmet");
|
||||
asbestos_plate = new ArmorFSB(MainRegistry.aMatAsbestos, 1, RefStrings.MODID + ":textures/armor/asbestos_1.png").setUnlocalizedName("asbestos_plate").setTextureName(RefStrings.MODID + ":asbestos_plate");
|
||||
asbestos_legs = new ArmorFSB(MainRegistry.aMatAsbestos, 2, RefStrings.MODID + ":textures/armor/asbestos_2.png").setUnlocalizedName("asbestos_legs").setTextureName(RefStrings.MODID + ":asbestos_legs");
|
||||
asbestos_boots = new ArmorFSB(MainRegistry.aMatAsbestos, 3, RefStrings.MODID + ":textures/armor/asbestos_1.png").setUnlocalizedName("asbestos_boots").setTextureName(RefStrings.MODID + ":asbestos_boots");
|
||||
security_helmet = new ArmorFSB(MainRegistry.aMatSecurity, 0, RefStrings.MODID + ":textures/armor/security_1.png").setUnlocalizedName("security_helmet").setTextureName(RefStrings.MODID + ":security_helmet");
|
||||
security_plate = new ArmorFSB(MainRegistry.aMatSecurity, 1, RefStrings.MODID + ":textures/armor/security_1.png").cloneStats((ArmorFSB) security_helmet).setUnlocalizedName("security_plate").setTextureName(RefStrings.MODID + ":security_plate");
|
||||
security_legs = new ArmorFSB(MainRegistry.aMatSecurity, 2, RefStrings.MODID + ":textures/armor/security_2.png").cloneStats((ArmorFSB) security_helmet).setUnlocalizedName("security_legs").setTextureName(RefStrings.MODID + ":security_legs");
|
||||
security_boots = new ArmorFSB(MainRegistry.aMatSecurity, 3, RefStrings.MODID + ":textures/armor/security_1.png").cloneStats((ArmorFSB) security_helmet).setUnlocalizedName("security_boots").setTextureName(RefStrings.MODID + ":security_boots");
|
||||
cobalt_helmet = new ArmorFSB(MainRegistry.aMatCobalt, 0, RefStrings.MODID + ":textures/armor/cobalt_1.png").setMod(0.7F).setUnlocalizedName("cobalt_helmet").setTextureName(RefStrings.MODID + ":cobalt_helmet");
|
||||
cobalt_helmet = new ArmorFSB(MainRegistry.aMatCobalt, 0, RefStrings.MODID + ":textures/armor/cobalt_1.png").setUnlocalizedName("cobalt_helmet").setTextureName(RefStrings.MODID + ":cobalt_helmet");
|
||||
cobalt_plate = new ArmorFSB(MainRegistry.aMatCobalt, 1, RefStrings.MODID + ":textures/armor/cobalt_1.png").cloneStats((ArmorFSB) cobalt_helmet).setUnlocalizedName("cobalt_plate").setTextureName(RefStrings.MODID + ":cobalt_plate");
|
||||
cobalt_legs = new ArmorFSB(MainRegistry.aMatCobalt, 2, RefStrings.MODID + ":textures/armor/cobalt_2.png").cloneStats((ArmorFSB) cobalt_helmet).setUnlocalizedName("cobalt_legs").setTextureName(RefStrings.MODID + ":cobalt_legs");
|
||||
cobalt_boots = new ArmorFSB(MainRegistry.aMatCobalt, 3, RefStrings.MODID + ":textures/armor/cobalt_1.png").cloneStats((ArmorFSB) cobalt_helmet).setUnlocalizedName("cobalt_boots").setTextureName(RefStrings.MODID + ":cobalt_boots");
|
||||
starmetal_helmet = new ArmorFSB(MainRegistry.aMatStarmetal, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png").setMod(0.5F).setCap(15F)
|
||||
.setFireproof(true).setUnlocalizedName("starmetal_helmet").setTextureName(RefStrings.MODID + ":starmetal_helmet");
|
||||
starmetal_helmet = new ArmorFSB(MainRegistry.aMatStarmetal, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png")
|
||||
.setUnlocalizedName("starmetal_helmet").setTextureName(RefStrings.MODID + ":starmetal_helmet");
|
||||
starmetal_plate = new ArmorFSB(MainRegistry.aMatStarmetal, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png").cloneStats((ArmorFSB) starmetal_helmet).setUnlocalizedName("starmetal_plate").setTextureName(RefStrings.MODID + ":starmetal_plate");
|
||||
starmetal_legs = new ArmorFSB(MainRegistry.aMatStarmetal, 2, RefStrings.MODID + ":textures/armor/starmetal_2.png").cloneStats((ArmorFSB) starmetal_helmet).setUnlocalizedName("starmetal_legs").setTextureName(RefStrings.MODID + ":starmetal_legs");
|
||||
starmetal_boots = new ArmorFSB(MainRegistry.aMatStarmetal, 3, RefStrings.MODID + ":textures/armor/starmetal_1.png").cloneStats((ArmorFSB) starmetal_helmet).setUnlocalizedName("starmetal_boots").setTextureName(RefStrings.MODID + ":starmetal_boots");
|
||||
|
||||
robes_helmet = new ArmorFSB(ArmorMaterial.CHAIN, 0, RefStrings.MODID + ":textures/armor/robes_1.png").setThreshold(1.0F).setUnlocalizedName("robes_helmet").setTextureName(RefStrings.MODID + ":robes_helmet");
|
||||
robes_helmet = new ArmorFSB(ArmorMaterial.CHAIN, 0, RefStrings.MODID + ":textures/armor/robes_1.png").setUnlocalizedName("robes_helmet").setTextureName(RefStrings.MODID + ":robes_helmet");
|
||||
robes_plate = new ArmorFSB(ArmorMaterial.CHAIN, 1, RefStrings.MODID + ":textures/armor/robes_1.png").cloneStats((ArmorFSB) robes_helmet).setUnlocalizedName("robes_plate").setTextureName(RefStrings.MODID + ":robes_plate");
|
||||
robes_legs = new ArmorFSB(ArmorMaterial.CHAIN, 2, RefStrings.MODID + ":textures/armor/robes_2.png").cloneStats((ArmorFSB) robes_helmet).setUnlocalizedName("robes_legs").setTextureName(RefStrings.MODID + ":robes_legs");
|
||||
robes_boots = new ArmorFSB(ArmorMaterial.CHAIN, 3, RefStrings.MODID + ":textures/armor/robes_1.png").cloneStats((ArmorFSB) robes_helmet).setUnlocalizedName("robes_boots").setTextureName(RefStrings.MODID + ":robes_boots");
|
||||
@ -4662,27 +4581,23 @@ public class ModItems {
|
||||
|
||||
ArmorMaterial aMatZirconium = EnumHelper.addArmorMaterial("HBM_ZIRCONIUM", 1000, new int[] { 2, 5, 3, 1 }, 100);
|
||||
aMatZirconium.customCraftingMaterial = ModItems.ingot_zirconium;
|
||||
zirconium_legs = new ArmorFSB(aMatZirconium, 2, RefStrings.MODID + ":textures/armor/zirconium_2.png").setMod(0.0F).setUnlocalizedName("zirconium_legs").setTextureName(RefStrings.MODID + ":zirconium_legs");
|
||||
zirconium_legs = new ArmorFSB(aMatZirconium, 2, RefStrings.MODID + ":textures/armor/zirconium_2.png").setUnlocalizedName("zirconium_legs").setTextureName(RefStrings.MODID + ":zirconium_legs");
|
||||
|
||||
ArmorMaterial aMatDNT = EnumHelper.addArmorMaterial("HBM_DNT_LOLOLOL", 3, new int[] { 1, 1, 1, 1 }, 0);
|
||||
aMatDNT.customCraftingMaterial = ModItems.ingot_dineutronium;
|
||||
dnt_helmet = new ArmorFSB(aMatDNT, 0, RefStrings.MODID + ":textures/armor/dnt_1.png")
|
||||
.setMod(5F).setUnlocalizedName("dnt_helmet").setTextureName(RefStrings.MODID + ":dnt_helmet");
|
||||
.setUnlocalizedName("dnt_helmet").setTextureName(RefStrings.MODID + ":dnt_helmet");
|
||||
dnt_plate = new ArmorFSB(aMatDNT, 1, RefStrings.MODID + ":textures/armor/dnt_1.png").cloneStats((ArmorFSB) dnt_helmet).setUnlocalizedName("dnt_plate").setTextureName(RefStrings.MODID + ":dnt_plate");
|
||||
dnt_legs = new ArmorFSB(aMatDNT, 2, RefStrings.MODID + ":textures/armor/dnt_2.png").cloneStats((ArmorFSB) dnt_helmet).setUnlocalizedName("dnt_legs").setTextureName(RefStrings.MODID + ":dnt_legs");
|
||||
dnt_boots = new ArmorFSB(aMatDNT, 3, RefStrings.MODID + ":textures/armor/dnt_1.png").cloneStats((ArmorFSB) dnt_helmet).setUnlocalizedName("dnt_boots").setTextureName(RefStrings.MODID + ":dnt_boots");
|
||||
|
||||
ArmorMaterial aMatT45 = EnumHelper.addArmorMaterial("HBM_T45", 150, new int[] { 3, 8, 6, 3 }, 0);
|
||||
aMatT45.customCraftingMaterial = ModItems.plate_armor_titanium;
|
||||
t45_helmet = new ArmorT45(aMatT45, 0, 1000000, 10000, 1000, 5).setCap(10F).setMod(0.5F)
|
||||
.setFireproof(true)
|
||||
t45_helmet = new ArmorT45(aMatT45, 0, 1000000, 10000, 1000, 5)
|
||||
.enableVATS(true)
|
||||
.setHasGeigerSound(true)
|
||||
.setHasHardLanding(true)
|
||||
.addEffect(new PotionEffect(Potion.damageBoost.id, 20, 0))
|
||||
.setBlastProtection(0.5F)
|
||||
.addResistance("monoxide", 0F)
|
||||
.addResistance("fall", 0)
|
||||
.hides(EnumPlayerPart.HAT)
|
||||
.setUnlocalizedName("t45_helmet").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":t45_helmet");
|
||||
t45_plate = new ArmorT45(aMatT45, 1, 1000000, 10000, 1000, 5).cloneStats((ArmorFSB) t45_helmet).setUnlocalizedName("t45_plate").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":t45_plate");
|
||||
@ -4691,13 +4606,9 @@ public class ModItems {
|
||||
|
||||
ArmorMaterial aMatDesh = EnumHelper.addArmorMaterial("HBM_DESH", 150, new int[] { 3, 8, 6, 3 }, 0);
|
||||
aMatDesh.customCraftingMaterial = ModItems.ingot_desh;
|
||||
steamsuit_helmet = new ArmorDesh(aMatDesh, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", Fluids.STEAM, 64_000, 500, 50, 1).setThreshold(5F).setMod(0.8F)
|
||||
.setFireproof(true)
|
||||
steamsuit_helmet = new ArmorDesh(aMatDesh, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", Fluids.STEAM, 64_000, 500, 50, 1)
|
||||
.setHasHardLanding(true)
|
||||
.addEffect(new PotionEffect(Potion.digSpeed.id, 20, 4))
|
||||
.setBlastProtection(0.5F)
|
||||
.addResistance("monoxide", 0F)
|
||||
.addResistance("fall", 0)
|
||||
.hides(EnumPlayerPart.HAT)
|
||||
.setUnlocalizedName("steamsuit_helmet").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":steamsuit_helmet");
|
||||
steamsuit_plate = new ArmorDesh(aMatDesh, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png", Fluids.STEAM, 64_000, 500, 50, 1).cloneStats((ArmorFSB) steamsuit_helmet).setUnlocalizedName("steamsuit_plate").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":steamsuit_plate");
|
||||
@ -4706,12 +4617,11 @@ public class ModItems {
|
||||
|
||||
ArmorMaterial aMatDiesel = EnumHelper.addArmorMaterial("HBM_BNUUY", 150, new int[] { 3, 8, 6, 3 }, 0);
|
||||
aMatDiesel.customCraftingMaterial = ModItems.plate_copper;
|
||||
dieselsuit_helmet = new ArmorDiesel(aMatDiesel, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", Fluids.DIESEL, 64_000, 500, 50, 1).setThreshold(2F).setMod(0.7F)
|
||||
dieselsuit_helmet = new ArmorDiesel(aMatDiesel, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", Fluids.DIESEL, 64_000, 500, 50, 1)
|
||||
.addEffect(new PotionEffect(Potion.moveSpeed.id, 20, 2))
|
||||
.addEffect(new PotionEffect(Potion.jump.id, 20, 2))
|
||||
.enableThermalSight(true)
|
||||
.enableVATS(true)
|
||||
.addResistance("fall", 0)
|
||||
.setUnlocalizedName("dieselsuit_helmet").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":dieselsuit_helmet");
|
||||
dieselsuit_plate = new ArmorDiesel(aMatDiesel, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png", Fluids.DIESEL, 64_000, 500, 50, 1).cloneStats((ArmorFSB) dieselsuit_helmet).setUnlocalizedName("dieselsuit_plate").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":dieselsuit_plate");
|
||||
dieselsuit_legs = new ArmorDiesel(aMatDiesel, 2, RefStrings.MODID + ":textures/armor/starmetal_2.png", Fluids.DIESEL, 64_000, 500, 50, 1).cloneStats((ArmorFSB) dieselsuit_helmet).setUnlocalizedName("dieselsuit_legs").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":dieselsuit_legs");
|
||||
@ -4719,57 +4629,40 @@ public class ModItems {
|
||||
|
||||
ArmorMaterial aMatAJR = EnumHelper.addArmorMaterial("HBM_T45AJR", 150, new int[] { 3, 8, 6, 3 }, 100);
|
||||
aMatAJR.customCraftingMaterial = ModItems.plate_armor_ajr;
|
||||
ajr_helmet = new ArmorAJR(aMatAJR, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 2500000, 10000, 2000, 25).setMod(0.25F).setCap(6.0F).setThreshold(4F)
|
||||
.setFireproof(true)
|
||||
ajr_helmet = new ArmorAJR(aMatAJR, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 2500000, 10000, 2000, 25)
|
||||
.enableVATS(true)
|
||||
.setHasGeigerSound(true)
|
||||
.setHasHardLanding(true)
|
||||
.addEffect(new PotionEffect(Potion.jump.id, 20, 0))
|
||||
.addEffect(new PotionEffect(Potion.damageBoost.id, 20, 0))
|
||||
.setBlastProtection(0.25F)
|
||||
.setStep("hbm:step.metal")
|
||||
.setJump("hbm:step.iron_jump")
|
||||
.setFall("hbm:step.iron_land")
|
||||
.addResistance("monoxide", 0F)
|
||||
.addResistance("fall", 0)
|
||||
.setStep("hbm:step.metal").setJump("hbm:step.iron_jump").setFall("hbm:step.iron_land")
|
||||
.hides(EnumPlayerPart.HAT)
|
||||
.setUnlocalizedName("ajr_helmet").setTextureName(RefStrings.MODID + ":ajr_helmet");
|
||||
ajr_plate = new ArmorAJR(aMatAJR, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png", 2500000, 10000, 2000, 25).cloneStats((ArmorFSB) ajr_helmet).setUnlocalizedName("ajr_plate").setTextureName(RefStrings.MODID + ":ajr_plate");
|
||||
ajr_legs = new ArmorAJR(aMatAJR, 2, RefStrings.MODID + ":textures/armor/starmetal_2.png", 2500000, 10000, 2000, 25).cloneStats((ArmorFSB) ajr_helmet).setUnlocalizedName("ajr_legs").setTextureName(RefStrings.MODID + ":ajr_legs");
|
||||
ajr_boots = new ArmorAJR(aMatAJR, 3, RefStrings.MODID + ":textures/armor/starmetal_1.png", 2500000, 10000, 2000, 25).cloneStats((ArmorFSB) ajr_helmet).setUnlocalizedName("ajr_boots").setTextureName(RefStrings.MODID + ":ajr_boots");
|
||||
|
||||
ajro_helmet = new ArmorAJRO(aMatAJR, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 2500000, 10000, 2000, 25).setMod(0.25F).setCap(6.0F).setThreshold(4F)
|
||||
.setFireproof(true)
|
||||
ajro_helmet = new ArmorAJRO(aMatAJR, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 2500000, 10000, 2000, 25)
|
||||
.enableVATS(true)
|
||||
.setHasGeigerSound(true)
|
||||
.setHasHardLanding(true)
|
||||
.addEffect(new PotionEffect(Potion.jump.id, 20, 0))
|
||||
.addEffect(new PotionEffect(Potion.damageBoost.id, 20, 0))
|
||||
.setBlastProtection(0.25F)
|
||||
.setStep("hbm:step.metal")
|
||||
.setJump("hbm:step.iron_jump")
|
||||
.setFall("hbm:step.iron_land")
|
||||
.addResistance("monoxide", 0F)
|
||||
.addResistance("fall", 0)
|
||||
.setStep("hbm:step.metal").setJump("hbm:step.iron_jump").setFall("hbm:step.iron_land")
|
||||
.hides(EnumPlayerPart.HAT)
|
||||
.setUnlocalizedName("ajro_helmet").setTextureName(RefStrings.MODID + ":ajro_helmet");
|
||||
ajro_plate = new ArmorAJRO(aMatAJR, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png", 2500000, 10000, 2000, 25).cloneStats((ArmorFSB) ajro_helmet).setUnlocalizedName("ajro_plate").setTextureName(RefStrings.MODID + ":ajro_plate");
|
||||
ajro_legs = new ArmorAJRO(aMatAJR, 2, RefStrings.MODID + ":textures/armor/starmetal_2.png", 2500000, 10000, 2000, 25).cloneStats((ArmorFSB) ajro_helmet).setUnlocalizedName("ajro_legs").setTextureName(RefStrings.MODID + ":ajro_legs");
|
||||
ajro_boots = new ArmorAJRO(aMatAJR, 3, RefStrings.MODID + ":textures/armor/starmetal_1.png", 2500000, 10000, 2000, 25).cloneStats((ArmorFSB) ajro_helmet).setUnlocalizedName("ajro_boots").setTextureName(RefStrings.MODID + ":ajro_boots");
|
||||
|
||||
rpa_helmet = new ArmorRPA(aMatAJR, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 2500000, 10000, 2000, 25).setMod(0.1F).setCap(6.0F).setThreshold(20F)
|
||||
.setFireproof(true)
|
||||
rpa_helmet = new ArmorRPA(aMatAJR, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 2500000, 10000, 2000, 25)
|
||||
.enableVATS(true)
|
||||
.setHasGeigerSound(true)
|
||||
.setHasHardLanding(true)
|
||||
.addEffect(new PotionEffect(Potion.damageBoost.id, 20, 3))
|
||||
.setBlastProtection(0.25F)
|
||||
.setProjectileProtection(0.25F)
|
||||
.setProtectionLevel(1500)
|
||||
.setStep("hbm:step.powered")
|
||||
.setJump("hbm:step.powered")
|
||||
.setFall("hbm:step.powered")
|
||||
.addResistance("fall", 0)
|
||||
.hides(EnumPlayerPart.HAT)
|
||||
.setUnlocalizedName("rpa_helmet").setTextureName(RefStrings.MODID + ":rpa_helmet");
|
||||
rpa_plate = new ArmorRPA(aMatAJR, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png", 2500000, 10000, 2000, 25).cloneStats((ArmorFSB) rpa_helmet).setUnlocalizedName("rpa_plate").setTextureName(RefStrings.MODID + ":rpa_plate");
|
||||
@ -4778,8 +4671,7 @@ public class ModItems {
|
||||
|
||||
ArmorMaterial aMatBJ = EnumHelper.addArmorMaterial("HBM_BLACKJACK", 150, new int[] { 3, 8, 6, 3 }, 100);
|
||||
aMatBJ.customCraftingMaterial = ModItems.plate_armor_lunar;
|
||||
bj_helmet = new ArmorBJ(aMatBJ, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 10000000, 10000, 1000, 100).setMod(0.25F).setCap(4.0F).setThreshold(4F)
|
||||
.setFireproof(true)
|
||||
bj_helmet = new ArmorBJ(aMatBJ, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 10000000, 10000, 1000, 100)
|
||||
.enableVATS(true)
|
||||
.enableThermalSight(true)
|
||||
.setHasGeigerSound(true)
|
||||
@ -4788,12 +4680,9 @@ public class ModItems {
|
||||
.addEffect(new PotionEffect(Potion.jump.id, 20, 0))
|
||||
.addEffect(new PotionEffect(Potion.field_76443_y.id, 20, 0))
|
||||
.addEffect(new PotionEffect(HbmPotion.radx.id, 20, 0))
|
||||
.setBlastProtection(0.5F)
|
||||
.setProtectionLevel(500F)
|
||||
.setStep("hbm:step.metal")
|
||||
.setJump("hbm:step.iron_jump")
|
||||
.setFall("hbm:step.iron_land")
|
||||
.addResistance("fall", 0).setUnlocalizedName("bj_helmet").setTextureName(RefStrings.MODID + ":bj_helmet");
|
||||
.setFall("hbm:step.iron_land").setUnlocalizedName("bj_helmet").setTextureName(RefStrings.MODID + ":bj_helmet");
|
||||
bj_plate = new ArmorBJ(aMatBJ, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png", 10000000, 10000, 1000, 100).cloneStats((ArmorFSB) bj_helmet).setUnlocalizedName("bj_plate").setTextureName(RefStrings.MODID + ":bj_plate");
|
||||
bj_plate_jetpack = new ArmorBJJetpack(aMatBJ, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png", 10000000, 10000, 1000, 100).cloneStats((ArmorFSB) bj_helmet).setUnlocalizedName("bj_plate_jetpack").setTextureName(RefStrings.MODID + ":bj_plate_jetpack");
|
||||
bj_legs = new ArmorBJ(aMatBJ, 2, RefStrings.MODID + ":textures/armor/starmetal_2.png", 10000000, 10000, 1000, 100).cloneStats((ArmorFSB) bj_helmet).setUnlocalizedName("bj_legs").setTextureName(RefStrings.MODID + ":bj_legs");
|
||||
@ -4801,12 +4690,9 @@ public class ModItems {
|
||||
|
||||
ArmorMaterial aMatEnv = EnumHelper.addArmorMaterial("HBM_ENV", 150, new int[] { 3, 8, 6, 3 }, 100);
|
||||
aMatEnv.customCraftingMaterial = ModItems.plate_armor_hev;
|
||||
envsuit_helmet = new ArmorEnvsuit(aMatEnv, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 100_000, 1_000, 250, 0).setMod(0.5F).setThreshold(2.0F)
|
||||
envsuit_helmet = new ArmorEnvsuit(aMatEnv, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 100_000, 1_000, 250, 0)
|
||||
.addEffect(new PotionEffect(Potion.moveSpeed.id, 20, 1))
|
||||
.addEffect(new PotionEffect(Potion.jump.id, 20, 0))
|
||||
.addResistance("fall", 0.25F)
|
||||
.addResistance("monoxide", 0F)
|
||||
.addResistance("onFire", 0F)
|
||||
.hides(EnumPlayerPart.HAT)
|
||||
.setUnlocalizedName("envsuit_helmet").setTextureName(RefStrings.MODID + ":envsuit_helmet");
|
||||
envsuit_plate = new ArmorEnvsuit(aMatEnv, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png", 100_000, 1_000, 250, 0).cloneStats((ArmorFSB) envsuit_helmet).setUnlocalizedName("envsuit_plate").setTextureName(RefStrings.MODID + ":envsuit_plate");
|
||||
@ -4815,16 +4701,11 @@ public class ModItems {
|
||||
|
||||
ArmorMaterial aMatHEV = EnumHelper.addArmorMaterial("HBM_HEV", 150, new int[] { 3, 8, 6, 3 }, 100);
|
||||
aMatHEV.customCraftingMaterial = ModItems.plate_armor_hev;
|
||||
hev_helmet = new ArmorHEV(aMatHEV, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 1000000, 10000, 2500, 0).setMod(0.20F).setCap(4.0F).setThreshold(2.0F)
|
||||
hev_helmet = new ArmorHEV(aMatHEV, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 1000000, 10000, 2500, 0)
|
||||
.addEffect(new PotionEffect(Potion.moveSpeed.id, 20, 1))
|
||||
.addEffect(new PotionEffect(Potion.jump.id, 20, 0))
|
||||
.setBlastProtection(0.25F)
|
||||
.setProtectionLevel(500F)
|
||||
.setHasGeigerSound(true)
|
||||
.setHasCustomGeiger(true)
|
||||
.addResistance("fall", 0.5F)
|
||||
.addResistance("monoxide", 0F)
|
||||
.addResistance("onFire", 0F)
|
||||
.hides(EnumPlayerPart.HAT)
|
||||
.setUnlocalizedName("hev_helmet").setTextureName(RefStrings.MODID + ":hev_helmet");
|
||||
hev_plate = new ArmorHEV(aMatHEV, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png", 1000000, 10000, 2500, 0).cloneStats((ArmorFSB) hev_helmet).setUnlocalizedName("hev_plate").setTextureName(RefStrings.MODID + ":hev_plate");
|
||||
@ -4836,20 +4717,14 @@ public class ModItems {
|
||||
|
||||
ArmorMaterial aMatFau = EnumHelper.addArmorMaterial("HBM_DIGAMMA", 150, new int[] { 3, 8, 6, 3 }, 100);
|
||||
aMatFau.customCraftingMaterial = ModItems.plate_armor_fau;
|
||||
fau_helmet = new ArmorDigamma(aMatFau, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 10000000, 10000, 2500, 0).setMod(0.25F).setCap(4.0F).setThreshold(2.0F)
|
||||
fau_helmet = new ArmorDigamma(aMatFau, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png", 10000000, 10000, 2500, 0)
|
||||
.addEffect(new PotionEffect(Potion.jump.id, 20, 1))
|
||||
.setBlastProtection(0.05F)
|
||||
.setMod(0.05F)
|
||||
.setHasGeigerSound(true)
|
||||
.enableThermalSight(true)
|
||||
.setHasHardLanding(true)
|
||||
.setStep("hbm:step.metal")
|
||||
.setJump("hbm:step.iron_jump")
|
||||
.setFall("hbm:step.iron_land")
|
||||
.setProtectionLevel(1000F)
|
||||
.addResistance("fall", 0F)
|
||||
.addResistance("monoxide", 0F)
|
||||
.setFireproof(true)
|
||||
.hides(EnumPlayerPart.HAT)
|
||||
.setUnlocalizedName("fau_helmet").setTextureName(RefStrings.MODID + ":fau_helmet");
|
||||
fau_plate = new ArmorDigamma(aMatFau, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png", 10000000, 10000, 2500, 0).cloneStats((ArmorFSB) fau_helmet).setFullSetForHide().setUnlocalizedName("fau_plate").setTextureName(RefStrings.MODID + ":fau_plate");
|
||||
@ -4869,7 +4744,6 @@ public class ModItems {
|
||||
.setStep("hbm:step.metal")
|
||||
.setJump("hbm:step.iron_jump")
|
||||
.setFall("hbm:step.iron_land")
|
||||
.setFireproof(true)
|
||||
.hides(EnumPlayerPart.HAT)
|
||||
.setUnlocalizedName("dns_helmet").setTextureName(RefStrings.MODID + ":dns_helmet");
|
||||
dns_plate = new ArmorDNT(aMatDNS, 1, RefStrings.MODID + ":textures/armor/starmetal_1.png", 1000000000, 1000000, 100000, 115).cloneStats((ArmorFSB) dns_helmet).setUnlocalizedName("dns_plate").setTextureName(RefStrings.MODID + ":dns_plate");
|
||||
@ -4878,14 +4752,12 @@ public class ModItems {
|
||||
|
||||
ArmorMaterial aMatTrench = EnumHelper.addArmorMaterial("HBM_TRENCH", 150, new int[] { 3, 8, 6, 3 }, 100);
|
||||
aMatTrench.customCraftingMaterial = ModItems.plate_iron;
|
||||
trenchmaster_helmet = new ArmorTrenchmaster(aMatTrench, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png").setMod(0.125F).setThreshold(5.0F)
|
||||
trenchmaster_helmet = new ArmorTrenchmaster(aMatTrench, 0, RefStrings.MODID + ":textures/armor/starmetal_1.png")
|
||||
.addEffect(new PotionEffect(Potion.damageBoost.id, 20, 2))
|
||||
.addEffect(new PotionEffect(Potion.digSpeed.id, 20, 1))
|
||||
.addEffect(new PotionEffect(Potion.jump.id, 20, 1))
|
||||
.addEffect(new PotionEffect(Potion.moveSpeed.id, 20, 0))
|
||||
.enableVATS(true)
|
||||
.addResistance("fall", 0F)
|
||||
.setFireproof(true)
|
||||
.setStepSize(1)
|
||||
.hides(EnumPlayerPart.HAT)
|
||||
.setUnlocalizedName("trenchmaster_helmet").setTextureName(RefStrings.MODID + ":trenchmaster_helmet");
|
||||
@ -4903,7 +4775,7 @@ public class ModItems {
|
||||
.addHitAbility(new WeaponAbility.ChainsawAbility(10))
|
||||
.addHitAbility(new WeaponAbility.BeheaderAbility()).setShears().setUnlocalizedName("chainsaw").setTextureName(RefStrings.MODID + ":chainsaw");
|
||||
|
||||
schrabidium_sword = new ItemSwordAbility(150, 0, MainRegistry.tMatSchrab)
|
||||
schrabidium_sword = new ItemSwordAbility(75, 0, MainRegistry.tMatSchrab)
|
||||
.addHitAbility(new WeaponAbility.RadiationAbility(50F))
|
||||
.addHitAbility(new WeaponAbility.VampireAbility(2F))
|
||||
.setRarity(EnumRarity.rare).setUnlocalizedName("schrabidium_sword").setTextureName(RefStrings.MODID + ":schrabidium_sword");
|
||||
@ -4954,22 +4826,22 @@ public class ModItems {
|
||||
steel_shovel = new ItemToolAbility(3F, 0, MainRegistry.tMatSteel, EnumToolType.SHOVEL).setUnlocalizedName("steel_shovel").setTextureName(RefStrings.MODID + ":steel_shovel");
|
||||
steel_hoe = new ModHoe(MainRegistry.tMatSteel).setUnlocalizedName("steel_hoe").setTextureName(RefStrings.MODID + ":steel_hoe");
|
||||
|
||||
alloy_sword = new ItemSwordAbility(9F, 0, MainRegistry.tMatAlloy)
|
||||
alloy_sword = new ItemSwordAbility(8F, 0, MainRegistry.tMatAlloy)
|
||||
.addHitAbility(new WeaponAbility.StunAbility(2)).setUnlocalizedName("alloy_sword").setTextureName(RefStrings.MODID + ":alloy_sword");
|
||||
|
||||
alloy_pickaxe = new ItemToolAbility(6F, 0, MainRegistry.tMatAlloy, EnumToolType.PICKAXE)
|
||||
alloy_pickaxe = new ItemToolAbility(5F, 0, MainRegistry.tMatAlloy, EnumToolType.PICKAXE)
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(3)).setUnlocalizedName("alloy_pickaxe").setTextureName(RefStrings.MODID + ":alloy_pickaxe");
|
||||
|
||||
alloy_axe = new ItemToolAbility(7F, 0, MainRegistry.tMatAlloy, EnumToolType.AXE)
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(3))
|
||||
.addHitAbility(new WeaponAbility.BeheaderAbility()).setUnlocalizedName("alloy_axe").setTextureName(RefStrings.MODID + ":alloy_axe");
|
||||
|
||||
alloy_shovel = new ItemToolAbility(5F, 0, MainRegistry.tMatAlloy, EnumToolType.SHOVEL)
|
||||
alloy_shovel = new ItemToolAbility(4F, 0, MainRegistry.tMatAlloy, EnumToolType.SHOVEL)
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(3)).setUnlocalizedName("alloy_shovel").setTextureName(RefStrings.MODID + ":alloy_shovel");
|
||||
|
||||
alloy_hoe = new ModHoe(MainRegistry.tMatAlloy).setUnlocalizedName("alloy_hoe").setTextureName(RefStrings.MODID + ":alloy_hoe");
|
||||
|
||||
cmb_sword = new ItemSwordAbility(50F, 0, MainRegistry.tMatCMB)
|
||||
cmb_sword = new ItemSwordAbility(35F, 0, MainRegistry.tMatCMB)
|
||||
.addHitAbility(new WeaponAbility.StunAbility(2))
|
||||
.addHitAbility(new WeaponAbility.VampireAbility(2F)).setUnlocalizedName("cmb_sword").setTextureName(RefStrings.MODID + ":cmb_sword");
|
||||
|
||||
@ -4979,7 +4851,7 @@ public class ModItems {
|
||||
.addBreakAbility(new ToolAbility.SilkAbility())
|
||||
.addBreakAbility(new LuckAbility(3)).setUnlocalizedName("cmb_pickaxe").setTextureName(RefStrings.MODID + ":cmb_pickaxe");
|
||||
|
||||
cmb_axe = new ItemToolAbility(12.5F, 0, MainRegistry.tMatCMB, EnumToolType.AXE)
|
||||
cmb_axe = new ItemToolAbility(30F, 0, MainRegistry.tMatCMB, EnumToolType.AXE)
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(5))
|
||||
.addBreakAbility(new ToolAbility.SmelterAbility())
|
||||
.addBreakAbility(new ToolAbility.SilkAbility())
|
||||
@ -4994,16 +4866,16 @@ public class ModItems {
|
||||
|
||||
cmb_hoe = new ModHoe(MainRegistry.tMatCMB).setUnlocalizedName("cmb_hoe").setTextureName(RefStrings.MODID + ":cmb_hoe");
|
||||
|
||||
elec_sword = new ItemSwordAbilityPower(15F, 0, MainRegistry.tMatElec, 500000, 1000, 100)
|
||||
elec_sword = new ItemSwordAbilityPower(12.5F, 0, MainRegistry.tMatElec, 500000, 1000, 100)
|
||||
.addHitAbility(new WeaponAbility.StunAbility(5)).setUnlocalizedName("elec_sword").setTextureName(RefStrings.MODID + ":elec_sword_anim");
|
||||
|
||||
elec_pickaxe = new ItemToolAbilityPower(10F, 0, MainRegistry.tMatElec, EnumToolType.PICKAXE, 500000, 1000, 100)
|
||||
elec_pickaxe = new ItemToolAbilityPower(6F, 0, MainRegistry.tMatElec, EnumToolType.PICKAXE, 500000, 1000, 100)
|
||||
.addBreakAbility(new ToolAbility.HammerAbility(2))
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(5))
|
||||
.addBreakAbility(new ToolAbility.SilkAbility())
|
||||
.addBreakAbility(new LuckAbility(2)).setUnlocalizedName("elec_pickaxe").setTextureName(RefStrings.MODID + ":elec_drill_anim");
|
||||
|
||||
elec_axe = new ItemToolAbilityPower(12.5F, 0, MainRegistry.tMatElec, EnumToolType.AXE, 500000, 1000, 100)
|
||||
elec_axe = new ItemToolAbilityPower(10F, 0, MainRegistry.tMatElec, EnumToolType.AXE, 500000, 1000, 100)
|
||||
.addBreakAbility(new ToolAbility.HammerAbility(2))
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(5))
|
||||
.addBreakAbility(new ToolAbility.SilkAbility())
|
||||
@ -5011,13 +4883,13 @@ public class ModItems {
|
||||
.addHitAbility(new WeaponAbility.ChainsawAbility(15))
|
||||
.addHitAbility(new WeaponAbility.BeheaderAbility()).setShears().setUnlocalizedName("elec_axe").setTextureName(RefStrings.MODID + ":elec_chainsaw_anim");
|
||||
|
||||
elec_shovel = new ItemToolAbilityPower(7.5F, 0, MainRegistry.tMatElec, EnumToolType.SHOVEL, 500000, 1000, 100)
|
||||
elec_shovel = new ItemToolAbilityPower(5F, 0, MainRegistry.tMatElec, EnumToolType.SHOVEL, 500000, 1000, 100)
|
||||
.addBreakAbility(new ToolAbility.HammerAbility(2))
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(5))
|
||||
.addBreakAbility(new ToolAbility.SilkAbility())
|
||||
.addBreakAbility(new LuckAbility(2)).setUnlocalizedName("elec_shovel").setTextureName(RefStrings.MODID + ":elec_shovel_anim");
|
||||
|
||||
desh_sword = new ItemSwordAbility(15F, 0, MainRegistry.tMatDesh)
|
||||
desh_sword = new ItemSwordAbility(12.5F, 0, MainRegistry.tMatDesh)
|
||||
.addHitAbility(new WeaponAbility.StunAbility(2)).setUnlocalizedName("desh_sword").setTextureName(RefStrings.MODID + ":desh_sword");
|
||||
|
||||
desh_pickaxe = new ItemToolAbility(5F, -0.05, MainRegistry.tMatDesh, EnumToolType.PICKAXE)
|
||||
@ -5026,7 +4898,7 @@ public class ModItems {
|
||||
.addBreakAbility(new ToolAbility.SilkAbility())
|
||||
.addBreakAbility(new LuckAbility(2)).setUnlocalizedName("desh_pickaxe").setTextureName(RefStrings.MODID + ":desh_pickaxe");
|
||||
|
||||
desh_axe = new ItemToolAbility(6.5F, -0.05, MainRegistry.tMatDesh, EnumToolType.AXE)
|
||||
desh_axe = new ItemToolAbility(7.5F, -0.05, MainRegistry.tMatDesh, EnumToolType.AXE)
|
||||
.addBreakAbility(new ToolAbility.HammerAbility(1))
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(3))
|
||||
.addBreakAbility(new ToolAbility.SilkAbility())
|
||||
@ -5108,14 +4980,14 @@ public class ModItems {
|
||||
.addBreakAbility(new ToolAbility.CentrifugeAbility()).setMaxDamage(50).setUnlocalizedName("centri_stick").setTextureName(RefStrings.MODID + ":centri_stick");
|
||||
smashing_hammer = new ItemToolAbility(12F, -0.1, MainRegistry.tMatSteel, EnumToolType.MINER)
|
||||
.addBreakAbility(new ToolAbility.ShredderAbility()).setMaxDamage(2500).setUnlocalizedName("smashing_hammer").setTextureName(RefStrings.MODID + ":smashing_hammer");
|
||||
drax = new ItemToolAbilityPower(15F, -0.05, MainRegistry.tMatElec, EnumToolType.MINER, 500000000, 100000, 5000)
|
||||
drax = new ItemToolAbilityPower(10F, -0.05, MainRegistry.tMatElec, EnumToolType.MINER, 500000000, 100000, 5000)
|
||||
.addBreakAbility(new ToolAbility.SmelterAbility())
|
||||
.addBreakAbility(new ToolAbility.ShredderAbility())
|
||||
.addBreakAbility(new ToolAbility.LuckAbility(2))
|
||||
.addBreakAbility(new ToolAbility.HammerAbility(1))
|
||||
.addBreakAbility(new ToolAbility.HammerAbility(2))
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(5)).setUnlocalizedName("drax").setTextureName(RefStrings.MODID + ":drax");
|
||||
drax_mk2 = new ItemToolAbilityPower(20F, -0.05, MainRegistry.tMatElec, EnumToolType.MINER, 1000000000, 250000, 7500)
|
||||
drax_mk2 = new ItemToolAbilityPower(15F, -0.05, MainRegistry.tMatElec, EnumToolType.MINER, 1000000000, 250000, 7500)
|
||||
.addBreakAbility(new ToolAbility.SmelterAbility())
|
||||
.addBreakAbility(new ToolAbility.ShredderAbility())
|
||||
.addBreakAbility(new ToolAbility.CentrifugeAbility())
|
||||
@ -5148,7 +5020,7 @@ public class ModItems {
|
||||
.addHitAbility(new WeaponAbility.VampireAbility(2F))
|
||||
.addHitAbility(new WeaponAbility.BeheaderAbility())
|
||||
.setDepthRockBreaker().setUnlocalizedName("bismuth_pickaxe").setTextureName(RefStrings.MODID + ":bismuth_pickaxe");
|
||||
bismuth_axe = new ItemToolAbility(125F, 0, matBismuth, EnumToolType.AXE)
|
||||
bismuth_axe = new ItemToolAbility(25F, 0, matBismuth, EnumToolType.AXE)
|
||||
.addBreakAbility(new ToolAbility.HammerAbility(2))
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(4))
|
||||
.addBreakAbility(new ToolAbility.ShredderAbility())
|
||||
@ -5170,7 +5042,7 @@ public class ModItems {
|
||||
.addHitAbility(new WeaponAbility.VampireAbility(2F))
|
||||
.addHitAbility(new WeaponAbility.BeheaderAbility())
|
||||
.setDepthRockBreaker().setUnlocalizedName("volcanic_pickaxe").setTextureName(RefStrings.MODID + ":volcanic_pickaxe");
|
||||
volcanic_axe = new ItemToolAbility(125F, 0, matVolcano, EnumToolType.AXE)
|
||||
volcanic_axe = new ItemToolAbility(25F, 0, matVolcano, EnumToolType.AXE)
|
||||
.addBreakAbility(new ToolAbility.HammerAbility(2))
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(4))
|
||||
.addBreakAbility(new ToolAbility.SmelterAbility())
|
||||
@ -5191,7 +5063,7 @@ public class ModItems {
|
||||
.addHitAbility(new WeaponAbility.VampireAbility(5F))
|
||||
.addHitAbility(new WeaponAbility.BeheaderAbility())
|
||||
.setDepthRockBreaker().setUnlocalizedName("chlorophyte_pickaxe").setTextureName(RefStrings.MODID + ":chlorophyte_pickaxe");
|
||||
chlorophyte_axe = new ItemToolAbility(175F, 0, matChlorophyte, EnumToolType.AXE)
|
||||
chlorophyte_axe = new ItemToolAbility(50F, 0, matChlorophyte, EnumToolType.AXE)
|
||||
.addBreakAbility(new ToolAbility.HammerAbility(2))
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(4))
|
||||
.addBreakAbility(new ToolAbility.LuckAbility(4))
|
||||
@ -5214,7 +5086,7 @@ public class ModItems {
|
||||
.addHitAbility(new WeaponAbility.PhosphorusAbility(60))
|
||||
.addHitAbility(new WeaponAbility.BeheaderAbility())
|
||||
.setDepthRockBreaker().setUnlocalizedName("mese_pickaxe").setTextureName(RefStrings.MODID + ":mese_pickaxe");
|
||||
mese_axe = new ItemToolAbility(250F, 0, matMese, EnumToolType.AXE)
|
||||
mese_axe = new ItemToolAbility(75F, 0, matMese, EnumToolType.AXE)
|
||||
.addBreakAbility(new ToolAbility.HammerAbility(3))
|
||||
.addBreakAbility(new ToolAbility.RecursionAbility(5))
|
||||
.addBreakAbility(new ToolAbility.SilkAbility())
|
||||
@ -5234,18 +5106,18 @@ public class ModItems {
|
||||
.addBreakAbility(new ToolAbility.HammerAbility(1)).setUnlocalizedName("dwarven_pickaxe").setMaxDamage(250).setTextureName(RefStrings.MODID + ":dwarven_pickaxe");
|
||||
|
||||
ToolMaterial matMeteorite = EnumHelper.addToolMaterial("HBM_METEORITE", 4, 0, 50F, 0.0F, 200).setRepairItem(new ItemStack(ModItems.plate_paa));
|
||||
meteorite_sword = new ItemSwordMeteorite(10F, 0, matMeteorite).setUnlocalizedName("meteorite_sword").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_seared = new ItemSwordMeteorite(15F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_seared").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_reforged = new ItemSwordMeteorite(25F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_reforged").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_hardened = new ItemSwordMeteorite(35F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_hardened").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_alloyed = new ItemSwordMeteorite(50F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_alloyed").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_machined = new ItemSwordMeteorite(65F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_machined").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_treated = new ItemSwordMeteorite(80F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_treated").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_etched = new ItemSwordMeteorite(100F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_etched").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_bred = new ItemSwordMeteorite(125F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_bred").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_irradiated = new ItemSwordMeteorite(175F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_irradiated").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_fused = new ItemSwordMeteorite(250F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_fused").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_baleful = new ItemSwordMeteorite(500F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_baleful").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword = new ItemSwordMeteorite(9F, 0, matMeteorite).setUnlocalizedName("meteorite_sword").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_seared = new ItemSwordMeteorite(10F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_seared").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_reforged = new ItemSwordMeteorite(12.5F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_reforged").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_hardened = new ItemSwordMeteorite(15F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_hardened").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_alloyed = new ItemSwordMeteorite(17.5F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_alloyed").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_machined = new ItemSwordMeteorite(20F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_machined").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_treated = new ItemSwordMeteorite(22.5F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_treated").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_etched = new ItemSwordMeteorite(25F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_etched").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_bred = new ItemSwordMeteorite(30F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_bred").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_irradiated = new ItemSwordMeteorite(35F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_irradiated").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_fused = new ItemSwordMeteorite(50F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_fused").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
meteorite_sword_baleful = new ItemSwordMeteorite(75F, 0, matMeteorite).setUnlocalizedName("meteorite_sword_baleful").setTextureName(RefStrings.MODID + ":meteorite_sword");
|
||||
|
||||
mask_of_infamy = new MaskOfInfamy(ArmorMaterial.IRON, 0).setUnlocalizedName("mask_of_infamy").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":mask_of_infamy");
|
||||
|
||||
@ -5258,12 +5130,12 @@ public class ModItems {
|
||||
hazmat_legs_red = new ArmorHazmat(MainRegistry.aMatHaz2, 2, RefStrings.MODID + ":textures/armor/hazmat_2_red.png").setUnlocalizedName("hazmat_legs_red").setTextureName(RefStrings.MODID + ":hazmat_legs_red");
|
||||
hazmat_boots_red = new ArmorHazmat(MainRegistry.aMatHaz2, 3, RefStrings.MODID + ":textures/armor/hazmat_1_red.png").setUnlocalizedName("hazmat_boots_red").setTextureName(RefStrings.MODID + ":hazmat_boots_red");
|
||||
hazmat_helmet_grey = new ArmorHazmatMask(MainRegistry.aMatHaz3, 0, "hbm:textures/models/ModelHazGrey.png")
|
||||
.setFireproof(true).setUnlocalizedName("hazmat_helmet_grey").setTextureName(RefStrings.MODID + ":hazmat_helmet_grey");
|
||||
.setUnlocalizedName("hazmat_helmet_grey").setTextureName(RefStrings.MODID + ":hazmat_helmet_grey");
|
||||
hazmat_plate_grey = new ArmorHazmat(MainRegistry.aMatHaz3, 1, RefStrings.MODID + ":textures/armor/hazmat_1_grey.png").cloneStats((ArmorFSB) hazmat_helmet_grey).setUnlocalizedName("hazmat_plate_grey").setTextureName(RefStrings.MODID + ":hazmat_plate_grey");
|
||||
hazmat_legs_grey = new ArmorHazmat(MainRegistry.aMatHaz3, 2, RefStrings.MODID + ":textures/armor/hazmat_2_grey.png").cloneStats((ArmorFSB) hazmat_helmet_grey).setUnlocalizedName("hazmat_legs_grey").setTextureName(RefStrings.MODID + ":hazmat_legs_grey");
|
||||
hazmat_boots_grey = new ArmorHazmat(MainRegistry.aMatHaz3, 3, RefStrings.MODID + ":textures/armor/hazmat_1_grey.png").cloneStats((ArmorFSB) hazmat_helmet_grey).setUnlocalizedName("hazmat_boots_grey").setTextureName(RefStrings.MODID + ":hazmat_boots_grey");
|
||||
hazmat_paa_helmet = new ArmorHazmatMask(MainRegistry.aMatPaa, 0, RefStrings.MODID + ":textures/armor/hazmat_paa_1.png")
|
||||
.setFireproof(true).setUnlocalizedName("hazmat_paa_helmet").setTextureName(RefStrings.MODID + ":hazmat_paa_helmet");
|
||||
.setUnlocalizedName("hazmat_paa_helmet").setTextureName(RefStrings.MODID + ":hazmat_paa_helmet");
|
||||
hazmat_paa_plate = new ArmorHazmat(MainRegistry.aMatPaa, 1, RefStrings.MODID + ":textures/armor/hazmat_paa_1.png").cloneStats((ArmorFSB) hazmat_paa_helmet).setUnlocalizedName("hazmat_paa_plate").setTextureName(RefStrings.MODID + ":hazmat_paa_plate");
|
||||
hazmat_paa_legs = new ArmorHazmat(MainRegistry.aMatPaa, 2, RefStrings.MODID + ":textures/armor/hazmat_paa_2.png").cloneStats((ArmorFSB) hazmat_paa_helmet).setUnlocalizedName("hazmat_paa_legs").setTextureName(RefStrings.MODID + ":hazmat_paa_legs");
|
||||
hazmat_paa_boots = new ArmorHazmat(MainRegistry.aMatPaa, 3, RefStrings.MODID + ":textures/armor/hazmat_paa_1.png").cloneStats((ArmorFSB) hazmat_paa_helmet).setUnlocalizedName("hazmat_paa_boots").setTextureName(RefStrings.MODID + ":hazmat_paa_boots");
|
||||
@ -5271,9 +5143,6 @@ public class ModItems {
|
||||
ArmorMaterial aMatLiquidator = EnumHelper.addArmorMaterial("HBM_LIQUIDATOR", 750, new int[] { 3, 8, 6, 3 }, 10);
|
||||
aMatLiquidator.customCraftingMaterial = ModItems.plate_lead;
|
||||
liquidator_helmet = new ArmorLiquidatorMask(aMatLiquidator, 0, RefStrings.MODID + ":textures/armor/liquidator_helmet.png")
|
||||
.setThreshold(1.0F)
|
||||
.setBlastProtection(0.25F)
|
||||
.setFireproof(true)
|
||||
.setStep("hbm:step.metal")
|
||||
.setJump("hbm:step.iron_jump")
|
||||
.setFall("hbm:step.iron_land").setUnlocalizedName("liquidator_helmet").setMaxStackSize(1).setTextureName(RefStrings.MODID + ":liquidator_helmet");
|
||||
@ -6110,12 +5979,6 @@ public class ModItems {
|
||||
GameRegistry.registerItem(assembly_nuke, assembly_nuke.getUnlocalizedName());
|
||||
GameRegistry.registerItem(assembly_luna, assembly_luna.getUnlocalizedName());
|
||||
|
||||
//Folly Parts
|
||||
GameRegistry.registerItem(folly_shell, folly_shell.getUnlocalizedName());
|
||||
GameRegistry.registerItem(folly_bullet, folly_bullet.getUnlocalizedName());
|
||||
GameRegistry.registerItem(folly_bullet_nuclear, folly_bullet_nuclear.getUnlocalizedName());
|
||||
GameRegistry.registerItem(folly_bullet_du, folly_bullet_du.getUnlocalizedName());
|
||||
|
||||
//Wiring
|
||||
GameRegistry.registerItem(wiring_red_copper, wiring_red_copper.getUnlocalizedName());
|
||||
|
||||
@ -6134,7 +5997,6 @@ public class ModItems {
|
||||
GameRegistry.registerItem(pellet_rtg_actinium, pellet_rtg_actinium.getUnlocalizedName());
|
||||
GameRegistry.registerItem(pellet_rtg_polonium, pellet_rtg_polonium.getUnlocalizedName());
|
||||
GameRegistry.registerItem(pellet_rtg_americium, pellet_rtg_americium.getUnlocalizedName());
|
||||
GameRegistry.registerItem(pellet_rtg_berkelium, pellet_rtg_berkelium.getUnlocalizedName());
|
||||
GameRegistry.registerItem(pellet_rtg_gold, pellet_rtg_gold.getUnlocalizedName());
|
||||
GameRegistry.registerItem(pellet_rtg_lead, pellet_rtg_lead.getUnlocalizedName());
|
||||
GameRegistry.registerItem(pellet_rtg_depleted, pellet_rtg_depleted.getUnlocalizedName());
|
||||
@ -6894,7 +6756,6 @@ public class ModItems {
|
||||
GameRegistry.registerItem(gun_ar15, gun_ar15.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_calamity, gun_calamity.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_lacunae, gun_lacunae.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_folly, gun_folly.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_b92, gun_b92.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_b93, gun_b93.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_rpg, gun_rpg.getUnlocalizedName());
|
||||
@ -6953,6 +6814,7 @@ public class ModItems {
|
||||
|
||||
GameRegistry.registerItem(gun_pepperbox, gun_pepperbox.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_light_revolver, gun_light_revolver.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_light_revolver_atlas, gun_light_revolver_atlas.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_light_revolver_dani, gun_light_revolver_dani.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_henry, gun_henry.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_greasegun, gun_greasegun.getUnlocalizedName());
|
||||
@ -6967,7 +6829,10 @@ public class ModItems {
|
||||
GameRegistry.registerItem(gun_liberator, gun_liberator.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_congolake, gun_congolake.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_flamer, gun_flamer.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_flamer_topaz, gun_flamer_topaz.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_flamer_daybreaker, gun_flamer_daybreaker.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_uzi, gun_uzi.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_uzi_akimbo, gun_uzi_akimbo.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_spas12, gun_spas12.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_panzerschreck, gun_panzerschreck.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_g3, gun_g3.getUnlocalizedName());
|
||||
@ -6979,6 +6844,7 @@ public class ModItems {
|
||||
GameRegistry.registerItem(gun_quadro, gun_quadro.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_lag, gun_lag.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_minigun, gun_minigun.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_minigun_lacunae, gun_minigun_lacunae.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_missile_launcher, gun_missile_launcher.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_tesla_cannon, gun_tesla_cannon.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_stg77, gun_stg77.getUnlocalizedName());
|
||||
@ -6988,8 +6854,10 @@ public class ModItems {
|
||||
GameRegistry.registerItem(gun_coilgun, gun_coilgun.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_hangman, gun_hangman.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_bolter, gun_bolter.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_folly, gun_folly.getUnlocalizedName());
|
||||
|
||||
GameRegistry.registerItem(ammo_standard, ammo_standard.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_secret, ammo_secret.getUnlocalizedName());
|
||||
|
||||
//Ammo
|
||||
GameRegistry.registerItem(gun_b92_ammo, gun_b92_ammo.getUnlocalizedName());
|
||||
@ -7033,42 +6901,6 @@ public class ModItems {
|
||||
GameRegistry.registerItem(ammo_dgk, ammo_dgk.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_arty, ammo_arty.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_himars, ammo_himars.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_folly, ammo_folly.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_folly_nuclear, ammo_folly_nuclear.getUnlocalizedName());
|
||||
GameRegistry.registerItem(ammo_folly_du, ammo_folly_du.getUnlocalizedName());
|
||||
|
||||
//-C-l-i-p-s- Magazines
|
||||
GameRegistry.registerItem(clip_revolver_iron, clip_revolver_iron.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_revolver, clip_revolver.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_revolver_gold, clip_revolver_gold.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_revolver_lead, clip_revolver_lead.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_revolver_schrabidium, clip_revolver_schrabidium.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_revolver_cursed, clip_revolver_cursed.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_revolver_nightmare, clip_revolver_nightmare.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_revolver_nightmare2, clip_revolver_nightmare2.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_revolver_pip, clip_revolver_pip.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_revolver_nopip, clip_revolver_nopip.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_rpg, clip_rpg.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_stinger, clip_stinger.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_fatman, clip_fatman.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_mirv, clip_mirv.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_bf, clip_bf.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_mp40, clip_mp40.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_uzi, clip_uzi.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_uboinik, clip_uboinik.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_lever_action, clip_lever_action.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_bolt_action, clip_bolt_action.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_xvl1456, clip_xvl1456.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_osipr, clip_osipr.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_immolator, clip_immolator.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_cryolator, clip_cryolator.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_mp, clip_mp.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_emp, clip_emp.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_jack, clip_jack.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_spark, clip_spark.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_hp, clip_hp.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_euthanasia, clip_euthanasia.getUnlocalizedName());
|
||||
GameRegistry.registerItem(clip_defabricator, clip_defabricator.getUnlocalizedName());
|
||||
|
||||
GameRegistry.registerItem(ammo_container, ammo_container.getUnlocalizedName());
|
||||
|
||||
@ -7599,7 +7431,6 @@ public class ModItems {
|
||||
GameRegistry.registerItem(detonator_laser, detonator_laser.getUnlocalizedName());
|
||||
GameRegistry.registerItem(detonator_deadman, detonator_deadman.getUnlocalizedName());
|
||||
GameRegistry.registerItem(detonator_de, detonator_de.getUnlocalizedName());
|
||||
GameRegistry.registerItem(crate_caller, crate_caller.getUnlocalizedName());
|
||||
GameRegistry.registerItem(bomb_caller, bomb_caller.getUnlocalizedName());
|
||||
GameRegistry.registerItem(meteor_remote, meteor_remote.getUnlocalizedName());
|
||||
GameRegistry.registerItem(anchor_remote, anchor_remote.getUnlocalizedName());
|
||||
|
||||
@ -184,13 +184,9 @@ public class ArmorDNT extends ArmorFSBPowered {
|
||||
}
|
||||
}
|
||||
|
||||
list.add(EnumChatFormatting.YELLOW + " " + I18nUtil.resolveKey("armor.explosionImmune"));
|
||||
list.add(EnumChatFormatting.YELLOW + " " + I18nUtil.resolveKey("armor.cap", 5));
|
||||
list.add(EnumChatFormatting.YELLOW + " " + I18nUtil.resolveKey("armor.modifier", 0.001F));
|
||||
list.add(EnumChatFormatting.RED + " " + I18nUtil.resolveKey("armor.vats"));
|
||||
list.add(EnumChatFormatting.RED + " " + I18nUtil.resolveKey("armor.thermal"));
|
||||
list.add(EnumChatFormatting.RED + " " + I18nUtil.resolveKey("armor.hardLanding"));
|
||||
list.add(EnumChatFormatting.DARK_RED + " " + I18nUtil.resolveKey("armor.ignoreLimit"));
|
||||
list.add(EnumChatFormatting.AQUA + " " + I18nUtil.resolveKey("armor.rocketBoots"));
|
||||
list.add(EnumChatFormatting.AQUA + " " + I18nUtil.resolveKey("armor.fastFall"));
|
||||
list.add(EnumChatFormatting.AQUA + " " + I18nUtil.resolveKey("armor.sprintBoost"));
|
||||
|
||||
@ -3,10 +3,8 @@ package com.hbm.items.armor;
|
||||
import java.lang.reflect.Field;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.HashMap;
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.Map.Entry;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
@ -28,7 +26,6 @@ import net.minecraft.client.renderer.OpenGlHelper;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.client.resources.I18n;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.item.EntityItem;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemArmor;
|
||||
@ -51,21 +48,12 @@ public class ArmorFSB extends ItemArmor implements IArmorDisableModel {
|
||||
private String texture = "";
|
||||
private ResourceLocation overlay = null;
|
||||
public List<PotionEffect> effects = new ArrayList<PotionEffect>();
|
||||
public HashMap<String, Float> resistance = new HashMap<String, Float>();
|
||||
public float blastProtection = -1;
|
||||
public float projectileProtection = -1;
|
||||
public float damageCap = -1;
|
||||
public float damageMod = -1;
|
||||
public float damageThreshold = 0;
|
||||
public float protectionYield = 100F;
|
||||
public boolean fireproof = false;
|
||||
public boolean noHelmet = false;
|
||||
public boolean vats = false;
|
||||
public boolean thermal = false;
|
||||
public boolean geigerSound = false;
|
||||
public boolean customGeiger = false;
|
||||
public boolean hardLanding = false;
|
||||
public double gravity = 0;
|
||||
public int dashCount = 0;
|
||||
public int stepSize = 0;
|
||||
public String step;
|
||||
@ -82,46 +70,6 @@ public class ArmorFSB extends ItemArmor implements IArmorDisableModel {
|
||||
return this;
|
||||
}
|
||||
|
||||
public ArmorFSB addResistance(String damage, float mod) {
|
||||
resistance.put(damage, mod);
|
||||
return this;
|
||||
}
|
||||
|
||||
public ArmorFSB setCap(float cap) {
|
||||
this.damageCap = cap;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ArmorFSB setMod(float mod) {
|
||||
this.damageMod = mod;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ArmorFSB setThreshold(float threshold) {
|
||||
this.damageThreshold = threshold;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ArmorFSB setProtectionLevel(float damageYield) {
|
||||
this.protectionYield = damageYield;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ArmorFSB setBlastProtection(float blastProtection) {
|
||||
this.blastProtection = blastProtection;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ArmorFSB setProjectileProtection(float projectileProtection) {
|
||||
this.projectileProtection = projectileProtection;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ArmorFSB setFireproof(boolean fire) {
|
||||
this.fireproof = fire;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ArmorFSB setNoHelmet(boolean noHelmet) {
|
||||
this.noHelmet = noHelmet;
|
||||
return this;
|
||||
@ -151,11 +99,6 @@ public class ArmorFSB extends ItemArmor implements IArmorDisableModel {
|
||||
this.hardLanding = hardLanding;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ArmorFSB setGravity(double gravity) {
|
||||
this.gravity = gravity;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ArmorFSB setDashCount(int dashCount) {
|
||||
this.dashCount = dashCount;
|
||||
@ -191,21 +134,12 @@ public class ArmorFSB extends ItemArmor implements IArmorDisableModel {
|
||||
|
||||
//lists aren't being modified after instantiation, so there's no need to dereference
|
||||
this.effects = original.effects;
|
||||
this.resistance = original.resistance;
|
||||
this.damageCap = original.damageCap;
|
||||
this.damageMod = original.damageMod;
|
||||
this.damageThreshold = original.damageThreshold;
|
||||
this.protectionYield = original.protectionYield;
|
||||
this.blastProtection = original.blastProtection;
|
||||
this.projectileProtection = original.projectileProtection;
|
||||
this.fireproof = original.fireproof;
|
||||
this.noHelmet = original.noHelmet;
|
||||
this.vats = original.vats;
|
||||
this.thermal = original.thermal;
|
||||
this.geigerSound = original.geigerSound;
|
||||
this.customGeiger = original.customGeiger;
|
||||
this.hardLanding = original.hardLanding;
|
||||
this.gravity = original.gravity;
|
||||
this.dashCount = original.dashCount;
|
||||
this.stepSize = original.stepSize;
|
||||
this.step = original.step;
|
||||
@ -222,85 +156,29 @@ public class ArmorFSB extends ItemArmor implements IArmorDisableModel {
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean bool) {
|
||||
|
||||
list.add(EnumChatFormatting.GOLD + I18nUtil.resolveKey("armor.fullSetBonus"));
|
||||
|
||||
List toAdd = new ArrayList();
|
||||
|
||||
if(!effects.isEmpty()) {
|
||||
|
||||
List potionList = new ArrayList();
|
||||
for(PotionEffect effect : effects) {
|
||||
list.add(EnumChatFormatting.AQUA + " " + I18n.format(Potion.potionTypes[effect.getPotionID()].getName()));
|
||||
potionList.add(I18n.format(Potion.potionTypes[effect.getPotionID()].getName()));
|
||||
}
|
||||
|
||||
toAdd.add(EnumChatFormatting.AQUA + String.join(", ", potionList));
|
||||
}
|
||||
|
||||
if(!resistance.isEmpty()) {
|
||||
if(geigerSound) toAdd.add(EnumChatFormatting.GOLD + " " + I18nUtil.resolveKey("armor.geigerSound"));
|
||||
if(customGeiger) toAdd.add(EnumChatFormatting.GOLD + " " + I18nUtil.resolveKey("armor.geigerHUD"));
|
||||
if(vats) toAdd.add(EnumChatFormatting.RED + " " + I18nUtil.resolveKey("armor.vats"));
|
||||
if(thermal) toAdd.add(EnumChatFormatting.RED + " " + I18nUtil.resolveKey("armor.thermal"));
|
||||
if(hardLanding) toAdd.add(EnumChatFormatting.RED + " " + I18nUtil.resolveKey("armor.hardLanding"));
|
||||
if(stepSize != 0) toAdd.add(EnumChatFormatting.BLUE + " " + I18nUtil.resolveKey("armor.stepSize", stepSize));
|
||||
if(dashCount > 0) toAdd.add(EnumChatFormatting.AQUA + " " + I18nUtil.resolveKey("armor.dash", dashCount));
|
||||
|
||||
for(Entry<String, Float> struct : resistance.entrySet()) {
|
||||
|
||||
if(struct.getValue() != 0)
|
||||
list.add(EnumChatFormatting.YELLOW + " " + I18nUtil.resolveKey("armor.damageModifier", struct.getValue(), I18n.format(struct.getKey())));
|
||||
else
|
||||
list.add(EnumChatFormatting.RED + " " + I18nUtil.resolveKey("armor.nullDamage", I18n.format(struct.getKey())));
|
||||
}
|
||||
}
|
||||
|
||||
if(blastProtection != -1) {
|
||||
list.add(EnumChatFormatting.YELLOW + " " + I18nUtil.resolveKey("armor.blastProtection", blastProtection));
|
||||
}
|
||||
|
||||
if(projectileProtection != -1) {
|
||||
list.add(EnumChatFormatting.YELLOW + " " + I18nUtil.resolveKey("armor.projectileProtection", projectileProtection));
|
||||
}
|
||||
|
||||
if(damageCap != -1) {
|
||||
list.add(EnumChatFormatting.YELLOW + " " + I18nUtil.resolveKey("armor.cap", damageCap));
|
||||
}
|
||||
|
||||
if(damageMod != -1) {
|
||||
list.add(EnumChatFormatting.YELLOW + " " + I18nUtil.resolveKey("armor.modifier", damageMod));
|
||||
}
|
||||
|
||||
if(damageThreshold > 0) {
|
||||
list.add(EnumChatFormatting.YELLOW + " " + I18nUtil.resolveKey("armor.threshold", damageThreshold));
|
||||
}
|
||||
|
||||
if(fireproof) {
|
||||
list.add(EnumChatFormatting.RED + " " + I18nUtil.resolveKey("armor.fireproof"));
|
||||
}
|
||||
|
||||
if(geigerSound) {
|
||||
list.add(EnumChatFormatting.GOLD + " " + I18nUtil.resolveKey("armor.geigerSound"));
|
||||
}
|
||||
|
||||
if(customGeiger) {
|
||||
list.add(EnumChatFormatting.GOLD + " " + I18nUtil.resolveKey("armor.geigerHUD"));
|
||||
}
|
||||
|
||||
if(vats) {
|
||||
list.add(EnumChatFormatting.RED + " " + I18nUtil.resolveKey("armor.vats"));
|
||||
}
|
||||
|
||||
if(thermal) {
|
||||
list.add(EnumChatFormatting.RED + " " + I18nUtil.resolveKey("armor.thermal"));
|
||||
}
|
||||
|
||||
if(hardLanding) {
|
||||
list.add(EnumChatFormatting.RED + " " + I18nUtil.resolveKey("armor.hardLanding"));
|
||||
}
|
||||
|
||||
if(gravity != 0) {
|
||||
list.add(EnumChatFormatting.BLUE + " " + I18nUtil.resolveKey("armor.gravity", gravity));
|
||||
}
|
||||
|
||||
if(stepSize != 0) {
|
||||
list.add(EnumChatFormatting.BLUE + " " + I18nUtil.resolveKey("armor.stepSize", stepSize));
|
||||
}
|
||||
|
||||
if(dashCount > 0) {
|
||||
list.add(EnumChatFormatting.AQUA + " " + I18nUtil.resolveKey("armor.dash", dashCount));
|
||||
}
|
||||
|
||||
if(protectionYield != 100F) {
|
||||
list.add(EnumChatFormatting.BLUE + " " + I18nUtil.resolveKey("armor.yield", protectionYield));
|
||||
if(!toAdd.isEmpty()) {
|
||||
list.add(EnumChatFormatting.GOLD + I18nUtil.resolveKey("armor.fullSetBonus"));
|
||||
list.addAll(toAdd);
|
||||
}
|
||||
}
|
||||
|
||||
@ -359,80 +237,6 @@ public class ArmorFSB extends ItemArmor implements IArmorDisableModel {
|
||||
return false;
|
||||
}
|
||||
|
||||
public void handleAttack(LivingAttackEvent event) {
|
||||
|
||||
EntityLivingBase e = event.entityLiving;
|
||||
|
||||
if(e instanceof EntityPlayer) {
|
||||
EntityPlayer player = (EntityPlayer) e;
|
||||
|
||||
if(ArmorFSB.hasFSBArmor(player)) {
|
||||
|
||||
ItemStack plate = player.inventory.armorInventory[2];
|
||||
|
||||
ArmorFSB chestplate = (ArmorFSB) plate.getItem();
|
||||
|
||||
if(chestplate.damageThreshold >= event.ammount && !event.source.isUnblockable()) {
|
||||
event.setCanceled(true);
|
||||
}
|
||||
|
||||
if(chestplate.fireproof && event.source.isFireDamage()) {
|
||||
player.extinguish();
|
||||
event.setCanceled(true);
|
||||
}
|
||||
|
||||
if(chestplate.resistance.get(event.source.getDamageType()) != null && chestplate.resistance.get(event.source.getDamageType()) <= 0) {
|
||||
event.setCanceled(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void handleHurt(LivingHurtEvent event) {
|
||||
|
||||
EntityLivingBase e = event.entityLiving;
|
||||
|
||||
if(e instanceof EntityPlayer) {
|
||||
EntityPlayer player = (EntityPlayer) e;
|
||||
|
||||
if(ArmorFSB.hasFSBArmor(player)) {
|
||||
|
||||
ArmorFSB chestplate = (ArmorFSB) player.inventory.armorInventory[2].getItem();
|
||||
|
||||
//store any damage above the yield
|
||||
float overFlow = Math.max(0, event.ammount - chestplate.protectionYield);
|
||||
//reduce the damage to the yield cap if it exceeds the yield
|
||||
event.ammount = Math.min(event.ammount, chestplate.protectionYield);
|
||||
|
||||
if(!event.source.isUnblockable())
|
||||
event.ammount -= chestplate.damageThreshold;
|
||||
|
||||
if(chestplate.damageMod != -1) {
|
||||
event.ammount *= chestplate.damageMod;
|
||||
}
|
||||
|
||||
if(chestplate.resistance.get(event.source.getDamageType()) != null) {
|
||||
event.ammount *= chestplate.resistance.get(event.source.getDamageType());
|
||||
}
|
||||
|
||||
if(chestplate.blastProtection != -1 && event.source.isExplosion()) {
|
||||
event.ammount *= chestplate.blastProtection;
|
||||
}
|
||||
|
||||
if(chestplate.projectileProtection != -1 && event.source.isProjectile()) {
|
||||
event.ammount *= chestplate.projectileProtection;
|
||||
}
|
||||
|
||||
if(chestplate.damageCap != -1) {
|
||||
event.ammount = Math.min(event.ammount, chestplate.damageCap);
|
||||
}
|
||||
|
||||
//add back anything that was above the protection yield before
|
||||
event.ammount += overFlow;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void handleTick(TickEvent.PlayerTickEvent event) {
|
||||
|
||||
EntityPlayer player = event.player;
|
||||
@ -450,9 +254,6 @@ public class ArmorFSB extends ItemArmor implements IArmorDisableModel {
|
||||
}
|
||||
}
|
||||
|
||||
if(!player.capabilities.isFlying && !player.isInWater())
|
||||
player.motionY -= chestplate.gravity;
|
||||
|
||||
if(chestplate.step != null && player.worldObj.isRemote && player.onGround) {
|
||||
|
||||
try {
|
||||
@ -531,14 +332,9 @@ public class ArmorFSB extends ItemArmor implements IArmorDisableModel {
|
||||
@Override
|
||||
public void onArmorTick(World world, EntityPlayer entity, ItemStack stack) {
|
||||
|
||||
if(this.armorType != 1)
|
||||
return;
|
||||
|
||||
if(!hasFSBArmor(entity) || !this.geigerSound)
|
||||
return;
|
||||
|
||||
if(entity.inventory.hasItem(ModItems.geiger_counter) || entity.inventory.hasItem(ModItems.dosimeter))
|
||||
return;
|
||||
if(this.armorType != 1) return;
|
||||
if(!hasFSBArmor(entity) || !this.geigerSound) return;
|
||||
if(entity.inventory.hasItem(ModItems.geiger_counter) || entity.inventory.hasItem(ModItems.dosimeter)) return;
|
||||
|
||||
if(world.getTotalWorldTime() % 5 == 0) {
|
||||
|
||||
@ -560,26 +356,20 @@ public class ArmorFSB extends ItemArmor implements IArmorDisableModel {
|
||||
|
||||
int r = list.get(world.rand.nextInt(list.size()));
|
||||
|
||||
if(r > 0)
|
||||
world.playSoundAtEntity(entity, "hbm:item.geiger" + r, 1.0F, 1.0F);
|
||||
if(r > 0) world.playSoundAtEntity(entity, "hbm:item.geiger" + r, 1.0F, 1.0F);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static int check(World world, int x, int y, int z) {
|
||||
|
||||
int rads = (int) Math.ceil(ChunkRadiationManager.proxy.getRadiation(world, x, y, z));
|
||||
return rads;
|
||||
}
|
||||
|
||||
// For crazier stuff not possible without hooking the event
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void handleOverlay(RenderGameOverlayEvent.Pre event, EntityPlayer player) {
|
||||
}
|
||||
@SideOnly(Side.CLIENT) public void handleOverlay(RenderGameOverlayEvent.Pre event, EntityPlayer player) { }
|
||||
|
||||
public boolean isArmorEnabled(ItemStack stack) {
|
||||
return true;
|
||||
}
|
||||
public boolean isArmorEnabled(ItemStack stack) { return true; }
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void renderHelmetOverlay(ItemStack stack, EntityPlayer player, ScaledResolution resolution, float partialTicks, boolean hasScreen, int mouseX, int mouseY) {
|
||||
@ -624,4 +414,7 @@ public class ArmorFSB extends ItemArmor implements IArmorDisableModel {
|
||||
public boolean disablesPart(EntityPlayer player, ItemStack stack, EnumPlayerPart part) {
|
||||
return hidden.contains(part) && (!needsFullSet || hasFSBArmorIgnoreCharge(player));
|
||||
}
|
||||
|
||||
public void handleAttack(LivingAttackEvent event) { }
|
||||
public void handleHurt(LivingHurtEvent event) { }
|
||||
}
|
||||
|
||||
@ -37,10 +37,7 @@ public class ItemBombCaller extends Item {
|
||||
case 5: list.add("Type: VT stinger rockets"); break;
|
||||
case 6: list.add("Type: PIP OH GOD"); break;
|
||||
case 7: list.add("Type: Cloud the cloud oh god the cloud"); break;
|
||||
default: list.add("Type: INVALID, Report it to mod creator");
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@ -1,70 +0,0 @@
|
||||
package com.hbm.items.tool;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.hbm.blocks.ModBlocks;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.ChatComponentText;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemCrateCaller extends Item {
|
||||
|
||||
Random rand = new Random();
|
||||
|
||||
public ItemCrateCaller() {
|
||||
this.canRepair = false;
|
||||
this.setMaxDamage(4);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool)
|
||||
{
|
||||
list.add("Right click to request supply drop!");
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player) {
|
||||
|
||||
stack.damageItem(1, player);
|
||||
|
||||
int x = rand.nextInt(31) - 15;
|
||||
int z = rand.nextInt(31) - 15;
|
||||
|
||||
Block crate = ModBlocks.crate;
|
||||
|
||||
int i = rand.nextInt(1000);
|
||||
|
||||
if(i < 350)
|
||||
crate = ModBlocks.crate_weapon;
|
||||
if(i < 100)
|
||||
crate = ModBlocks.crate_metal;
|
||||
if(i < 50)
|
||||
crate = ModBlocks.crate_lead;
|
||||
if(i == 0)
|
||||
crate = ModBlocks.crate_red;
|
||||
|
||||
if(!world.isRemote)
|
||||
{
|
||||
if(world.getBlock((int)player.posX + x, 255, (int)player.posZ + z) == Blocks.air)
|
||||
world.setBlock((int)player.posX + x, 255, (int)player.posZ + z, crate);
|
||||
}
|
||||
if(world.isRemote)
|
||||
{
|
||||
player.addChatMessage(new ChatComponentText("Called in supply drop!"));
|
||||
}
|
||||
|
||||
world.playSoundAtEntity(player, "hbm:item.techBleep", 1.0F, 1.0F);
|
||||
|
||||
player.swingItem();
|
||||
|
||||
return stack;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@ -1,270 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.google.common.collect.Multimap;
|
||||
import com.hbm.entity.effect.EntityCloudFleijaRainbow;
|
||||
import com.hbm.entity.logic.EntityNukeExplosionMK3;
|
||||
import com.hbm.entity.projectile.EntityModBeam;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.attributes.AttributeModifier;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.EnumAction;
|
||||
import net.minecraft.item.EnumRarity;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
import net.minecraftforge.event.entity.player.ArrowLooseEvent;
|
||||
import net.minecraftforge.event.entity.player.ArrowNockEvent;
|
||||
|
||||
public class GunB93 extends Item {
|
||||
|
||||
Random rand = new Random();
|
||||
|
||||
public int dmgMin = 16;
|
||||
public int dmgMax = 28;
|
||||
|
||||
public GunB93() {
|
||||
|
||||
this.maxStackSize = 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onPlayerStoppedUsing(ItemStack p_77615_1_, World p_77615_2_, EntityPlayer p_77615_3_, int p_77615_4_) {
|
||||
if (!p_77615_3_.isSneaking()) {
|
||||
int j = this.getMaxItemUseDuration(p_77615_1_) - p_77615_4_;
|
||||
|
||||
ArrowLooseEvent event = new ArrowLooseEvent(p_77615_3_, p_77615_1_, j);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
j = event.charge;
|
||||
|
||||
boolean flag = true;
|
||||
|
||||
if (flag) {
|
||||
float f = j / 20.0F;
|
||||
f = (f * f + f * 2.0F) / 3.0F;
|
||||
|
||||
if (j < 10.0D) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (j > 10.0F) {
|
||||
f = 10.0F;
|
||||
}
|
||||
|
||||
if (!p_77615_2_.isRemote) {
|
||||
|
||||
EntityModBeam entityarrow1;
|
||||
entityarrow1 = new EntityModBeam(p_77615_2_, p_77615_3_, 3.0F);
|
||||
entityarrow1.mode = getPower(p_77615_1_) - 1;
|
||||
p_77615_1_.damageItem(1, p_77615_3_);
|
||||
|
||||
p_77615_2_.spawnEntityInWorld(entityarrow1);
|
||||
|
||||
p_77615_2_.playSoundAtEntity(p_77615_3_, "hbm:weapon.sparkShoot", 5.0F, 1.0F);
|
||||
}
|
||||
|
||||
setAnim(p_77615_1_, 1);
|
||||
setPower(p_77615_1_, 0);
|
||||
}
|
||||
} else {
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUpdate(ItemStack stack, World world, Entity entity, int i, boolean b) {
|
||||
int j = getAnim(stack);
|
||||
|
||||
if (j > 0) {
|
||||
if (j < 30)
|
||||
setAnim(stack, j + 1);
|
||||
else
|
||||
setAnim(stack, 0);
|
||||
|
||||
if (j == 15) {
|
||||
world.playSoundAtEntity(entity, "hbm:weapon.b92Reload", 2F, 0.9F);
|
||||
setPower(stack, getPower(stack) + 1);
|
||||
|
||||
if(getPower(stack) > 10) {
|
||||
|
||||
setPower(stack, 0);
|
||||
|
||||
if(!world.isRemote) {
|
||||
EntityNukeExplosionMK3 ex = EntityNukeExplosionMK3.statFacFleija(world, entity.posX, entity.posY, entity.posZ, 50);
|
||||
if(!ex.isDead) {
|
||||
world.playSoundEffect(entity.posX, entity.posY, entity.posZ, "random.explode", 100.0f, world.rand.nextFloat() * 0.1F + 0.9F);
|
||||
|
||||
world.spawnEntityInWorld(ex);
|
||||
|
||||
EntityCloudFleijaRainbow cloud = new EntityCloudFleijaRainbow(world, 50);
|
||||
cloud.posX = entity.posX;
|
||||
cloud.posY = entity.posY;
|
||||
cloud.posZ = entity.posZ;
|
||||
world.spawnEntityInWorld(cloud);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onEaten(ItemStack p_77654_1_, World p_77654_2_, EntityPlayer p_77654_3_) {
|
||||
return p_77654_1_;
|
||||
}
|
||||
|
||||
/**
|
||||
* How long it takes to use or consume an item
|
||||
*/
|
||||
@Override
|
||||
public int getMaxItemUseDuration(ItemStack p_77626_1_) {
|
||||
return 72000;
|
||||
}
|
||||
|
||||
/**
|
||||
* returns the action that specifies what animation to play when the items
|
||||
* is being used
|
||||
*/
|
||||
@Override
|
||||
public EnumAction getItemUseAction(ItemStack p_77661_1_) {
|
||||
return EnumAction.bow;
|
||||
}
|
||||
|
||||
/**
|
||||
* 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_3_.isSneaking() && getPower(p_77659_1_) > 0) {
|
||||
ArrowNockEvent event = new ArrowNockEvent(p_77659_3_, p_77659_1_);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
|
||||
if (this.getAnim(p_77659_1_) == 0)
|
||||
p_77659_3_.setItemInUse(p_77659_1_, this.getMaxItemUseDuration(p_77659_1_));
|
||||
} else {
|
||||
if (getAnim(p_77659_1_) == 0) {
|
||||
setAnim(p_77659_1_, 1);
|
||||
}
|
||||
}
|
||||
|
||||
return p_77659_1_;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the enchantability factor of the item, most of the time is based
|
||||
* on material.
|
||||
*/
|
||||
@Override
|
||||
public int getItemEnchantability() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool) {
|
||||
|
||||
list.add("[LEGENDARY WEAPON]");
|
||||
}
|
||||
|
||||
@Override
|
||||
public Multimap getItemAttributeModifiers() {
|
||||
Multimap multimap = super.getItemAttributeModifiers();
|
||||
multimap.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(),
|
||||
new AttributeModifier(field_111210_e, "Weapon modifier", 3.5, 0));
|
||||
return multimap;
|
||||
}
|
||||
|
||||
private static int getAnim(ItemStack stack) {
|
||||
if (stack.stackTagCompound == null) {
|
||||
stack.stackTagCompound = new NBTTagCompound();
|
||||
return 0;
|
||||
}
|
||||
|
||||
return stack.stackTagCompound.getInteger("animation");
|
||||
|
||||
}
|
||||
|
||||
private static void setAnim(ItemStack stack, int i) {
|
||||
if (stack.stackTagCompound == null) {
|
||||
stack.stackTagCompound = new NBTTagCompound();
|
||||
}
|
||||
|
||||
stack.stackTagCompound.setInteger("animation", i);
|
||||
|
||||
}
|
||||
|
||||
private static int getPower(ItemStack stack) {
|
||||
if (stack.stackTagCompound == null) {
|
||||
stack.stackTagCompound = new NBTTagCompound();
|
||||
return 0;
|
||||
}
|
||||
|
||||
return stack.stackTagCompound.getInteger("energy");
|
||||
|
||||
}
|
||||
|
||||
private static void setPower(ItemStack stack, int i) {
|
||||
if (stack.stackTagCompound == null) {
|
||||
stack.stackTagCompound = new NBTTagCompound();
|
||||
}
|
||||
|
||||
stack.stackTagCompound.setInteger("energy", i);
|
||||
|
||||
}
|
||||
|
||||
public static float getRotationFromAnim(ItemStack stack) {
|
||||
float rad = 0.0174533F;
|
||||
rad *= 7.5F;
|
||||
int i = getAnim(stack);
|
||||
|
||||
if (i < 10)
|
||||
return 0;
|
||||
i -= 10;
|
||||
|
||||
if (i < 6)
|
||||
return rad * i;
|
||||
if (i > 14)
|
||||
return rad * (5 - (i - 15));
|
||||
return rad * 5;
|
||||
}
|
||||
|
||||
public static float getOffsetFromAnim(ItemStack stack) {
|
||||
float i = getAnim(stack);
|
||||
|
||||
if (i < 10)
|
||||
return 0;
|
||||
i -= 10;
|
||||
|
||||
if (i < 10)
|
||||
return i / 10;
|
||||
else
|
||||
return 2 - (i / 10);
|
||||
}
|
||||
|
||||
public static float getTransFromAnim(ItemStack stack) {
|
||||
float i = getAnim(stack);
|
||||
|
||||
if (i < 10)
|
||||
return 0;
|
||||
i -= 10;
|
||||
|
||||
if (i > 4 && i < 10)
|
||||
return (i - 5) * 0.05F;
|
||||
|
||||
if (i > 9 && i < 15)
|
||||
return (10 * 0.05F) - ((i - 5) * 0.05F);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EnumRarity getRarity(ItemStack p_77613_1_) {
|
||||
|
||||
return EnumRarity.uncommon;
|
||||
}
|
||||
}
|
||||
@ -1,95 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.google.common.collect.Multimap;
|
||||
import com.hbm.entity.projectile.EntityLN2;
|
||||
import com.hbm.items.ModItems;
|
||||
|
||||
import net.minecraft.enchantment.Enchantment;
|
||||
import net.minecraft.enchantment.EnchantmentHelper;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.attributes.AttributeModifier;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.EnumAction;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.event.entity.player.ArrowNockEvent;
|
||||
|
||||
public class GunCryolator extends Item {
|
||||
|
||||
Random rand = new Random();
|
||||
|
||||
public GunCryolator() {
|
||||
this.maxStackSize = 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EnumAction getItemUseAction(ItemStack par1ItemStack) {
|
||||
return EnumAction.bow;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMaxItemUseDuration(ItemStack p_77626_1_) {
|
||||
return 72000;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onItemRightClick(ItemStack p_77659_1_, World p_77659_2_, EntityPlayer p_77659_3_) {
|
||||
new ArrowNockEvent(p_77659_3_, p_77659_1_);
|
||||
{
|
||||
p_77659_3_.setItemInUse(p_77659_1_, this.getMaxItemUseDuration(p_77659_1_));
|
||||
}
|
||||
|
||||
return p_77659_1_;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUsingTick(ItemStack stack, EntityPlayer player, int count) {
|
||||
World world = player.worldObj;
|
||||
|
||||
boolean flag = player.capabilities.isCreativeMode
|
||||
|| EnchantmentHelper.getEnchantmentLevel(Enchantment.infinity.effectId, stack) > 0;
|
||||
if ((player.capabilities.isCreativeMode || player.inventory.hasItem(ModItems.gun_cryolator_ammo))) {
|
||||
EntityLN2 entityarrow = new EntityLN2(world, player, 3.0F);
|
||||
|
||||
if (flag) {
|
||||
entityarrow.canBePickedUp = 2;
|
||||
} else {
|
||||
if (count % 10 == 0)
|
||||
player.inventory.consumeInventoryItem(ModItems.gun_cryolator_ammo);
|
||||
}
|
||||
|
||||
if (count % 5 == 0)
|
||||
world.playSoundAtEntity(player, "hbm:weapon.cryolatorShoot", 1.0F, 1F);
|
||||
|
||||
if (!world.isRemote) {
|
||||
world.spawnEntityInWorld(entityarrow);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemEnchantability() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool) {
|
||||
|
||||
list.add("Ice to meet you!");
|
||||
list.add("");
|
||||
list.add("Ammo: Cryolator Ammo");
|
||||
list.add("Damage: 5");
|
||||
}
|
||||
|
||||
@Override
|
||||
public Multimap getItemAttributeModifiers() {
|
||||
Multimap multimap = super.getItemAttributeModifiers();
|
||||
multimap.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(),
|
||||
new AttributeModifier(field_111210_e, "Weapon modifier", 4, 0));
|
||||
return multimap;
|
||||
}
|
||||
}
|
||||
@ -1,103 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.google.common.collect.Multimap;
|
||||
import com.hbm.entity.projectile.EntityBullet;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.main.MainRegistry;
|
||||
|
||||
import net.minecraft.enchantment.Enchantment;
|
||||
import net.minecraft.enchantment.EnchantmentHelper;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.attributes.AttributeModifier;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.EnumAction;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.event.entity.player.ArrowNockEvent;
|
||||
|
||||
public class GunDefabricator extends Item {
|
||||
|
||||
Random rand = new Random();
|
||||
|
||||
public GunDefabricator()
|
||||
{
|
||||
this.maxStackSize = 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EnumAction getItemUseAction(ItemStack par1ItemStack) {
|
||||
return EnumAction.bow;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMaxItemUseDuration(ItemStack p_77626_1_) {
|
||||
return 72000;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onItemRightClick(ItemStack p_77659_1_, World p_77659_2_, EntityPlayer p_77659_3_) {
|
||||
new ArrowNockEvent(p_77659_3_, p_77659_1_);
|
||||
{
|
||||
p_77659_3_.setItemInUse(p_77659_1_, this.getMaxItemUseDuration(p_77659_1_));
|
||||
}
|
||||
|
||||
return p_77659_1_;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUsingTick(ItemStack stack, EntityPlayer player, int count)
|
||||
{
|
||||
World world = player.worldObj;
|
||||
|
||||
boolean flag = player.capabilities.isCreativeMode
|
||||
|| EnchantmentHelper.getEnchantmentLevel(Enchantment.infinity.effectId, stack) > 0;
|
||||
if ((player.capabilities.isCreativeMode || player.inventory.hasItem(ModItems.gun_defabricator_ammo))
|
||||
&& count % 2 == 0) {
|
||||
EntityBullet entitybullet = new EntityBullet(world, player, 3.0F, 40, 120, false, "tauDay");
|
||||
entitybullet.setDamage(40 + rand.nextInt(120 - 40));
|
||||
|
||||
//world.playSoundAtEntity(player, "random.explode", 1.0F, 1.5F + (rand.nextFloat() / 4));
|
||||
world.playSoundAtEntity(player, "hbm:weapon.defabShoot", 1.0F, 0.9F + (rand.nextFloat() * 0.2F));
|
||||
if(count == this.getMaxItemUseDuration(stack))
|
||||
world.playSoundAtEntity(player, "hbm:weapon.defabSpinup", 1.0F, 1.0F);
|
||||
|
||||
if(count % 20 == 0 && !flag)
|
||||
player.inventory.consumeInventoryItem(ModItems.gun_defabricator_ammo);
|
||||
|
||||
if (!world.isRemote) {
|
||||
world.spawnEntityInWorld(entitybullet);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemEnchantability() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool) {
|
||||
|
||||
if(MainRegistry.polaroidID == 11)
|
||||
list.add("Did you set your alarm for volcano day?");
|
||||
else
|
||||
list.add("BAD WOLF");
|
||||
list.add("");
|
||||
list.add("Ammo: Defabricator Energy Cell");
|
||||
list.add("Damage: 40 - 120");
|
||||
list.add("");
|
||||
list.add("[LEGENDARY WEAPON]");
|
||||
}
|
||||
|
||||
@Override
|
||||
public Multimap getItemAttributeModifiers() {
|
||||
Multimap multimap = super.getItemAttributeModifiers();
|
||||
multimap.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(),
|
||||
new AttributeModifier(field_111210_e, "Weapon modifier", 6.5, 0));
|
||||
return multimap;
|
||||
}
|
||||
}
|
||||
@ -1,105 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.google.common.collect.Multimap;
|
||||
import com.hbm.entity.projectile.EntityBullet;
|
||||
import com.hbm.items.ModItems;
|
||||
|
||||
import net.minecraft.enchantment.Enchantment;
|
||||
import net.minecraft.enchantment.EnchantmentHelper;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.attributes.AttributeModifier;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.EnumAction;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.event.entity.player.ArrowNockEvent;
|
||||
|
||||
public class GunEuthanasia extends Item {
|
||||
|
||||
Random rand = new Random();
|
||||
|
||||
public GunEuthanasia()
|
||||
{
|
||||
this.maxStackSize = 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EnumAction getItemUseAction(ItemStack par1ItemStack) {
|
||||
return EnumAction.bow;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMaxItemUseDuration(ItemStack p_77626_1_) {
|
||||
return 72000;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onItemRightClick(ItemStack p_77659_1_, World p_77659_2_, EntityPlayer p_77659_3_) {
|
||||
new ArrowNockEvent(p_77659_3_, p_77659_1_);
|
||||
{
|
||||
p_77659_3_.setItemInUse(p_77659_1_, this.getMaxItemUseDuration(p_77659_1_));
|
||||
}
|
||||
|
||||
return p_77659_1_;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUsingTick(ItemStack stack, EntityPlayer player, int count)
|
||||
{
|
||||
World world = player.worldObj;
|
||||
|
||||
boolean flag = player.capabilities.isCreativeMode
|
||||
|| EnchantmentHelper.getEnchantmentLevel(Enchantment.infinity.effectId, stack) > 0;
|
||||
if ((player.capabilities.isCreativeMode || player.inventory.hasItem(ModItems.gun_euthanasia_ammo))
|
||||
&& count % 8 == 0) {
|
||||
|
||||
int deadly = rand.nextInt(5);
|
||||
|
||||
EntityBullet entityarrow = new EntityBullet(world, player, 3.0F, 2, 8, deadly == 0, false);
|
||||
entityarrow.setDamage(1 + rand.nextInt(3));
|
||||
entityarrow.antidote = true;
|
||||
|
||||
//world.playSoundAtEntity(player, "random.explode", 1.0F, 1.5F + (rand.nextFloat() / 4));
|
||||
world.playSoundAtEntity(player, "hbm:weapon.rifleShoot", 1.0F, 0.8F + (rand.nextFloat() * 0.4F));
|
||||
|
||||
if (flag) {
|
||||
entityarrow.canBePickedUp = 2;
|
||||
} else {
|
||||
player.inventory.consumeInventoryItem(ModItems.gun_euthanasia_ammo);
|
||||
}
|
||||
|
||||
if (!world.isRemote) {
|
||||
world.spawnEntityInWorld(entityarrow);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemEnchantability() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool) {
|
||||
|
||||
list.add("Say hello to my little syringe gun!");
|
||||
list.add("");
|
||||
list.add("Ammo: Syringe");
|
||||
list.add("Damage: 1 - 4");
|
||||
list.add("Syringes have a 20% chance to instakill the enemy.");
|
||||
list.add("");
|
||||
list.add("[LEGENDARY WEAPON]");
|
||||
}
|
||||
|
||||
@Override
|
||||
public Multimap getItemAttributeModifiers() {
|
||||
Multimap multimap = super.getItemAttributeModifiers();
|
||||
multimap.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(),
|
||||
new AttributeModifier(field_111210_e, "Weapon modifier", 3, 0));
|
||||
return multimap;
|
||||
}
|
||||
}
|
||||
@ -1,135 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import com.hbm.entity.projectile.EntityBulletBaseNT;
|
||||
import com.hbm.handler.BulletConfigSyncingUtil;
|
||||
import com.hbm.interfaces.IHoldableWeapon;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.weapon.sedna.Crosshair;
|
||||
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class GunFolly extends Item implements IHoldableWeapon {
|
||||
|
||||
@Override
|
||||
public Crosshair getCrosshair() {
|
||||
return Crosshair.L_SPLIT;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player) {
|
||||
|
||||
int state = getState(stack);
|
||||
|
||||
if(state == 0) {
|
||||
|
||||
world.playSoundAtEntity(player, "hbm:weapon.follyOpen", 1.0F, 1.0F);
|
||||
setState(stack, 1);
|
||||
|
||||
} else if(state == 1) {
|
||||
|
||||
if(player.inventory.hasItem(ModItems.ammo_folly)) {
|
||||
|
||||
world.playSoundAtEntity(player, "hbm:weapon.follyReload", 1.0F, 1.0F);
|
||||
player.inventory.consumeInventoryItem(ModItems.ammo_folly);
|
||||
setState(stack, 2);
|
||||
} else {
|
||||
|
||||
world.playSoundAtEntity(player, "hbm:weapon.follyClose", 1.0F, 1.0F);
|
||||
setState(stack, 0);
|
||||
}
|
||||
|
||||
} else if(state == 2) {
|
||||
|
||||
world.playSoundAtEntity(player, "hbm:weapon.follyClose", 1.0F, 1.0F);
|
||||
setState(stack, 3);
|
||||
setTimer(stack, 100);
|
||||
} else if(state == 3) {
|
||||
|
||||
if(getTimer(stack) == 0) {
|
||||
|
||||
setState(stack, 0);
|
||||
world.playSoundAtEntity(player, "hbm:weapon.follyFire", 1.0F, 1.0F);
|
||||
|
||||
double mult = 1.75D;
|
||||
|
||||
player.motionX -= player.getLookVec().xCoord * mult;
|
||||
player.motionY -= player.getLookVec().yCoord * mult;
|
||||
player.motionZ -= player.getLookVec().zCoord * mult;
|
||||
|
||||
if (!world.isRemote) {
|
||||
EntityBulletBaseNT bullet = new EntityBulletBaseNT(world, BulletConfigSyncingUtil.TEST_CONFIG, player);
|
||||
world.spawnEntityInWorld(bullet);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return stack;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUpdate(ItemStack stack, World world, Entity entity, int slot, boolean isCurrentItem) {
|
||||
|
||||
if(getState(stack) == 3) {
|
||||
|
||||
if(isCurrentItem) {
|
||||
int timer = getTimer(stack);
|
||||
|
||||
if(timer > 0) {
|
||||
timer--;
|
||||
|
||||
if(timer % 20 == 0 && timer != 0)
|
||||
world.playSoundAtEntity(entity, "hbm:weapon.follyBuzzer", 1.0F, 1.0F);
|
||||
|
||||
if(timer == 0)
|
||||
world.playSoundAtEntity(entity, "hbm:weapon.follyAquired", 1.0F, 1.0F);
|
||||
|
||||
setTimer(stack, timer);
|
||||
}
|
||||
} else {
|
||||
setTimer(stack, 100);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//0: closed, empty,
|
||||
//1: open, empty
|
||||
//2: open, full
|
||||
//3: closed, full
|
||||
public static void setState(ItemStack stack, int i) {
|
||||
writeNBT(stack, "state", i);
|
||||
}
|
||||
|
||||
public static int getState(ItemStack stack) {
|
||||
return readNBT(stack, "state");
|
||||
}
|
||||
|
||||
public static void setTimer(ItemStack stack, int i) {
|
||||
writeNBT(stack, "timer", i);
|
||||
}
|
||||
|
||||
public static int getTimer(ItemStack stack) {
|
||||
return readNBT(stack, "timer");
|
||||
}
|
||||
|
||||
private static void writeNBT(ItemStack stack, String key, int value) {
|
||||
|
||||
if(!stack.hasTagCompound())
|
||||
stack.stackTagCompound = new NBTTagCompound();
|
||||
|
||||
stack.stackTagCompound.setInteger(key, value);
|
||||
}
|
||||
|
||||
private static int readNBT(ItemStack stack, String key) {
|
||||
|
||||
if(!stack.hasTagCompound())
|
||||
return 0;
|
||||
|
||||
return stack.stackTagCompound.getInteger(key);
|
||||
}
|
||||
|
||||
}
|
||||
@ -1,71 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.google.common.collect.Multimap;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.attributes.AttributeModifier;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.EnumAction;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.event.entity.player.ArrowNockEvent;
|
||||
|
||||
@Deprecated
|
||||
public class GunHP extends Item {
|
||||
|
||||
Random rand = new Random();
|
||||
|
||||
public GunHP() {
|
||||
this.maxStackSize = 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EnumAction getItemUseAction(ItemStack par1ItemStack) {
|
||||
return EnumAction.bow;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMaxItemUseDuration(ItemStack p_77626_1_) {
|
||||
return 72000;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onItemRightClick(ItemStack p_77659_1_, World p_77659_2_, EntityPlayer p_77659_3_) {
|
||||
new ArrowNockEvent(p_77659_3_, p_77659_1_);
|
||||
{
|
||||
p_77659_3_.setItemInUse(p_77659_1_, this.getMaxItemUseDuration(p_77659_1_));
|
||||
}
|
||||
|
||||
return p_77659_1_;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUsingTick(ItemStack stack, EntityPlayer player, int count) { }
|
||||
|
||||
@Override
|
||||
public int getItemEnchantability() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool) {
|
||||
|
||||
list.add("Rrrrt - rrrrt - rrrrt, weeee!");
|
||||
list.add("");
|
||||
list.add("Ammo: Ink Cartridge");
|
||||
list.add("Damage: 25 - 45");
|
||||
list.add("");
|
||||
list.add("[LEGENDARY WEAPON]");
|
||||
}
|
||||
|
||||
@Override
|
||||
public Multimap getItemAttributeModifiers() {
|
||||
Multimap multimap = super.getItemAttributeModifiers();
|
||||
multimap.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(),
|
||||
new AttributeModifier(field_111210_e, "Weapon modifier", 4, 0));
|
||||
return multimap;
|
||||
}
|
||||
}
|
||||
@ -1,150 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.google.common.collect.Multimap;
|
||||
import com.hbm.entity.projectile.EntityBullet;
|
||||
import com.hbm.items.ModItems;
|
||||
|
||||
import net.minecraft.enchantment.Enchantment;
|
||||
import net.minecraft.enchantment.EnchantmentHelper;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.attributes.AttributeModifier;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.EnumAction;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
import net.minecraftforge.event.entity.player.ArrowLooseEvent;
|
||||
import net.minecraftforge.event.entity.player.ArrowNockEvent;
|
||||
|
||||
public class GunJack extends Item {
|
||||
Random rand = new Random();
|
||||
|
||||
public int dmgMin = 12;
|
||||
public int dmgMax = 24;
|
||||
|
||||
public GunJack() {
|
||||
|
||||
this.maxStackSize = 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* called when the player releases the use item button. Args: itemstack,
|
||||
* world, entityplayer, itemInUseCount
|
||||
*/
|
||||
@Override
|
||||
public void onPlayerStoppedUsing(ItemStack p_77615_1_, World p_77615_2_, EntityPlayer p_77615_3_, int p_77615_4_) {
|
||||
int j = this.getMaxItemUseDuration(p_77615_1_) - p_77615_4_;
|
||||
|
||||
ArrowLooseEvent event = new ArrowLooseEvent(p_77615_3_, p_77615_1_, j);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
j = event.charge;
|
||||
|
||||
boolean flag = p_77615_3_.capabilities.isCreativeMode
|
||||
|| EnchantmentHelper.getEnchantmentLevel(Enchantment.infinity.effectId, p_77615_1_) > 0;
|
||||
|
||||
if (flag || p_77615_3_.inventory.hasItem(ModItems.gun_jack_ammo)) {
|
||||
float f = j / 20.0F;
|
||||
f = (f * f + f * 2.0F) / 3.0F;
|
||||
|
||||
if (j < 10.0D) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (j > 10.0F) {
|
||||
f = 10.0F;
|
||||
}
|
||||
|
||||
p_77615_1_.damageItem(1, p_77615_3_);
|
||||
|
||||
p_77615_2_.playSoundAtEntity(p_77615_3_, "hbm:weapon.shotgunShoot", 1.0F, 1.0F);
|
||||
|
||||
if (flag) { } else {
|
||||
p_77615_3_.inventory.consumeInventoryItem(ModItems.gun_jack_ammo);
|
||||
}
|
||||
|
||||
int k = rand.nextInt(25) + 24;
|
||||
|
||||
for(int i = 0; i < k; i++) {
|
||||
|
||||
EntityBullet entityarrow1 = new EntityBullet(p_77615_2_, p_77615_3_, 3.0F);
|
||||
entityarrow1.setDamage(dmgMin + rand.nextInt(dmgMax - dmgMin));
|
||||
|
||||
if(!p_77615_2_.isRemote)
|
||||
p_77615_2_.spawnEntityInWorld(entityarrow1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onEaten(ItemStack p_77654_1_, World p_77654_2_, EntityPlayer p_77654_3_) {
|
||||
return p_77654_1_;
|
||||
}
|
||||
|
||||
/**
|
||||
* How long it takes to use or consume an item
|
||||
*/
|
||||
@Override
|
||||
public int getMaxItemUseDuration(ItemStack p_77626_1_) {
|
||||
return 72000;
|
||||
}
|
||||
|
||||
/**
|
||||
* returns the action that specifies what animation to play when the items
|
||||
* is being used
|
||||
*/
|
||||
@Override
|
||||
public EnumAction getItemUseAction(ItemStack p_77661_1_) {
|
||||
return EnumAction.bow;
|
||||
}
|
||||
|
||||
/**
|
||||
* 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_) {
|
||||
ArrowNockEvent event = new ArrowNockEvent(p_77659_3_, p_77659_1_);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
|
||||
if (p_77659_3_.capabilities.isCreativeMode || p_77659_3_.inventory.hasItem(ModItems.gun_jack_ammo)) {
|
||||
p_77659_3_.setItemInUse(p_77659_1_, this.getMaxItemUseDuration(p_77659_1_));
|
||||
}
|
||||
|
||||
return p_77659_1_;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the enchantability factor of the item, most of the time is based
|
||||
* on material.
|
||||
*/
|
||||
@Override
|
||||
public int getItemEnchantability() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool) {
|
||||
|
||||
list.add("One barrel? Boring.");
|
||||
list.add("Two barrels? Nah.");
|
||||
list.add("Four barrels? Heck yes!");
|
||||
list.add("");
|
||||
list.add("Ammo: Quadruple Shotgun Shells");
|
||||
list.add("Damage: 12 - 24");
|
||||
list.add("Projectiles: 24 - 48");
|
||||
list.add("");
|
||||
list.add("[LEGENDARY WEAPON]");
|
||||
}
|
||||
|
||||
@Override
|
||||
public Multimap getItemAttributeModifiers() {
|
||||
Multimap multimap = super.getItemAttributeModifiers();
|
||||
multimap.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(),
|
||||
new AttributeModifier(field_111210_e, "Weapon modifier", 4.5, 0));
|
||||
return multimap;
|
||||
}
|
||||
}
|
||||
@ -1,232 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.google.common.collect.Multimap;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.lib.ModDamageSource;
|
||||
import com.hbm.main.MainRegistry;
|
||||
|
||||
import net.minecraft.enchantment.Enchantment;
|
||||
import net.minecraft.enchantment.EnchantmentHelper;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.attributes.AttributeModifier;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.EnumAction;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.StatCollector;
|
||||
import net.minecraft.util.Vec3;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
import net.minecraftforge.event.entity.player.ArrowLooseEvent;
|
||||
import net.minecraftforge.event.entity.player.ArrowNockEvent;
|
||||
|
||||
public class GunLeverActionS extends Item {
|
||||
|
||||
Random rand = new Random();
|
||||
|
||||
public int dmgMin = 8;
|
||||
public int dmgMax = 16;
|
||||
|
||||
public GunLeverActionS() {
|
||||
|
||||
this.maxStackSize = 1;
|
||||
|
||||
this.setMaxDamage(500);
|
||||
}
|
||||
|
||||
/**
|
||||
* called when the player releases the use item button. Args: itemstack,
|
||||
* world, entityplayer, itemInUseCount
|
||||
*/
|
||||
@Override
|
||||
public void onPlayerStoppedUsing(ItemStack p_77615_1_, World p_77615_2_, EntityPlayer p_77615_3_, int p_77615_4_) {
|
||||
int j = this.getMaxItemUseDuration(p_77615_1_) - p_77615_4_;
|
||||
|
||||
ArrowLooseEvent event = new ArrowLooseEvent(p_77615_3_, p_77615_1_, j);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
j = event.charge;
|
||||
|
||||
boolean flag = p_77615_3_.capabilities.isCreativeMode
|
||||
|| EnchantmentHelper.getEnchantmentLevel(Enchantment.infinity.effectId, p_77615_1_) > 0;
|
||||
|
||||
if (flag || p_77615_3_.inventory.hasItem(ModItems.ammo_20gauge)) {
|
||||
float f = j / 20.0F;
|
||||
f = (f * f + f * 2.0F) / 3.0F;
|
||||
|
||||
if (j < 10.0D) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (j > 10.0F) {
|
||||
f = 10.0F;
|
||||
}
|
||||
|
||||
Vec3 vec = p_77615_3_.getLookVec();
|
||||
vec.xCoord *= -1;
|
||||
vec.yCoord *= -1;
|
||||
vec.zCoord *= -1;
|
||||
vec.normalize();
|
||||
|
||||
p_77615_3_.motionX += vec.xCoord * 0.75;
|
||||
p_77615_3_.motionY += vec.yCoord * 0.75;
|
||||
p_77615_3_.motionZ += vec.zCoord * 0.75;
|
||||
|
||||
p_77615_3_.inventory.consumeInventoryItem(ModItems.ammo_20gauge);
|
||||
|
||||
p_77615_1_.damageItem(1, p_77615_3_);
|
||||
|
||||
p_77615_3_.attackEntityFrom(ModDamageSource.suicide, 10000);
|
||||
if(!p_77615_3_.capabilities.isCreativeMode)
|
||||
p_77615_3_.setHealth(0.0F);
|
||||
|
||||
p_77615_2_.playSoundAtEntity(p_77615_3_, "hbm:weapon.revolverShootAlt", 5.0F, 0.75F);
|
||||
|
||||
setAnim(p_77615_1_, 1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void onUpdate(ItemStack stack, World world, Entity entity, int i, boolean b) {
|
||||
int j = getAnim(stack);
|
||||
|
||||
if(j > 0) {
|
||||
if(j < 30)
|
||||
setAnim(stack, j + 1);
|
||||
else
|
||||
setAnim(stack, 0);
|
||||
|
||||
if(j == 15)
|
||||
world.playSoundAtEntity(entity, "hbm:weapon.leverActionReload", 2F, 0.85F);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onEaten(ItemStack p_77654_1_, World p_77654_2_, EntityPlayer p_77654_3_) {
|
||||
return p_77654_1_;
|
||||
}
|
||||
|
||||
/**
|
||||
* How long it takes to use or consume an item
|
||||
*/
|
||||
@Override
|
||||
public int getMaxItemUseDuration(ItemStack p_77626_1_) {
|
||||
return 72000;
|
||||
}
|
||||
|
||||
/**
|
||||
* returns the action that specifies what animation to play when the items
|
||||
* is being used
|
||||
*/
|
||||
@Override
|
||||
public EnumAction getItemUseAction(ItemStack p_77661_1_) {
|
||||
return EnumAction.bow;
|
||||
}
|
||||
|
||||
/**
|
||||
* 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_) {
|
||||
ArrowNockEvent event = new ArrowNockEvent(p_77659_3_, p_77659_1_);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
|
||||
if(this.getAnim(p_77659_1_) == 0)
|
||||
p_77659_3_.setItemInUse(p_77659_1_, this.getMaxItemUseDuration(p_77659_1_));
|
||||
|
||||
return p_77659_1_;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the enchantability factor of the item, most of the time is based
|
||||
* on material.
|
||||
*/
|
||||
@Override
|
||||
public int getItemEnchantability() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
public String getItemStackDisplayName(ItemStack stack)
|
||||
{
|
||||
if(MainRegistry.polaroidID == 11)
|
||||
return ("" + StatCollector.translateToLocal(this.getUnlocalizedName() + "_2.name")).trim();
|
||||
else
|
||||
return ("" + StatCollector.translateToLocal(this.getUnlocalizedName() + ".name")).trim();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool) {
|
||||
|
||||
if(MainRegistry.polaroidID == 11)
|
||||
list.add("Vee guilt-tripped me into this.");
|
||||
else
|
||||
list.add("I hate your guts, Vee.");
|
||||
list.add("");
|
||||
list.add("Ammo: 12x74 Buckshot");
|
||||
list.add("Damage: Infinite");
|
||||
list.add("");
|
||||
list.add("[LEGENDARY WEAPON]");
|
||||
}
|
||||
|
||||
@Override
|
||||
public Multimap getItemAttributeModifiers() {
|
||||
Multimap multimap = super.getItemAttributeModifiers();
|
||||
multimap.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(),
|
||||
new AttributeModifier(field_111210_e, "Weapon modifier", 3.5, 0));
|
||||
return multimap;
|
||||
}
|
||||
|
||||
private static int getAnim(ItemStack stack) {
|
||||
if(stack.stackTagCompound == null) {
|
||||
stack.stackTagCompound = new NBTTagCompound();
|
||||
return 0;
|
||||
}
|
||||
|
||||
return stack.stackTagCompound.getInteger("animation");
|
||||
|
||||
}
|
||||
|
||||
private static void setAnim(ItemStack stack, int i) {
|
||||
if(stack.stackTagCompound == null) {
|
||||
stack.stackTagCompound = new NBTTagCompound();
|
||||
}
|
||||
|
||||
stack.stackTagCompound.setInteger("animation", i);
|
||||
|
||||
}
|
||||
|
||||
public static float getRotationFromAnim(ItemStack stack) {
|
||||
float rad = 0.0174533F;
|
||||
rad *= 7.5F;
|
||||
int i = getAnim(stack);
|
||||
|
||||
if(i < 10)
|
||||
return 0;
|
||||
i -= 10;
|
||||
|
||||
if(i < 10)
|
||||
return rad * i;
|
||||
else
|
||||
return (rad * 10) - (rad * (i - 10));
|
||||
}
|
||||
|
||||
public static float getOffsetFromAnim(ItemStack stack) {
|
||||
float i = getAnim(stack);
|
||||
|
||||
if(i < 10)
|
||||
return 0;
|
||||
i -= 10;
|
||||
|
||||
if(i < 10)
|
||||
return i / 10;
|
||||
else
|
||||
return 2 - (i / 10);
|
||||
}
|
||||
}
|
||||
@ -1,141 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.google.common.collect.Multimap;
|
||||
import com.hbm.entity.projectile.EntitySparkBeam;
|
||||
import com.hbm.items.ModItems;
|
||||
|
||||
import net.minecraft.enchantment.Enchantment;
|
||||
import net.minecraft.enchantment.EnchantmentHelper;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.attributes.AttributeModifier;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.EnumAction;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
import net.minecraftforge.event.entity.player.ArrowLooseEvent;
|
||||
import net.minecraftforge.event.entity.player.ArrowNockEvent;
|
||||
|
||||
public class GunSpark extends Item {
|
||||
Random rand = new Random();
|
||||
|
||||
public int dmgMin = 12;
|
||||
public int dmgMax = 24;
|
||||
|
||||
public GunSpark() {
|
||||
|
||||
this.maxStackSize = 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* called when the player releases the use item button. Args: itemstack,
|
||||
* world, entityplayer, itemInUseCount
|
||||
*/
|
||||
@Override
|
||||
public void onPlayerStoppedUsing(ItemStack p_77615_1_, World p_77615_2_, EntityPlayer p_77615_3_, int p_77615_4_) {
|
||||
int j = this.getMaxItemUseDuration(p_77615_1_) - p_77615_4_;
|
||||
|
||||
ArrowLooseEvent event = new ArrowLooseEvent(p_77615_3_, p_77615_1_, j);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
j = event.charge;
|
||||
|
||||
boolean flag = p_77615_3_.capabilities.isCreativeMode
|
||||
|| EnchantmentHelper.getEnchantmentLevel(Enchantment.infinity.effectId, p_77615_1_) > 0;
|
||||
|
||||
if (flag || p_77615_3_.inventory.hasItem(ModItems.gun_spark_ammo)) {
|
||||
float f = j / 20.0F;
|
||||
f = (f * f + f * 2.0F) / 3.0F;
|
||||
|
||||
if (j < 10.0D) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (j > 10.0F) {
|
||||
f = 10.0F;
|
||||
}
|
||||
|
||||
p_77615_1_.damageItem(1, p_77615_3_);
|
||||
|
||||
p_77615_2_.playSoundAtEntity(p_77615_3_, "hbm:weapon.sparkShoot", 1.0F, 1.0F);
|
||||
|
||||
if (flag) { } else {
|
||||
p_77615_3_.inventory.consumeInventoryItem(ModItems.gun_spark_ammo);
|
||||
}
|
||||
|
||||
EntitySparkBeam beam = new EntitySparkBeam(p_77615_2_, p_77615_3_, 3F);
|
||||
beam.setDamage(dmgMin + rand.nextInt(dmgMax - dmgMin));
|
||||
|
||||
if(!p_77615_2_.isRemote)
|
||||
p_77615_2_.spawnEntityInWorld(beam);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onEaten(ItemStack p_77654_1_, World p_77654_2_, EntityPlayer p_77654_3_) {
|
||||
return p_77654_1_;
|
||||
}
|
||||
|
||||
/**
|
||||
* How long it takes to use or consume an item
|
||||
*/
|
||||
@Override
|
||||
public int getMaxItemUseDuration(ItemStack p_77626_1_) {
|
||||
return 72000;
|
||||
}
|
||||
|
||||
/**
|
||||
* returns the action that specifies what animation to play when the items
|
||||
* is being used
|
||||
*/
|
||||
@Override
|
||||
public EnumAction getItemUseAction(ItemStack p_77661_1_) {
|
||||
return EnumAction.bow;
|
||||
}
|
||||
|
||||
/**
|
||||
* 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_) {
|
||||
ArrowNockEvent event = new ArrowNockEvent(p_77659_3_, p_77659_1_);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
|
||||
p_77659_3_.setItemInUse(p_77659_1_, this.getMaxItemUseDuration(p_77659_1_));
|
||||
|
||||
return p_77659_1_;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the enchantability factor of the item, most of the time is based
|
||||
* on material.
|
||||
*/
|
||||
@Override
|
||||
public int getItemEnchantability() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool) {
|
||||
|
||||
list.add("'magic does not compute'");
|
||||
list.add("'aeiou'");
|
||||
list.add("");
|
||||
list.add("Ammo: Electromagnetic Cartridge");
|
||||
list.add("Projectiles explode on impact.");
|
||||
list.add("");
|
||||
list.add("[LEGENDARY WEAPON]");
|
||||
}
|
||||
|
||||
@Override
|
||||
public Multimap getItemAttributeModifiers() {
|
||||
Multimap multimap = super.getItemAttributeModifiers();
|
||||
multimap.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(),
|
||||
new AttributeModifier(field_111210_e, "Weapon modifier", 4.5, 0));
|
||||
return multimap;
|
||||
}
|
||||
}
|
||||
@ -1,158 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import com.google.common.collect.Multimap;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.lib.ModDamageSource;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.enchantment.Enchantment;
|
||||
import net.minecraft.enchantment.EnchantmentHelper;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.ai.attributes.AttributeModifier;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.EnumAction;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
import net.minecraftforge.event.entity.player.ArrowLooseEvent;
|
||||
import net.minecraftforge.event.entity.player.ArrowNockEvent;
|
||||
|
||||
public class GunSuicide extends Item {
|
||||
|
||||
public static final String[] bowPullIconNameArray = new String[] {"pulling_0", "pulling_1", "pulling_2"};
|
||||
@SideOnly(Side.CLIENT)
|
||||
private IIcon[] iconArray;
|
||||
private Item ammo;
|
||||
Random rand = new Random();
|
||||
|
||||
public GunSuicide()
|
||||
{
|
||||
this.maxStackSize = 1;
|
||||
//if(this == ModItems.gun_revolver)
|
||||
{
|
||||
this.setMaxDamage(500);
|
||||
}
|
||||
|
||||
this.ammo = ModItems.ammo_357;
|
||||
}
|
||||
|
||||
/**
|
||||
* called when the player releases the use item button. Args: itemstack, world, entityplayer, itemInUseCount
|
||||
*/
|
||||
@Override
|
||||
public void onPlayerStoppedUsing(ItemStack p_77615_1_, World p_77615_2_, EntityPlayer p_77615_3_, int p_77615_4_)
|
||||
{
|
||||
int j = this.getMaxItemUseDuration(p_77615_1_) - p_77615_4_;
|
||||
|
||||
ArrowLooseEvent event = new ArrowLooseEvent(p_77615_3_, p_77615_1_, j);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
j = event.charge;
|
||||
|
||||
boolean flag = p_77615_3_.capabilities.isCreativeMode || EnchantmentHelper.getEnchantmentLevel(Enchantment.infinity.effectId, p_77615_1_) > 0;
|
||||
|
||||
|
||||
if (flag || p_77615_3_.inventory.hasItem(ammo))
|
||||
{
|
||||
float f = j / 20.0F;
|
||||
f = (f * f + f * 2.0F) / 3.0F;
|
||||
|
||||
if (j < 10.0D)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (j > 10.0F)
|
||||
{
|
||||
f = 10.0F;
|
||||
}
|
||||
|
||||
p_77615_1_.damageItem(1, p_77615_3_);
|
||||
p_77615_2_.playSoundAtEntity(p_77615_3_, "hbm:weapon.revolverShoot", 1.0F, 1.0F);
|
||||
|
||||
if (flag)
|
||||
{ }
|
||||
else
|
||||
{
|
||||
p_77615_3_.inventory.consumeInventoryItem(ammo);
|
||||
}
|
||||
|
||||
if (!p_77615_2_.isRemote)
|
||||
{
|
||||
p_77615_3_.attackEntityFrom(ModDamageSource.suicide, 10000);
|
||||
if(!p_77615_3_.capabilities.isCreativeMode)
|
||||
p_77615_3_.setHealth(0.0F);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onEaten(ItemStack p_77654_1_, World p_77654_2_, EntityPlayer p_77654_3_)
|
||||
{
|
||||
return p_77654_1_;
|
||||
}
|
||||
|
||||
/**
|
||||
* How long it takes to use or consume an item
|
||||
*/
|
||||
@Override
|
||||
public int getMaxItemUseDuration(ItemStack p_77626_1_)
|
||||
{
|
||||
return 72000;
|
||||
}
|
||||
|
||||
/**
|
||||
* returns the action that specifies what animation to play when the items is being used
|
||||
*/
|
||||
@Override
|
||||
public EnumAction getItemUseAction(ItemStack p_77661_1_)
|
||||
{
|
||||
return EnumAction.bow;
|
||||
}
|
||||
|
||||
/**
|
||||
* 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_)
|
||||
{
|
||||
ArrowNockEvent event = new ArrowNockEvent(p_77659_3_, p_77659_1_);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
|
||||
p_77659_3_.setItemInUse(p_77659_1_, this.getMaxItemUseDuration(p_77659_1_));
|
||||
|
||||
return p_77659_1_;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the enchantability factor of the item, most of the time is based on material.
|
||||
*/
|
||||
@Override
|
||||
public int getItemEnchantability()
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool) {
|
||||
|
||||
list.add("I've seen things...");
|
||||
list.add("...I shouldn't have seen.");
|
||||
list.add("");
|
||||
list.add("Ammo: Lead Bullets");
|
||||
list.add("Damage: Infinite");
|
||||
}
|
||||
|
||||
@Override
|
||||
public Multimap getItemAttributeModifiers() {
|
||||
Multimap multimap = super.getItemAttributeModifiers();
|
||||
multimap.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(),
|
||||
new AttributeModifier(field_111210_e, "Weapon modifier", 2.5, 0));
|
||||
return multimap;
|
||||
}
|
||||
}
|
||||
@ -1,40 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import com.hbm.handler.GunConfiguration;
|
||||
import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class ItemCoilgun extends ItemGunBase {
|
||||
|
||||
public ItemCoilgun(GunConfiguration config) {
|
||||
super(config);
|
||||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public BusAnimation getAnimation(ItemStack stack, AnimType type) {
|
||||
|
||||
if(type == AnimType.CYCLE) {
|
||||
return new BusAnimation()
|
||||
.addBus("RECOIL", new BusAnimationSequence()
|
||||
.addPos(1, 0, 0, 100)
|
||||
.addPos(0, 0, 0, 200));
|
||||
}
|
||||
|
||||
if(type == AnimType.RELOAD) {
|
||||
return new BusAnimation()
|
||||
.addBus("RELOAD", new BusAnimationSequence()
|
||||
.addPos(1, 0, 0, 250)
|
||||
.addPos(1, 0, 0, 500)
|
||||
.addPos(0, 0, 0, 250));
|
||||
}
|
||||
|
||||
GunConfiguration config = ((ItemGunBase) stack.getItem()).mainConfig;
|
||||
return config.animations.get(type);
|
||||
}
|
||||
}
|
||||
@ -1,125 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import com.hbm.handler.GunConfiguration;
|
||||
import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.Vec3;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemGunBio extends ItemGunBase {
|
||||
|
||||
public ItemGunBio(GunConfiguration config) {
|
||||
super(config);
|
||||
}
|
||||
|
||||
public static long lastShot;
|
||||
public static List<double[]> smokeNodes = new ArrayList();
|
||||
|
||||
@Override
|
||||
public void startActionClient(ItemStack stack, World world, EntityPlayer player, boolean main) { }
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
protected void updateClient(ItemStack stack, World world, EntityPlayer entity, int slot, boolean isCurrentItem) {
|
||||
super.updateClient(stack, world, entity, slot, isCurrentItem);
|
||||
|
||||
boolean smoking = lastShot + 2000 > System.currentTimeMillis();
|
||||
|
||||
if(!smoking && !smokeNodes.isEmpty()) {
|
||||
smokeNodes.clear();
|
||||
}
|
||||
|
||||
if(smoking) {
|
||||
|
||||
Vec3 prev = Vec3.createVectorHelper(-entity.motionX, -entity.motionY, -entity.motionZ);
|
||||
prev.rotateAroundY((float) (entity.rotationYaw * Math.PI / 180D));
|
||||
double accel = 15D;
|
||||
double side = (entity.rotationYaw - entity.prevRotationYawHead) * 0.1D;
|
||||
double waggle = 0.025D;
|
||||
|
||||
for(double[] node : smokeNodes) {
|
||||
node[0] += prev.xCoord * accel + world.rand.nextGaussian() * waggle + side;
|
||||
node[1] += prev.yCoord + 1.5D;
|
||||
node[2] += prev.zCoord * accel + world.rand.nextGaussian() * waggle;
|
||||
}
|
||||
|
||||
double alpha = (System.currentTimeMillis() - ItemGunBio.lastShot) / 2000D;
|
||||
alpha = (1 - alpha) * 0.5D;
|
||||
|
||||
if(this.getIsReloading(stack)) alpha = 0;
|
||||
|
||||
smokeNodes.add(new double[] {0, 0, 0, alpha});
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public BusAnimation getAnimation(ItemStack stack, AnimType type) {
|
||||
|
||||
if(type == AnimType.CYCLE) {
|
||||
lastShot = System.currentTimeMillis();
|
||||
return new BusAnimation()
|
||||
.addBus("RECOIL", new BusAnimationSequence()
|
||||
.addPos(0, 0, 0, 50)
|
||||
.addPos(0, 0, -3, 50)
|
||||
.addPos(0, 0, 0, 250)
|
||||
)
|
||||
.addBus("HAMMER", new BusAnimationSequence()
|
||||
.addPos(0, 0, 1, 50)
|
||||
.addPos(0, 0, 1, 300)
|
||||
.addPos(0, 0, 0, 200)
|
||||
)
|
||||
.addBus("DRUM", new BusAnimationSequence()
|
||||
.addPos(0, 0, 1, 50)
|
||||
);
|
||||
}
|
||||
|
||||
if(type == AnimType.RELOAD) {
|
||||
return new BusAnimation()
|
||||
.addBus("LATCH", new BusAnimationSequence()
|
||||
.addPos(0, 0, 90, 300)
|
||||
.addPos(0, 0, 90, 2000)
|
||||
.addPos(0, 0, 0, 150)
|
||||
)
|
||||
.addBus("FRONT", new BusAnimationSequence()
|
||||
.addPos(0, 0, 0, 200)
|
||||
.addPos(0, 0, 45, 150)
|
||||
.addPos(0, 0, 45, 2000)
|
||||
.addPos(0, 0, 0, 75)
|
||||
)
|
||||
.addBus("RELOAD_ROT", new BusAnimationSequence()
|
||||
.addPos(0, 0, 0, 300)
|
||||
.addPos(60, 0, 0, 500)
|
||||
.addPos(60, 0, 0, 500)
|
||||
.addPos(0, -90, -90, 0)
|
||||
.addPos(0, -90, -90, 600)
|
||||
.addPos(0, 0, 0, 300)
|
||||
.addPos(0, 0, 0, 100)
|
||||
.addPos(-45, 0, 0, 50)
|
||||
.addPos(-45, 0, 0, 100)
|
||||
.addPos(0, 0, 0, 300)
|
||||
)
|
||||
.addBus("RELOAD_MOVE", new BusAnimationSequence()
|
||||
.addPos(0, 0, 0, 300)
|
||||
.addPos(0, -15, 0, 1000)
|
||||
.addPos(0, 0, 0, 450)
|
||||
)
|
||||
.addBus("DRUM_PUSH", new BusAnimationSequence()
|
||||
.addPos(0, 0, 0, 1600)
|
||||
.addPos(0, 0, -5, 0)
|
||||
.addPos(0, 0, 0, 300)
|
||||
);
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@ -1,226 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.hbm.config.GeneralConfig;
|
||||
import com.hbm.entity.projectile.EntityChemical;
|
||||
import com.hbm.handler.GunConfiguration;
|
||||
import com.hbm.handler.guncfg.GunEnergyFactory;
|
||||
import com.hbm.interfaces.IHoldableWeapon;
|
||||
import com.hbm.inventory.fluid.FluidType;
|
||||
import com.hbm.inventory.fluid.Fluids;
|
||||
import com.hbm.items.machine.ItemFluidIcon;
|
||||
import com.hbm.items.weapon.sedna.Crosshair;
|
||||
import com.hbm.packet.PacketDispatcher;
|
||||
import com.hbm.packet.toclient.GunAnimationPacket;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
import com.hbm.render.util.RenderScreenOverlay;
|
||||
import api.hbm.fluid.IFillableItem;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.enchantment.Enchantment;
|
||||
import net.minecraft.enchantment.EnchantmentHelper;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.entity.player.EntityPlayerMP;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.EnumChatFormatting;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.client.event.RenderGameOverlayEvent.ElementType;
|
||||
import net.minecraftforge.client.event.RenderGameOverlayEvent.Pre;
|
||||
|
||||
public class ItemGunChemthrower extends ItemGunBase implements IFillableItem {
|
||||
|
||||
public ItemGunChemthrower() {
|
||||
super(GunEnergyFactory.getChemConfig());
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void fire(ItemStack stack, World world, EntityPlayer player) {
|
||||
|
||||
if(!hasAmmo(stack, player, true))
|
||||
return;
|
||||
|
||||
int bullets = 1;
|
||||
|
||||
for(int i = 0; i < bullets; i++) {
|
||||
spawnProjectile(world, player, stack, 0);
|
||||
}
|
||||
|
||||
if(player instanceof EntityPlayerMP)
|
||||
PacketDispatcher.wrapper.sendTo(new GunAnimationPacket(AnimType.CYCLE.ordinal()), (EntityPlayerMP) player);
|
||||
|
||||
useUpAmmo(player, stack, true);
|
||||
player.inventoryContainer.detectAndSendChanges();
|
||||
|
||||
int wear = (int) Math.ceil(10 / (1F + EnchantmentHelper.getEnchantmentLevel(Enchantment.unbreaking.effectId, stack)));
|
||||
setItemWear(stack, getItemWear(stack) + wear);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasAmmo(ItemStack stack, EntityPlayer player, boolean main) {
|
||||
return getMag(stack) >= 0 + this.getConsumption(stack);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void useUpAmmo(EntityPlayer player, ItemStack stack, boolean main) {
|
||||
|
||||
if(!main && altConfig == null)
|
||||
return;
|
||||
|
||||
GunConfiguration config = mainConfig;
|
||||
|
||||
if(!main)
|
||||
config = altConfig;
|
||||
|
||||
if(hasInfinity(stack, config))
|
||||
return;
|
||||
|
||||
setMag(stack, getMag(stack) - this.getConsumption(stack));
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canReload(ItemStack stack, World world, EntityPlayer player) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void spawnProjectile(World world, EntityPlayer player, ItemStack stack, int config) {
|
||||
//spawn fluid projectile
|
||||
EntityChemical chem = new EntityChemical(world, player, 0, 0, 0);
|
||||
chem.setFluid(this.getFluidType(stack));
|
||||
world.spawnEntityInWorld(chem);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean bool) {
|
||||
|
||||
list.add("Ammo: " + getMag(stack) + " / " + mainConfig.ammoCap + "mB");
|
||||
|
||||
list.add("Ammo Type: " + this.getFluidType(stack).getLocalizedName());
|
||||
|
||||
int dura = mainConfig.durability - getItemWear(stack);
|
||||
|
||||
if(dura < 0)
|
||||
dura = 0;
|
||||
|
||||
list.add("Durability: " + dura + " / " + mainConfig.durability);
|
||||
list.add("");
|
||||
list.add("Name: " + mainConfig.name);
|
||||
list.add("Manufacturer: " + mainConfig.manufacturer);
|
||||
|
||||
if(!mainConfig.comment.isEmpty()) {
|
||||
list.add("");
|
||||
for(String s : mainConfig.comment)
|
||||
list.add(EnumChatFormatting.ITALIC + s);
|
||||
}
|
||||
|
||||
if(GeneralConfig.enableExtendedLogging) {
|
||||
list.add("");
|
||||
list.add("Type: " + getMagType(stack));
|
||||
list.add("Is Reloading: " + getIsReloading(stack));
|
||||
list.add("Reload Cycle: " + getReloadCycle(stack));
|
||||
list.add("RoF Cooldown: " + getDelay(stack));
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void renderHUD(Pre event, ElementType type, EntityPlayer player, ItemStack stack) {
|
||||
|
||||
ItemGunBase gun = ((ItemGunBase)stack.getItem());
|
||||
GunConfiguration gcfg = gun.mainConfig;
|
||||
|
||||
if(type == ElementType.HOTBAR) {
|
||||
|
||||
FluidType fluid = this.getFluidType(stack);
|
||||
|
||||
ItemStack ammo = ItemFluidIcon.make(fluid, 1);
|
||||
|
||||
int count = ItemGunBase.getMag(stack);
|
||||
int max = gcfg.ammoCap;
|
||||
boolean showammo = gcfg.showAmmo;
|
||||
|
||||
int dura = ItemGunBase.getItemWear(stack) * 50 / gcfg.durability;
|
||||
|
||||
RenderScreenOverlay.renderAmmo(event.resolution, Minecraft.getMinecraft().ingameGUI, ammo, count, max, dura, showammo);
|
||||
}
|
||||
|
||||
if(type == ElementType.CROSSHAIRS && GeneralConfig.enableCrosshairs) {
|
||||
|
||||
event.setCanceled(true);
|
||||
|
||||
if(!(gcfg.hasSights && player.isSneaking()))
|
||||
RenderScreenOverlay.renderCustomCrosshairs(event.resolution, Minecraft.getMinecraft().ingameGUI, ((IHoldableWeapon)player.getHeldItem().getItem()).getCrosshair());
|
||||
else
|
||||
RenderScreenOverlay.renderCustomCrosshairs(event.resolution, Minecraft.getMinecraft().ingameGUI, Crosshair.NONE);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void reload2(ItemStack stack, World world, EntityPlayer player) {
|
||||
this.setIsReloading(stack, false);
|
||||
}
|
||||
|
||||
public FluidType getFluidType(ItemStack stack) {
|
||||
return Fluids.fromID(this.getMagType(stack));
|
||||
}
|
||||
|
||||
public int getConsumption(ItemStack stack) {
|
||||
return 3;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean acceptsFluid(FluidType type, ItemStack stack) {
|
||||
return getFluidType(stack) == type || this.getMag(stack) == 0;
|
||||
}
|
||||
|
||||
public static final int transferSpeed = 50;
|
||||
|
||||
@Override
|
||||
public int tryFill(FluidType type, int amount, ItemStack stack) {
|
||||
|
||||
if(!acceptsFluid(type, stack))
|
||||
return amount;
|
||||
|
||||
if(this.getMag(stack) == 0)
|
||||
this.setMagType(stack, type.getID());
|
||||
|
||||
int fill = this.getMag(stack);
|
||||
int req = this.mainConfig.ammoCap - fill;
|
||||
|
||||
int toFill = Math.min(amount, req);
|
||||
toFill = Math.min(toFill, transferSpeed);
|
||||
|
||||
this.setMag(stack, fill + toFill);
|
||||
|
||||
return amount - toFill;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean providesFluid(FluidType type, ItemStack stack) {
|
||||
return getFluidType(stack) == type;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int tryEmpty(FluidType type, int amount, ItemStack stack) {
|
||||
|
||||
int fill = this.getMag(stack);
|
||||
int toUnload = Math.min(fill, amount);
|
||||
toUnload = Math.min(toUnload, transferSpeed);
|
||||
|
||||
this.setMag(stack, fill - toUnload);
|
||||
|
||||
return toUnload;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FluidType getFirstFluidType(ItemStack stack) {
|
||||
return this.getFluidType(stack);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getFill(ItemStack stack) {
|
||||
return this.getMag(stack);
|
||||
}
|
||||
}
|
||||
@ -1,78 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import com.hbm.handler.GunConfiguration;
|
||||
|
||||
import api.hbm.item.IDesignatorItem;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.server.MinecraftServer;
|
||||
import net.minecraft.util.ChatComponentText;
|
||||
import net.minecraft.util.ChatStyle;
|
||||
import net.minecraft.util.EnumChatFormatting;
|
||||
import net.minecraft.util.Vec3;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemGunDart extends ItemGunBase implements IDesignatorItem {
|
||||
|
||||
public ItemGunDart(GunConfiguration config) {
|
||||
super(config);
|
||||
}
|
||||
|
||||
public static void writePlayer(ItemStack stack, EntityPlayer player) {
|
||||
|
||||
if(!stack.hasTagCompound())
|
||||
stack.stackTagCompound = new NBTTagCompound();
|
||||
|
||||
stack.stackTagCompound.setString("player", player.getDisplayName());
|
||||
stack.stackTagCompound.setLong("lease", player.worldObj.getTotalWorldTime() + 60 * 60 * 20);
|
||||
}
|
||||
|
||||
public static EntityPlayer readPlayer(World world, ItemStack stack) {
|
||||
|
||||
if(!stack.hasTagCompound())
|
||||
return null;
|
||||
|
||||
if(stack.stackTagCompound.getLong("lease") < world.getTotalWorldTime())
|
||||
return null;
|
||||
|
||||
return MinecraftServer.getServer().getConfigurationManager().func_152612_a(stack.stackTagCompound.getString("player"));
|
||||
}
|
||||
|
||||
public void startAction(ItemStack stack, World world, EntityPlayer player, boolean main) {
|
||||
|
||||
if(main) {
|
||||
super.startAction(stack, world, player, main);
|
||||
} else {
|
||||
|
||||
EntityPlayer target = readPlayer(world, stack);
|
||||
|
||||
if(target != null) {
|
||||
|
||||
int dim = target.worldObj.provider.dimensionId;
|
||||
int x = (int)target.posX;
|
||||
int y = (int)target.posY;
|
||||
int z = (int)target.posZ;
|
||||
int dist = (int) target.getDistanceToEntity(player);
|
||||
|
||||
player.addChatComponentMessage(new ChatComponentText(target.getDisplayName()).setChatStyle(new ChatStyle().setColor(EnumChatFormatting.YELLOW)));
|
||||
player.addChatComponentMessage(new ChatComponentText("Dim: " + dim + " X:" + x + " Y:" + y + " Z:" + z + " (" + dist + " blocks away)").setChatStyle(new ChatStyle().setColor(EnumChatFormatting.YELLOW)));
|
||||
} else {
|
||||
|
||||
player.addChatComponentMessage(new ChatComponentText("No Target").setChatStyle(new ChatStyle().setColor(EnumChatFormatting.RED)));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isReady(World world, ItemStack stack, int x, int y, int z) {
|
||||
EntityPlayer target = readPlayer(world, stack);
|
||||
return target != null && target.dimension == world.provider.dimensionId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Vec3 getCoords(World world, ItemStack stack, int x, int y, int z) {
|
||||
EntityPlayer target = readPlayer(world, stack);
|
||||
return Vec3.createVectorHelper(target.posX, target.posY, target.posZ);
|
||||
}
|
||||
}
|
||||
@ -1,17 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import com.hbm.handler.GunConfiguration;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class ItemGunDetonator extends ItemGunBase {
|
||||
|
||||
public ItemGunDetonator(GunConfiguration config) {
|
||||
super(config);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasInfinity(ItemStack stack, GunConfiguration config) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@ -1,158 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import com.hbm.entity.projectile.EntityBulletBaseNT;
|
||||
import com.hbm.handler.GunConfiguration;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.lib.ModDamageSource;
|
||||
import com.hbm.main.MainRegistry;
|
||||
import com.hbm.packet.PacketDispatcher;
|
||||
import com.hbm.packet.toclient.GunAnimationPacket;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
import com.hbm.sound.AudioWrapper;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.entity.player.EntityPlayerMP;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemGunGauss extends ItemGunBase {
|
||||
|
||||
private AudioWrapper chargeLoop;
|
||||
|
||||
public ItemGunGauss(GunConfiguration config, GunConfiguration alt) {
|
||||
super(config, alt);
|
||||
}
|
||||
|
||||
public void endAction(ItemStack stack, World world, EntityPlayer player, boolean main) {
|
||||
|
||||
if(getHasShot(stack)) {
|
||||
world.playSoundAtEntity(player, "hbm:weapon.sparkShoot", 2.0F, 1.0F);
|
||||
setHasShot(stack, false);
|
||||
}
|
||||
|
||||
if(!main && getStored(stack) > 0) {
|
||||
EntityBulletBaseNT bullet = new EntityBulletBaseNT(world, altConfig.config.get(0), player);
|
||||
bullet.overrideDamage = Math.max(getStored(stack), 1) * 10F;
|
||||
world.spawnEntityInWorld(bullet);
|
||||
world.playSoundAtEntity(player, "hbm:weapon.tauShoot", 0.5F, 0.75F);
|
||||
setItemWear(stack, getItemWear(stack) + (getCharge(stack)) * 2);
|
||||
setCharge(stack, 0);
|
||||
|
||||
if(player instanceof EntityPlayerMP)
|
||||
PacketDispatcher.wrapper.sendTo(new GunAnimationPacket(AnimType.CYCLE.ordinal()), (EntityPlayerMP) player);
|
||||
}
|
||||
}
|
||||
|
||||
public void endActionClient(ItemStack stack, World world, EntityPlayer player, boolean main) {
|
||||
|
||||
if(chargeLoop != null) {
|
||||
chargeLoop.stopSound();
|
||||
chargeLoop = null;
|
||||
}
|
||||
}
|
||||
|
||||
protected void altFire(ItemStack stack, World world, EntityPlayer player) {
|
||||
setCharge(stack, 1);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void startActionClient(ItemStack stack, World world, EntityPlayer player, boolean main) {
|
||||
|
||||
if(!main && getItemWear(stack) < mainConfig.durability && player.inventory.hasItem(ModItems.gun_xvl1456_ammo)) {
|
||||
chargeLoop = MainRegistry.proxy.getLoopedSound("hbm:weapon.tauChargeLoop2", (float)player.posX, (float)player.posY, (float)player.posZ, 1.0F, 5F, 0.75F);
|
||||
world.playSoundAtEntity(player, "hbm:weapon.tauChargeLoop2", 1.0F, 0.75F);
|
||||
|
||||
if(chargeLoop != null) {
|
||||
chargeLoop.startSound();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected void updateServer(ItemStack stack, World world, EntityPlayer player, int slot, boolean isCurrentItem) {
|
||||
|
||||
super.updateServer(stack, world, player, slot, isCurrentItem);
|
||||
|
||||
if(getIsAltDown(stack) && getItemWear(stack) < mainConfig.durability) {
|
||||
|
||||
int c = getCharge(stack);
|
||||
|
||||
if(c > 200) {
|
||||
setCharge(stack, 0);
|
||||
setItemWear(stack, mainConfig.durability);
|
||||
player.attackEntityFrom(ModDamageSource.tauBlast, 1000);
|
||||
world.newExplosion(player, player.posX, player.posY + player.eyeHeight, player.posZ, 5.0F, true, true);
|
||||
return;
|
||||
}
|
||||
|
||||
if(c > 0) {
|
||||
setCharge(stack, c + 1);
|
||||
|
||||
if(c % 10 == 1 && c < 140 && c > 2) {
|
||||
|
||||
if(player.inventory.hasItem(ModItems.gun_xvl1456_ammo)) {
|
||||
player.inventory.consumeInventoryItem(ModItems.gun_xvl1456_ammo);
|
||||
setStored(stack, getStored(stack) + 1);
|
||||
} else {
|
||||
setCharge(stack, 0);
|
||||
setStored(stack, 0);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
setStored(stack, 0);
|
||||
}
|
||||
} else {
|
||||
setCharge(stack, 0);
|
||||
setStored(stack, 0);
|
||||
}
|
||||
}
|
||||
|
||||
protected void updateClient(ItemStack stack, World world, EntityPlayer player, int slot, boolean isCurrentItem) {
|
||||
super.updateClient(stack, world, player, slot, isCurrentItem);
|
||||
|
||||
if(chargeLoop != null) {
|
||||
if(!chargeLoop.isPlaying()) {
|
||||
chargeLoop = rebootAudio(chargeLoop, player);
|
||||
}
|
||||
chargeLoop.updatePosition((float)player.posX, (float)player.posY, (float)player.posZ);
|
||||
chargeLoop.updatePitch(1 + (getCharge(stack)) * 0.01F);
|
||||
}
|
||||
}
|
||||
|
||||
public AudioWrapper rebootAudio(AudioWrapper wrapper, EntityPlayer player) {
|
||||
wrapper.stopSound();
|
||||
AudioWrapper audio = MainRegistry.proxy.getLoopedSound("hbm:weapon.tauChargeLoop2", (float)player.posX, (float)player.posY, (float)player.posZ, wrapper.getVolume(), wrapper.getRange(), wrapper.getPitch());
|
||||
audio.startSound();
|
||||
return audio;
|
||||
}
|
||||
|
||||
protected void spawnProjectile(World world, EntityPlayer player, ItemStack stack, int config) {
|
||||
|
||||
super.spawnProjectile(world, player, stack, config);
|
||||
setHasShot(stack, true);
|
||||
}
|
||||
|
||||
public static void setHasShot(ItemStack stack, boolean b) {
|
||||
writeNBT(stack, "hasShot", b ? 1 : 0);
|
||||
}
|
||||
|
||||
public static boolean getHasShot(ItemStack stack) {
|
||||
return readNBT(stack, "hasShot") == 1;
|
||||
}
|
||||
|
||||
/// gauss charge state ///
|
||||
public static void setCharge(ItemStack stack, int i) {
|
||||
writeNBT(stack, "gauss_charge", i);
|
||||
}
|
||||
|
||||
public static int getCharge(ItemStack stack) {
|
||||
return readNBT(stack, "gauss_charge");
|
||||
}
|
||||
|
||||
public static void setStored(ItemStack stack, int i) {
|
||||
writeNBT(stack, "gauss_stored", i);
|
||||
}
|
||||
|
||||
public static int getStored(ItemStack stack) {
|
||||
return readNBT(stack, "gauss_stored");
|
||||
}
|
||||
}
|
||||
@ -1,42 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import com.hbm.handler.GunConfiguration;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemGunLacunae extends ItemGunBase {
|
||||
|
||||
public ItemGunLacunae(GunConfiguration config) {
|
||||
super(config);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void startAction(ItemStack stack, World world, EntityPlayer player, boolean main) {
|
||||
|
||||
if(main) {
|
||||
setDelay(stack, 20);
|
||||
world.playSoundAtEntity(player, "hbm:weapon.lacunaeSpinup", 1.0F, 1.0F);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void endAction(ItemStack stack, World world, EntityPlayer player, boolean main) {
|
||||
|
||||
if(main)
|
||||
world.playSoundAtEntity(player, "hbm:weapon.lacunaeSpindown", 1.0F, 1.0F);
|
||||
}
|
||||
|
||||
protected void updateServer(ItemStack stack, World world, EntityPlayer player, int slot, boolean isCurrentItem) {
|
||||
|
||||
super.updateServer(stack, world, player, slot, isCurrentItem);
|
||||
|
||||
if(getIsMouseDown(stack)) {
|
||||
|
||||
int rot = readNBT(stack, "rot") % 360;
|
||||
rot += 25;
|
||||
writeNBT(stack, "rot", rot);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,62 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import com.hbm.entity.projectile.EntityCombineBallNT;
|
||||
import com.hbm.handler.BulletConfigSyncingUtil;
|
||||
import com.hbm.handler.GunConfiguration;
|
||||
import com.hbm.items.ModItems;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemGunOSIPR extends ItemGunBase {
|
||||
|
||||
public ItemGunOSIPR(GunConfiguration config, GunConfiguration alt) {
|
||||
super(config, alt);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void altFire(ItemStack stack, World world, EntityPlayer player) {
|
||||
|
||||
setCharge(stack, 1);
|
||||
world.playSoundAtEntity(player, "hbm:weapon.osiprCharging", 1.0F, 1F);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void updateServer(ItemStack stack, World world, EntityPlayer player, int slot, boolean isCurrentItem) {
|
||||
super.updateServer(stack, world, player, slot, isCurrentItem);
|
||||
|
||||
if(!isCurrentItem) {
|
||||
setCharge(stack, 0);
|
||||
return;
|
||||
}
|
||||
|
||||
int i = getCharge(stack);
|
||||
|
||||
if(i >= 20) {
|
||||
EntityCombineBallNT energyBall = new EntityCombineBallNT(world, BulletConfigSyncingUtil.SPECIAL_OSIPR_CHARGED, player);
|
||||
world.spawnEntityInWorld(energyBall);
|
||||
world.playSoundAtEntity(player, altConfig.firingSound, 1.0F, 1F);
|
||||
setCharge(stack, 0);
|
||||
setDelay(stack, altConfig.rateOfFire);
|
||||
player.inventory.consumeInventoryItem(ModItems.gun_osipr_ammo2);
|
||||
|
||||
} else if(i > 0)
|
||||
setCharge(stack, i + 1);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean tryShoot(ItemStack stack, World world, EntityPlayer player, boolean main) {
|
||||
|
||||
return super.tryShoot(stack, world, player, main) && getCharge(stack) == 0;
|
||||
}
|
||||
|
||||
/// CMB charge state ///
|
||||
public static void setCharge(ItemStack stack, int i) {
|
||||
writeNBT(stack, "cmb_charge", i);
|
||||
}
|
||||
|
||||
public static int getCharge(ItemStack stack) {
|
||||
return readNBT(stack, "cmb_charge");
|
||||
}
|
||||
}
|
||||
@ -1,137 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import com.hbm.handler.GunConfiguration;
|
||||
import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.Vec3;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemGunPip extends ItemGunBase {
|
||||
|
||||
public static long lastShot;
|
||||
public static List<double[]> smokeNodes = new ArrayList();
|
||||
|
||||
public ItemGunPip(GunConfiguration config) {
|
||||
super(config);
|
||||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
protected void updateClient(ItemStack stack, World world, EntityPlayer entity, int slot, boolean isCurrentItem) {
|
||||
super.updateClient(stack, world, entity, slot, isCurrentItem);
|
||||
|
||||
boolean smoking = lastShot + 2000 > System.currentTimeMillis();
|
||||
|
||||
if(!smoking && !smokeNodes.isEmpty()) {
|
||||
smokeNodes.clear();
|
||||
}
|
||||
|
||||
if(smoking) {
|
||||
Vec3 prev = Vec3.createVectorHelper(-entity.motionX, -entity.motionY, -entity.motionZ);
|
||||
prev.rotateAroundY((float) (entity.rotationYaw * Math.PI / 180D));
|
||||
double accel = 15D;
|
||||
double side = (entity.rotationYaw - entity.prevRotationYawHead) * 0.1D;
|
||||
double waggle = 0.025D;
|
||||
|
||||
for(double[] node : smokeNodes) {
|
||||
node[0] += -prev.zCoord * accel + world.rand.nextGaussian() * waggle;
|
||||
node[1] += prev.yCoord + 1.5D;
|
||||
node[2] += prev.xCoord * accel + world.rand.nextGaussian() * waggle + side;
|
||||
}
|
||||
|
||||
double alpha = (System.currentTimeMillis() - lastShot) / 2000D;
|
||||
alpha = (1 - alpha) * 0.5D;
|
||||
|
||||
if(this.getIsReloading(stack)) alpha = 0;
|
||||
|
||||
smokeNodes.add(new double[] {0, 0, 0, alpha});
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public BusAnimation getAnimation(ItemStack stack, AnimType type) {
|
||||
|
||||
if(type == AnimType.EQUIP) {
|
||||
return new BusAnimation()
|
||||
.addBus("ROTATE", new BusAnimationSequence()
|
||||
.addPos(-360, 0, 0, 350)
|
||||
);
|
||||
}
|
||||
|
||||
if(type == AnimType.CYCLE) {
|
||||
lastShot = System.currentTimeMillis();
|
||||
int s = 1;
|
||||
return new BusAnimation()
|
||||
.addBus("RECOIL", new BusAnimationSequence()
|
||||
.addPos(0, 0, 0, 50 * s)
|
||||
.addPos(0, 0, -3, 50 * s)
|
||||
.addPos(0, 0, 0, 250 * s)
|
||||
)
|
||||
.addBus("HAMMER", new BusAnimationSequence()
|
||||
.addPos(0, 0, 1, 50 * s)
|
||||
.addPos(0, 0, 1, 300 * s)
|
||||
.addPos(0, 0, 0, 200 * s)
|
||||
)
|
||||
.addBus("DRUM", new BusAnimationSequence()
|
||||
.addPos(0, 0, 1, 50 * s)
|
||||
);
|
||||
}
|
||||
|
||||
if(type == AnimType.RELOAD) {
|
||||
int s = 1;
|
||||
return new BusAnimation()
|
||||
.addBus("RELAOD_TILT", new BusAnimationSequence()
|
||||
.addPos(-15, 0, 0, 100 * s)
|
||||
.addPos(65, 0, 0, 100 * s) //200
|
||||
.addPos(45, 0, 0, 50 * s) //250
|
||||
.addPos(0, 0, 0, 200 * s) //450
|
||||
.addPos(0, 0, 0, 1450 * s) //1900
|
||||
.addPos(-80, 0, 0, 100 * s) //2000
|
||||
.addPos(-80, 0, 0, 100 * s) //2100
|
||||
.addPos(0, 0, 0, 200 * s) //2300
|
||||
)
|
||||
.addBus("RELOAD_CYLINDER", new BusAnimationSequence()
|
||||
.addPos(0, 0, 0, 200 * s)
|
||||
.addPos(90, 0, 0, 100 * s) //300
|
||||
.addPos(90, 0, 0, 1700 * s) //2000
|
||||
.addPos(0, 0, 0, 70 * s) //2100
|
||||
)
|
||||
.addBus("RELOAD_LIFT", new BusAnimationSequence()
|
||||
.addPos(0, 0, 0, 350 * s)
|
||||
.addPos(-45, 0, 0, 250 * s) //600
|
||||
.addPos(-45, 0, 0, 350 * s) //950
|
||||
.addPos(-15, 0, 0, 200 * s) //1150
|
||||
.addPos(-15, 0, 0, 1050 * s) //2200
|
||||
.addPos(0, 0, 0, 100 * s) //2300
|
||||
)
|
||||
.addBus("RELOAD_JOLT", new BusAnimationSequence()
|
||||
.addPos(0, 0, 0, 600 * s)
|
||||
.addPos(2, 0, 0, 50 * s) //650
|
||||
.addPos(0, 0, 0, 100 * s) //750
|
||||
)
|
||||
.addBus("RELOAD_BULLETS", new BusAnimationSequence()
|
||||
.addPos(0, 0, 0, 650 * s)
|
||||
.addPos(10, 0, 0, 300 * s) //950
|
||||
.addPos(10, 0, 0, 200 * s) //1150
|
||||
.addPos(0, 0, 0, 700 * s) //1850
|
||||
)
|
||||
.addBus("RELOAD_BULLETS_CON", new BusAnimationSequence()
|
||||
.addPos(1, 0, 0, 0 * s)
|
||||
.addPos(1, 0, 0, 950 * s)
|
||||
.addPos(0, 0, 0, 1 * s)
|
||||
);
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@ -1,24 +0,0 @@
|
||||
package com.hbm.items.weapon;
|
||||
|
||||
import com.hbm.handler.GunConfiguration;
|
||||
import com.hbm.util.ShadyUtil;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemGunShotty extends ItemGunBase {
|
||||
|
||||
public ItemGunShotty(GunConfiguration config) {
|
||||
super(config);
|
||||
}
|
||||
|
||||
protected void updateServer(ItemStack stack, World world, EntityPlayer player, int slot, boolean isCurrentItem) {
|
||||
super.updateServer(stack, world, player, slot, isCurrentItem);
|
||||
|
||||
if((player.getUniqueID().toString().equals(ShadyUtil.Dr_Nostalgia) || player.getDisplayName().equals("Tankish") || player.getDisplayName().equals("Tankish020")) &&
|
||||
this.getDelay(stack) < this.mainConfig.rateOfFire * 0.9)
|
||||
this.setDelay(stack, 0);
|
||||
}
|
||||
|
||||
}
|
||||
@ -10,16 +10,19 @@ import com.hbm.entity.projectile.EntityBulletBeamBase;
|
||||
import com.hbm.interfaces.NotableComments;
|
||||
import com.hbm.inventory.RecipesCommon.ComparableStack;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.weapon.sedna.factory.ConfettiUtil;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmo;
|
||||
import com.hbm.lib.ModDamageSource;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmoSecret;
|
||||
import com.hbm.particle.SpentCasing;
|
||||
import com.hbm.util.BobMathUtil;
|
||||
import com.hbm.util.EntityDamageUtil;
|
||||
import com.hbm.util.TrackerUtil;
|
||||
import com.hbm.util.DamageResistanceHandler.DamageClass;
|
||||
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.EntityDamageSourceIndirect;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
@ -42,16 +45,15 @@ public class BulletConfig implements Cloneable {
|
||||
public float wear = 1F;
|
||||
public int projectilesMin = 1;
|
||||
public int projectilesMax = 1;
|
||||
public ProjectileType pType = ProjectileType.BULLET;
|
||||
|
||||
public float damageMult = 1.0F;
|
||||
public float armorThresholdNegation = 0.0F;
|
||||
public float armorPiercingPercent = 0.0F;
|
||||
public float knockbackMult = 0.1F;
|
||||
public float headshotMult = 1.0F;
|
||||
|
||||
public String damageType = ModDamageSource.s_bullet;
|
||||
public boolean dmgProj = true;
|
||||
public boolean dmgFire = false;
|
||||
public boolean dmgExplosion = false;
|
||||
public boolean dmgBypass = false;
|
||||
public DamageClass dmgClass = DamageClass.PHYSICAL;
|
||||
|
||||
public float ricochetAngle = 5F;
|
||||
public int maxRicochetCount = 2;
|
||||
@ -90,8 +92,12 @@ public class BulletConfig implements Cloneable {
|
||||
return this;
|
||||
}
|
||||
|
||||
public BulletConfig setBeam() { this.pType = ProjectileType.BEAM; return this; }
|
||||
public BulletConfig setChunkloading() { this.pType = ProjectileType.BULLET_CHUNKLOADING; return this; }
|
||||
public BulletConfig setItem(Item ammo) { this.ammo = new ComparableStack(ammo); return this; }
|
||||
public BulletConfig setItem(ItemStack ammo) { this.ammo = new ComparableStack(ammo); return this; }
|
||||
public BulletConfig setItem(EnumAmmo ammo) { this.ammo = new ComparableStack(ModItems.ammo_standard, 1, ammo.ordinal()); return this; }
|
||||
public BulletConfig setItem(EnumAmmoSecret ammo) { this.ammo = new ComparableStack(ModItems.ammo_secret, 1, ammo.ordinal()); return this; }
|
||||
public BulletConfig setReloadCount(int ammoReloadCount) { this.ammoReloadCount = ammoReloadCount; return this; }
|
||||
public BulletConfig setVel(float velocity) { this.velocity = velocity; return this; }
|
||||
public BulletConfig setSpread(float spread) { this.spread = spread; return this; }
|
||||
@ -99,10 +105,11 @@ public class BulletConfig implements Cloneable {
|
||||
public BulletConfig setProjectiles(int amount) { this.projectilesMin = this.projectilesMax = amount; return this; }
|
||||
public BulletConfig setProjectiles(int min, int max) { this.projectilesMin = min; this.projectilesMax = max; return this; }
|
||||
public BulletConfig setDamage(float damageMult) { this.damageMult = damageMult; return this; }
|
||||
public BulletConfig setThresholdNegation(float armorThresholdNegation) { this.armorThresholdNegation = armorThresholdNegation; return this; }
|
||||
public BulletConfig setArmorPiercing(float armorPiercingPercent) { this.armorPiercingPercent = armorPiercingPercent; return this; }
|
||||
public BulletConfig setKnockback(float knockbackMult) { this.knockbackMult = knockbackMult; return this; }
|
||||
public BulletConfig setHeadshot(float headshotMult) { this.headshotMult = headshotMult; return this; }
|
||||
public BulletConfig setDamageType(String type) { this.damageType = type; return this; }
|
||||
public BulletConfig setupDamageClass(boolean proj, boolean fire, boolean explosion, boolean bypass) { this.dmgProj = proj; this.dmgFire = fire; this.dmgExplosion = explosion; this.dmgBypass = bypass; return this; }
|
||||
public BulletConfig setupDamageClass(DamageClass clazz) { this.dmgClass = clazz; return this; }
|
||||
public BulletConfig setRicochetAngle(float angle) { this.ricochetAngle = angle; return this; }
|
||||
public BulletConfig setRicochetCount(int count) { this.maxRicochetCount = count; return this; }
|
||||
public BulletConfig setDamageFalloutByPen(boolean falloff) { this.damageFalloffByPen = falloff; return this; }
|
||||
@ -125,17 +132,28 @@ public class BulletConfig implements Cloneable {
|
||||
public BulletConfig setOnBeamImpact(BiConsumer<EntityBulletBeamBase, MovingObjectPosition> lambda) { this.onImpactBeam = lambda; return this; }
|
||||
public BulletConfig setOnEntityHit(BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> lambda) { this.onEntityHit = lambda; return this; }
|
||||
|
||||
public DamageSource getDamage(Entity projectile, EntityLivingBase shooter, boolean bypass) {
|
||||
public static enum ProjectileType {
|
||||
BULLET,
|
||||
BULLET_CHUNKLOADING,
|
||||
BEAM
|
||||
}
|
||||
|
||||
@SuppressWarnings("incomplete-switch") //shut up
|
||||
public static DamageSource getDamage(Entity projectile, EntityLivingBase shooter, DamageClass dmgClass) {
|
||||
|
||||
DamageSource dmg;
|
||||
|
||||
if(shooter != null) dmg = new EntityDamageSourceIndirect(damageType, projectile, shooter);
|
||||
else dmg = new DamageSource(damageType);
|
||||
if(shooter != null) dmg = new EntityDamageSourceIndirect(dmgClass.name(), projectile, shooter);
|
||||
else dmg = new DamageSource(dmgClass.name());
|
||||
|
||||
if(this.dmgProj) dmg.setProjectile();
|
||||
if(this.dmgFire) dmg.setFireDamage();
|
||||
if(this.dmgExplosion) dmg.setExplosion();
|
||||
if(this.dmgBypass || bypass) dmg.setDamageBypassesArmor();
|
||||
switch(dmgClass) {
|
||||
case PHYSICAL: dmg.setProjectile(); break;
|
||||
case FIRE: dmg.setFireDamage(); break;
|
||||
case EXPLOSIVE: dmg.setExplosion(); break;
|
||||
case ELECTRIC: break;
|
||||
case LASER: break;
|
||||
case SUBATOMIC: break;
|
||||
}
|
||||
|
||||
return dmg;
|
||||
}
|
||||
@ -184,22 +202,17 @@ public class BulletConfig implements Cloneable {
|
||||
if(entity == bullet.getThrower() && bullet.ticksExisted < bullet.selfDamageDelay()) return;
|
||||
if(entity instanceof EntityLivingBase && ((EntityLivingBase) entity).getHealth() <= 0) return;
|
||||
|
||||
DamageSource damageCalc = bullet.config.getDamage(bullet, bullet.getThrower(), false);
|
||||
DamageSource source = bullet.config.getDamage(bullet, bullet.getThrower(), bullet.config.dmgClass);
|
||||
|
||||
if(!(entity instanceof EntityLivingBase)) {
|
||||
EntityDamageUtil.attackEntityFromIgnoreIFrame(entity, damageCalc, bullet.damage);
|
||||
EntityDamageUtil.attackEntityFromIgnoreIFrame(entity, source, bullet.damage);
|
||||
return;
|
||||
}
|
||||
|
||||
EntityLivingBase living = (EntityLivingBase) entity;
|
||||
float prevHealth = living.getHealth();
|
||||
|
||||
if(bullet.config.armorPiercingPercent == 0) {
|
||||
EntityDamageUtil.attackEntityFromIgnoreIFrame(entity, damageCalc, bullet.damage);
|
||||
} else {
|
||||
DamageSource damagePiercing = bullet.config.getDamage(bullet, bullet.getThrower(), true);
|
||||
EntityDamageUtil.attackArmorPiercing(living, damageCalc, damagePiercing, bullet.damage, bullet.config.armorPiercingPercent);
|
||||
}
|
||||
EntityDamageUtil.attackEntityFromNT(living, source, bullet.damage, true, true, bullet.config.knockbackMult, bullet.config.armorThresholdNegation, bullet.config.armorPiercingPercent);
|
||||
|
||||
float newHealth = living.getHealth();
|
||||
|
||||
@ -208,6 +221,8 @@ public class BulletConfig implements Cloneable {
|
||||
bullet.setPosition(mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord);
|
||||
bullet.setDead();
|
||||
}
|
||||
|
||||
if(!living.isEntityAlive()) ConfettiUtil.decideConfetti(living, source);
|
||||
}
|
||||
};
|
||||
|
||||
@ -217,22 +232,17 @@ public class BulletConfig implements Cloneable {
|
||||
Entity entity = mop.entityHit;
|
||||
|
||||
if(entity instanceof EntityLivingBase && ((EntityLivingBase) entity).getHealth() <= 0) return;
|
||||
|
||||
DamageSource damageCalc = bullet.config.getDamage(bullet, bullet.getThrower(), false);
|
||||
|
||||
DamageSource source = bullet.config.getDamage(bullet, bullet.getThrower(), bullet.config.dmgClass);
|
||||
|
||||
if(!(entity instanceof EntityLivingBase)) {
|
||||
EntityDamageUtil.attackEntityFromIgnoreIFrame(entity, damageCalc, bullet.damage);
|
||||
EntityDamageUtil.attackEntityFromIgnoreIFrame(entity, source, bullet.damage);
|
||||
return;
|
||||
}
|
||||
|
||||
EntityLivingBase living = (EntityLivingBase) entity;
|
||||
|
||||
if(bullet.config.armorPiercingPercent == 0) {
|
||||
EntityDamageUtil.attackEntityFromIgnoreIFrame(entity, damageCalc, bullet.damage);
|
||||
} else {
|
||||
DamageSource damagePiercing = bullet.config.getDamage(bullet, bullet.getThrower(), true);
|
||||
EntityDamageUtil.attackArmorPiercing(living, damageCalc, damagePiercing, bullet.damage, bullet.config.armorPiercingPercent);
|
||||
}
|
||||
EntityDamageUtil.attackEntityFromNT(living, source, bullet.damage, true, true, bullet.config.knockbackMult, bullet.config.armorThresholdNegation, bullet.config.armorPiercingPercent);
|
||||
if(!living.isEntityAlive()) ConfettiUtil.decideConfetti(living, source);
|
||||
}
|
||||
};
|
||||
|
||||
@ -243,21 +253,15 @@ public class BulletConfig implements Cloneable {
|
||||
|
||||
if(entity instanceof EntityLivingBase && ((EntityLivingBase) entity).getHealth() <= 0) return;
|
||||
|
||||
DamageSource damageCalc = beam.config.getDamage(beam, beam.thrower, false);
|
||||
DamageSource source = beam.config.getDamage(beam, beam.thrower, beam.config.dmgClass);
|
||||
|
||||
if(!(entity instanceof EntityLivingBase)) {
|
||||
EntityDamageUtil.attackEntityFromIgnoreIFrame(entity, damageCalc, beam.damage);
|
||||
EntityDamageUtil.attackEntityFromIgnoreIFrame(entity, source, beam.damage);
|
||||
return;
|
||||
}
|
||||
|
||||
EntityLivingBase living = (EntityLivingBase) entity;
|
||||
|
||||
if(beam.config.armorPiercingPercent == 0) {
|
||||
EntityDamageUtil.attackEntityFromIgnoreIFrame(entity, damageCalc, beam.damage);
|
||||
} else {
|
||||
DamageSource damagePiercing = beam.config.getDamage(beam, beam.thrower, true);
|
||||
EntityDamageUtil.attackArmorPiercing(living, damageCalc, damagePiercing, beam.damage, beam.config.armorPiercingPercent);
|
||||
}
|
||||
EntityDamageUtil.attackEntityFromNT(living, source, beam.damage, true, false, beam.config.knockbackMult, beam.config.armorThresholdNegation, beam.config.armorPiercingPercent);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@ -66,6 +66,7 @@ public class ItemGunBaseNT extends Item implements IKeybindReceiver, IEquipRecei
|
||||
public static final String KEY_ANIMTIMER = "animtimer_";
|
||||
public static final String KEY_LOCKONTARGET = "lockontarget";
|
||||
public static final String KEY_LOCKEDON = "lockedon";
|
||||
public static final String KEY_CANCELRELOAD = "cancel";
|
||||
|
||||
public static ConcurrentHashMap<EntityLivingBase, AudioWrapper> loopedSounds = new ConcurrentHashMap();
|
||||
|
||||
@ -131,7 +132,7 @@ public class ItemGunBaseNT extends Item implements IKeybindReceiver, IEquipRecei
|
||||
case B_SIDE: list.add(EnumChatFormatting.GOLD + "B-Side"); break;
|
||||
case LEGENDARY: list.add(EnumChatFormatting.RED + "Legendary Weapon"); break;
|
||||
case SPECIAL: list.add(EnumChatFormatting.AQUA + "Special Weapon"); break;
|
||||
case SECRET: list.add(EnumChatFormatting.DARK_RED + "SECRET"); break;
|
||||
case SECRET: list.add((BobMathUtil.getBlink() ? EnumChatFormatting.DARK_RED : EnumChatFormatting.RED) + "SECRET"); break;
|
||||
case DEBUG: list.add((BobMathUtil.getBlink() ? EnumChatFormatting.YELLOW : EnumChatFormatting.GOLD) + "DEBUG"); break;
|
||||
}
|
||||
}
|
||||
@ -285,6 +286,9 @@ public class ItemGunBaseNT extends Item implements IKeybindReceiver, IEquipRecei
|
||||
public static void setTertiary(ItemStack stack, int index, boolean value) { setValueBool(stack, KEY_TERTIARY + index, value); }
|
||||
public static boolean getReloadKey(ItemStack stack, int index) { return getValueBool(stack, KEY_RELOAD + index); }
|
||||
public static void setReloadKey(ItemStack stack, int index, boolean value) { setValueBool(stack, KEY_RELOAD + index, value); }
|
||||
// RELOAD CANCEL //
|
||||
public static boolean getReloadCancel(ItemStack stack) { return getValueBool(stack, KEY_CANCELRELOAD); }
|
||||
public static void setReloadCancel(ItemStack stack, boolean value) { setValueBool(stack, KEY_CANCELRELOAD, value); }
|
||||
|
||||
|
||||
/// UTIL ///
|
||||
|
||||
@ -138,6 +138,5 @@ public class Receiver {
|
||||
}
|
||||
|
||||
public Receiver setupStandardFire() { return this.canFire(Lego.LAMBDA_STANDARD_CAN_FIRE) .fire(Lego.LAMBDA_STANDARD_FIRE); }
|
||||
public Receiver setupBeamFire() { return this.canFire(Lego.LAMBDA_STANDARD_CAN_FIRE) .fire(Lego.LAMBDA_BEAM_FIRE); }
|
||||
public Receiver setupLockonFire() { return this.canFire(Lego.LAMBDA_LOCKON_CAN_FIRE) .fire(Lego.LAMBDA_STANDARD_FIRE); }
|
||||
}
|
||||
|
||||
@ -0,0 +1,46 @@
|
||||
package com.hbm.items.weapon.sedna.factory;
|
||||
|
||||
import com.hbm.packet.PacketDispatcher;
|
||||
import com.hbm.packet.toclient.AuxParticlePacketNT;
|
||||
import com.hbm.particle.helper.AshesCreator;
|
||||
import com.hbm.particle.helper.SkeletonCreator;
|
||||
import com.hbm.util.DamageResistanceHandler.DamageClass;
|
||||
|
||||
import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.MathHelper;
|
||||
|
||||
public class ConfettiUtil {
|
||||
|
||||
public static void decideConfetti(EntityLivingBase entity, DamageSource source) {
|
||||
if(entity.isEntityAlive()) return;
|
||||
if(source.damageType.equals(DamageClass.LASER.name())) pulverize(entity);
|
||||
if(source.damageType.equals(DamageClass.ELECTRIC.name())) pulverize(entity);
|
||||
if(source.isExplosion()) gib(entity);
|
||||
if(source.isFireDamage()) cremate(entity);
|
||||
}
|
||||
|
||||
public static void pulverize(EntityLivingBase entity) {
|
||||
int amount = MathHelper.clamp_int((int) (entity.width * entity.height * entity.width * 25), 5, 50);
|
||||
AshesCreator.composeEffect(entity.worldObj, entity, amount, 0.125F);
|
||||
SkeletonCreator.composeEffect(entity.worldObj, entity, 1F);
|
||||
entity.worldObj.playSoundEffect(entity.posX, entity.posY, entity.posZ, "hbm:weapon.fire.disintegration", 2.0F, 0.9F + entity.getRNG().nextFloat() * 0.2F);
|
||||
}
|
||||
|
||||
public static void cremate(EntityLivingBase entity) {
|
||||
int amount = MathHelper.clamp_int((int) (entity.width * entity.height * entity.width * 25), 5, 50);
|
||||
AshesCreator.composeEffect(entity.worldObj, entity, amount, 0.125F);
|
||||
SkeletonCreator.composeEffect(entity.worldObj, entity, 0.25F);
|
||||
entity.worldObj.playSoundEffect(entity.posX, entity.posY, entity.posZ, "hbm:weapon.fire.disintegration", 2.0F, 0.9F + entity.getRNG().nextFloat() * 0.2F);
|
||||
}
|
||||
|
||||
public static void gib(EntityLivingBase entity) {
|
||||
NBTTagCompound vdat = new NBTTagCompound();
|
||||
vdat.setString("type", "giblets");
|
||||
vdat.setInteger("ent", entity.getEntityId());
|
||||
PacketDispatcher.wrapper.sendToAllAround(new AuxParticlePacketNT(vdat, entity.posX, entity.posY + entity.height * 0.5, entity.posZ), new TargetPoint(entity.dimension, entity.posX, entity.posY + entity.height * 0.5, entity.posZ, 150));
|
||||
entity.worldObj.playSoundEffect(entity.posX, entity.posY, entity.posZ, "mob.zombie.woodbreak", 2.0F, 0.95F + entity.getRNG().nextFloat() * 0.2F);
|
||||
}
|
||||
}
|
||||
@ -28,6 +28,7 @@ public class GunFactory {
|
||||
/// AMMO ITEMS ///
|
||||
ModItems.ammo_debug = new Item().setUnlocalizedName("ammo_debug").setTextureName(RefStrings.MODID + ":ammo_45");
|
||||
ModItems.ammo_standard = new ItemEnumMulti(EnumAmmo.class, true, true).setUnlocalizedName("ammo_standard").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_standard");
|
||||
ModItems.ammo_secret = new ItemEnumMulti(EnumAmmoSecret.class, true, true).setUnlocalizedName("ammo_secret").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":ammo_secret");
|
||||
|
||||
/// BULLLET CFGS ///
|
||||
ammo_debug = new BulletConfig().setItem(ModItems.ammo_debug).setSpread(0.01F).setRicochetAngle(45).setCasing(CASING44.clone().register("DEBUG0"));
|
||||
@ -41,7 +42,7 @@ public class GunFactory {
|
||||
.mag(new MagazineFullReload(0, 12).addConfigs(ammo_debug, ammo_debug_buckshot))
|
||||
.offset(0.75, -0.0625, -0.3125D)
|
||||
.canFire(Lego.LAMBDA_STANDARD_CAN_FIRE).fire(Lego.LAMBDA_STANDARD_FIRE))
|
||||
.pp(Lego.LAMBDA_STANDARD_CLICK_PRIMARY) .pr(Lego.LAMBDA_STANDARD_RELOAD) .pt(Lego.LAMBDA_TOGGLE_AIM)
|
||||
.pp(Lego.LAMBDA_STANDARD_CLICK_PRIMARY).pr(Lego.LAMBDA_STANDARD_RELOAD).pt(Lego.LAMBDA_TOGGLE_AIM)
|
||||
.decider(GunStateDecider.LAMBDA_STANDARD_DECIDER)
|
||||
.anim(Lego.LAMBDA_DEBUG_ANIMS)
|
||||
).setUnlocalizedName("gun_debug");
|
||||
@ -62,6 +63,8 @@ public class GunFactory {
|
||||
XFactoryAccelerator.init();
|
||||
XFactoryCatapult.init();
|
||||
XFactory75Bolt.init();
|
||||
XFactoryFolly.init();
|
||||
XFactoryTurret.init();
|
||||
|
||||
/// PROXY BULLSHIT ///
|
||||
MainRegistry.proxy.registerGunCfg();
|
||||
@ -77,15 +80,19 @@ public class GunFactory {
|
||||
R762_SP, R762_FMJ, R762_JHP, R762_AP, R762_DU,
|
||||
BMG50_SP, BMG50_FMJ, BMG50_JHP, BMG50_AP, BMG50_DU,
|
||||
B75, B75_INC, B75_EXP,
|
||||
G12_BP, G12_BP_MAGNUM, G12_BP_SLUG, G12, G12_SLUG, G12_FLECHETTE, G12_MAGNUM, G12_EXPLOSIVE, G12_PHOSPHORUS, G12_ANTHRAX,
|
||||
G12_BP, G12_BP_MAGNUM, G12_BP_SLUG, G12, G12_SLUG, G12_FLECHETTE, G12_MAGNUM, G12_EXPLOSIVE, G12_PHOSPHORUS, //G12_ANTHRAX,
|
||||
G26_FLARE, G26_FLARE_SUPPLY, G26_FLARE_WEAPON,
|
||||
G40_HE, G40_HEAT, G40_DEMO, G40_INC, G40_PHOSPHORUS,
|
||||
ROCKET_HE, ROCKET_HEAT, ROCKET_DEMO, ROCKET_INC, ROCKET_PHOSPHORUS,
|
||||
FLAME_DIESEL, FLAME_GAS, FLAME_NAPALM, FLAME_BALEFIRE,
|
||||
CAPACITOR, CAPACITOR_OVERCHARGE, CAPACITOR_BLACKLIGHTNING,
|
||||
CAPACITOR, CAPACITOR_OVERCHARGE, CAPACITOR_IR,
|
||||
TAU_URANIUM,
|
||||
COIL_TUNGSTEN, COIL_FERROURANIUM,
|
||||
NUKE_STANDARD, NUKE_DEMO, NUKE_HIGH, NUKE_TOTS, NUKE_HIVE,
|
||||
NUKE_STANDARD, NUKE_DEMO, NUKE_HIGH, NUKE_TOTS, NUKE_HIVE
|
||||
}
|
||||
|
||||
public static enum EnumAmmoSecret {
|
||||
FOLLY_SM, FOLLY_NUKE,
|
||||
M44_EQUESTRIAN, G12_EQUESTRIAN, BMG50_EQUESTRIAN
|
||||
}
|
||||
}
|
||||
|
||||
@ -15,6 +15,8 @@ import static com.hbm.items.weapon.sedna.factory.XFactoryAccelerator.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactoryBlackPowder.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactoryCatapult.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactoryEnergy.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactoryFolly.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactoryTurret.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactoryRocket.*;
|
||||
|
||||
import java.util.function.BiConsumer;
|
||||
@ -35,7 +37,8 @@ public class GunFactoryClient {
|
||||
//GUNS
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_debug, new ItemRenderDebug());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_pepperbox, new ItemRenderPepperbox());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_light_revolver, new ItemRenderAtlas());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_light_revolver, new ItemRenderAtlas(ResourceManager.bio_revolver_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_light_revolver_atlas, new ItemRenderAtlas(ResourceManager.bio_revolver_atlas_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_light_revolver_dani, new ItemRenderDANI());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_henry, new ItemRenderHenry());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_greasegun, new ItemRenderGreasegun());
|
||||
@ -49,9 +52,12 @@ public class GunFactoryClient {
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_am180, new ItemRenderAm180());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_liberator, new ItemRenderLiberator());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_congolake, new ItemRenderCongoLake());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_flamer, new ItemRenderFlamer());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_flamer, new ItemRenderFlamer(ResourceManager.flamethrower_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_flamer_topaz, new ItemRenderFlamer(ResourceManager.flamethrower_topaz_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_flamer_daybreaker, new ItemRenderFlamer(ResourceManager.flamethrower_daybreaker_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_lag, new ItemRenderLAG());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_uzi, new ItemRenderUzi());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_uzi_akimbo, new ItemRenderUziAkimbo());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_spas12, new ItemRenderSPAS12());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_panzerschreck, new ItemRenderPanzerschreck());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_g3, new ItemRenderG3());
|
||||
@ -61,7 +67,8 @@ public class GunFactoryClient {
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_autoshotgun, new ItemRenderShredder(ResourceManager.shredder_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_autoshotgun_sexy, new ItemRenderShredder(ResourceManager.sexy_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_quadro, new ItemRenderQuadro());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_minigun, new ItemRenderMinigun());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_minigun, new ItemRenderMinigun(ResourceManager.minigun_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_minigun_lacunae, new ItemRenderMinigun(ResourceManager.minigun_lacunae_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_missile_launcher, new ItemRenderMissileLauncher());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_tesla_cannon, new ItemRenderTeslaCannon());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_stg77, new ItemRenderSTG77());
|
||||
@ -71,6 +78,7 @@ public class GunFactoryClient {
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_coilgun, new ItemRenderCoilgun());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_hangman, new ItemRenderHangman());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_bolter, new ItemRenderBolter());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_folly, new ItemRenderFolly());
|
||||
//PROJECTILES
|
||||
ammo_debug.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
ammo_debug_buckshot.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
@ -135,14 +143,14 @@ public class GunFactoryClient {
|
||||
g12_magnum.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
g12_explosive.setRenderer(LegoClient.RENDER_EXPRESS_BULLET);
|
||||
g12_phosphorus.setRenderer(LegoClient.RENDER_AP_BULLET);
|
||||
g12_anthrax.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
//g12_anthrax.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
g12_equestrian.setRenderer(LegoClient.RENDER_LEGENDARY_BULLET);
|
||||
|
||||
g26_flare.setRenderer(LegoClient.RENDER_FLARE);
|
||||
g26_flare_supply.setRenderer(LegoClient.RENDER_FLARE_SUPPLY);
|
||||
g26_flare_weapon.setRenderer(LegoClient.RENDER_FLARE_WEAPON);
|
||||
|
||||
setRendererBulk(LegoClient.RENDER_GRENADE, g40_he, g40_heat, g40_demo, g40_inc);
|
||||
setRendererBulk(LegoClient.RENDER_GRENADE, g40_he, g40_heat, g40_demo, g40_inc, g40_phosphorus);
|
||||
|
||||
setRendererBulk(LegoClient.RENDER_RPZB, rocket_rpzb);
|
||||
setRendererBulk(LegoClient.RENDER_QD, rocket_qd);
|
||||
@ -155,14 +163,21 @@ public class GunFactoryClient {
|
||||
setRendererBulkBeam(LegoClient.RENDER_LIGHTNING, energy_tesla, energy_tesla_overcharge);
|
||||
setRendererBulkBeam(LegoClient.RENDER_TAU, tau_uranium);
|
||||
setRendererBulkBeam(LegoClient.RENDER_TAU_CHARGE, tau_uranium_charge);
|
||||
setRendererBulkBeam(LegoClient.RENDER_LASER, energy_las, energy_las_overcharge);
|
||||
setRendererBulkBeam(LegoClient.RENDER_LASER_RED, energy_las, energy_las_overcharge, energy_las_ir);
|
||||
setRendererBulkBeam(LegoClient.RENDER_LASER_PURPLE, energy_lacunae, energy_lacunae_overcharge, energy_lacunae_ir);
|
||||
|
||||
setRendererBulk(LegoClient.RENDER_AP_BULLET, coil_tungsten, coil_ferrouranium);
|
||||
|
||||
folly_sm.setRendererBeam(LegoClient.RENDER_FOLLY);
|
||||
folly_nuke.setRenderer(LegoClient.RENDER_BIG_NUKE);
|
||||
|
||||
setRendererBulk(LegoClient.RENDER_GRENADE, shell_normal, shell_explosive, shell_ap, shell_du, shell_w9); //TODO: change the sabots
|
||||
|
||||
//HUDS
|
||||
((ItemGunBaseNT) ModItems.gun_debug) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_pepperbox) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_light_revolver) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_light_revolver_atlas) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_henry) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_greasegun) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_maresleg) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
@ -175,6 +190,8 @@ public class GunFactoryClient {
|
||||
((ItemGunBaseNT) ModItems.gun_liberator) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_congolake) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_flamer) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO_NOCOUNTER);
|
||||
((ItemGunBaseNT) ModItems.gun_flamer_topaz) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO_NOCOUNTER);
|
||||
((ItemGunBaseNT) ModItems.gun_flamer_daybreaker) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO_NOCOUNTER);
|
||||
((ItemGunBaseNT) ModItems.gun_uzi) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_spas12) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_panzerschreck) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
@ -187,6 +204,7 @@ public class GunFactoryClient {
|
||||
((ItemGunBaseNT) ModItems.gun_quadro) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_lag) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_minigun) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_minigun_lacunae) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_missile_launcher) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_tesla_cannon) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_stg77) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
@ -196,11 +214,14 @@ public class GunFactoryClient {
|
||||
((ItemGunBaseNT) ModItems.gun_coilgun) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_hangman) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_bolter) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_folly) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_AMMO);
|
||||
|
||||
((ItemGunBaseNT) ModItems.gun_light_revolver_dani) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY_MIRROR, LegoClient.HUD_COMPONENT_AMMO_MIRROR);
|
||||
((ItemGunBaseNT) ModItems.gun_light_revolver_dani) .getConfig(null, 1).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_maresleg_akimbo) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY_MIRROR, LegoClient.HUD_COMPONENT_AMMO_MIRROR);
|
||||
((ItemGunBaseNT) ModItems.gun_maresleg_akimbo) .getConfig(null, 1).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_uzi_akimbo) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY_MIRROR, LegoClient.HUD_COMPONENT_AMMO_MIRROR);
|
||||
((ItemGunBaseNT) ModItems.gun_uzi_akimbo) .getConfig(null, 1).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
}
|
||||
|
||||
public static void setRendererBulk(BiConsumer<EntityBulletBaseMK4, Float> renderer, BulletConfig... configs) { for(BulletConfig config : configs) config.setRenderer(renderer); }
|
||||
|
||||
@ -63,9 +63,10 @@ public class GunStateDecider {
|
||||
IMagazine mag = rec.getMagazine(stack);
|
||||
|
||||
mag.reloadAction(stack, ctx.inventory);
|
||||
boolean cancel = ItemGunBaseNT.getReloadCancel(stack);
|
||||
|
||||
//if after reloading the gun can still reload, assume a tube mag and resume reloading
|
||||
if(mag.canReload(stack, ctx.inventory)) {
|
||||
if(!cancel && mag.canReload(stack, ctx.inventory)) {
|
||||
ItemGunBaseNT.setState(stack, gunIndex, GunState.RELOADING);
|
||||
ItemGunBaseNT.setTimer(stack, gunIndex, rec.getReloadCycleDuration(stack));
|
||||
ItemGunBaseNT.playAnimation(player, stack, AnimType.RELOAD_CYCLE, gunIndex);
|
||||
@ -82,6 +83,8 @@ public class GunStateDecider {
|
||||
ItemGunBaseNT.setTimer(stack, gunIndex, duration);
|
||||
ItemGunBaseNT.playAnimation(player, stack, AnimType.RELOAD_END, gunIndex);
|
||||
}
|
||||
|
||||
ItemGunBaseNT.setReloadCancel(stack, false);
|
||||
}
|
||||
|
||||
mag.setAmountAfterReload(stack, mag.getAmount(stack, ctx.inventory));
|
||||
|
||||
@ -6,6 +6,7 @@ import java.util.function.BiConsumer;
|
||||
import java.util.function.BiFunction;
|
||||
|
||||
import com.hbm.entity.projectile.EntityBulletBaseMK4;
|
||||
import com.hbm.entity.projectile.EntityBulletBaseMK4CL;
|
||||
import com.hbm.entity.projectile.EntityBulletBeamBase;
|
||||
import com.hbm.explosion.vanillant.ExplosionVNT;
|
||||
import com.hbm.explosion.vanillant.standard.EntityProcessorCrossSmooth;
|
||||
@ -13,6 +14,7 @@ import com.hbm.explosion.vanillant.standard.ExplosionEffectWeapon;
|
||||
import com.hbm.explosion.vanillant.standard.PlayerProcessorStandard;
|
||||
import com.hbm.interfaces.NotableComments;
|
||||
import com.hbm.items.weapon.sedna.BulletConfig;
|
||||
import com.hbm.items.weapon.sedna.BulletConfig.ProjectileType;
|
||||
import com.hbm.items.weapon.sedna.GunConfig;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.GunState;
|
||||
@ -20,7 +22,7 @@ import com.hbm.items.weapon.sedna.ItemGunBaseNT.LambdaContext;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.SmokeNode;
|
||||
import com.hbm.items.weapon.sedna.Receiver;
|
||||
import com.hbm.items.weapon.sedna.mags.IMagazine;
|
||||
import com.hbm.particle.helper.BlackPowderHelper;
|
||||
import com.hbm.particle.helper.BlackPowderCreator;
|
||||
import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
@ -105,6 +107,10 @@ public class Lego {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(state == GunState.RELOADING) {
|
||||
ItemGunBaseNT.setReloadCancel(stack, true);
|
||||
}
|
||||
}
|
||||
|
||||
/** If IDLE, switch mode between 0 and 1. */
|
||||
@ -194,9 +200,6 @@ public class Lego {
|
||||
doStandardFire(stack, ctx, AnimType.CYCLE, true);
|
||||
ItemGunBaseNT.setIsLockedOn(stack, false);
|
||||
};
|
||||
public static BiConsumer<ItemStack, LambdaContext> LAMBDA_BEAM_FIRE = (stack, ctx) -> {
|
||||
doBeamFire(stack, ctx, AnimType.CYCLE, true);
|
||||
};
|
||||
|
||||
public static void doStandardFire(ItemStack stack, LambdaContext ctx, AnimType anim, boolean calcWear) {
|
||||
EntityLivingBase entity = ctx.entity;
|
||||
@ -224,45 +227,21 @@ public class Lego {
|
||||
for(int i = 0; i < projectiles; i++) {
|
||||
float damage = calcDamage(ctx, stack, primary, calcWear, index);
|
||||
float spread = calcSpread(ctx, stack, primary, calcWear, index, aim);
|
||||
EntityBulletBaseMK4 mk4 = new EntityBulletBaseMK4(entity, config, damage, spread, sideOffset, heightOffset, forwardOffset);
|
||||
if(ItemGunBaseNT.getIsLockedOn(stack)) mk4.lockonTarget = entity.worldObj.getEntityByID(ItemGunBaseNT.getLockonTarget(stack));
|
||||
if(i == 0 && config.blackPowder) BlackPowderHelper.composeEffect(entity.worldObj, mk4.posX, mk4.posY, mk4.posZ, mk4.motionX, mk4.motionY, mk4.motionZ, 10, 0.25F, 0.5F, 10, 0.25F);
|
||||
entity.worldObj.spawnEntityInWorld(mk4);
|
||||
}
|
||||
|
||||
mag.useUpAmmo(stack, ctx.inventory, 1);
|
||||
if(calcWear) ItemGunBaseNT.setWear(stack, index, Math.min(ItemGunBaseNT.getWear(stack, index) + config.wear, ctx.config.getDurability(stack)));
|
||||
}
|
||||
|
||||
//shittily copy pasted because god damn this sucks ass why do projectiles need this much fucking setup jesus christ have mercy
|
||||
public static void doBeamFire(ItemStack stack, LambdaContext ctx, AnimType anim, boolean calcWear) {
|
||||
EntityLivingBase entity = ctx.entity;
|
||||
EntityPlayer player = ctx.getPlayer();
|
||||
int index = ctx.configIndex;
|
||||
if(anim != null) ItemGunBaseNT.playAnimation(player, stack, anim, ctx.configIndex);
|
||||
|
||||
float aim = ItemGunBaseNT.getIsAiming(stack) ? 0.25F : 1F;
|
||||
Receiver primary = ctx.config.getReceivers(stack)[0];
|
||||
IMagazine mag = primary.getMagazine(stack);
|
||||
BulletConfig config = (BulletConfig) mag.getType(stack, ctx.inventory);
|
||||
|
||||
Vec3 offset = primary.getProjectileOffset(stack);
|
||||
double forwardOffset = offset.xCoord;
|
||||
double heightOffset = offset.yCoord;
|
||||
double sideOffset = ItemGunBaseNT.getIsAiming(stack) ? 0 : offset.zCoord;
|
||||
|
||||
/*forwardOffset = 0.75;
|
||||
heightOffset = -0.0625 * 1.5;
|
||||
sideOffset = -0.1875D;*/
|
||||
|
||||
int projectiles = config.projectilesMin;
|
||||
if(config.projectilesMax > config.projectilesMin) projectiles += entity.getRNG().nextInt(config.projectilesMax - config.projectilesMin + 1);
|
||||
|
||||
for(int i = 0; i < projectiles; i++) {
|
||||
float damage = calcDamage(ctx, stack, primary, calcWear, index);
|
||||
float spread = calcSpread(ctx, stack, primary, calcWear, index, aim);
|
||||
EntityBulletBeamBase mk4 = new EntityBulletBeamBase(entity, config, damage, spread, sideOffset, heightOffset, forwardOffset);
|
||||
entity.worldObj.spawnEntityInWorld(mk4);
|
||||
|
||||
if(config.pType == ProjectileType.BULLET) {
|
||||
EntityBulletBaseMK4 mk4 = new EntityBulletBaseMK4(entity, config, damage, spread, sideOffset, heightOffset, forwardOffset);
|
||||
if(ItemGunBaseNT.getIsLockedOn(stack)) mk4.lockonTarget = entity.worldObj.getEntityByID(ItemGunBaseNT.getLockonTarget(stack));
|
||||
if(i == 0 && config.blackPowder) BlackPowderCreator.composeEffect(entity.worldObj, mk4.posX, mk4.posY, mk4.posZ, mk4.motionX, mk4.motionY, mk4.motionZ, 10, 0.25F, 0.5F, 10, 0.25F);
|
||||
entity.worldObj.spawnEntityInWorld(mk4);
|
||||
} else if(config.pType == ProjectileType.BULLET_CHUNKLOADING) {
|
||||
EntityBulletBaseMK4CL mk4 = new EntityBulletBaseMK4CL(entity, config, damage, spread, sideOffset, heightOffset, forwardOffset);
|
||||
if(ItemGunBaseNT.getIsLockedOn(stack)) mk4.lockonTarget = entity.worldObj.getEntityByID(ItemGunBaseNT.getLockonTarget(stack));
|
||||
if(i == 0 && config.blackPowder) BlackPowderCreator.composeEffect(entity.worldObj, mk4.posX, mk4.posY, mk4.posZ, mk4.motionX, mk4.motionY, mk4.motionZ, 10, 0.25F, 0.5F, 10, 0.25F);
|
||||
entity.worldObj.spawnEntityInWorld(mk4);
|
||||
} else if(config.pType == ProjectileType.BEAM) {
|
||||
EntityBulletBeamBase mk4 = new EntityBulletBeamBase(entity, config, damage, spread, sideOffset, heightOffset, forwardOffset);
|
||||
entity.worldObj.spawnEntityInWorld(mk4);
|
||||
}
|
||||
}
|
||||
|
||||
mag.useUpAmmo(stack, ctx.inventory, 1);
|
||||
@ -300,7 +279,7 @@ public class Lego {
|
||||
public static void standardExplode(EntityBulletBaseMK4 bullet, MovingObjectPosition mop, float range) { standardExplode(bullet, mop, range, 1F); }
|
||||
public static void standardExplode(EntityBulletBaseMK4 bullet, MovingObjectPosition mop, float range, float damageMod) {
|
||||
ExplosionVNT vnt = new ExplosionVNT(bullet.worldObj, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, range);
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(1, bullet.damage * damageMod));
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(1, bullet.damage * damageMod).setupPiercing(bullet.config.armorThresholdNegation, bullet.config.armorPiercingPercent));
|
||||
vnt.setPlayerProcessor(new PlayerProcessorStandard());
|
||||
vnt.setSFX(new ExplosionEffectWeapon(10, 2.5F, 1F));
|
||||
vnt.explode();
|
||||
|
||||
@ -19,6 +19,7 @@ import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.renderer.ActiveRenderInfo;
|
||||
import net.minecraft.client.renderer.RenderHelper;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.Vec3;
|
||||
@ -121,11 +122,18 @@ public class LegoClient {
|
||||
public static BiConsumer<EntityBulletBaseMK4, Float> RENDER_FLARE_WEAPON = (bullet, interp) -> { renderFlare(bullet, interp, 0.5F, 1F, 0.5F); };
|
||||
|
||||
private static final ResourceLocation flare = new ResourceLocation(RefStrings.MODID + ":textures/particle/flare.png");
|
||||
public static void renderFlare(EntityBulletBaseMK4 bullet, float interp, float r, float g, float b) {
|
||||
public static void renderFlare(Entity bullet, float interp, float r, float g, float b) {
|
||||
|
||||
if(bullet.ticksExisted < 2) return;
|
||||
|
||||
RenderArcFurnace.fullbright(true);
|
||||
|
||||
double scale = Math.min(5, (bullet.ticksExisted + interp - 2) * 0.5) * (0.8 + bullet.worldObj.rand.nextDouble() * 0.4);
|
||||
renderFlareSprite(bullet, interp, r, g, b, scale, 0.5F, 0.75F);
|
||||
|
||||
RenderArcFurnace.fullbright(false);
|
||||
}
|
||||
public static void renderFlareSprite(Entity bullet, float interp, float r, float g, float b, double scale, float outerAlpha, float innerAlpha) {
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glEnable(GL11.GL_BLEND);
|
||||
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE);
|
||||
@ -148,9 +156,8 @@ public class LegoClient {
|
||||
double posX = 0;
|
||||
double posY = 0;
|
||||
double posZ = 0;
|
||||
double scale = Math.min(5, (bullet.ticksExisted + interp - 2) * 0.5) * (0.8 + bullet.worldObj.rand.nextDouble() * 0.4);
|
||||
|
||||
tess.setColorRGBA_F(r, g, b, 0.5F);
|
||||
tess.setColorRGBA_F(r, g, b, outerAlpha);
|
||||
tess.addVertexWithUV((double) (posX - f1 * scale - f3 * scale), (double) (posY - f5 * scale), (double) (posZ - f2 * scale - f4 * scale), 1, 1);
|
||||
tess.addVertexWithUV((double) (posX - f1 * scale + f3 * scale), (double) (posY + f5 * scale), (double) (posZ - f2 * scale + f4 * scale), 1, 0);
|
||||
tess.addVertexWithUV((double) (posX + f1 * scale + f3 * scale), (double) (posY + f5 * scale), (double) (posZ + f2 * scale + f4 * scale), 0, 0);
|
||||
@ -158,7 +165,7 @@ public class LegoClient {
|
||||
|
||||
scale *= 0.5D;
|
||||
|
||||
tess.setColorRGBA_F(1F, 1F, 1F, 0.75F);
|
||||
tess.setColorRGBA_F(1F, 1F, 1F, innerAlpha);
|
||||
tess.addVertexWithUV((double) (posX - f1 * scale - f3 * scale), (double) (posY - f5 * scale), (double) (posZ - f2 * scale - f4 * scale), 1, 1);
|
||||
tess.addVertexWithUV((double) (posX - f1 * scale + f3 * scale), (double) (posY + f5 * scale), (double) (posZ - f2 * scale + f4 * scale), 1, 0);
|
||||
tess.addVertexWithUV((double) (posX + f1 * scale + f3 * scale), (double) (posY + f5 * scale), (double) (posZ + f2 * scale + f4 * scale), 0, 0);
|
||||
@ -172,7 +179,6 @@ public class LegoClient {
|
||||
GL11.glAlphaFunc(GL11.GL_GREATER, 0.1F);
|
||||
GL11.glDisable(GL11.GL_BLEND);
|
||||
GL11.glPopMatrix();
|
||||
RenderArcFurnace.fullbright(false);
|
||||
}
|
||||
|
||||
public static BiConsumer<EntityBulletBaseMK4, Float> RENDER_GRENADE = (bullet, interp) -> {
|
||||
@ -184,6 +190,15 @@ public class LegoClient {
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBaseMK4, Float> RENDER_BIG_NUKE = (bullet, interp) -> {
|
||||
GL11.glScalef(0.5F, 0.5F, 0.5F);
|
||||
GL11.glRotated(90, 0, 0, 1);
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
Minecraft.getMinecraft().getTextureManager().bindTexture(ResourceManager.rocket_mirv_tex);
|
||||
ResourceManager.projectiles.renderPart("MissileMIRV");
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBaseMK4, Float> RENDER_RPZB = (bullet, interp) -> {
|
||||
|
||||
GL11.glPushMatrix();
|
||||
@ -304,7 +319,15 @@ public class LegoClient {
|
||||
RenderArcFurnace.fullbright(false);
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBeamBase, Float> RENDER_LASER = (bullet, interp) -> {
|
||||
public static BiConsumer<EntityBulletBeamBase, Float> RENDER_LASER_RED = (bullet, interp) -> {
|
||||
renderStandardLaser(bullet, interp, 0x80, 0x15, 0x15);
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBeamBase, Float> RENDER_LASER_PURPLE = (bullet, interp) -> {
|
||||
renderStandardLaser(bullet, interp, 0x60, 0x15, 0x80);
|
||||
};
|
||||
|
||||
public static void renderStandardLaser(EntityBulletBeamBase bullet, float interp, int r, int g, int b) {
|
||||
|
||||
RenderArcFurnace.fullbright(true);
|
||||
GL11.glPushMatrix();
|
||||
@ -313,9 +336,34 @@ public class LegoClient {
|
||||
Vec3 delta = Vec3.createVectorHelper(0, bullet.beamLength, 0);
|
||||
double age = MathHelper.clamp_double(1D - ((double) bullet.ticksExisted - 2 + interp) / (double) bullet.getBulletConfig().expires, 0, 1);
|
||||
GL11.glScaled(age / 2 + 0.5, 1, age / 2 + 0.5);
|
||||
int colorInner = ((int)(0x80 * age) << 16) | ((int)(0x15 * age) << 8) | (int) (0x15 * age);
|
||||
int colorInner = ((int)(r * age) << 16) | ((int)(g * age) << 8) | (int) (b * age);
|
||||
BeamPronter.prontBeam(delta, EnumWaveType.RANDOM, EnumBeamType.SOLID, colorInner, colorInner, bullet.ticksExisted / 3, (int)(bullet.beamLength / 2 + 1), 0F, 8, 0.0625F);
|
||||
GL11.glPopMatrix();
|
||||
RenderArcFurnace.fullbright(false);
|
||||
}
|
||||
|
||||
public static BiConsumer<EntityBulletBeamBase, Float> RENDER_FOLLY = (bullet, interp) -> {
|
||||
|
||||
double age = MathHelper.clamp_double(1D - ((double) bullet.ticksExisted - 2 + interp) / (double) bullet.getBulletConfig().expires, 0, 1);
|
||||
RenderArcFurnace.fullbright(true);
|
||||
|
||||
GL11.glPushMatrix();
|
||||
renderFlareSprite(bullet, interp, 1F, 1F, 1F, (1 - age) * 7.5 + 1.5, 0.5F * (float) age, 0.75F * (float) age);
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE);
|
||||
GL11.glAlphaFunc(GL11.GL_GREATER, 0);
|
||||
GL11.glRotatef(180 - bullet.rotationYaw, 0, 1F, 0);
|
||||
GL11.glRotatef(-bullet.rotationPitch - 90, 1F, 0, 0);
|
||||
Vec3 delta = Vec3.createVectorHelper(0, bullet.beamLength, 0);
|
||||
GL11.glScaled((1 - age) * 25 + 2.5, 1, (1 - age) * 25 + 2.5);
|
||||
int colorInner = ((int)(0x20 * age) << 16) | ((int)(0x20 * age) << 8) | (int) (0x20 * age);
|
||||
BeamPronter.prontBeam(delta, EnumWaveType.RANDOM, EnumBeamType.SOLID, colorInner, colorInner, bullet.ticksExisted / 3, (int)(bullet.beamLength / 2 + 1), 0F, 8, 0.0625F);
|
||||
GL11.glAlphaFunc(GL11.GL_GREATER, 0.1F);
|
||||
GL11.glDisable(GL11.GL_BLEND);
|
||||
GL11.glPopMatrix();
|
||||
|
||||
RenderArcFurnace.fullbright(false);
|
||||
};
|
||||
|
||||
|
||||
@ -573,12 +573,49 @@ public class Orchestras {
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_FLAMER_DAYBREAKER = (stack, ctx) -> {
|
||||
EntityLivingBase entity = ctx.entity;
|
||||
if(entity.worldObj.isRemote) return;
|
||||
AnimType type = ItemGunBaseNT.getLastAnim(stack, ctx.configIndex);
|
||||
int timer = ItemGunBaseNT.getAnimTimer(stack, ctx.configIndex);
|
||||
|
||||
if(type == AnimType.RELOAD) {
|
||||
if(timer == 15) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.openLatch", 1F, 1F);
|
||||
if(timer == 35) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.impact", 0.5F, 1F);
|
||||
if(timer == 60) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 0.75F);
|
||||
if(timer == 70) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.insertCanister", 1F, 1F);
|
||||
if(timer == 85) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.pressureValve", 1F, 1F);
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_LAG = (stack, ctx) -> {
|
||||
EntityLivingBase entity = ctx.entity;
|
||||
if(entity.worldObj.isRemote) return;
|
||||
AnimType type = ItemGunBaseNT.getLastAnim(stack, ctx.configIndex);
|
||||
int timer = ItemGunBaseNT.getAnimTimer(stack, ctx.configIndex);
|
||||
boolean aiming = ItemGunBaseNT.getIsAiming(stack);
|
||||
|
||||
if(type == AnimType.CYCLE) {
|
||||
if(timer == 1) {
|
||||
SpentCasing casing = ctx.config.getReceivers(stack)[0].getMagazine(stack).getCasing(stack, ctx.inventory);
|
||||
if(casing != null) CasingCreator.composeEffect(entity.worldObj, entity, 0.375, aiming ? 0 : -0.0625, aiming ? 0 : -0.25D, 0, 0.18, -0.12, 0.01, casing.getName());
|
||||
}
|
||||
}
|
||||
if(type == AnimType.CYCLE_DRY) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 1F, 1F);
|
||||
if(timer == 8) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverCock", 1F, 1F);
|
||||
|
||||
}
|
||||
if(type == AnimType.RELOAD) {
|
||||
if(timer == 8) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magRemove", 1F, 1F);
|
||||
if(timer == 26) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magInsert", 1F, 1F);
|
||||
if(timer == 40) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.pistolCock", 1F, 1F);
|
||||
}
|
||||
if(type == AnimType.JAMMED) {
|
||||
if(timer == 8) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magRemove", 1F, 1F);
|
||||
if(timer == 20) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.impact", 0.5F, 1.6F);
|
||||
if(timer == 36) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magInsert", 1F, 1F);
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_UZI = (stack, ctx) -> {
|
||||
@ -613,6 +650,38 @@ public class Orchestras {
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_UZI_AKIMBO = (stack, ctx) -> {
|
||||
EntityLivingBase entity = ctx.entity;
|
||||
if(entity.worldObj.isRemote) return;
|
||||
AnimType type = ItemGunBaseNT.getLastAnim(stack, ctx.configIndex);
|
||||
int timer = ItemGunBaseNT.getAnimTimer(stack, ctx.configIndex);
|
||||
|
||||
if(type == AnimType.EQUIP) {
|
||||
if(timer == 8) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.openLatch", 1F, 1.25F);
|
||||
}
|
||||
if(type == AnimType.CYCLE) {
|
||||
if(timer == 1) {
|
||||
int mult = ctx.configIndex == 0 ? -1 : 1;
|
||||
SpentCasing casing = ctx.config.getReceivers(stack)[0].getMagazine(stack).getCasing(stack, ctx.inventory);
|
||||
if(casing != null) CasingCreator.composeEffect(entity.worldObj, entity, 0.375, -0.125, -0.375D * mult, 0, 0.18, -0.12 * mult, 0.01, casing.getName());
|
||||
}
|
||||
}
|
||||
if(type == AnimType.CYCLE_DRY) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 1F, 1F);
|
||||
if(timer == 8) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.pistolCock", 1F, 1F);
|
||||
|
||||
}
|
||||
if(type == AnimType.RELOAD) {
|
||||
if(timer == 4) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magRemove", 1F, 1F);
|
||||
if(timer == 26) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magInsert", 1F, 1F);
|
||||
if(timer == 36) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.pistolCock", 1F, 1F);
|
||||
}
|
||||
if(type == AnimType.JAMMED) {
|
||||
if(timer == 17) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.pistolCock", 1F, 1F);
|
||||
if(timer == 31) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.pistolCock", 1F, 1F);
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_SPAS = (stack, ctx) -> {
|
||||
EntityLivingBase entity = ctx.entity;
|
||||
if(entity.worldObj.isRemote) return;
|
||||
@ -679,8 +748,7 @@ public class Orchestras {
|
||||
}
|
||||
if(type == AnimType.CYCLE_DRY) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 1F, 0.8F);
|
||||
if(timer == 5) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 0.9F);
|
||||
if(timer == 9) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
if(timer == 5) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.pistolCock", 1F, 0.9F);
|
||||
|
||||
}
|
||||
if(type == AnimType.RELOAD) {
|
||||
@ -848,6 +916,9 @@ public class Orchestras {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 1F, 0.75F);
|
||||
if(timer == 1) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverSpin", 1F, 0.75F);
|
||||
}
|
||||
if(type == AnimType.RELOAD) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverSpin", 1F, 0.75F);
|
||||
}
|
||||
if(type == AnimType.INSPECT) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverSpin", 1F, 0.75F);
|
||||
}
|
||||
@ -1047,6 +1118,10 @@ public class Orchestras {
|
||||
if(entity.worldObj.isRemote) return;
|
||||
AnimType type = ItemGunBaseNT.getLastAnim(stack, ctx.configIndex);
|
||||
int timer = ItemGunBaseNT.getAnimTimer(stack, ctx.configIndex);
|
||||
|
||||
if(type == AnimType.CYCLE_DRY) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 1F, 1.5F);
|
||||
}
|
||||
|
||||
if(type == AnimType.RELOAD) {
|
||||
if(timer == 2) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallRemove", 1F, 1F);
|
||||
@ -1146,9 +1221,21 @@ public class Orchestras {
|
||||
}
|
||||
|
||||
if(type == AnimType.RELOAD) {
|
||||
|
||||
if(timer == 5) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magRemove", 1F, 1F);
|
||||
if(timer == 26) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magInsert", 1F, 1F);
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_FOLLY = (stack, ctx) -> {
|
||||
EntityLivingBase entity = ctx.entity;
|
||||
if(entity.worldObj.isRemote) return;
|
||||
AnimType type = ItemGunBaseNT.getLastAnim(stack, ctx.configIndex);
|
||||
int timer = ItemGunBaseNT.getAnimTimer(stack, ctx.configIndex);
|
||||
|
||||
if(type == AnimType.RELOAD) {
|
||||
if(timer == 20) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.screw", 1F, 1F);
|
||||
if(timer == 80) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.insertRocket", 1F, 1F);
|
||||
if(timer == 120) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.screw", 1F, 1F);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
@ -4,6 +4,7 @@ import java.util.function.BiConsumer;
|
||||
import java.util.function.BiFunction;
|
||||
|
||||
import com.hbm.entity.projectile.EntityBulletBaseMK4;
|
||||
import com.hbm.extprop.HbmLivingProps;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.weapon.sedna.BulletConfig;
|
||||
import com.hbm.items.weapon.sedna.Crosshair;
|
||||
@ -14,6 +15,7 @@ import com.hbm.items.weapon.sedna.ItemGunBaseNT.GunState;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.LambdaContext;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.WeaponQuality;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmo;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmoSecret;
|
||||
import com.hbm.items.weapon.sedna.mags.MagazineFullReload;
|
||||
import com.hbm.items.weapon.sedna.mags.MagazineSingleReload;
|
||||
import com.hbm.main.MainRegistry;
|
||||
@ -50,24 +52,25 @@ public class XFactory12ga {
|
||||
|
||||
public static void init() {
|
||||
|
||||
g12_bp = new BulletConfig().setItem(EnumAmmo.G12_BP).setBlackPowder(true).setProjectiles(8).setSpread(0.05F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(SpentCasing.COLOR_CASE_BRASS, SpentCasing.COLOR_CASE_BRASS).setScale(0.75F).register("12GA_BP"));
|
||||
g12_bp_magnum = new BulletConfig().setItem(EnumAmmo.G12_BP_MAGNUM).setBlackPowder(true).setProjectiles(4).setSpread(0.05F).setRicochetAngle(25).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(SpentCasing.COLOR_CASE_BRASS, SpentCasing.COLOR_CASE_BRASS).setScale(0.75F).register("12GA_BP_MAGNUM"));
|
||||
g12_bp_slug = new BulletConfig().setItem(EnumAmmo.G12_BP_SLUG).setBlackPowder(true).setSpread(0.01F).setRicochetAngle(5).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(SpentCasing.COLOR_CASE_BRASS, SpentCasing.COLOR_CASE_BRASS).setScale(0.75F).register("12GA_BP_SLUG"));
|
||||
g12 = new BulletConfig().setItem(EnumAmmo.G12).setProjectiles(8).setSpread(0.05F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0xB52B2B, SpentCasing.COLOR_CASE_BRASS).setScale(0.75F).register("12GA"));
|
||||
g12_bp = new BulletConfig().setItem(EnumAmmo.G12_BP).setBlackPowder(true).setProjectiles(8).setDamage(0.5F/8F).setSpread(0.05F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(SpentCasing.COLOR_CASE_BRASS, SpentCasing.COLOR_CASE_BRASS).setScale(0.75F).register("12GA_BP"));
|
||||
g12_bp_magnum = new BulletConfig().setItem(EnumAmmo.G12_BP_MAGNUM).setBlackPowder(true).setProjectiles(4).setDamage(0.5F/4F).setSpread(0.05F).setRicochetAngle(25).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(SpentCasing.COLOR_CASE_BRASS, SpentCasing.COLOR_CASE_BRASS).setScale(0.75F).register("12GA_BP_MAGNUM"));
|
||||
g12_bp_slug = new BulletConfig().setItem(EnumAmmo.G12_BP_SLUG).setBlackPowder(true).setDamage(0.5F).setSpread(0.01F).setRicochetAngle(5).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(SpentCasing.COLOR_CASE_BRASS, SpentCasing.COLOR_CASE_BRASS).setScale(0.75F).register("12GA_BP_SLUG"));
|
||||
g12 = new BulletConfig().setItem(EnumAmmo.G12).setProjectiles(8).setDamage(1F/8F).setSpread(0.05F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0xB52B2B, SpentCasing.COLOR_CASE_BRASS).setScale(0.75F).register("12GA"));
|
||||
g12_slug = new BulletConfig().setItem(EnumAmmo.G12_SLUG).setSpread(0.0F).setRicochetAngle(25).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0x393939, SpentCasing.COLOR_CASE_BRASS).setScale(0.75F).register("12GA_SLUG"));
|
||||
g12_flechette = new BulletConfig().setItem(EnumAmmo.G12_FLECHETTE).setProjectiles(8).setSpread(0.025F).setRicochetAngle(5).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0x3C80F0, SpentCasing.COLOR_CASE_BRASS).setScale(0.75F).register("12GA_FLECHETTE"));
|
||||
g12_magnum = new BulletConfig().setItem(EnumAmmo.G12_MAGNUM).setProjectiles(4).setSpread(0.015F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0x278400, SpentCasing.COLOR_CASE_12GA).setScale(0.75F).register("12GA_MAGNUM"));
|
||||
g12_explosive = new BulletConfig().setItem(EnumAmmo.G12_EXPLOSIVE).setOnImpact(LAMBDA_STANDARD_EXPLODE).setSpread(0F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0xDA4127, SpentCasing.COLOR_CASE_12GA).setScale(0.75F).register("12GA_EXPLOSIVE"));
|
||||
g12_phosphorus = new BulletConfig().setItem(EnumAmmo.G12_PHOSPHORUS).setProjectiles(8).setSpread(0.015F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0x910001, SpentCasing.COLOR_CASE_12GA).setScale(0.75F).register("12GA_PHOSPHORUS"));
|
||||
g12_anthrax = new BulletConfig().setItem(EnumAmmo.G12_ANTHRAX).setProjectiles(8).setSpread(0.015F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0x749300, SpentCasing.COLOR_CASE_12GA).setScale(0.75F).register("12GA_ANTHRAX"));
|
||||
g12_equestrian = new BulletConfig().setItem(EnumAmmo.G12_EQUESTRIAN).setDamage(0F).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(SpentCasing.COLOR_CASE_EQUESTRIAN, SpentCasing.COLOR_CASE_12GA).setScale(0.75F).register("12gaEquestrian"));
|
||||
g12_flechette = new BulletConfig().setItem(EnumAmmo.G12_FLECHETTE).setProjectiles(8).setDamage(1F/8F).setThresholdNegation(5F).setArmorPiercing(0.2F).setSpread(0.025F).setRicochetAngle(5).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0x3C80F0, SpentCasing.COLOR_CASE_BRASS).setScale(0.75F).register("12GA_FLECHETTE"));
|
||||
g12_magnum = new BulletConfig().setItem(EnumAmmo.G12_MAGNUM).setProjectiles(4).setDamage(2F/4F).setSpread(0.015F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0x278400, SpentCasing.COLOR_CASE_12GA).setScale(0.75F).register("12GA_MAGNUM"));
|
||||
g12_explosive = new BulletConfig().setItem(EnumAmmo.G12_EXPLOSIVE).setDamage(5F).setOnImpact(LAMBDA_STANDARD_EXPLODE).setSpread(0F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0xDA4127, SpentCasing.COLOR_CASE_12GA).setScale(0.75F).register("12GA_EXPLOSIVE"));
|
||||
g12_phosphorus = new BulletConfig().setItem(EnumAmmo.G12_PHOSPHORUS).setProjectiles(8).setDamage(1F/8F).setSpread(0.015F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0x910001, SpentCasing.COLOR_CASE_12GA).setScale(0.75F).register("12GA_PHOSPHORUS"))
|
||||
.setOnImpact((bullet, mop) -> { if(mop.entityHit != null && mop.entityHit instanceof EntityLivingBase) { HbmLivingProps data = HbmLivingProps.getData((EntityLivingBase) mop.entityHit); if(data.phosphorus < 300) data.phosphorus = 300; } });
|
||||
//g12_anthrax = new BulletConfig().setItem(EnumAmmo.G12_ANTHRAX).setProjectiles(8).setDamage(1F/8F).setSpread(0.015F).setRicochetAngle(15).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(0x749300, SpentCasing.COLOR_CASE_12GA).setScale(0.75F).register("12GA_ANTHRAX"));
|
||||
g12_equestrian = new BulletConfig().setItem(EnumAmmoSecret.G12_EQUESTRIAN).setDamage(0F).setCasing(new SpentCasing(CasingType.SHOTGUN).setColor(SpentCasing.COLOR_CASE_EQUESTRIAN, SpentCasing.COLOR_CASE_12GA).setScale(0.75F).register("12gaEquestrian"));
|
||||
|
||||
BulletConfig[] all = new BulletConfig[] {g12_bp, g12_bp_magnum, g12_bp_slug, g12, g12_slug, g12_flechette, g12_magnum, g12_explosive, g12_phosphorus, g12_anthrax};
|
||||
BulletConfig[] all = new BulletConfig[] {g12_bp, g12_bp_magnum, g12_bp_slug, g12, g12_slug, g12_flechette, g12_magnum, g12_explosive, g12_phosphorus};
|
||||
|
||||
ModItems.gun_maresleg = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(600).draw(10).inspect(39).reloadSequential(true).crosshair(Crosshair.L_CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(12F).delay(20).reload(22, 10, 13, 0).jam(24).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(16F).delay(20).reload(22, 10, 13, 0).jam(24).sound("hbm:weapon.fire.shotgun", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 6).addConfigs(all))
|
||||
.offset(0.75, -0.0625, -0.1875)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -77,7 +80,7 @@ public class XFactory12ga {
|
||||
ModItems.gun_maresleg_akimbo = new ItemGunBaseNT(WeaponQuality.B_SIDE,
|
||||
new GunConfig().dura(600).draw(5).inspect(39).reloadSequential(true).crosshair(Crosshair.L_CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(12F).delay(20).reload(22, 10, 13, 0).jam(24).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(16F).delay(20).reload(22, 10, 13, 0).jam(24).sound("hbm:weapon.fire.shotgun", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 6).addConfigs(all))
|
||||
.offset(0.75, -0.0625, 0.1875D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -86,7 +89,7 @@ public class XFactory12ga {
|
||||
.anim(LAMBDA_MARESLEG_SHORT_ANIMS).orchestra(Orchestras.ORCHESTRA_MARESLEG_AKIMBO),
|
||||
new GunConfig().dura(600).draw(5).inspect(39).reloadSequential(true).crosshair(Crosshair.L_CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(12F).delay(20).reload(22, 10, 13, 0).jam(24).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(12F).delay(20).reload(22, 10, 13, 0).jam(24).sound("hbm:weapon.fire.shotgun", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(1, 6).addConfigs(all))
|
||||
.offset(0.75, -0.0625, -0.1875)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -97,7 +100,7 @@ public class XFactory12ga {
|
||||
ModItems.gun_maresleg_broken = new ItemGunBaseNT(WeaponQuality.LEGENDARY, new GunConfig()
|
||||
.dura(0).draw(5).inspect(39).reloadSequential(true).crosshair(Crosshair.L_CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(12F).delay(20).reload(22, 10, 13, 0).jam(24).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(32F).delay(20).reload(22, 10, 13, 0).jam(24).sound("hbm:weapon.fire.shotgun", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 6).addConfigs(all))
|
||||
.offset(0.75, -0.0625, -0.1875)
|
||||
.canFire(Lego.LAMBDA_STANDARD_CAN_FIRE).fire(Lego.LAMBDA_NOWEAR_FIRE).recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -108,7 +111,7 @@ public class XFactory12ga {
|
||||
ModItems.gun_liberator = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(200).draw(20).inspect(21).reloadSequential(true).crosshair(Crosshair.L_CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(12F).delay(20).rounds(4).reload(25, 15, 7, 0).jam(45).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(8F).delay(20).rounds(4).reload(25, 15, 7, 0).jam(45).sound("hbm:weapon.fire.shotgunAlt", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 4).addConfigs(all))
|
||||
.offset(0.75, -0.0625, -0.1875)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -119,7 +122,7 @@ public class XFactory12ga {
|
||||
ModItems.gun_spas12 = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(600).draw(20).inspect(39).reloadSequential(true).crosshair(Crosshair.L_CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(12F).delay(20).reload(5, 10, 10, 10, 0).jam(36).sound("hbm:weapon.shotgunShoot", 1.0F, 1.0F)
|
||||
.dmg(32F).delay(20).reload(5, 10, 10, 10, 0).jam(36).sound("hbm:weapon.shotgunShoot", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 8).addConfigs(all))
|
||||
.offset(0.75, -0.0625, -0.1875)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -130,7 +133,7 @@ public class XFactory12ga {
|
||||
ModItems.gun_autoshotgun = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(2_000).draw(10).inspect(33).reloadSequential(true).crosshair(Crosshair.L_CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(15F).delay(10).auto(true).autoAfterDry(true).dryfireAfterAuto(true).reload(44).jam(19).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(48F).delay(10).auto(true).autoAfterDry(true).dryfireAfterAuto(true).reload(44).jam(19).sound("hbm:weapon.fire.shotgunAuto", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 20).addConfigs(all))
|
||||
.offset(0.75, -0.125, -0.25)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -140,15 +143,15 @@ public class XFactory12ga {
|
||||
ModItems.gun_autoshotgun_sexy = new ItemGunBaseNT(WeaponQuality.LEGENDARY, new GunConfig()
|
||||
.dura(5_000).draw(10).inspect(33).reloadSequential(true).crosshair(Crosshair.L_CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(15F).delay(1).auto(true).dryfireAfterAuto(true).reload(44).jam(19).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 100).addConfigs(g12_equestrian, g12_bp, g12_bp_magnum, g12_bp_slug, g12, g12_slug, g12_flechette, g12_magnum, g12_explosive, g12_phosphorus, g12_anthrax))
|
||||
.dmg(64F).delay(1).auto(true).dryfireAfterAuto(true).reload(44).jam(19).sound("hbm:weapon.fire.shotgunAuto", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 100).addConfigs(g12_equestrian, g12_bp, g12_bp_magnum, g12_bp_slug, g12, g12_slug, g12_flechette, g12_magnum, g12_explosive, g12_phosphorus))
|
||||
.offset(0.75, -0.125, -0.25)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_SEXY_ANIMS).orchestra(Orchestras.ORCHESTRA_SHREDDER_SEXY)
|
||||
).setUnlocalizedName("gun_autoshotgun_sexy");
|
||||
}
|
||||
//TODO: make generic code for this crap
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> LAMBDA_SPAS_SECONDARY = (stack, ctx) -> {
|
||||
EntityLivingBase entity = ctx.entity;
|
||||
EntityPlayer player = ctx.getPlayer();
|
||||
@ -177,6 +180,9 @@ public class XFactory12ga {
|
||||
}
|
||||
}
|
||||
}
|
||||
if(state == GunState.RELOADING) {
|
||||
ItemGunBaseNT.setReloadCancel(stack, true);
|
||||
}
|
||||
};
|
||||
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_MARESLEG_ANIMS = (stack, type) -> {
|
||||
|
||||
@ -33,19 +33,19 @@ public class XFactory22lr {
|
||||
|
||||
public static void init() {
|
||||
SpentCasing casing22 = new SpentCasing(CasingType.STRAIGHT).setColor(SpentCasing.COLOR_CASE_BRASS).setScale(0.5F);
|
||||
p22_sp = new BulletConfig().setItem(EnumAmmo.P22_SP)
|
||||
p22_sp = new BulletConfig().setItem(EnumAmmo.P22_SP).setKnockback(0F)
|
||||
.setCasing(casing22.clone().register("p22"));
|
||||
p22_fmj = new BulletConfig().setItem(EnumAmmo.P22_FMJ).setDamage(0.8F).setArmorPiercing(0.1F)
|
||||
p22_fmj = new BulletConfig().setItem(EnumAmmo.P22_FMJ).setKnockback(0F).setDamage(0.8F).setArmorPiercing(0.1F)
|
||||
.setCasing(casing22.clone().register("p22fmj"));
|
||||
p22_jhp = new BulletConfig().setItem(EnumAmmo.P22_JHP).setDamage(1.5F).setArmorPiercing(-0.25F)
|
||||
p22_jhp = new BulletConfig().setItem(EnumAmmo.P22_JHP).setKnockback(0F).setDamage(1.5F).setArmorPiercing(-0.25F)
|
||||
.setCasing(casing22.clone().register("p22jhp"));
|
||||
p22_ap = new BulletConfig().setItem(EnumAmmo.P22_AP).setDoesPenetrate(true).setDamageFalloutByPen(false).setDamage(1.5F).setArmorPiercing(0.15F)
|
||||
p22_ap = new BulletConfig().setItem(EnumAmmo.P22_AP).setKnockback(0F).setDoesPenetrate(true).setDamageFalloutByPen(false).setDamage(1.5F).setArmorPiercing(0.15F)
|
||||
.setCasing(casing22.clone().setColor(SpentCasing.COLOR_CASE_44).register("p22ap"));
|
||||
|
||||
ModItems.gun_am180 = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(177 * 25).draw(15).inspect(38).crosshair(Crosshair.L_CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(5F).delay(1).dry(10).auto(true).spread(0.02F).reload(66).jam(30).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(2F).delay(1).dry(10).auto(true).spread(0.02F).reload(66).jam(30).sound("hbm:weapon.fire.silenced", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 177).addConfigs(p22_sp, p22_fmj, p22_jhp, p22_ap))
|
||||
.offset(1, -0.0625 * 1.5, -0.1875D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
|
||||
@ -38,18 +38,27 @@ public class XFactory357 {
|
||||
ModItems.gun_light_revolver = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(300).draw(4).inspect(23).crosshair(Crosshair.CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(10F).delay(16).reload(55).jam(45).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(7.5F).delay(16).reload(55).jam(45).sound("hbm:weapon.fire.pistol", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 6).addConfigs(m357_bp, m357_sp, m357_fmj, m357_jhp, m357_ap, m357_express))
|
||||
.offset(0.75, -0.0625, -0.3125D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_ATLAS_ANIMS).orchestra(Orchestras.ORCHESTRA_ATLAS)
|
||||
).setUnlocalizedName("gun_light_revolver");
|
||||
|
||||
ModItems.gun_light_revolver_atlas = new ItemGunBaseNT(WeaponQuality.B_SIDE, new GunConfig()
|
||||
.dura(300).draw(4).inspect(23).crosshair(Crosshair.CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(12.5F).delay(16).reload(55).jam(45).sound("hbm:weapon.fire.pistol", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 6).addConfigs(m357_bp, m357_sp, m357_fmj, m357_jhp, m357_ap, m357_express))
|
||||
.offset(0.75, -0.0625, -0.3125D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_ATLAS_ANIMS).orchestra(Orchestras.ORCHESTRA_ATLAS)
|
||||
).setUnlocalizedName("gun_light_revolver_atlas");
|
||||
ModItems.gun_light_revolver_dani = new ItemGunBaseNT(WeaponQuality.LEGENDARY,
|
||||
new GunConfig().dura(30_000).draw(20).inspect(23).crosshair(Crosshair.CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(10F).delay(11).reload(55).jam(45).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(15F).delay(11).reload(55).jam(45).sound("hbm:weapon.fire.pistol", 1.0F, 1.1F)
|
||||
.mag(new MagazineFullReload(0, 6).addConfigs(m357_bp, m357_sp, m357_fmj, m357_jhp, m357_ap, m357_express))
|
||||
.offset(0.75, -0.0625, 0.3125D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -58,7 +67,7 @@ public class XFactory357 {
|
||||
.anim(LAMBDA_DANI_ANIMS).orchestra(Orchestras.ORCHESTRA_DANI),
|
||||
new GunConfig().dura(30_000).draw(20).inspect(23).crosshair(Crosshair.CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(10F).delay(11).reload(55).jam(45).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(15F).delay(11).reload(55).jam(45).sound("hbm:weapon.fire.pistol", 1.0F, 0.9F)
|
||||
.mag(new MagazineFullReload(1, 6).addConfigs(m357_bp, m357_sp, m357_fmj, m357_jhp, m357_ap, m357_express))
|
||||
.offset(0.75, -0.0625, -0.3125D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
|
||||
@ -2,8 +2,11 @@ package com.hbm.items.weapon.sedna.factory;
|
||||
|
||||
import java.util.function.BiConsumer;
|
||||
import java.util.function.BiFunction;
|
||||
import java.util.function.Consumer;
|
||||
|
||||
import com.hbm.entity.effect.EntityFireLingering;
|
||||
import com.hbm.entity.logic.EntityC130;
|
||||
import com.hbm.entity.logic.EntityC130.C130PayloadType;
|
||||
import com.hbm.entity.projectile.EntityBulletBaseMK4;
|
||||
import com.hbm.explosion.vanillant.ExplosionVNT;
|
||||
import com.hbm.explosion.vanillant.standard.BlockAllocatorStandard;
|
||||
@ -30,7 +33,11 @@ import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.BusAnimationKeyframe.IType;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
import com.hbm.util.EntityDamageUtil;
|
||||
import com.hbm.util.TrackerUtil;
|
||||
import com.hbm.util.DamageResistanceHandler.DamageClass;
|
||||
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@ -48,6 +55,7 @@ public class XFactory40mm {
|
||||
public static BulletConfig g40_heat;
|
||||
public static BulletConfig g40_demo;
|
||||
public static BulletConfig g40_inc;
|
||||
public static BulletConfig g40_phosphorus;
|
||||
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_STANDARD_IGNITE = (bullet, mop) -> {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY) {
|
||||
@ -62,7 +70,13 @@ public class XFactory40mm {
|
||||
};
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_STANDARD_EXPLODE_HEAT = (bullet, mop) -> {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 3) return;
|
||||
Lego.standardExplode(bullet, mop, 2.5F); bullet.setDead();
|
||||
Lego.standardExplode(bullet, mop, 3.5F); bullet.setDead();
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && mop.entityHit instanceof EntityLivingBase) {
|
||||
EntityLivingBase living = (EntityLivingBase) mop.entityHit;
|
||||
EntityDamageUtil.attackEntityFromNT(living, bullet.config.getDamage(bullet, bullet.getThrower(), DamageClass.EXPLOSIVE), bullet.damage * 3F, true, true, 0.5F, 3F, 0.15F);
|
||||
} else if(mop.typeOfHit == mop.typeOfHit.ENTITY) {
|
||||
mop.entityHit.attackEntityFrom(bullet.config.getDamage(bullet, bullet.getThrower(), DamageClass.EXPLOSIVE), bullet.damage * 3F);
|
||||
}
|
||||
};
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_STANDARD_EXPLODE_DEMO = (bullet, mop) -> {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 3) return;
|
||||
@ -76,16 +90,23 @@ public class XFactory40mm {
|
||||
bullet.setDead();
|
||||
};
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_STANDARD_EXPLODE_INC = (bullet, mop) -> {
|
||||
spawnFire(bullet, mop, false, 200);
|
||||
};
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_STANDARD_EXPLODE_PHOSPHORUS = (bullet, mop) -> {
|
||||
spawnFire(bullet, mop, true, 400);
|
||||
};
|
||||
|
||||
public static void spawnFire(EntityBulletBaseMK4 bullet, MovingObjectPosition mop, boolean phosphorus, int duration) {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 3) return;
|
||||
World world = bullet.worldObj;
|
||||
Lego.standardExplode(bullet, mop, 3F);
|
||||
EntityFireLingering fire = new EntityFireLingering(world).setArea(5, 2).setDuration(200).setType(EntityFireLingering.TYPE_DIESEL);
|
||||
EntityFireLingering fire = new EntityFireLingering(world).setArea(5, 2).setDuration(duration).setType(phosphorus ? EntityFireLingering.TYPE_PHOSPHORUS : EntityFireLingering.TYPE_DIESEL);
|
||||
fire.setPosition(mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord);
|
||||
world.spawnEntityInWorld(fire);
|
||||
bullet.setDead();
|
||||
for(int dx = -1; dx <= 1; dx++) {
|
||||
for(int dy = -1; dy <= 1; dy++) {
|
||||
for(int dz = -2; dz <= 2; dz++) {
|
||||
for(int dz = -1; dz <= 1; dz++) {
|
||||
int x = (int) Math.floor(mop.hitVec.xCoord) + dx;
|
||||
int y = (int) Math.floor(mop.hitVec.yCoord) + dy;
|
||||
int z = (int) Math.floor(mop.hitVec.zCoord) + dz;
|
||||
@ -98,19 +119,37 @@ public class XFactory40mm {
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
public static Consumer<Entity> LAMBDA_SPAWN_C130_SUPPLIESS = (entity) -> { spawnPlane(entity, C130PayloadType.SUPPLIES); };
|
||||
public static Consumer<Entity> LAMBDA_SPAWN_C130_WEAPONS = (entity) -> { spawnPlane(entity, C130PayloadType.WEAPONS); };
|
||||
|
||||
public static void spawnPlane(Entity entity, C130PayloadType payload) {
|
||||
if(!entity.worldObj.isRemote && entity.ticksExisted == 40) {
|
||||
EntityBulletBaseMK4 bullet = (EntityBulletBaseMK4) entity;
|
||||
if(bullet.getThrower() != null) bullet.worldObj.playSoundAtEntity(bullet.getThrower(), "hbm:item.techBleep", 1.0F, 1.0F);
|
||||
EntityC130 c130 = new EntityC130(bullet.worldObj);
|
||||
int x = (int) Math.floor(bullet.posX);
|
||||
int z = (int) Math.floor(bullet.posZ);
|
||||
int y = bullet.worldObj.getHeightValue(x, z);
|
||||
c130.fac(bullet.worldObj, x, y, z, payload);
|
||||
bullet.worldObj.spawnEntityInWorld(c130);
|
||||
TrackerUtil.setTrackingRange(bullet.worldObj, c130, 250);
|
||||
}
|
||||
}
|
||||
|
||||
public static void init() {
|
||||
|
||||
g26_flare = new BulletConfig().setItem(EnumAmmo.G26_FLARE).setLife(100).setVel(2F).setGrav(0.015D).setRenderRotations(false).setOnImpact(LAMBDA_STANDARD_IGNITE).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0x9E1616).setScale(2F).register("g26Flare"));
|
||||
g26_flare_supply = new BulletConfig().setItem(EnumAmmo.G26_FLARE_SUPPLY).setLife(100).setVel(2F).setGrav(0.015D).setRenderRotations(false).setOnImpact(LAMBDA_STANDARD_IGNITE).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0x3C80F0).setScale(2F).register("g26FlareSupply"));
|
||||
g26_flare_weapon = new BulletConfig().setItem(EnumAmmo.G26_FLARE_WEAPON).setLife(100).setVel(2F).setGrav(0.015D).setRenderRotations(false).setOnImpact(LAMBDA_STANDARD_IGNITE).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0x278400).setScale(2F).register("g26FlareWeapon"));
|
||||
g26_flare_supply = new BulletConfig().setItem(EnumAmmo.G26_FLARE_SUPPLY).setLife(100).setVel(2F).setGrav(0.015D).setRenderRotations(false).setOnImpact(LAMBDA_STANDARD_IGNITE).setOnUpdate(LAMBDA_SPAWN_C130_SUPPLIESS).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0x3C80F0).setScale(2F).register("g26FlareSupply"));
|
||||
g26_flare_weapon = new BulletConfig().setItem(EnumAmmo.G26_FLARE_WEAPON).setLife(100).setVel(2F).setGrav(0.015D).setRenderRotations(false).setOnImpact(LAMBDA_STANDARD_IGNITE).setOnUpdate(LAMBDA_SPAWN_C130_WEAPONS).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0x278400).setScale(2F).register("g26FlareWeapon"));
|
||||
|
||||
BulletConfig g40_base = new BulletConfig().setLife(200).setVel(2F).setGrav(0.035D);
|
||||
g40_he = g40_base.clone().setItem(EnumAmmo.G40_HE).setOnImpact(LAMBDA_STANDARD_EXPLODE).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0x777777).setScale(2, 2F, 1.5F).register("g40"));
|
||||
g40_heat = g40_base.clone().setItem(EnumAmmo.G40_HEAT).setOnImpact(LAMBDA_STANDARD_EXPLODE_HEAT).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0x5E6854).setScale(2, 2F, 1.5F).register("g40heat"));
|
||||
g40_demo = g40_base.clone().setItem(EnumAmmo.G40_DEMO).setOnImpact(LAMBDA_STANDARD_EXPLODE_DEMO).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0xE30000).setScale(2, 2F, 1.5F).register("g40demo"));
|
||||
g40_inc = g40_base.clone().setItem(EnumAmmo.G40_INC).setOnImpact(LAMBDA_STANDARD_EXPLODE_INC).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0xE86F20).setScale(2, 2F, 1.5F).register("g40inc"));
|
||||
g40_heat = g40_base.clone().setItem(EnumAmmo.G40_HEAT).setOnImpact(LAMBDA_STANDARD_EXPLODE_HEAT).setDamage(0.5F).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0x5E6854).setScale(2, 2F, 1.5F).register("g40heat"));
|
||||
g40_demo = g40_base.clone().setItem(EnumAmmo.G40_DEMO).setOnImpact(LAMBDA_STANDARD_EXPLODE_DEMO).setDamage(0.75F).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0xE30000).setScale(2, 2F, 1.5F).register("g40demo"));
|
||||
g40_inc = g40_base.clone().setItem(EnumAmmo.G40_INC).setOnImpact(LAMBDA_STANDARD_EXPLODE_INC).setDamage(0.75F).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0xE86F20).setScale(2, 2F, 1.5F).register("g40inc"));
|
||||
g40_phosphorus = g40_base.clone().setItem(EnumAmmo.G40_PHOSPHORUS).setOnImpact(LAMBDA_STANDARD_EXPLODE_PHOSPHORUS).setDamage(0.75F).setCasing(new SpentCasing(CasingType.STRAIGHT).setColor(0xC8C8C8).setScale(2, 2F, 1.5F).register("g40phos"));
|
||||
|
||||
ModItems.gun_flaregun = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(100).draw(7).inspect(39).crosshair(Crosshair.L_CIRCUMFLEX).smoke(LAMBDA_SMOKE)
|
||||
@ -126,8 +165,8 @@ public class XFactory40mm {
|
||||
ModItems.gun_congolake = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(400).draw(7).inspect(39).reloadSequential(true).crosshair(Crosshair.L_CIRCUMFLEX).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(30F).delay(24).reload(16, 16, 16, 0).jam(0).sound("hbm:weapon.glShoot", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 4).addConfigs(g40_he, g40_heat, g40_demo, g40_inc))
|
||||
.dmg(20F).delay(24).reload(16, 16, 16, 0).jam(0).sound("hbm:weapon.glShoot", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 4).addConfigs(g40_he, g40_heat, g40_demo, g40_inc, g40_phosphorus))
|
||||
.offset(0.75, -0.0625, -0.1875D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
|
||||
@ -13,6 +13,7 @@ import com.hbm.items.weapon.sedna.ItemGunBaseNT.GunState;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.LambdaContext;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.WeaponQuality;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmo;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmoSecret;
|
||||
import com.hbm.items.weapon.sedna.mags.MagazineFullReload;
|
||||
import com.hbm.items.weapon.sedna.mags.MagazineSingleReload;
|
||||
import com.hbm.lib.RefStrings;
|
||||
@ -52,13 +53,13 @@ public class XFactory44 {
|
||||
.setCasing(casing44.clone().setColor(SpentCasing.COLOR_CASE_44).register("m44ap"));
|
||||
m44_express = new BulletConfig().setItem(EnumAmmo.M44_EXPRESS).setDoesPenetrate(true).setDamage(1.5F).setArmorPiercing(0.1F).setWear(1.5F)
|
||||
.setCasing(casing44.clone().register("m44express"));
|
||||
m44_equestrian = new BulletConfig().setItem(EnumAmmo.M44_EQUESTRIAN).setDamage(0F)
|
||||
m44_equestrian = new BulletConfig().setItem(EnumAmmoSecret.M44_EQUESTRIAN).setDamage(0F)
|
||||
.setCasing(casing44.clone().setColor(SpentCasing.COLOR_CASE_EQUESTRIAN).register("m44equestrian"));
|
||||
|
||||
ModItems.gun_henry = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(300).draw(15).inspect(23).reloadSequential(true).crosshair(Crosshair.CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(12F).delay(20).reload(25, 11, 14, 8).jam(45).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(10F).delay(20).reload(25, 11, 14, 8).jam(45).sound("hbm:weapon.fire.rifle", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 14).addConfigs(m44_bp, m44_sp, m44_fmj, m44_jhp, m44_ap, m44_express))
|
||||
.offset(0.75, -0.0625, -0.1875D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -69,7 +70,7 @@ public class XFactory44 {
|
||||
ModItems.gun_heavy_revolver = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(600).draw(10).inspect(23).crosshair(Crosshair.L_CLASSIC).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(10F).delay(14).reload(46).jam(23).sound("hbm:weapon.44Shoot", 1.0F, 1.0F)
|
||||
.dmg(15F).delay(14).reload(46).jam(23).sound("hbm:weapon.44Shoot", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 6).addConfigs(m44_bp, m44_sp, m44_fmj, m44_jhp, m44_ap, m44_express))
|
||||
.offset(0.75, -0.0625, -0.3125D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -79,7 +80,7 @@ public class XFactory44 {
|
||||
ModItems.gun_heavy_revolver_lilmac = new ItemGunBaseNT(WeaponQuality.LEGENDARY, new GunConfig()
|
||||
.dura(31_000).draw(10).inspect(23).crosshair(Crosshair.L_CLASSIC).scopeTexture(scope_lilmac).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(10F).delay(14).reload(46).jam(23).sound("hbm:weapon.44Shoot", 1.0F, 1.0F)
|
||||
.dmg(30F).delay(14).reload(46).jam(23).sound("hbm:weapon.44Shoot", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 6).addConfigs(m44_equestrian, m44_bp, m44_sp, m44_fmj, m44_jhp, m44_ap, m44_express))
|
||||
.offset(0.75, -0.0625, -0.3125D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -90,7 +91,7 @@ public class XFactory44 {
|
||||
ModItems.gun_hangman = new ItemGunBaseNT(WeaponQuality.LEGENDARY, new GunConfig()
|
||||
.dura(600).draw(10).inspect(31).inspectCancel(false).crosshair(Crosshair.CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(10F).delay(10).reload(46).jam(23).sound("hbm:weapon.44Shoot", 1.0F, 1.0F)
|
||||
.dmg(25F).delay(10).reload(46).jam(23).sound("hbm:weapon.44Shoot", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 8).addConfigs(m44_bp, m44_sp, m44_fmj, m44_jhp, m44_ap, m44_express))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
|
||||
@ -46,7 +46,7 @@ public class XFactory50 {
|
||||
ModItems.gun_m2 = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(3_000).draw(10).inspect(31).crosshair(Crosshair.L_CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(5F).delay(2).dry(10).auto(true).spread(0.005F).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(7.5F).delay(2).dry(10).auto(true).spread(0.005F).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineBelt().addConfigs(bmg50_sp, bmg50_fmj, bmg50_jhp, bmg50_ap, bmg50_du))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
|
||||
@ -47,7 +47,7 @@ public class XFactory556mm {
|
||||
ModItems.gun_g3 = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(3_000).draw(10).inspect(33).crosshair(Crosshair.CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(15F).delay(2).auto(true).dry(15).spread(0.0F).reload(50).jam(47).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(5F).delay(2).auto(true).dry(15).spread(0.0F).reload(50).jam(47).sound("hbm:weapon.fire.assault", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 30).addConfigs(r556_sp, r556_fmj, r556_jhp, r556_ap))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -58,7 +58,7 @@ public class XFactory556mm {
|
||||
ModItems.gun_stg77 = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(3_000).draw(10).inspect(125).crosshair(Crosshair.CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(15F).delay(2).dry(15).auto(true).spread(0.0F).reload(46).jam(0).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(10F).delay(2).dry(15).auto(true).spread(0.0F).reload(46).jam(0).sound("hbm:weapon.fire.assault", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 30).addConfigs(r556_sp, r556_fmj, r556_jhp, r556_ap))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
|
||||
@ -40,7 +40,7 @@ public class XFactory75Bolt {
|
||||
ModItems.gun_bolter = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(3_000).draw(20).inspect(31).crosshair(Crosshair.L_CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(5F).delay(2).auto(true).spread(0.005F).reload(40).jam(55).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(15F).delay(2).auto(true).spread(0.005F).reload(40).jam(55).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 30).addConfigs(b75, b75_inc, b75_exp))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
|
||||
@ -21,6 +21,7 @@ import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.BusAnimationKeyframe.IType;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
import com.hbm.util.DamageResistanceHandler.DamageClass;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
@ -32,6 +33,10 @@ public class XFactory762mm {
|
||||
public static BulletConfig r762_ap;
|
||||
public static BulletConfig r762_du;
|
||||
|
||||
public static BulletConfig energy_lacunae;
|
||||
public static BulletConfig energy_lacunae_overcharge;
|
||||
public static BulletConfig energy_lacunae_ir;
|
||||
|
||||
public static void init() {
|
||||
SpentCasing casing762 = new SpentCasing(CasingType.BOTTLENECK).setColor(SpentCasing.COLOR_CASE_BRASS);
|
||||
r762_sp = new BulletConfig().setItem(EnumAmmo.R762_SP)
|
||||
@ -44,28 +49,42 @@ public class XFactory762mm {
|
||||
.setCasing(casing762.clone().setColor(SpentCasing.COLOR_CASE_44).register("r762ap"));
|
||||
r762_du = new BulletConfig().setItem(EnumAmmo.R762_DU).setDoesPenetrate(true).setDamageFalloutByPen(false).setDamage(2.5F).setArmorPiercing(0.25F)
|
||||
.setCasing(casing762.clone().setColor(SpentCasing.COLOR_CASE_44).register("r762du"));
|
||||
|
||||
energy_lacunae = new BulletConfig().setItem(EnumAmmo.CAPACITOR).setupDamageClass(DamageClass.LASER).setBeam().setReloadCount(40).setSpread(0.0F).setLife(5).setRenderRotations(false).setOnBeamImpact(BulletConfig.LAMBDA_STANDARD_BEAM_HIT);
|
||||
energy_lacunae_overcharge = new BulletConfig().setItem(EnumAmmo.CAPACITOR_OVERCHARGE).setupDamageClass(DamageClass.LASER).setBeam().setReloadCount(40).setSpread(0.0F).setLife(5).setRenderRotations(false).setDoesPenetrate(true).setOnBeamImpact(BulletConfig.LAMBDA_STANDARD_BEAM_HIT);
|
||||
energy_lacunae_ir = new BulletConfig().setItem(EnumAmmo.CAPACITOR_IR).setupDamageClass(DamageClass.FIRE).setBeam().setReloadCount(40).setSpread(0.0F).setLife(5).setRenderRotations(false).setOnBeamImpact(XFactoryEnergy.LAMBDA_IR_HIT);
|
||||
|
||||
ModItems.gun_carbine = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(3_000).draw(10).inspect(31).reloadSequential(true).crosshair(Crosshair.CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(5F).delay(5).dry(15).spread(0.0F).reload(30, 0, 15, 0).jam(60).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(15F).delay(5).dry(15).spread(0.0F).reload(30, 0, 15, 0).jam(60).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 14).addConfigs(r762_sp, r762_fmj, r762_jhp, r762_ap, r762_du))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_CARBINE_ANIMS).orchestra(Orchestras.ORCHESTRA_CARBIBE)
|
||||
).setUnlocalizedName("gun_carbine");
|
||||
|
||||
|
||||
ModItems.gun_minigun = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(50_000).draw(20).inspect(20).crosshair(Crosshair.L_CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(10F).delay(1).auto(true).dry(15).spread(0.01F).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(6F).delay(1).auto(true).dry(15).spread(0.01F).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineBelt().addConfigs(r762_sp, r762_fmj, r762_jhp, r762_ap, r762_du))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_MINIGUN_ANIMS).orchestra(Orchestras.ORCHESTRA_MINIGUN)
|
||||
).setUnlocalizedName("gun_minigun");
|
||||
ModItems.gun_minigun_lacunae = new ItemGunBaseNT(WeaponQuality.LEGENDARY, new GunConfig()
|
||||
.dura(50_000).draw(20).inspect(20).crosshair(Crosshair.L_CIRCLE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(12F).delay(1).auto(true).dry(15).reload(15).spread(0.01F).sound("hbm:weapon.fire.laserGatling", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 200).addConfigs(energy_lacunae, energy_lacunae_overcharge, energy_lacunae_ir))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_MINIGUN_ANIMS).orchestra(Orchestras.ORCHESTRA_MINIGUN)
|
||||
).setUnlocalizedName("gun_minigun_lacunae");
|
||||
}
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> LAMBDA_SMOKE = (stack, ctx) -> {
|
||||
@ -113,6 +132,9 @@ public class XFactory762mm {
|
||||
.addBus("ROTATE", new BusAnimationSequence().addPos(0, 0, 60, 50).addPos(0, 0, 720, 1000, IType.SIN_DOWN));
|
||||
case CYCLE_DRY: return new BusAnimation()
|
||||
.addBus("ROTATE", new BusAnimationSequence().addPos(0, 0, 60, 50).addPos(0, 0, 720, 1000, IType.SIN_DOWN));
|
||||
case RELOAD: return new BusAnimation()
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(-15, 0, 0, 250, IType.SIN_DOWN).addPos(0, 0, 0, 500, IType.SIN_FULL))
|
||||
.addBus("ROTATE", new BusAnimationSequence().addPos(0, 0, 60, 50).addPos(0, 0, 720, 1000, IType.SIN_DOWN));
|
||||
case INSPECT: return new BusAnimation()
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(3, 0, 0, 150, IType.SIN_DOWN).addPos(0, 0, 0, 100, IType.SIN_FULL))
|
||||
.addBus("ROTATE", new BusAnimationSequence().addPos(0, 0, -720, 1000, IType.SIN_DOWN));
|
||||
|
||||
@ -9,11 +9,13 @@ import com.hbm.items.weapon.sedna.Crosshair;
|
||||
import com.hbm.items.weapon.sedna.GunConfig;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT;
|
||||
import com.hbm.items.weapon.sedna.Receiver;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.GunState;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.LambdaContext;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.WeaponQuality;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmo;
|
||||
import com.hbm.items.weapon.sedna.mags.MagazineFullReload;
|
||||
import com.hbm.main.MainRegistry;
|
||||
import com.hbm.main.ResourceManager;
|
||||
import com.hbm.particle.SpentCasing;
|
||||
import com.hbm.particle.SpentCasing.CasingType;
|
||||
import com.hbm.render.anim.BusAnimation;
|
||||
@ -44,7 +46,7 @@ public class XFactory9mm {
|
||||
ModItems.gun_greasegun = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(3_000).draw(20).inspect(31).crosshair(Crosshair.L_CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(5F).delay(4).dry(40).auto(true).spread(0.015F).reload(60).jam(55).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(3F).delay(4).dry(40).auto(true).spread(0.015F).reload(60).jam(55).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 30).addConfigs(p9_sp, p9_fmj, p9_jhp, p9_ap))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -53,9 +55,9 @@ public class XFactory9mm {
|
||||
).setUnlocalizedName("gun_greasegun");
|
||||
|
||||
ModItems.gun_lag = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(1_700).draw(15).inspect(31).crosshair(Crosshair.CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.dura(1_700).draw(7).inspect(31).crosshair(Crosshair.CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(15F).delay(4).dry(40).spread(0.005F).reload(60).jam(55).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(25F).delay(4).dry(4).spread(0.005F).reload(53).jam(44).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 17).addConfigs(p9_sp, p9_fmj, p9_jhp, p9_ap))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -66,17 +68,46 @@ public class XFactory9mm {
|
||||
ModItems.gun_uzi = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(3_000).draw(15).inspect(31).crosshair(Crosshair.CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(7.5F).delay(2).dry(25).auto(true).spread(0.005F).reload(55).jam(50).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(3F).delay(2).dry(25).auto(true).spread(0.005F).reload(55).jam(50).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 30).addConfigs(p9_sp, p9_fmj, p9_jhp, p9_ap))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_UZI_ANIMS).orchestra(Orchestras.ORCHESTRA_UZI)
|
||||
).setUnlocalizedName("gun_uzi");
|
||||
ModItems.gun_uzi_akimbo = new ItemGunBaseNT(WeaponQuality.B_SIDE,
|
||||
new GunConfig().dura(3_000).draw(15).inspect(31).crosshair(Crosshair.CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(3F).delay(2).dry(25).auto(true).spread(0.005F).reload(55).jam(50).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 30).addConfigs(p9_sp, p9_fmj, p9_jhp, p9_ap))
|
||||
.offset(1, -0.0625 * 2.5, 0.375D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.pp(Lego.LAMBDA_STANDARD_CLICK_PRIMARY).pr(Lego.LAMBDA_STANDARD_RELOAD)
|
||||
.decider(GunStateDecider.LAMBDA_STANDARD_DECIDER)
|
||||
.anim(LAMBDA_UZI_ANIMS).orchestra(Orchestras.ORCHESTRA_UZI_AKIMBO),
|
||||
new GunConfig().dura(3_000).draw(15).inspect(31).crosshair(Crosshair.CIRCLE).smoke(LAMBDA_SMOKE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(7.5F).delay(2).dry(25).auto(true).spread(0.005F).reload(55).jam(50).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(1, 30).addConfigs(p9_sp, p9_fmj, p9_jhp, p9_ap))
|
||||
.offset(1, -0.0625 * 2.5, -0.375D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.ps(Lego.LAMBDA_STANDARD_CLICK_PRIMARY).pr(Lego.LAMBDA_STANDARD_RELOAD)
|
||||
.decider(LAMBDA_SECOND_UZI)
|
||||
.anim(LAMBDA_UZI_ANIMS).orchestra(Orchestras.ORCHESTRA_UZI_AKIMBO)
|
||||
).setUnlocalizedName("gun_uzi_akimbo");
|
||||
}
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> LAMBDA_SECOND_UZI = (stack, ctx) -> {
|
||||
int index = ctx.configIndex;
|
||||
GunState lastState = ItemGunBaseNT.getState(stack, index);
|
||||
GunStateDecider.deciderStandardFinishDraw(stack, lastState, index);
|
||||
GunStateDecider.deciderStandardClearJam(stack, lastState, index);
|
||||
GunStateDecider.deciderStandardReload(stack, ctx, lastState, 0, index);
|
||||
GunStateDecider.deciderAutoRefire(stack, ctx, lastState, 0, index, () -> { return ItemGunBaseNT.getSecondary(stack, index) && ItemGunBaseNT.getMode(stack, ctx.configIndex) == 0; });
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> LAMBDA_SMOKE = (stack, ctx) -> {
|
||||
Lego.handleStandardSmoke(ctx.entity, stack, 2000, 0.05D, 1.1D, 0);
|
||||
Lego.handleStandardSmoke(ctx.entity, stack, 2000, 0.05D, 1.1D, ctx.configIndex);
|
||||
};
|
||||
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_GREASEGUN_ANIMS = (stack, type) -> {
|
||||
@ -111,7 +142,20 @@ public class XFactory9mm {
|
||||
return null;
|
||||
};
|
||||
|
||||
public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_LAG_ANIMS = (stack, type) -> {
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_LAG_ANIMS = (stack, type) -> {
|
||||
switch(type) {
|
||||
case EQUIP: return new BusAnimation()
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(-90, 0, 0, 0).addPos(0, 0, 0, 350, IType.SIN_DOWN));
|
||||
case CYCLE: return ResourceManager.lag_anim.get("Firing");
|
||||
//.addBus("HAMMER", new BusAnimationSequence().addPos(0, 0, 25, 50).addPos(0, 0, 25, 50).addPos(0, 0, 0, 100, IType.SIN_DOWN));
|
||||
case CYCLE_DRY: return ResourceManager.lag_anim.get("Dryfire");
|
||||
case RELOAD: return ResourceManager.lag_anim.get("Reload");
|
||||
case JAMMED: return ResourceManager.lag_anim.get("Jam");
|
||||
case INSPECT: return ResourceManager.lag_anim.get("Inspect")
|
||||
.addBus("ADD_TRANS", new BusAnimationSequence().addPos(-4, 0, -3, 500).addPos(-4, 0, -3, 2000).addPos(0, 0, 0, 500))
|
||||
.addBus("ADD_ROT", new BusAnimationSequence().addPos(0, -2, 5, 500).addPos(0, -2, 5, 2000).addPos(0, 0, 0, 500));
|
||||
}
|
||||
|
||||
return null;
|
||||
};
|
||||
|
||||
|
||||
@ -21,6 +21,7 @@ import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.BusAnimationKeyframe.IType;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
import com.hbm.util.DamageResistanceHandler.DamageClass;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
@ -79,9 +80,9 @@ public class XFactoryAccelerator {
|
||||
|
||||
public static void init() {
|
||||
|
||||
tau_uranium = new BulletConfig().setItem(EnumAmmo.TAU_URANIUM).setLife(5).setRenderRotations(false).setDoesPenetrate(true).setDamageFalloutByPen(false)
|
||||
tau_uranium = new BulletConfig().setItem(EnumAmmo.TAU_URANIUM).setupDamageClass(DamageClass.SUBATOMIC).setBeam().setLife(5).setRenderRotations(false).setDoesPenetrate(true).setDamageFalloutByPen(false)
|
||||
.setOnBeamImpact(BulletConfig.LAMBDA_BEAM_HIT);
|
||||
tau_uranium_charge = new BulletConfig().setItem(EnumAmmo.TAU_URANIUM).setLife(5).setRenderRotations(false).setDoesPenetrate(true).setDamageFalloutByPen(false).setSpectral(true)
|
||||
tau_uranium_charge = new BulletConfig().setItem(EnumAmmo.TAU_URANIUM).setupDamageClass(DamageClass.SUBATOMIC).setBeam().setLife(5).setRenderRotations(false).setDoesPenetrate(true).setDamageFalloutByPen(false).setSpectral(true)
|
||||
.setOnBeamImpact(BulletConfig.LAMBDA_BEAM_HIT);
|
||||
|
||||
coil_tungsten = new BulletConfig().setItem(EnumAmmo.COIL_TUNGSTEN).setVel(7.5F).setLife(50).setDoesPenetrate(true).setDamageFalloutByPen(false).setSpectral(true)
|
||||
@ -94,10 +95,10 @@ public class XFactoryAccelerator {
|
||||
ModItems.gun_tau = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(6_400).draw(10).inspect(10).crosshair(Crosshair.CIRCLE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(10F).delay(4).auto(true).spread(0F)
|
||||
.dmg(25F).delay(4).auto(true).spread(0F)
|
||||
.mag(new MagazineBelt().addConfigs(tau_uranium))
|
||||
.offset(1, -0.0625 * 2.5, -0.25D)
|
||||
.setupBeamFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.pp(Lego.LAMBDA_STANDARD_CLICK_PRIMARY)
|
||||
.rp(LAMBDA_TAU_PRIMARY_RELEASE)
|
||||
.ps(LAMBDA_TAU_SECONDARY_PRESS)
|
||||
@ -110,7 +111,7 @@ public class XFactoryAccelerator {
|
||||
ModItems.gun_coilgun = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(400).draw(5).inspect(39).crosshair(Crosshair.L_CIRCUMFLEX)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(15F).delay(5).reload(20).jam(33).sound("hbm:weapon.coilgunShoot", 1.0F, 1.0F)
|
||||
.dmg(35F).delay(5).reload(20).jam(33).sound("hbm:weapon.coilgunShoot", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 1).addConfigs(coil_tungsten, coil_ferrouranium))
|
||||
.offset(0.75, -0.0625, -0.1875D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
|
||||
@ -122,7 +122,7 @@ public class XFactoryCatapult {
|
||||
if(bullet.isDead) return;
|
||||
bullet.setDead();
|
||||
ExplosionVNT vnt = new ExplosionVNT(bullet.worldObj, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, 5);
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(2, bullet.damage).withRangeMod(1.5F));
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(1, bullet.damage).withRangeMod(1.5F));
|
||||
vnt.setPlayerProcessor(new PlayerProcessorStandard());
|
||||
vnt.setSFX(new ExplosionEffectWeapon(10, 2.5F, 1F));
|
||||
vnt.explode();
|
||||
@ -133,13 +133,13 @@ public class XFactoryCatapult {
|
||||
nuke_standard = new BulletConfig().setItem(EnumAmmo.NUKE_STANDARD).setLife(300).setVel(3F).setGrav(0.025F).setOnImpact(LAMBDA_NUKE_STANDARD);
|
||||
nuke_demo = new BulletConfig().setItem(EnumAmmo.NUKE_DEMO).setLife(300).setVel(3F).setGrav(0.025F).setOnImpact(LAMBDA_NUKE_DEMO);
|
||||
nuke_high = new BulletConfig().setItem(EnumAmmo.NUKE_HIGH).setLife(300).setVel(3F).setGrav(0.025F).setOnImpact(LAMBDA_NUKE_HIGH);
|
||||
nuke_tots = new BulletConfig().setItem(EnumAmmo.NUKE_TOTS).setProjectiles(8).setLife(300).setVel(3F).setGrav(0.025F).setSpread(0.1F).setOnImpact(LAMBDA_NUKE_TINYTOT);
|
||||
nuke_hive = new BulletConfig().setItem(EnumAmmo.NUKE_HIVE).setProjectiles(12).setLife(300).setVel(1F).setGrav(0.025F).setSpread(0.15F).setOnImpact(LAMBDA_NUKE_HIVE);
|
||||
nuke_tots = new BulletConfig().setItem(EnumAmmo.NUKE_TOTS).setProjectiles(8).setLife(300).setVel(3F).setGrav(0.025F).setSpread(0.1F).setDamage(0.35F).setOnImpact(LAMBDA_NUKE_TINYTOT);
|
||||
nuke_hive = new BulletConfig().setItem(EnumAmmo.NUKE_HIVE).setProjectiles(12).setLife(300).setVel(1F).setGrav(0.025F).setSpread(0.15F).setDamage(0.25F).setOnImpact(LAMBDA_NUKE_HIVE);
|
||||
|
||||
ModItems.gun_fatman = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(300).draw(20).inspect(30).crosshair(Crosshair.L_CIRCUMFLEX).hideCrosshair(false)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(25F).delay(10).reload(57).jam(40).sound("hbm:weapon.fire.fatman", 1.0F, 1.0F)
|
||||
.dmg(100F).delay(10).reload(57).jam(40).sound("hbm:weapon.fire.fatman", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 1).addConfigs(nuke_standard, nuke_demo, nuke_high, nuke_tots, nuke_hive))
|
||||
.offset(1, -0.0625 * 1.5, -0.1875D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
|
||||
@ -3,10 +3,12 @@ package com.hbm.items.weapon.sedna.factory;
|
||||
import java.util.function.BiConsumer;
|
||||
import java.util.function.BiFunction;
|
||||
|
||||
import com.hbm.entity.effect.EntityFireLingering;
|
||||
import com.hbm.entity.projectile.EntityBulletBeamBase;
|
||||
import com.hbm.explosion.vanillant.ExplosionVNT;
|
||||
import com.hbm.explosion.vanillant.standard.EntityProcessorCrossSmooth;
|
||||
import com.hbm.explosion.vanillant.standard.PlayerProcessorStandard;
|
||||
import com.hbm.extprop.HbmLivingProps;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.weapon.sedna.BulletConfig;
|
||||
import com.hbm.items.weapon.sedna.Crosshair;
|
||||
@ -25,15 +27,19 @@ import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.BusAnimationKeyframe.IType;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
import com.hbm.util.DamageResistanceHandler.DamageClass;
|
||||
|
||||
import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.potion.Potion;
|
||||
import net.minecraft.potion.PotionEffect;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
public class XFactoryEnergy {
|
||||
@ -42,11 +48,10 @@ public class XFactoryEnergy {
|
||||
|
||||
public static BulletConfig energy_tesla;
|
||||
public static BulletConfig energy_tesla_overcharge;
|
||||
public static BulletConfig energy_tesla_blacklightning;
|
||||
|
||||
public static BulletConfig energy_las;
|
||||
public static BulletConfig energy_las_overcharge;
|
||||
public static BulletConfig energy_las_blacklightning;
|
||||
public static BulletConfig energy_las_ir;
|
||||
|
||||
public static BiConsumer<EntityBulletBeamBase, MovingObjectPosition> LAMBDA_LIGHTNING_HIT = (beam, mop) -> {
|
||||
|
||||
@ -58,7 +63,7 @@ public class XFactoryEnergy {
|
||||
}
|
||||
|
||||
ExplosionVNT vnt = new ExplosionVNT(beam.worldObj, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, 2F);
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(1, beam.damage));
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(1, beam.damage).setDamageClass(beam.config.dmgClass));
|
||||
vnt.setPlayerProcessor(new PlayerProcessorStandard());
|
||||
vnt.explode();
|
||||
beam.worldObj.playSoundEffect(mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, "hbm:entity.ufoBlast", 5.0F, 0.9F + beam.worldObj.rand.nextFloat() * 0.2F);
|
||||
@ -86,26 +91,52 @@ public class XFactoryEnergy {
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBeamBase, MovingObjectPosition> LAMBDA_IR_HIT = (beam, mop) -> {
|
||||
BulletConfig.LAMBDA_STANDARD_BEAM_HIT.accept(beam, mop);
|
||||
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY) {
|
||||
if(mop.entityHit instanceof EntityLivingBase) {
|
||||
EntityLivingBase living = (EntityLivingBase) mop.entityHit;
|
||||
HbmLivingProps props = HbmLivingProps.getData(living);
|
||||
if(props.fire < 100) props.fire = 100;
|
||||
}
|
||||
}
|
||||
|
||||
if(mop.typeOfHit == mop.typeOfHit.BLOCK) {
|
||||
World world = beam.worldObj;
|
||||
Block b = world.getBlock(mop.blockX, mop.blockY, mop.blockZ);
|
||||
ForgeDirection dir = ForgeDirection.getOrientation(mop.sideHit);
|
||||
if(b.isFlammable(world, mop.blockX, mop.blockY, mop.blockZ, dir.getOpposite())) {
|
||||
if(world.getBlock(mop.blockX + dir.offsetX, mop.blockY + dir.offsetY, mop.blockZ + dir.offsetZ).isAir(world, mop.blockX + dir.offsetX, mop.blockY + dir.offsetY, mop.blockZ + dir.offsetZ)) {
|
||||
world.setBlock(mop.blockX + dir.offsetX, mop.blockY + dir.offsetY, mop.blockZ + dir.offsetZ, Blocks.fire);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
EntityFireLingering fire = new EntityFireLingering(beam.worldObj).setArea(2, 1).setDuration(100).setType(EntityFireLingering.TYPE_DIESEL);
|
||||
fire.setPosition(mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord);
|
||||
beam.worldObj.spawnEntityInWorld(fire);
|
||||
}
|
||||
};
|
||||
|
||||
public static void init() {
|
||||
|
||||
energy_tesla = new BulletConfig().setItem(EnumAmmo.CAPACITOR).setSpread(0.0F).setLife(5).setRenderRotations(false).setDoesPenetrate(true)
|
||||
energy_tesla = new BulletConfig().setItem(EnumAmmo.CAPACITOR).setupDamageClass(DamageClass.ELECTRIC).setBeam().setSpread(0.0F).setLife(5).setRenderRotations(false).setDoesPenetrate(true)
|
||||
.setOnBeamImpact(LAMBDA_LIGHTNING_HIT);
|
||||
energy_tesla_overcharge = new BulletConfig().setItem(EnumAmmo.CAPACITOR_OVERCHARGE).setSpread(0.0F).setLife(5).setRenderRotations(false).setDoesPenetrate(true)
|
||||
energy_tesla_overcharge = new BulletConfig().setItem(EnumAmmo.CAPACITOR_OVERCHARGE).setupDamageClass(DamageClass.ELECTRIC).setBeam().setSpread(0.0F).setLife(5).setRenderRotations(false).setDoesPenetrate(true)
|
||||
.setDamage(1.5F).setOnBeamImpact(LAMBDA_LIGHTNING_HIT);
|
||||
energy_tesla_blacklightning = new BulletConfig().setItem(EnumAmmo.CAPACITOR_BLACKLIGHTNING).setSpread(0.0F).setLife(5).setRenderRotations(false).setDoesPenetrate(true)
|
||||
.setDamage(5F).setOnBeamImpact(LAMBDA_LIGHTNING_HIT);
|
||||
|
||||
energy_las = new BulletConfig().setItem(EnumAmmo.CAPACITOR).setSpread(0.0F).setLife(5).setRenderRotations(false).setOnBeamImpact(BulletConfig.LAMBDA_STANDARD_BEAM_HIT);
|
||||
energy_las_overcharge = new BulletConfig().setItem(EnumAmmo.CAPACITOR_OVERCHARGE).setSpread(0.0F).setLife(5).setRenderRotations(false).setDoesPenetrate(true).setOnBeamImpact(BulletConfig.LAMBDA_STANDARD_BEAM_HIT);
|
||||
energy_las_blacklightning = new BulletConfig().setItem(EnumAmmo.CAPACITOR_BLACKLIGHTNING).setSpread(0.0F).setLife(5).setRenderRotations(false).setDoesPenetrate(true).setOnBeamImpact(BulletConfig.LAMBDA_STANDARD_BEAM_HIT);
|
||||
energy_las = new BulletConfig().setItem(EnumAmmo.CAPACITOR).setupDamageClass(DamageClass.LASER).setBeam().setSpread(0.0F).setLife(5).setRenderRotations(false).setOnBeamImpact(BulletConfig.LAMBDA_STANDARD_BEAM_HIT);
|
||||
energy_las_overcharge = new BulletConfig().setItem(EnumAmmo.CAPACITOR_OVERCHARGE).setupDamageClass(DamageClass.LASER).setBeam().setSpread(0.0F).setLife(5).setRenderRotations(false).setDoesPenetrate(true).setOnBeamImpact(BulletConfig.LAMBDA_STANDARD_BEAM_HIT);
|
||||
energy_las_ir = new BulletConfig().setItem(EnumAmmo.CAPACITOR_IR).setupDamageClass(DamageClass.FIRE).setBeam().setSpread(0.0F).setLife(5).setRenderRotations(false).setOnBeamImpact(LAMBDA_IR_HIT);
|
||||
|
||||
ModItems.gun_tesla_cannon = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(2_000).draw(10).inspect(33).reloadSequential(true).crosshair(Crosshair.CIRCLE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(15F).delay(20).reload(44).jam(19).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineBelt().addConfigs(energy_tesla, energy_tesla_overcharge, energy_tesla_blacklightning))
|
||||
.dmg(35F).delay(20).reload(44).jam(19).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineBelt().addConfigs(energy_tesla, energy_tesla_overcharge))
|
||||
.offset(0.75, 0, -0.375)
|
||||
.setupBeamFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_TESLA_ANIMS).orchestra(Orchestras.ORCHESTRA_TESLA)
|
||||
).setUnlocalizedName("gun_tesla_cannon");
|
||||
@ -113,10 +144,10 @@ public class XFactoryEnergy {
|
||||
ModItems.gun_lasrifle = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(2_000).draw(10).inspect(26).reloadSequential(true).crosshair(Crosshair.CIRCLE).scopeTexture(scope_luna)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(15F).delay(8).reload(44).jam(36).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 24).addConfigs(energy_las, energy_las_overcharge, energy_las_blacklightning))
|
||||
.dmg(50F).delay(8).reload(44).jam(36).sound("hbm:weapon.fire.laser", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 24).addConfigs(energy_las, energy_las_overcharge, energy_las_ir))
|
||||
.offset(0.75, -0.0625 * 1.5, -0.1875)
|
||||
.setupBeamFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_LASRIFLE).orchestra(Orchestras.ORCHESTRA_LASRIFLE)
|
||||
).setUnlocalizedName("gun_lasrifle");
|
||||
|
||||
@ -26,6 +26,7 @@ import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.BusAnimationKeyframe.IType;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
import com.hbm.util.DamageResistanceHandler.DamageClass;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.Entity;
|
||||
@ -43,7 +44,16 @@ public class XFactoryFlamer {
|
||||
public static BulletConfig flame_gas;
|
||||
public static BulletConfig flame_napalm;
|
||||
public static BulletConfig flame_balefire;
|
||||
public static BulletConfig flame_digamma;
|
||||
|
||||
public static BulletConfig flame_topaz_diesel;
|
||||
public static BulletConfig flame_topaz_gas;
|
||||
public static BulletConfig flame_topaz_napalm;
|
||||
public static BulletConfig flame_topaz_balefire;
|
||||
|
||||
public static BulletConfig flame_daybreaker_diesel;
|
||||
public static BulletConfig flame_daybreaker_gas;
|
||||
public static BulletConfig flame_daybreaker_napalm;
|
||||
public static BulletConfig flame_daybreaker_balefire;
|
||||
|
||||
public static Consumer<Entity> LAMBDA_FIRE = (bullet) -> {
|
||||
if(bullet.worldObj.isRemote && MainRegistry.proxy.me().getDistanceToEntity(bullet) < 100) FlameCreator.composeEffectClient(bullet.worldObj, bullet.posX, bullet.posY - 0.125, bullet.posZ, FlameCreator.META_FIRE);
|
||||
@ -98,21 +108,59 @@ public class XFactoryFlamer {
|
||||
}
|
||||
|
||||
public static void init() {
|
||||
flame_diesel = new BulletConfig().setItem(EnumAmmo.FLAME_DIESEL).setLife(100).setVel(1F).setGrav(0.02D).setReloadCount(300).setOnUpdate(LAMBDA_FIRE).setOnRicochet(LAMBDA_LINGER_DIESEL);
|
||||
flame_gas = new BulletConfig().setItem(EnumAmmo.FLAME_GAS).setLife(10).setSpread(0.05F).setVel(1F).setGrav(0.0D).setReloadCount(300).setOnUpdate(LAMBDA_FIRE).setOnRicochet(LAMBDA_LINGER_GAS);
|
||||
flame_napalm = new BulletConfig().setItem(EnumAmmo.FLAME_NAPALM).setLife(200).setVel(1F).setGrav(0.02D).setReloadCount(300).setOnUpdate(LAMBDA_FIRE).setOnRicochet(LAMBDA_LINGER_NAPALM);
|
||||
flame_balefire = new BulletConfig().setItem(EnumAmmo.FLAME_BALEFIRE).setLife(200).setVel(1F).setGrav(0.02D).setReloadCount(300).setOnUpdate(LAMBDA_BALEFIRE).setOnRicochet(LAMBDA_LINGER_BALEFIRE);
|
||||
flame_diesel = new BulletConfig().setItem(EnumAmmo.FLAME_DIESEL).setupDamageClass(DamageClass.FIRE).setLife(100).setVel(1F).setGrav(0.02D).setReloadCount(500).setSelfDamageDelay(20).setKnockback(0F)
|
||||
.setOnUpdate(LAMBDA_FIRE).setOnRicochet(LAMBDA_LINGER_DIESEL);
|
||||
flame_gas = new BulletConfig().setItem(EnumAmmo.FLAME_GAS).setupDamageClass(DamageClass.FIRE).setLife(10).setSpread(0.05F).setVel(1F).setGrav(0.0D).setReloadCount(500).setSelfDamageDelay(20).setKnockback(0F)
|
||||
.setOnUpdate(LAMBDA_FIRE).setOnRicochet(LAMBDA_LINGER_GAS);
|
||||
flame_napalm = new BulletConfig().setItem(EnumAmmo.FLAME_NAPALM).setupDamageClass(DamageClass.FIRE).setLife(200).setVel(1F).setGrav(0.02D).setReloadCount(500).setSelfDamageDelay(20).setKnockback(0F)
|
||||
.setOnUpdate(LAMBDA_FIRE).setOnRicochet(LAMBDA_LINGER_NAPALM);
|
||||
flame_balefire = new BulletConfig().setItem(EnumAmmo.FLAME_BALEFIRE).setupDamageClass(DamageClass.FIRE).setLife(200).setVel(1F).setGrav(0.02D).setReloadCount(500).setSelfDamageDelay(20).setKnockback(0F)
|
||||
.setOnUpdate(LAMBDA_BALEFIRE).setOnRicochet(LAMBDA_LINGER_BALEFIRE);
|
||||
|
||||
flame_topaz_diesel = flame_diesel .clone().setProjectiles(2).setSpread(0.05F).setLife(60).setGrav(0.0D);
|
||||
flame_topaz_gas = flame_gas .clone().setProjectiles(2).setSpread(0.05F);
|
||||
flame_topaz_napalm = flame_napalm .clone().setProjectiles(2).setSpread(0.05F).setLife(60).setGrav(0.0D);
|
||||
flame_topaz_balefire = flame_balefire .clone().setProjectiles(2).setSpread(0.05F).setLife(60).setGrav(0.0D);
|
||||
|
||||
flame_daybreaker_diesel = flame_diesel.clone().setLife(200).setVel(2F).setGrav(0.035D)
|
||||
.setOnImpact((bullet, mop) -> { Lego.standardExplode(bullet, mop, 5F); spawnFire(bullet, mop, 6F, 2F, 200, EntityFireLingering.TYPE_DIESEL); bullet.setDead(); });
|
||||
flame_daybreaker_gas = flame_gas.clone().setLife(200).setVel(2F).setGrav(0.035D)
|
||||
.setOnImpact((bullet, mop) -> { Lego.standardExplode(bullet, mop, 5F); bullet.setDead(); });
|
||||
flame_daybreaker_napalm = flame_napalm.clone().setLife(200).setVel(2F).setGrav(0.035D)
|
||||
.setOnImpact((bullet, mop) -> { Lego.standardExplode(bullet, mop, 7.5F); spawnFire(bullet, mop, 6F, 2F, 300, EntityFireLingering.TYPE_DIESEL); bullet.setDead(); });
|
||||
flame_daybreaker_balefire = flame_balefire.clone().setLife(200).setVel(2F).setGrav(0.035D)
|
||||
.setOnImpact((bullet, mop) -> { Lego.standardExplode(bullet, mop, 5F); spawnFire(bullet, mop, 7.5F, 2.5F, 400, EntityFireLingering.TYPE_BALEFIRE); bullet.setDead(); });
|
||||
|
||||
ModItems.gun_flamer = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(20_000).draw(10).inspect(17).crosshair(Crosshair.L_CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.dura(20_000).draw(10).inspect(17).crosshair(Crosshair.L_CIRCLE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(10F).delay(1).auto(true).reload(90).jam(17)
|
||||
.dmg(1F).delay(1).auto(true).reload(90).jam(17)
|
||||
.mag(new MagazineFullReload(0, 300).addConfigs(flame_diesel, flame_gas, flame_napalm, flame_balefire))
|
||||
.offset(0.75, -0.0625, -0.25D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardFire())
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_FLAMER_ANIMS).orchestra(Orchestras.ORCHESTRA_FLAMER)
|
||||
).setUnlocalizedName("gun_flamer");
|
||||
ModItems.gun_flamer_topaz = new ItemGunBaseNT(WeaponQuality.B_SIDE, new GunConfig()
|
||||
.dura(20_000).draw(10).inspect(17).crosshair(Crosshair.L_CIRCLE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(1.5F).delay(1).auto(true).reload(90).jam(17)
|
||||
.mag(new MagazineFullReload(0, 500).addConfigs(flame_topaz_diesel, flame_topaz_gas, flame_topaz_napalm, flame_topaz_balefire))
|
||||
.offset(0.75, -0.0625, -0.25D)
|
||||
.setupStandardFire())
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_FLAMER_ANIMS).orchestra(Orchestras.ORCHESTRA_FLAMER)
|
||||
).setUnlocalizedName("gun_flamer_topaz");
|
||||
ModItems.gun_flamer_daybreaker = new ItemGunBaseNT(WeaponQuality.LEGENDARY, new GunConfig()
|
||||
.dura(20_000).draw(10).inspect(17).crosshair(Crosshair.L_CIRCLE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(25F).delay(10).auto(true).reload(90).jam(17).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 50).addConfigs(flame_daybreaker_diesel, flame_daybreaker_gas, flame_daybreaker_napalm, flame_daybreaker_balefire))
|
||||
.offset(0.75, -0.0625, -0.25D)
|
||||
.setupStandardFire())
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_FLAMER_ANIMS).orchestra(Orchestras.ORCHESTRA_FLAMER_DAYBREAKER)
|
||||
).setUnlocalizedName("gun_flamer_daybreaker");
|
||||
|
||||
ModItems.gun_chemthrower = new ItemGunChemthrower(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(90_000).draw(10).inspect(17).crosshair(Crosshair.L_CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
|
||||
@ -0,0 +1,149 @@
|
||||
package com.hbm.items.weapon.sedna.factory;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.function.BiConsumer;
|
||||
import java.util.function.BiFunction;
|
||||
import java.util.function.Consumer;
|
||||
|
||||
import com.hbm.entity.effect.EntityNukeTorex;
|
||||
import com.hbm.entity.logic.EntityNukeExplosionMK5;
|
||||
import com.hbm.entity.projectile.EntityBulletBaseMK4;
|
||||
import com.hbm.entity.projectile.EntityBulletBeamBase;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.weapon.sedna.BulletConfig;
|
||||
import com.hbm.items.weapon.sedna.Crosshair;
|
||||
import com.hbm.items.weapon.sedna.GunConfig;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT;
|
||||
import com.hbm.items.weapon.sedna.Receiver;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.GunState;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.LambdaContext;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.WeaponQuality;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmoSecret;
|
||||
import com.hbm.items.weapon.sedna.mags.MagazineSingleReload;
|
||||
import com.hbm.packet.PacketDispatcher;
|
||||
import com.hbm.packet.toclient.AuxParticlePacketNT;
|
||||
import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.BusAnimationKeyframe.IType;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
import com.hbm.util.ContaminationUtil;
|
||||
import com.hbm.util.EntityDamageUtil;
|
||||
import com.hbm.util.Vec3NT;
|
||||
import com.hbm.util.ContaminationUtil.ContaminationType;
|
||||
import com.hbm.util.ContaminationUtil.HazardType;
|
||||
import com.hbm.util.DamageResistanceHandler.DamageClass;
|
||||
|
||||
import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
|
||||
public class XFactoryFolly {
|
||||
|
||||
public static BulletConfig folly_sm;
|
||||
public static BulletConfig folly_nuke;
|
||||
|
||||
public static Consumer<Entity> LAMBDA_SM_UPDATE = (entity) -> {
|
||||
if(entity.worldObj.isRemote) return;
|
||||
EntityBulletBeamBase beam = (EntityBulletBeamBase) entity;
|
||||
Vec3NT dir = new Vec3NT(beam.headingX, beam.headingY, beam.headingZ).normalizeSelf();
|
||||
|
||||
if(beam.ticksExisted < 50) {
|
||||
double spacing = 10;
|
||||
double dist = beam.ticksExisted * spacing;
|
||||
NBTTagCompound data = new NBTTagCompound();
|
||||
data.setString("type", "plasmablast");
|
||||
data.setFloat("r", 0.75F);
|
||||
data.setFloat("g", 0.75F);
|
||||
data.setFloat("b", 0.75F);
|
||||
data.setFloat("pitch", (float) beam.rotationPitch + 90);
|
||||
data.setFloat("yaw", (float) -beam.rotationYaw);
|
||||
data.setFloat("scale", 2F + beam.ticksExisted / (float)(beam.beamLength / spacing) * 3F);
|
||||
PacketDispatcher.wrapper.sendToAllAround(new AuxParticlePacketNT(data, beam.posX + dir.xCoord * dist, beam.posY + dir.yCoord * dist, beam.posZ + dir.zCoord * dist), new TargetPoint(beam.dimension, beam.posX, beam.posY, beam.posZ, 250));
|
||||
}
|
||||
|
||||
if(entity.ticksExisted != 2) return;
|
||||
|
||||
if(beam.thrower != null) ContaminationUtil.contaminate(beam.thrower, HazardType.RADIATION, ContaminationType.CREATIVE, 150F);
|
||||
|
||||
List<Entity> entities = beam.worldObj.getEntitiesWithinAABBExcludingEntity(beam, beam.boundingBox.addCoord(beam.headingX, beam.headingY, beam.headingZ).expand(1.0D, 1.0D, 1.0D));
|
||||
|
||||
for(int i = 1; i < beam.beamLength; i += 2) {
|
||||
int x = (int) Math.floor(beam.posX + dir.xCoord * i);
|
||||
int y = (int) Math.floor(beam.posY + dir.yCoord * i);
|
||||
int z = (int) Math.floor(beam.posZ + dir.zCoord * i);
|
||||
|
||||
for(int ix = x - 1; ix <= x + 1; ix++) for(int iy = y - 1; iy <= y + 1; iy++) for(int iz = z - 1; iz <= z + 1; iz++) {
|
||||
if(iy > 0 && iy < 256) beam.worldObj.setBlock(ix, iy, iz, Blocks.air);
|
||||
AxisAlignedBB aabb = AxisAlignedBB.getBoundingBox(ix - 1, iy - 1, iz - 1, ix + 2, iy + 2, iz + 2);
|
||||
for(Entity e : entities) if(e != beam.thrower && e.boundingBox.intersectsWith(aabb)) EntityDamageUtil.attackEntityFromIgnoreIFrame(e, beam.config.getDamage(beam, beam.thrower, beam.config.dmgClass), beam.damage);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_NUKE_IMPACT = (bullet, mop) -> {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 2) return;
|
||||
if(bullet.isDead) return;
|
||||
bullet.setDead();
|
||||
bullet.worldObj.spawnEntityInWorld(EntityNukeExplosionMK5.statFac(bullet.worldObj, 100, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord));
|
||||
EntityNukeTorex.statFac(bullet.worldObj, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, 100);
|
||||
};
|
||||
|
||||
public static void init() {
|
||||
|
||||
folly_sm = new BulletConfig().setItem(EnumAmmoSecret.FOLLY_SM).setupDamageClass(DamageClass.SUBATOMIC).setBeam().setLife(100).setVel(2F).setGrav(0.015D).setRenderRotations(false).setSpectral(true).setDoesPenetrate(true)
|
||||
.setOnUpdate(LAMBDA_SM_UPDATE);
|
||||
folly_nuke = new BulletConfig().setItem(EnumAmmoSecret.FOLLY_NUKE).setChunkloading().setLife(600).setVel(4F).setGrav(0.015D)
|
||||
.setOnImpact(LAMBDA_NUKE_IMPACT);
|
||||
|
||||
ModItems.gun_folly = new ItemGunBaseNT(WeaponQuality.SECRET, new GunConfig()
|
||||
.dura(0).draw(40).crosshair(Crosshair.NONE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(1_000F).delay(26).dryfire(false).reload(160).jam(0).sound("hbm:weapon.fire.loudestNoiseOnEarth", 100.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 1).addConfigs(folly_sm, folly_nuke))
|
||||
.offset(0.75, -0.0625, -0.1875D)
|
||||
.canFire(LAMBDA_CAN_FIRE).fire(LAMBDA_FIRE).recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration().pt(LAMBDA_TOGGLE_AIM)
|
||||
.anim(LAMBDA_FOLLY_ANIMS).orchestra(Orchestras.ORCHESTRA_FOLLY)
|
||||
).setUnlocalizedName("gun_folly");
|
||||
}
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> LAMBDA_TOGGLE_AIM = (stack, ctx) -> {
|
||||
if(ItemGunBaseNT.getState(stack, ctx.configIndex) == GunState.IDLE) {
|
||||
boolean wasAiming = ItemGunBaseNT.getIsAiming(stack);
|
||||
ItemGunBaseNT.setIsAiming(stack, !wasAiming);
|
||||
if(!wasAiming) ItemGunBaseNT.playAnimation(ctx.getPlayer(), stack, AnimType.SPINUP, ctx.configIndex);
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> LAMBDA_FIRE = (stack, ctx) -> {
|
||||
Lego.doStandardFire(stack, ctx, AnimType.CYCLE, false);
|
||||
};
|
||||
|
||||
public static BiFunction<ItemStack, LambdaContext, Boolean> LAMBDA_CAN_FIRE = (stack, ctx) -> {
|
||||
if(!ItemGunBaseNT.getIsAiming(stack)) return false;
|
||||
if(ItemGunBaseNT.getLastAnim(stack, ctx.configIndex) != AnimType.SPINUP) return false;
|
||||
if(ItemGunBaseNT.getAnimTimer(stack, ctx.configIndex) < 100) return false;
|
||||
return ctx.config.getReceivers(stack)[0].getMagazine(stack).getAmount(stack, ctx.inventory) > 0;
|
||||
};
|
||||
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_FOLLY_ANIMS = (stack, type) -> {
|
||||
switch(type) {
|
||||
case EQUIP: return new BusAnimation()
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(-60, 0, 0, 0).addPos(5, 0, 0, 1500, IType.SIN_DOWN).addPos(0, 0, 0, 500, IType.SIN_FULL));
|
||||
case CYCLE: return new BusAnimation()
|
||||
.addBus("RECOIL", new BusAnimationSequence().addPos(0, 0, -4.5, 50).addPos(0, 0, -4.5, 500).addPos(0, 0, 0, 500, IType.SIN_UP))
|
||||
.addBus("LOAD", new BusAnimationSequence().addPos(0, 0, 0, 50).addPos(-25, 0, 0, 250, IType.SIN_DOWN).addPos(0, 0, 0, 1000, IType.SIN_FULL));
|
||||
case RELOAD: return new BusAnimation()
|
||||
.addBus("LOAD", new BusAnimationSequence().addPos(60, 0, 0, 1000, IType.SIN_FULL).addPos(60, 0, 0, 6000).addPos(0, 0, 0, 1000, IType.SIN_FULL))
|
||||
.addBus("SCREW", new BusAnimationSequence().addPos(0, 0, 0, 1000).addPos(0, 0, -135, 1000, IType.SIN_FULL).addPos(0, 0, -135, 4000).addPos(0, 0, 0, 1000, IType.SIN_FULL))
|
||||
.addBus("BREECH", new BusAnimationSequence().addPos(0, 0, 0, 1000).addPos(0, 0, -0.5, 1000, IType.SIN_FULL).addPos(0, -4, -0.5, 1000, IType.SIN_FULL).addPos(0, -4, -0.5, 2000).addPos(0, 0, -0.5, 1000, IType.SIN_FULL).addPos(0, 0, 0, 1000, IType.SIN_FULL))
|
||||
.addBus("SHELL", new BusAnimationSequence().addPos(0, -4, -4.5, 0).addPos(0, -4, -4.5, 3000).addPos(0, 0, -4.5, 1000, IType.SIN_FULL).addPos(0, 0, 0, 500, IType.SIN_UP));
|
||||
}
|
||||
|
||||
return null;
|
||||
};
|
||||
}
|
||||
@ -30,8 +30,11 @@ import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.BusAnimationKeyframe.IType;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
import com.hbm.util.EntityDamageUtil;
|
||||
import com.hbm.util.DamageResistanceHandler.DamageClass;
|
||||
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@ -82,7 +85,13 @@ public class XFactoryRocket {
|
||||
};
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_STANDARD_EXPLODE_HEAT = (bullet, mop) -> {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 3) return;
|
||||
Lego.standardExplode(bullet, mop, 2.5F); bullet.setDead();
|
||||
Lego.standardExplode(bullet, mop, 3.5F); bullet.setDead();
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && mop.entityHit instanceof EntityLivingBase) {
|
||||
EntityLivingBase living = (EntityLivingBase) mop.entityHit;
|
||||
EntityDamageUtil.attackEntityFromNT(living, bullet.config.getDamage(bullet, bullet.getThrower(), DamageClass.EXPLOSIVE), bullet.damage * 3F, true, true, 0.5F, 5F, 0.2F);
|
||||
} else if(mop.typeOfHit == mop.typeOfHit.ENTITY) {
|
||||
mop.entityHit.attackEntityFrom(bullet.config.getDamage(bullet, bullet.getThrower(), DamageClass.EXPLOSIVE), bullet.damage * 3F);
|
||||
}
|
||||
};
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_STANDARD_EXPLODE_DEMO = (bullet, mop) -> {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 3) return;
|
||||
@ -96,10 +105,17 @@ public class XFactoryRocket {
|
||||
bullet.setDead();
|
||||
};
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_STANDARD_EXPLODE_INC = (bullet, mop) -> {
|
||||
spawnFire(bullet, mop, false, 300);
|
||||
};
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_STANDARD_EXPLODE_PHOSPHORUS = (bullet, mop) -> {
|
||||
spawnFire(bullet, mop, true, 600);
|
||||
};
|
||||
|
||||
public static void spawnFire(EntityBulletBaseMK4 bullet, MovingObjectPosition mop, boolean phosphorus, int duration) {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 3) return;
|
||||
World world = bullet.worldObj;
|
||||
Lego.standardExplode(bullet, mop, 3F);
|
||||
EntityFireLingering fire = new EntityFireLingering(world).setArea(6, 2).setDuration(300).setType(EntityFireLingering.TYPE_DIESEL);
|
||||
EntityFireLingering fire = new EntityFireLingering(world).setArea(6, 2).setDuration(duration).setType(phosphorus ? EntityFireLingering.TYPE_PHOSPHORUS : EntityFireLingering.TYPE_DIESEL);
|
||||
fire.setPosition(mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord);
|
||||
world.spawnEntityInWorld(fire);
|
||||
bullet.setDead();
|
||||
@ -118,7 +134,7 @@ public class XFactoryRocket {
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
public static BulletConfig makeRPZB(BulletConfig original) { return original.clone(); }
|
||||
public static BulletConfig makeQD(BulletConfig original) { return original.clone().setLife(400).setOnUpdate(LAMBDA_STEERING_ACCELERATE); }
|
||||
@ -127,14 +143,15 @@ public class XFactoryRocket {
|
||||
//this is starting to get messy but we need to put this crap *somewhere* and fragmenting it into a billion classes with two methods each just isn't gonna help
|
||||
public static void init() {
|
||||
|
||||
rocket_template = new BulletConfig[4];
|
||||
rocket_template = new BulletConfig[5];
|
||||
|
||||
BulletConfig baseRocket = new BulletConfig().setLife(300).setSelfDamageDelay(10).setVel(0F).setGrav(0D).setOnEntityHit(null).setOnRicochet(null).setOnUpdate(LAMBDA_STANDARD_ACCELERATE);
|
||||
|
||||
rocket_template[0] = baseRocket.clone().setItem(EnumAmmo.ROCKET_HE).setOnImpact(LAMBDA_STANDARD_EXPLODE);
|
||||
rocket_template[1] = baseRocket.clone().setItem(EnumAmmo.ROCKET_HEAT).setDamage(1.5F).setOnImpact(LAMBDA_STANDARD_EXPLODE_HEAT);
|
||||
rocket_template[2] = baseRocket.clone().setItem(EnumAmmo.ROCKET_DEMO).setDamage(0.5F).setOnImpact(LAMBDA_STANDARD_EXPLODE_DEMO);
|
||||
rocket_template[1] = baseRocket.clone().setItem(EnumAmmo.ROCKET_HEAT).setDamage(0.5F).setOnImpact(LAMBDA_STANDARD_EXPLODE_HEAT);
|
||||
rocket_template[2] = baseRocket.clone().setItem(EnumAmmo.ROCKET_DEMO).setDamage(0.75F).setOnImpact(LAMBDA_STANDARD_EXPLODE_DEMO);
|
||||
rocket_template[3] = baseRocket.clone().setItem(EnumAmmo.ROCKET_INC).setDamage(0.75F).setOnImpact(LAMBDA_STANDARD_EXPLODE_INC);
|
||||
rocket_template[4] = baseRocket.clone().setItem(EnumAmmo.ROCKET_PHOSPHORUS).setDamage(0.75F).setOnImpact(LAMBDA_STANDARD_EXPLODE_PHOSPHORUS);
|
||||
|
||||
rocket_rpzb = new BulletConfig[rocket_template.length];
|
||||
rocket_qd = new BulletConfig[rocket_template.length];
|
||||
@ -160,7 +177,7 @@ public class XFactoryRocket {
|
||||
ModItems.gun_stinger = new ItemGunStinger(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(300).draw(7).inspect(40).crosshair(Crosshair.L_BOX_OUTLINE)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(25F).delay(5).reload(50).jam(40).sound("hbm:weapon.rpgShoot", 1.0F, 1.0F)
|
||||
.dmg(35F).delay(5).reload(50).jam(40).sound("hbm:weapon.rpgShoot", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 1).addConfigs(rocket_rpzb))
|
||||
.offset(1, -0.0625 * 1.5, -0.1875D)
|
||||
.setupLockonFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -171,7 +188,7 @@ public class XFactoryRocket {
|
||||
ModItems.gun_quadro = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(400).draw(7).inspect(40).crosshair(Crosshair.L_CIRCUMFLEX).hideCrosshair(false)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(25F).delay(10).reload(55).jam(40).sound("hbm:weapon.rpgShoot", 1.0F, 1.0F)
|
||||
.dmg(40F).delay(10).reload(55).jam(40).sound("hbm:weapon.rpgShoot", 1.0F, 1.0F)
|
||||
.mag(new MagazineFullReload(0, 4).addConfigs(rocket_qd))
|
||||
.offset(1, -0.0625 * 1.5, -0.1875D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
@ -182,7 +199,7 @@ public class XFactoryRocket {
|
||||
ModItems.gun_missile_launcher = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(500).draw(20).inspect(40).crosshair(Crosshair.L_CIRCUMFLEX).hideCrosshair(false)
|
||||
.rec(new Receiver(0)
|
||||
.dmg(25F).delay(5).reload(48).jam(33).sound("hbm:weapon.rpgShoot", 1.0F, 1.0F)
|
||||
.dmg(50F).delay(5).reload(48).jam(33).sound("hbm:weapon.rpgShoot", 1.0F, 1.0F)
|
||||
.mag(new MagazineSingleReload(0, 1).addConfigs(rocket_ml))
|
||||
.offset(1, -0.0625 * 1.5, -0.1875D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
|
||||
@ -0,0 +1,48 @@
|
||||
package com.hbm.items.weapon.sedna.factory;
|
||||
|
||||
import com.hbm.explosion.vanillant.ExplosionVNT;
|
||||
import com.hbm.explosion.vanillant.standard.BlockAllocatorStandard;
|
||||
import com.hbm.explosion.vanillant.standard.BlockProcessorStandard;
|
||||
import com.hbm.explosion.vanillant.standard.EntityProcessorCrossSmooth;
|
||||
import com.hbm.explosion.vanillant.standard.ExplosionEffectWeapon;
|
||||
import com.hbm.explosion.vanillant.standard.PlayerProcessorStandard;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.ItemAmmoEnums.Ammo240Shell;
|
||||
import com.hbm.items.weapon.sedna.BulletConfig;
|
||||
import com.hbm.particle.SpentCasing;
|
||||
import com.hbm.particle.SpentCasing.CasingType;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class XFactoryTurret {
|
||||
|
||||
public static BulletConfig dgk_normal;
|
||||
|
||||
public static SpentCasing CASINNG240MM = new SpentCasing(CasingType.BOTTLENECK).setScale(7.5F).setBounceMotion(0.02F, 0.05F).setColor(SpentCasing.COLOR_CASE_BRASS).setupSmoke(1F, 0.5D, 60, 20);
|
||||
public static BulletConfig shell_normal;
|
||||
public static BulletConfig shell_explosive;
|
||||
public static BulletConfig shell_ap;
|
||||
public static BulletConfig shell_du;
|
||||
public static BulletConfig shell_w9;
|
||||
|
||||
public static void init() {
|
||||
dgk_normal = new BulletConfig().setItem(new ItemStack(ModItems.ammo_dgk));
|
||||
|
||||
shell_normal = new BulletConfig().setItem(ModItems.ammo_shell.stackFromEnum(Ammo240Shell.STOCK)).setDamage(1F).setCasing(CASINNG240MM.clone().register("240standard")).setOnImpact((bullet, mop) -> {
|
||||
Lego.standardExplode(bullet, mop, 10F); bullet.setDead();
|
||||
});
|
||||
shell_explosive = new BulletConfig().setItem(ModItems.ammo_shell.stackFromEnum(Ammo240Shell.EXPLOSIVE)).setDamage(1.5F).setCasing(CASINNG240MM.clone().register("240ext")).setOnImpact((bullet, mop) -> {
|
||||
ExplosionVNT vnt = new ExplosionVNT(bullet.worldObj, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, 10F);
|
||||
vnt.setBlockAllocator(new BlockAllocatorStandard());
|
||||
vnt.setBlockProcessor(new BlockProcessorStandard());
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(1, bullet.damage));
|
||||
vnt.setPlayerProcessor(new PlayerProcessorStandard());
|
||||
vnt.setSFX(new ExplosionEffectWeapon(10, 2.5F, 1F));
|
||||
vnt.explode();
|
||||
bullet.setDead();
|
||||
});
|
||||
shell_ap = new BulletConfig().setItem(ModItems.ammo_shell.stackFromEnum(Ammo240Shell.APFSDS_T)).setDamage(2F).setDoesPenetrate(true).setCasing(CASINNG240MM.clone().register("240w"));
|
||||
shell_du = new BulletConfig().setItem(ModItems.ammo_shell.stackFromEnum(Ammo240Shell.APFSDS_DU)).setDamage(2.5F).setDoesPenetrate(true).setDamageFalloutByPen(false).setCasing(CASINNG240MM.clone().register("240u"));
|
||||
shell_w9 = new BulletConfig().setItem(ModItems.ammo_shell.stackFromEnum(Ammo240Shell.W9)).setDamage(2.5F).setCasing(CASINNG240MM.clone().register("240n")).setOnImpact(XFactoryCatapult.LAMBDA_NUKE_STANDARD);
|
||||
}
|
||||
}
|
||||
@ -47,6 +47,7 @@ public class HUDComponentAmmoCounter implements IHUDComponent {
|
||||
@Override
|
||||
public void renderHUDComponent(Pre event, ElementType type, EntityPlayer player, ItemStack stack, int bottomOffset, int gunIndex) {
|
||||
|
||||
if(type != type.HOTBAR) return;
|
||||
ScaledResolution resolution = event.resolution;
|
||||
Minecraft mc = Minecraft.getMinecraft();
|
||||
|
||||
|
||||
@ -33,7 +33,8 @@ public class HUDComponentDurabilityBar implements IHUDComponent {
|
||||
|
||||
@Override
|
||||
public void renderHUDComponent(Pre event, ElementType type, EntityPlayer player, ItemStack stack, int bottomOffset, int gunIndex) {
|
||||
|
||||
|
||||
if(type != type.HOTBAR) return;
|
||||
ScaledResolution resolution = event.resolution;
|
||||
Minecraft mc = Minecraft.getMinecraft();
|
||||
|
||||
|
||||
@ -269,6 +269,7 @@ public class ClientProxy extends ServerProxy {
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMachineLPW2.class, new RenderLPW2());
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMachinePress.class, new RenderPress());
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMachineEPress.class, new RenderEPress());
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMachineAmmoPress.class, new RenderAmmoPress());
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMachineRadGen.class, new RenderRadGen());
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMachineRadarNT.class, new RenderRadar());
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMachineRadarLarge.class, new RenderRadarLarge());
|
||||
@ -531,72 +532,10 @@ public class ClientProxy extends ServerProxy {
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.chainsaw, new ItemRenderChainsaw());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.boltgun, new ItemRenderBoltgun());
|
||||
//guns
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_rpg, new ItemRenderRpg());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_karl, new ItemRenderRpg());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_skystinger, new ItemRenderStinger());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver, new ItemRenderWeaponFFColt(ResourceManager.ff_gun_bright, ResourceManager.ff_iron, ResourceManager.ff_wood));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_saturnite, new ItemRenderWeaponFFColt(ResourceManager.ff_saturnite, ResourceManager.ff_iron, ResourceManager.ff_wood));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_gold, new ItemRenderWeaponFFColt(ResourceManager.ff_gold, ResourceManager.ff_gold, ResourceManager.ff_gun_dark));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_schrabidium, new ItemRenderWeaponFFColt(ResourceManager.ff_schrabidium, ResourceManager.ff_schrabidium, ResourceManager.ff_gun_dark));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_cursed, new ItemRenderWeaponFFCursed());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_nightmare, new ItemRenderWeaponFFNightmare());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_nightmare2, new ItemRenderWeaponFFNightmareDark());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_proto, new ItemRenderFatMan());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_mirv, new ItemRenderMIRVLauncher());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_bf, new ItemRenderBFLauncher());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_xvl1456, new ItemRenderWeaponTau());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_zomg, new ItemRenderZOMG());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_osipr, new ItemRenderOSIPR());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_mp, new ItemRenderMP());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_inverted, new ItemRenderRevolverInverted());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_mp40, new ItemRenderMP40());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_emp, new ItemRenderEMPRay());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_immolator, new ItemRenderImmolator());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_cryolator, new ItemRenderCryolator());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_uboinik, new ItemRenderUboinik());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_jack, new ItemRenderOverkill());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_spark, new ItemRenderOverkill());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_hp, new ItemRenderOverkill());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_euthanasia, new ItemRenderOverkill());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_defabricator, new ItemRenderOverkill());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_lever_action, new ItemRenderWeaponFFMaresLeg(ResourceManager.ff_gun_bright, ResourceManager.ff_wood));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_bolt_action, new ItemRenderWeaponFFBolt(ResourceManager.rem700, ResourceManager.rem700_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_lever_action_dark, new ItemRenderWeaponFFMaresLeg(ResourceManager.ff_gun_normal, ResourceManager.ff_wood_red));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_bolt_action_green, new ItemRenderWeaponFFBolt(ResourceManager.rem700poly, ResourceManager.rem700poly_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_lever_action_sonata, new ItemRenderGunAnim());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_bolt_action_saturnite, new ItemRenderGunAnim());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_bolt_action_saturnite, new ItemRenderWeaponFFBolt(ResourceManager.rem700sat, ResourceManager.rem700sat_tex));
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_b92, new ItemRenderGunAnim());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_b93, new ItemRenderGunAnim());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_uzi_silencer, new ItemRenderUZI());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_uzi_saturnite, new ItemRenderUZI());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_uzi_saturnite_silencer, new ItemRenderUZI());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_calamity, new ItemRenderWeaponFFMG42());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_lacunae, new ItemRenderOverkill());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_folly, new ItemRenderOverkill());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_hk69, new ItemRenderWeaponObj());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_bio_revolver, new ItemRenderBioRevolver());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_deagle, new ItemRenderWeaponObj());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_supershotgun, new ItemRenderWeaponShotty());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_ks23, new ItemRenderWeaponKS23());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_flechette, new ItemRenderWeaponObj());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_vortex, new ItemRenderWeaponVortex());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_thompson, new ItemRenderWeaponThompson());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_bolter_digamma, new ItemRenderWeaponBolter());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_fireext, new ItemRenderFireExt());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_ar15, new ItemRenderWeaponAR15());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.detonator_laser, new ItemRenderDetonatorLaser());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_remington, new ItemRenderWeaponRemington());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_glass_cannon, new ItemRenderWeaponGlass());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_nopip, new ItemRenderWeaponNovac());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_pip, new ItemRenderWeaponLilMac());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_blackjack, new ItemRenderWeaponNovac());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_silver, new ItemRenderWeaponNovac());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_revolver_red, new ItemRenderWeaponNovac());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_lunatic_marksman, new ItemRenderLunaticSniper());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_benelli, new ItemRenderBenelli());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_uac_pistol, new ItemRenderUACPistol());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_cryocannon, new ItemRenderWeaponCryoCannon());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.detonator_laser, new ItemRenderDetonatorLaser());
|
||||
//multitool
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.multitool_dig, new ItemRenderMultitool());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.multitool_silk, new ItemRenderMultitool());
|
||||
@ -620,6 +559,7 @@ public class ClientProxy extends ServerProxy {
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityBullet.class, new RenderRocket());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityBulletBaseNT.class, new RenderBullet());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityBulletBaseMK4.class, new RenderBulletMK4());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityBulletBaseMK4CL.class, new RenderBulletMK4());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityBulletBeamBase.class, new RenderBeam());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityRainbow.class, new RenderRainbow());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityLaserBeam.class, new RenderBeam2());
|
||||
@ -635,6 +575,7 @@ public class ClientProxy extends ServerProxy {
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityDuchessGambit.class, new RenderBoxcar());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityBuilding.class, new RenderBoxcar());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityBomber.class, new RenderBomber());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityC130.class, new RenderC130());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityBurningFOEQ.class, new RenderFOEQ());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityFallingNuke.class, new RenderFallingNuke());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityMinerRocket.class, new RenderMinerRocket());
|
||||
@ -733,6 +674,7 @@ public class ClientProxy extends ServerProxy {
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityMissileDoomsdayRusted.class, new RenderMissileNuclear());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntitySoyuz.class, new RenderSoyuz());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntitySoyuzCapsule.class, new RenderSoyuzCapsule());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityParachuteCrate.class, new RenderParachuteCrate());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityMissileTaint.class, new RenderMissileTaint());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityMissileMicro.class, new RenderMissileTaint());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityMissileBHole.class, new RenderMissileTaint());
|
||||
@ -809,6 +751,7 @@ public class ClientProxy extends ServerProxy {
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityFBIDrone.class, new RenderDrone());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityPlasticBag.class, new RenderPlasticBag());
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityPigeon.class, new RenderPigeon(new ModelPigeon(), 0.3F));
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityDummy.class, new RenderDummy());
|
||||
//"particles"
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityBSmokeFX.class, new MultiCloudRenderer(new Item[] { ModItems.b_smoke1, ModItems.b_smoke2, ModItems.b_smoke3, ModItems.b_smoke4, ModItems.b_smoke5, ModItems.b_smoke6, ModItems.b_smoke7, ModItems.b_smoke8 }));
|
||||
RenderingRegistry.registerEntityRenderingHandler(EntityChlorineFX.class, new MultiCloudRenderer(new Item[] { ModItems.chlorine1, ModItems.chlorine2, ModItems.chlorine3, ModItems.chlorine4, ModItems.chlorine5, ModItems.chlorine6, ModItems.chlorine7, ModItems.chlorine8 }));
|
||||
@ -2036,21 +1979,14 @@ public class ClientProxy extends ServerProxy {
|
||||
}
|
||||
}
|
||||
|
||||
private HashMap<Integer, Long> vanished = new HashMap();
|
||||
|
||||
public void vanish(int ent) {
|
||||
vanished.put(ent, System.currentTimeMillis() + 2000);
|
||||
}
|
||||
private static HashMap<Integer, Long> vanished = new HashMap();
|
||||
public static void vanish(int ent) { vanished.put(ent, System.currentTimeMillis() + 2000); }
|
||||
public static void vanish(int ent, int duration) { vanished.put(ent, System.currentTimeMillis() + duration); }
|
||||
|
||||
@Override
|
||||
public boolean isVanished(Entity e) {
|
||||
|
||||
if(e == null)
|
||||
return false;
|
||||
|
||||
if(!this.vanished.containsKey(e.getEntityId()))
|
||||
return false;
|
||||
|
||||
if(e == null) return false;
|
||||
if(!this.vanished.containsKey(e.getEntityId())) return false;
|
||||
return this.vanished.get(e.getEntityId()) > System.currentTimeMillis();
|
||||
}
|
||||
|
||||
|
||||
@ -293,6 +293,7 @@ public class CraftingManager {
|
||||
addRecipeAuto(new ItemStack(ModBlocks.machine_funnel, 1), new Object[] { "S S", "SRS", " S ", 'S', STEEL.ingot(), 'R', REDSTONE.dust() });
|
||||
addRecipeAuto(new ItemStack(ModBlocks.machine_waste_drum, 1), new Object[] { "LRL", "BRB", "LRL", 'L', PB.ingot(), 'B', Blocks.iron_bars, 'R', ModItems.rod_quad_empty });
|
||||
addRecipeAuto(new ItemStack(ModBlocks.machine_press, 1), new Object[] { "IRI", "IPI", "IBI", 'I', IRON.ingot(), 'R', Blocks.furnace, 'B', IRON.block(), 'P', Blocks.piston });
|
||||
addRecipeAuto(new ItemStack(ModBlocks.machine_ammo_press, 1), new Object[] { "IPI", "C C", "SSS", 'I', IRON.ingot(), 'P', Blocks.piston, 'C', CU.ingot(), 'S', Blocks.stone });
|
||||
addRecipeAuto(new ItemStack(ModBlocks.machine_siren, 1), new Object[] { "SIS", "ICI", "SRS", 'S', STEEL.plate(), 'I', ANY_RUBBER.ingot(), 'C', DictFrame.fromOne(ModItems.circuit, EnumCircuitType.VACUUM_TUBE), 'R', REDSTONE.dust() });
|
||||
addRecipeAuto(new ItemStack(ModBlocks.machine_microwave, 1), new Object[] { "III", "SGM", "IDI", 'I', ModItems.plate_polymer, 'S', STEEL.plate(), 'G', KEY_ANYPANE, 'M', ModItems.magnetron, 'D', ModItems.motor });
|
||||
addRecipeAuto(new ItemStack(ModBlocks.machine_solar_boiler), new Object[] { "SHS", "DHD", "SHS", 'S', STEEL.ingot(), 'H', STEEL.shell(), 'D', KEY_BLACK });
|
||||
@ -482,16 +483,6 @@ public class CraftingManager {
|
||||
|
||||
public static void reg2() {
|
||||
|
||||
addRecipeAuto(new ItemStack(ModItems.stamp_357, 1), new Object[] { "RSR", "III", " C ", 'R', REDSTONE.dust(), 'S', ModItems.stamp_iron_flat, 'I', ModItems.plate_polymer, 'C', ModItems.casing_357 });
|
||||
addRecipeAuto(new ItemStack(ModItems.stamp_44, 1), new Object[] { "RSR", "III", " C ", 'R', REDSTONE.dust(), 'S', ModItems.stamp_iron_flat, 'I', ModItems.plate_polymer, 'C', ModItems.casing_44 });
|
||||
addRecipeAuto(new ItemStack(ModItems.stamp_9, 1), new Object[] { "RSR", "III", " C ", 'R', REDSTONE.dust(), 'S', ModItems.stamp_iron_flat, 'I', ModItems.plate_polymer, 'C', ModItems.casing_9 });
|
||||
addRecipeAuto(new ItemStack(ModItems.stamp_50, 1), new Object[] { "RSR", "III", " C ", 'R', REDSTONE.dust(), 'S', ModItems.stamp_iron_flat, 'I', ModItems.plate_polymer, 'C', ModItems.casing_50 });
|
||||
|
||||
addRecipeAuto(new ItemStack(ModItems.stamp_desh_357, 1), new Object[] { "RSR", "III", " C ", 'R', ModItems.ingot_dura_steel, 'S', ModItems.stamp_desh_flat, 'I', ModItems.ingot_saturnite, 'C', ModItems.casing_357 });
|
||||
addRecipeAuto(new ItemStack(ModItems.stamp_desh_44, 1), new Object[] { "RSR", "III", " C ", 'R', ModItems.ingot_dura_steel, 'S', ModItems.stamp_desh_flat, 'I', ModItems.ingot_saturnite, 'C', ModItems.casing_44 });
|
||||
addRecipeAuto(new ItemStack(ModItems.stamp_desh_9, 1), new Object[] { "RSR", "III", " C ", 'R', ModItems.ingot_dura_steel, 'S', ModItems.stamp_desh_flat, 'I', ModItems.ingot_saturnite, 'C', ModItems.casing_9 });
|
||||
addRecipeAuto(new ItemStack(ModItems.stamp_desh_50, 1), new Object[] { "RSR", "III", " C ", 'R', ModItems.ingot_dura_steel, 'S', ModItems.stamp_desh_flat, 'I', ModItems.ingot_saturnite, 'C', ModItems.casing_50 });
|
||||
|
||||
addRecipeAuto(new ItemStack(ModBlocks.sat_dock, 1), new Object[] { "SSS", "PCP", 'S', STEEL.ingot(), 'P', ANY_PLASTIC.ingot(), 'C', ModBlocks.crate_iron });
|
||||
addRecipeAuto(new ItemStack(ModBlocks.book_guide, 1), new Object[] { "IBI", "LBL", "IBI", 'B', Items.book, 'I', KEY_BLACK, 'L', KEY_BLUE });
|
||||
|
||||
@ -1060,7 +1051,7 @@ public class CraftingManager {
|
||||
|
||||
addRecipeAuto(new ItemStack(ModItems.book_of_), new Object[] { "BGB", "GAG", "BGB", 'B', ModItems.egg_balefire_shard, 'G', GOLD.ingot(), 'A', Items.book });
|
||||
}
|
||||
|
||||
|
||||
for(NTMMaterial mat : Mats.orderedList) {
|
||||
if(mat.autogen.contains(MaterialShapes.BOLT)) for(String name : mat.names) addRecipeAuto(new ItemStack(ModItems.bolt, 16, mat.id), new Object[] { "#", "#", '#', MaterialShapes.INGOT.prefixes[0] + name });
|
||||
}
|
||||
|
||||
@ -921,6 +921,9 @@ public class MainRegistry {
|
||||
MinecraftForge.EVENT_BUS.register(pollution);
|
||||
FMLCommonHandler.instance().bus().register(pollution);
|
||||
|
||||
DamageResistanceHandler dmgHandler = new DamageResistanceHandler();
|
||||
MinecraftForge.EVENT_BUS.register(dmgHandler);
|
||||
|
||||
if(event.getSide() == Side.CLIENT) {
|
||||
HbmKeybinds.register();
|
||||
HbmKeybinds keyHandler = new HbmKeybinds();
|
||||
@ -1454,6 +1457,47 @@ public class MainRegistry {
|
||||
ignoreMappings.add("hbm:item.powder_daffergon");
|
||||
ignoreMappings.add("hbm:item.powder_verticium");
|
||||
ignoreMappings.add("hbm:tile.ore_random");
|
||||
ignoreMappings.add("hbm:item.crate_caller");
|
||||
ignoreMappings.add("hbm:item.pellet_rtg_berkelium");
|
||||
ignoreMappings.add("hbm:item.folly_shell");
|
||||
ignoreMappings.add("hbm:item.folly_bullet");
|
||||
ignoreMappings.add("hbm:item.folly_bullet_nuclear");
|
||||
ignoreMappings.add("hbm:item.folly_bullet_du");
|
||||
ignoreMappings.add("hbm:item.ammo_folly");
|
||||
ignoreMappings.add("hbm:item.ammo_folly_nuclear");
|
||||
ignoreMappings.add("hbm:item.ammo_folly_du");
|
||||
ignoreMappings.add("hbm:item.clip_revolver_iron");
|
||||
ignoreMappings.add("hbm:item.clip_revolver");
|
||||
ignoreMappings.add("hbm:item.clip_revolver_gold");
|
||||
ignoreMappings.add("hbm:item.clip_revolver_lead");
|
||||
ignoreMappings.add("hbm:item.clip_revolver_schrabidium");
|
||||
ignoreMappings.add("hbm:item.clip_revolver_cursed");
|
||||
ignoreMappings.add("hbm:item.clip_revolver_nightmare");
|
||||
ignoreMappings.add("hbm:item.clip_revolver_nightmare2");
|
||||
ignoreMappings.add("hbm:item.clip_revolver_pip");
|
||||
ignoreMappings.add("hbm:item.clip_revolver_nopip");
|
||||
ignoreMappings.add("hbm:item.clip_rpg");
|
||||
ignoreMappings.add("hbm:item.clip_stinger");
|
||||
ignoreMappings.add("hbm:item.clip_fatman");
|
||||
ignoreMappings.add("hbm:item.clip_mirv");
|
||||
ignoreMappings.add("hbm:item.clip_bf");
|
||||
ignoreMappings.add("hbm:item.clip_mp40");
|
||||
ignoreMappings.add("hbm:item.clip_uzi");
|
||||
ignoreMappings.add("hbm:item.clip_uboinik");
|
||||
ignoreMappings.add("hbm:item.clip_lever_action");
|
||||
ignoreMappings.add("hbm:item.clip_bolt_action");
|
||||
ignoreMappings.add("hbm:item.clip_xvl1456");
|
||||
ignoreMappings.add("hbm:item.clip_osipr");
|
||||
ignoreMappings.add("hbm:item.clip_immolator");
|
||||
ignoreMappings.add("hbm:item.clip_cryolator");
|
||||
ignoreMappings.add("hbm:item.clip_mp");
|
||||
ignoreMappings.add("hbm:item.clip_emp");
|
||||
ignoreMappings.add("hbm:item.clip_jack");
|
||||
ignoreMappings.add("hbm:item.clip_spark");
|
||||
ignoreMappings.add("hbm:item.clip_hp");
|
||||
ignoreMappings.add("hbm:item.clip_euthanasia");
|
||||
ignoreMappings.add("hbm:item.clip_defabricator");
|
||||
ignoreMappings.add("hbm:item.ammo_folly_du");
|
||||
|
||||
/// REMAP ///
|
||||
remapItems.put("hbm:item.gadget_explosive8", ModItems.early_explosive_lenses);
|
||||
|
||||
@ -56,6 +56,10 @@ import com.hbm.util.ArmorRegistry.HazardClass;
|
||||
import com.hbm.wiaj.GuiWorldInAJar;
|
||||
import com.hbm.wiaj.cannery.CanneryBase;
|
||||
import com.hbm.wiaj.cannery.Jars;
|
||||
import com.hbm.util.ArmorRegistry;
|
||||
import com.hbm.util.ArmorUtil;
|
||||
import com.hbm.util.DamageResistanceHandler;
|
||||
import com.hbm.util.ArmorRegistry.HazardClass;
|
||||
import com.mojang.authlib.minecraft.MinecraftProfileTexture.Type;
|
||||
import cpw.mods.fml.client.FMLClientHandler;
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
@ -678,6 +682,9 @@ public class ModEventHandlerClient {
|
||||
ItemStack stack = event.itemStack;
|
||||
List<String> list = event.toolTip;
|
||||
|
||||
/// DAMAGE RESISTANCE ///
|
||||
DamageResistanceHandler.addInfo(stack, list);
|
||||
|
||||
/// HAZMAT INFO ///
|
||||
List<HazardClass> hazInfo = ArmorRegistry.hazardClasses.get(stack.getItem());
|
||||
|
||||
@ -1277,6 +1284,7 @@ public class ModEventHandlerClient {
|
||||
public static IIcon particleBase;
|
||||
public static IIcon particleLeaf;
|
||||
public static IIcon particleSplash;
|
||||
public static IIcon particleAshes;
|
||||
|
||||
@SubscribeEvent
|
||||
public void onTextureStitch(TextureStitchEvent.Pre event) {
|
||||
@ -1285,6 +1293,7 @@ public class ModEventHandlerClient {
|
||||
particleBase = event.map.registerIcon(RefStrings.MODID + ":particle/particle_base");
|
||||
particleLeaf = event.map.registerIcon(RefStrings.MODID + ":particle/dead_leaf");
|
||||
particleSplash = event.map.registerIcon(RefStrings.MODID + ":particle/particle_splash");
|
||||
particleAshes = event.map.registerIcon(RefStrings.MODID + ":particle/particle_ashes");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -507,7 +507,7 @@ public class ModEventHandlerRenderer {
|
||||
}
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
@SubscribeEvent(priority = EventPriority.HIGHEST)
|
||||
public void onRenderHUD(RenderGameOverlayEvent.Pre event) {
|
||||
|
||||
if(event.type == ElementType.HOTBAR && (ModEventHandlerClient.shakeTimestamp + ModEventHandlerClient.shakeDuration - System.currentTimeMillis()) > 0 && ClientConfig.NUKE_HUD_SHAKE.get()) {
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user