Merge remote-tracking branch 'refs/remotes/upstream/master' into Optimization
# Conflicts: # src/main/java/com/hbm/main/ModEventHandlerClient.java # src/main/java/com/hbm/main/ResourceManager.java # src/main/java/com/hbm/util/EntityDamageUtil.java
@ -6,6 +6,8 @@
|
||||
|
||||
[Official NTM Wiki](https://nucleartech.wiki/wiki/Main_Page)
|
||||
|
||||
[Bobcat's Blog (the blag)](https://hbmmods.github.io/), you can find lengthy yapping, upcoming features and some secrets here.
|
||||
|
||||
**This is for 1.7.10!** For 1.12, check out these projects:
|
||||
|
||||
* NTM Reloaded: https://github.com/TheOriginalGolem/Hbm-s-Nuclear-Tech-GIT/releases
|
||||
|
||||
@ -52,6 +52,8 @@
|
||||
* Reeds rendering into water can now be toggled with the RENDER_REEDS client config
|
||||
* This option is usually enabled by default, unless Angelica is installed
|
||||
* 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
|
||||
|
||||
## Fixed
|
||||
* The conveyor grabber should no longer skip over items when used in long lines
|
||||
@ -68,3 +70,5 @@
|
||||
* Fixed issue regarding mass storage filters when using GTNH-NEI
|
||||
* Fixed DFC emitters calculating their original 98% inefficiency twice when hitting another emitter or tungsten crate
|
||||
* 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
|
||||
|
||||
@ -49,7 +49,7 @@ credits=HbMinecraft,\
|
||||
\ Voxelstice (OpenComputers integration, turbine spinup),\
|
||||
\ BallOfEnergy1 (OpenComputers integration),\
|
||||
\ sdddddf80 (recipe configs, chinese localization, custom machine holograms),\
|
||||
\ Abel1502 (optimization, crate upgrade recipes, strand caster improvements),\
|
||||
\ Abel1502 (optimization, crate upgrade recipes, strand caster improvements, varous tweaks),\
|
||||
\ SuperCraftAlex (tooltips)\
|
||||
\ Ice-Arrow (research reactor tweaks),\
|
||||
\ 245tt (anvil GUI improvements),\
|
||||
|
||||
@ -135,7 +135,7 @@ public class BlockDynamicSlag extends BlockContainer {
|
||||
TileEntitySlag self = (TileEntitySlag) s;
|
||||
|
||||
/* Flow down */
|
||||
if(world.getBlock(x, y - 1, z).isReplaceable(world, x, y - 1, z)) {
|
||||
if(world.getBlock(x, y - 1, z).isReplaceable(world, x, y - 1, z) && y > 0) {
|
||||
world.setBlock(x, y - 1, z, ModBlocks.slag);
|
||||
TileEntitySlag tile = (TileEntitySlag) Compat.getTileStandard(world, x, y - 1, z);
|
||||
tile.mat = self.mat;
|
||||
|
||||
@ -120,7 +120,6 @@ public class WeaponRecipes {
|
||||
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_fatman, 1), new Object[] { "SSI", "IIM", "WPH", 'S', STEEL.plate(), 'I', STEEL.ingot(), 'W', AL.wireFine(), 'H', STEEL.shell(), 'P', Item.getItemFromBlock(Blocks.piston), 'M', 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 });
|
||||
@ -183,10 +182,6 @@ public class WeaponRecipes {
|
||||
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() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.gun_coilgun), new Object[] { "CCC", "SSM", " P", 'C', ModBlocks.capacitor_copper, 'S', BIGMT.plate(), 'M', ModItems.mechanism_special, 'P', ANY_PLASTIC.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.ammo_coilgun, 16, 0), new Object[] { " T ", "TST", " T ", 'T', W.ingot(), 'S', BIGMT.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.ammo_coilgun, 16, 1), new Object[] { " T ", "TST", " T ", 'T', FERRO.ingot(), 'S', BIGMT.ingot() });
|
||||
CraftingManager.addRecipeAuto(new ItemStack(ModItems.ammo_coilgun, 16, 2), new Object[] { " T ", "TST", " T ", 'T', RUBBER.ingot(), 'S', ANY_PLASTIC.ingot() });
|
||||
|
||||
//TODO: somehow add more variance, 4 gauge is still missing
|
||||
CraftingManager.addShapelessAuto(new ItemStack(ModItems.ammo_22lr, 16), new Object[] { ModItems.nitra_small });
|
||||
|
||||
@ -35,6 +35,8 @@ public class EntityBulletBeamBase extends Entity implements IEntityAdditionalSpa
|
||||
this.setSize(0.5F, 0.5F);
|
||||
}
|
||||
|
||||
public EntityLivingBase getThrower() { return this.thrower; }
|
||||
|
||||
public EntityBulletBeamBase(EntityLivingBase entity, BulletConfig config, float baseDamage, float angularInaccuracy, double sideOffset, double heightOffset, double frontOffset) {
|
||||
this(entity.worldObj);
|
||||
|
||||
@ -186,8 +188,12 @@ public class EntityBulletBeamBase extends Entity implements IEntityAdditionalSpa
|
||||
|
||||
@Override public void writeSpawnData(ByteBuf buf) {
|
||||
buf.writeDouble(beamLength);
|
||||
buf.writeFloat(rotationYaw);
|
||||
buf.writeFloat(rotationPitch);
|
||||
}
|
||||
@Override public void readSpawnData(ByteBuf buf) {
|
||||
this.beamLength = buf.readDouble();
|
||||
this.rotationYaw = buf.readFloat();
|
||||
this.rotationPitch = buf.readFloat();
|
||||
}
|
||||
}
|
||||
|
||||
@ -60,12 +60,12 @@ public class FT_Polluting extends FluidTrait {
|
||||
public void serializeJSON(JsonWriter writer) throws IOException {
|
||||
writer.name("release").beginObject();
|
||||
for(Entry<PollutionType, Float> entry : releaseMap.entrySet()) {
|
||||
writer.name(entry.toString()).value(entry.getValue());
|
||||
writer.name(entry.getKey().name()).value(entry.getValue());
|
||||
}
|
||||
writer.endObject();
|
||||
writer.name("burn").beginObject();
|
||||
for(Entry<PollutionType, Float> entry : burnMap.entrySet()) {
|
||||
writer.name(entry.toString()).value(entry.getValue());
|
||||
writer.name(entry.getKey().name()).value(entry.getValue());
|
||||
}
|
||||
writer.endObject();
|
||||
}
|
||||
|
||||
@ -19,6 +19,7 @@ import com.hbm.items.ItemEnums.EnumCasingType;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmo;
|
||||
|
||||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class AmmoPressRecipes extends SerializableRecipe {
|
||||
@ -36,6 +37,7 @@ public class AmmoPressRecipes extends SerializableRecipe {
|
||||
OreDictStack copper = new OreDictStack(CU.ingot());
|
||||
OreDictStack plastic = new OreDictStack(ANY_PLASTIC.ingot());
|
||||
OreDictStack uranium = new OreDictStack(U238.ingot());
|
||||
ComparableStack smokeful = new ComparableStack(Items.gunpowder);
|
||||
OreDictStack smokeless = new OreDictStack(ANY_SMOKELESS.dust());
|
||||
OreDictStack he = new OreDictStack(ANY_HIGHEXPLOSIVE.ingot());
|
||||
OreDictStack wp = new OreDictStack(P_WHITE.ingot());
|
||||
@ -46,7 +48,11 @@ public class AmmoPressRecipes extends SerializableRecipe {
|
||||
ComparableStack bpShell = new ComparableStack(ModItems.casing, 1, EnumCasingType.SHOTSHELL);
|
||||
ComparableStack pShell = new ComparableStack(ModItems.casing, 1, EnumCasingType.BUCKSHOT);
|
||||
ComparableStack sShell = new ComparableStack(ModItems.casing, 1, EnumCasingType.BUCKSHOT_ADVANCED);
|
||||
|
||||
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.M357_BP, 16),
|
||||
null, lead.copy(2), null,
|
||||
null, smokeful, null,
|
||||
null, cSmall, null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.M357_SP, 8),
|
||||
null, lead, null,
|
||||
null, smokeless, null,
|
||||
@ -67,7 +73,11 @@ public class AmmoPressRecipes extends SerializableRecipe {
|
||||
null, steel, null,
|
||||
null, smokeless.copy(3), null,
|
||||
null, cSmall, null));
|
||||
|
||||
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.M44_BP, 12),
|
||||
null, lead.copy(2), null,
|
||||
null, smokeful, null,
|
||||
null, cSmall, null));
|
||||
recipes.add(new AmmoPressRecipe(DictFrame.fromOne(ModItems.ammo_standard, EnumAmmo.M44_SP, 6),
|
||||
null, lead, null,
|
||||
null, smokeless, null,
|
||||
|
||||
@ -108,7 +108,6 @@ public class ItemPoolsLegacy {
|
||||
weighted(ModItems.gun_kit_2, 0, 1, 2, 3),
|
||||
weighted(ModItems.gun_rpg, 0, 1, 1, 4),
|
||||
weighted(ModItems.ammo_rocket, 0, 1, 4, 5),
|
||||
weighted(ModItems.gun_fatman, 0, 1, 1, 1),
|
||||
weighted(ModItems.ammo_nuke, AmmoFatman.SAFE.ordinal(), 1, 2, 1),
|
||||
weighted(ModItems.ammo_nuke, AmmoFatman.LOW.ordinal(), 1, 2, 1),
|
||||
weighted(ModItems.ammo_nuke, AmmoFatman.PUMPKIN.ordinal(), 1, 2, 1),
|
||||
@ -203,7 +202,6 @@ public class ItemPoolsLegacy {
|
||||
weighted(ModItems.billet_uranium_fuel, 0, 1, 1, 2),
|
||||
weighted(ModItems.ingot_uranium_fuel, 0, 1, 1, 2),
|
||||
weighted(ModItems.ammo_nuke, AmmoFatman.SAFE.ordinal(), 1, 2, 1),
|
||||
weighted(ModItems.gun_fatman, 0, 1, 1, 1),
|
||||
weighted(ModItems.bottle_nuka, 0, 1, 3, 6),
|
||||
weighted(ModItems.bottle_quantum, 0, 1, 1, 3),
|
||||
weighted(ModItems.stealth_boy, 0, 1, 1, 7),
|
||||
|
||||
@ -90,7 +90,6 @@ public class ItemPoolsSingle {
|
||||
weighted(ModItems.grenade_mirv, 0, 1, 1, 1),
|
||||
weighted(ModItems.powder_yellowcake, 0, 26, 42, 1),
|
||||
weighted(ModItems.ingot_u235, 0, 3, 6, 1),
|
||||
weighted(ModItems.gun_fatman, 0, 1, 1, 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),
|
||||
@ -104,7 +103,6 @@ public class ItemPoolsSingle {
|
||||
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_fatman, 0, 1, 1, 1),
|
||||
weighted(ModItems.gun_proto, 0, 1, 1, 1),
|
||||
weighted(ModItems.gun_b92, 0, 1, 1, 1),
|
||||
weighted(ModItems.ingot_combine_steel, 0, 16, 28, 1),
|
||||
|
||||
@ -1527,7 +1527,6 @@ public class ModItems {
|
||||
public static Item gun_calamity;
|
||||
public static Item gun_lacunae;
|
||||
public static Item gun_folly;
|
||||
public static Item gun_fatman;
|
||||
public static Item gun_proto;
|
||||
public static Item gun_mirv;
|
||||
public static Item gun_bf;
|
||||
@ -1552,7 +1551,6 @@ public class ModItems {
|
||||
public static Item gun_b92;
|
||||
public static Item gun_b92_ammo;
|
||||
public static Item gun_b93;
|
||||
public static Item gun_coilgun;
|
||||
public static Item gun_xvl1456;
|
||||
public static Item gun_xvl1456_ammo;
|
||||
public static Item gun_osipr;
|
||||
@ -1565,7 +1563,6 @@ public class ModItems {
|
||||
public static Item gun_cryolator_ammo;
|
||||
public static Item gun_fireext;
|
||||
public static Item gun_mp;
|
||||
public static Item gun_bolter;
|
||||
public static Item gun_bolter_digamma;
|
||||
public static Item gun_zomg;
|
||||
public static Item gun_super_shotgun;
|
||||
@ -1625,6 +1622,11 @@ public class ModItems {
|
||||
public static Item gun_tesla_cannon;
|
||||
public static Item gun_stg77;
|
||||
public static Item gun_tau;
|
||||
public static Item gun_fatman;
|
||||
public static Item gun_lasrifle;
|
||||
public static Item gun_coilgun;
|
||||
public static Item gun_hangman;
|
||||
public static Item gun_bolter;
|
||||
|
||||
public static Item ammo_standard;
|
||||
|
||||
@ -4078,7 +4080,6 @@ public class ModItems {
|
||||
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_fatman = new ItemGunBase(GunFatmanFactory.getFatmanConfig()).setUnlocalizedName("gun_fatman").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_fatman");
|
||||
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");
|
||||
@ -4103,7 +4104,6 @@ public class ModItems {
|
||||
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_coilgun = new ItemCoilgun(GunEnergyFactory.getCoilgunConfig()).setUnlocalizedName("gun_coilgun").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_coilgun");
|
||||
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_osipr_ammo = new Item().setUnlocalizedName("gun_osipr_ammo").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_osipr_ammo");
|
||||
@ -4116,7 +4116,6 @@ public class ModItems {
|
||||
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 = new ItemGunBase(Gun75BoltFactory.getBolterConfig()).setUnlocalizedName("gun_bolter").setCreativeTab(MainRegistry.weaponTab).setTextureName(RefStrings.MODID + ":gun_bolter");
|
||||
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");
|
||||
@ -6901,7 +6900,6 @@ public class ModItems {
|
||||
GameRegistry.registerItem(gun_rpg, gun_rpg.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_karl, gun_karl.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_hk69, gun_hk69.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_fatman, gun_fatman.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_proto, gun_proto.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_mirv, gun_mirv.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_bf, gun_bf.getUnlocalizedName());
|
||||
@ -6923,7 +6921,6 @@ public class ModItems {
|
||||
GameRegistry.registerItem(gun_bolt_action_green, gun_bolt_action_green.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_bolt_action_saturnite, gun_bolt_action_saturnite.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_mymy, gun_mymy.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_coilgun, gun_coilgun.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_xvl1456, gun_xvl1456.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_osipr, gun_osipr.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_immolator, gun_immolator.getUnlocalizedName());
|
||||
@ -6931,7 +6928,6 @@ public class ModItems {
|
||||
GameRegistry.registerItem(gun_cryocannon, gun_cryocannon.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_fireext, gun_fireext.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_mp, gun_mp.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_bolter, gun_bolter.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_bolter_digamma, gun_bolter_digamma.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_zomg, gun_zomg.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_emp, gun_emp.getUnlocalizedName());
|
||||
@ -6987,6 +6983,11 @@ public class ModItems {
|
||||
GameRegistry.registerItem(gun_tesla_cannon, gun_tesla_cannon.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_stg77, gun_stg77.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_tau, gun_tau.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_fatman, gun_fatman.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_lasrifle, gun_lasrifle.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_coilgun, gun_coilgun.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_hangman, gun_hangman.getUnlocalizedName());
|
||||
GameRegistry.registerItem(gun_bolter, gun_bolter.getUnlocalizedName());
|
||||
|
||||
GameRegistry.registerItem(ammo_standard, ammo_standard.getUnlocalizedName());
|
||||
|
||||
|
||||
@ -211,6 +211,31 @@ public class BulletConfig implements Cloneable {
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBeamBase, MovingObjectPosition> LAMBDA_STANDARD_BEAM_HIT = (bullet, mop) -> {
|
||||
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY) {
|
||||
Entity entity = mop.entityHit;
|
||||
|
||||
if(entity instanceof EntityLivingBase && ((EntityLivingBase) entity).getHealth() <= 0) return;
|
||||
|
||||
DamageSource damageCalc = bullet.config.getDamage(bullet, bullet.getThrower(), false);
|
||||
|
||||
if(!(entity instanceof EntityLivingBase)) {
|
||||
EntityDamageUtil.attackEntityFromIgnoreIFrame(entity, damageCalc, 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);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBeamBase, MovingObjectPosition> LAMBDA_BEAM_HIT = (beam, mop) -> {
|
||||
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY) {
|
||||
|
||||
@ -14,6 +14,7 @@ import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
/**
|
||||
* Despite how complicated the GunConfig looks, it actually only exists to hold together a bunch of fields. Everything else is infrastructure for getting and setting.
|
||||
@ -29,9 +30,11 @@ public class GunConfig {
|
||||
public static final String F_DURABILITY = "F_DURABILITY";
|
||||
public static final String I_DRAWDURATION = "I_DRAWDURATION";
|
||||
public static final String I_INSPECTDURATION = "I_INSPECTDURATION";
|
||||
public static final String I_INSPECTCANCEL = "I_INSPECTCANCEL";
|
||||
public static final String O_CROSSHAIR = "O_CROSSHAIR";
|
||||
public static final String B_HIDECROSSHAIR = "B_HIDECROSSHAIR";
|
||||
public static final String B_RELOADANIMATIONSEQUENTIAL = "B_RELOADANIMATIONSEQUENTIAL";
|
||||
public static final String O_SCOPETEXTURE = "O_SCOPETEXTURE";
|
||||
public static final String CON_SMOKE = "CON_SMOKE";
|
||||
public static final String CON_ORCHESTRA = "CON_ORCHESTRA";
|
||||
public static final String CON_ONPRESSPRIMARY = "CON_ONPRESSPRIMARY";
|
||||
@ -53,9 +56,11 @@ public class GunConfig {
|
||||
protected float durability_DNA;
|
||||
protected int drawDuration_DNA = 0;
|
||||
protected int inspectDuration_DNA = 0;
|
||||
protected boolean inspectCancel_DNA = true;
|
||||
protected Crosshair crosshair_DNA;
|
||||
protected boolean hideCrosshair_DNA = true;
|
||||
protected boolean reloadAnimationsSequential_DNA;
|
||||
protected ResourceLocation scopeTexture_DNA;
|
||||
/** Handles smoke clientside */
|
||||
protected BiConsumer<ItemStack, LambdaContext> smokeHandler_DNA;
|
||||
/** This piece only triggers during reloads, playing sounds depending on the reload's progress making reload sounds easier and synced to animations */
|
||||
@ -82,9 +87,11 @@ public class GunConfig {
|
||||
public float getDurability(ItemStack stack) { return WeaponUpgradeManager.eval(durability_DNA, stack, F_DURABILITY, this); }
|
||||
public int getDrawDuration(ItemStack stack) { return WeaponUpgradeManager.eval(drawDuration_DNA, stack, I_DRAWDURATION, this); }
|
||||
public int getInspectDuration(ItemStack stack) { return WeaponUpgradeManager.eval(inspectDuration_DNA, stack, I_INSPECTDURATION, this); }
|
||||
public boolean getInspectCancel(ItemStack stack) { return WeaponUpgradeManager.eval(inspectCancel_DNA, stack, I_INSPECTCANCEL, this); }
|
||||
public Crosshair getCrosshair(ItemStack stack) { return WeaponUpgradeManager.eval(crosshair_DNA, stack, O_CROSSHAIR, this); }
|
||||
public boolean getHideCrosshair(ItemStack stack) { return WeaponUpgradeManager.eval(hideCrosshair_DNA, stack, B_HIDECROSSHAIR, this); }
|
||||
public boolean getReloadAnimSequential(ItemStack stack) { return WeaponUpgradeManager.eval(reloadAnimationsSequential_DNA, stack, B_RELOADANIMATIONSEQUENTIAL, this); }
|
||||
public ResourceLocation getScopeTexture(ItemStack stack) { return WeaponUpgradeManager.eval(scopeTexture_DNA, stack, O_SCOPETEXTURE, this); }
|
||||
public BiConsumer<ItemStack, LambdaContext> getSmokeHandler(ItemStack stack) { return WeaponUpgradeManager.eval(smokeHandler_DNA, stack, CON_SMOKE, this); }
|
||||
public BiConsumer<ItemStack, LambdaContext> getOrchestra(ItemStack stack) { return WeaponUpgradeManager.eval(this.orchestra_DNA, stack, CON_ORCHESTRA, this); }
|
||||
|
||||
@ -105,13 +112,15 @@ public class GunConfig {
|
||||
|
||||
/* SETTERS */
|
||||
|
||||
public GunConfig rec(Receiver... receivers) { this.receivers_DNA = receivers; return this; }
|
||||
public GunConfig dura(float dura) { this.durability_DNA = dura; return this; }
|
||||
public GunConfig draw(int draw) { this.drawDuration_DNA = draw; return this; }
|
||||
public GunConfig inspect(int inspect) { this.inspectDuration_DNA = inspect; return this; }
|
||||
public GunConfig crosshair(Crosshair crosshair) { this.crosshair_DNA = crosshair; return this; }
|
||||
public GunConfig hideCrosshair(boolean flag) { this.hideCrosshair_DNA = flag; return this; }
|
||||
public GunConfig reloadSequential(boolean flag) { this.reloadAnimationsSequential_DNA = flag; return this; }
|
||||
public GunConfig rec(Receiver... receivers) { this.receivers_DNA = receivers; return this; }
|
||||
public GunConfig dura(float dura) { this.durability_DNA = dura; return this; }
|
||||
public GunConfig draw(int draw) { this.drawDuration_DNA = draw; return this; }
|
||||
public GunConfig inspect(int inspect) { this.inspectDuration_DNA = inspect; return this; }
|
||||
public GunConfig inspectCancel(boolean flag) { this.inspectCancel_DNA = flag; return this; }
|
||||
public GunConfig crosshair(Crosshair crosshair) { this.crosshair_DNA = crosshair; return this; }
|
||||
public GunConfig hideCrosshair(boolean flag) { this.hideCrosshair_DNA = flag; return this; }
|
||||
public GunConfig reloadSequential(boolean flag) { this.reloadAnimationsSequential_DNA = flag; return this; }
|
||||
public GunConfig scopeTexture(ResourceLocation tex) { this.scopeTexture_DNA = tex; return this; }
|
||||
|
||||
public GunConfig smoke(BiConsumer<ItemStack, LambdaContext> smoke) { this.smokeHandler_DNA = smoke; return this; }
|
||||
public GunConfig orchestra(BiConsumer<ItemStack, LambdaContext> orchestra) { this.orchestra_DNA = orchestra; return this; }
|
||||
|
||||
@ -23,6 +23,7 @@ import com.hbm.util.EnumUtil;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.Gui;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
@ -100,12 +101,11 @@ public class ItemGunBaseNT extends Item implements IKeybindReceiver, IEquipRecei
|
||||
}
|
||||
|
||||
public static enum GunState {
|
||||
DRAWING, //initial delay after selecting
|
||||
IDLE, //gun can be fired or reloaded
|
||||
WINDUP, //fire button is down, added delay before fire
|
||||
COOLDOWN, //gun has been fired, cooldown
|
||||
RELOADING, //gun is currently reloading
|
||||
JAMMED, //gun is jammed, either after reloading or while firing
|
||||
DRAWING, //forced delay where nothing can be done
|
||||
IDLE, //the gun is ready to fire or reload
|
||||
COOLDOWN, //forced delay, but with option for refire
|
||||
RELOADING, //forced delay after which a reload action happens, may be canceled (TBI)
|
||||
JAMMED, //forced delay due to jamming
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@ -117,7 +117,12 @@ public class ItemGunBaseNT extends Item implements IKeybindReceiver, IEquipRecei
|
||||
for(Receiver rec : config.getReceivers(stack)) {
|
||||
IMagazine mag = rec.getMagazine(stack);
|
||||
list.add("Ammo: " + mag.getIconForHUD(stack, player).getDisplayName() + " " + mag.reportAmmoStateForHUD(stack, player));
|
||||
list.add("Base Damage: " + rec.getBaseDamage(stack));
|
||||
float dmg = rec.getBaseDamage(stack);
|
||||
list.add("Base Damage: " + dmg);
|
||||
if(mag.getType(stack, player.inventory) instanceof BulletConfig) {
|
||||
BulletConfig bullet = (BulletConfig) mag.getType(stack, player.inventory);
|
||||
list.add("Damage with current ammo: " + dmg * bullet.damageMult + (bullet.projectilesMin > 1 ? (" x" + (bullet.projectilesMin != bullet.projectilesMax ? (bullet.projectilesMin + "-" + bullet.projectilesMax) : bullet.projectilesMin)) : ""));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -339,6 +344,8 @@ public class ItemGunBaseNT extends Item implements IKeybindReceiver, IEquipRecei
|
||||
bottomOffset += component.getComponentHeight(player, stack);
|
||||
}
|
||||
}
|
||||
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(Gui.icons);
|
||||
}
|
||||
|
||||
public static class SmokeNode {
|
||||
|
||||
@ -60,6 +60,8 @@ public class GunFactory {
|
||||
XFactory50.init();
|
||||
XFactoryEnergy.init();
|
||||
XFactoryAccelerator.init();
|
||||
XFactoryCatapult.init();
|
||||
XFactory75Bolt.init();
|
||||
|
||||
/// PROXY BULLSHIT ///
|
||||
MainRegistry.proxy.registerGunCfg();
|
||||
@ -67,13 +69,14 @@ public class GunFactory {
|
||||
|
||||
public static enum EnumAmmo {
|
||||
STONE, STONE_AP, STONE_IRON, STONE_SHOT,
|
||||
M357_SP, M357_FMJ, M357_JHP, M357_AP, M357_EXPRESS,
|
||||
M44_SP, M44_FMJ, M44_JHP, M44_AP, M44_EXPRESS,
|
||||
M357_BP, M357_SP, M357_FMJ, M357_JHP, M357_AP, M357_EXPRESS,
|
||||
M44_BP, M44_SP, M44_FMJ, M44_JHP, M44_AP, M44_EXPRESS,
|
||||
P22_SP, P22_FMJ, P22_JHP, P22_AP,
|
||||
P9_SP, P9_FMJ, P9_JHP, P9_AP,
|
||||
R556_SP, R556_FMJ, R556_JHP, R556_AP,
|
||||
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,
|
||||
G26_FLARE, G26_FLARE_SUPPLY, G26_FLARE_WEAPON,
|
||||
G40_HE, G40_HEAT, G40_DEMO, G40_INC, G40_PHOSPHORUS,
|
||||
@ -81,6 +84,8 @@ public class GunFactory {
|
||||
FLAME_DIESEL, FLAME_GAS, FLAME_NAPALM, FLAME_BALEFIRE,
|
||||
CAPACITOR, CAPACITOR_OVERCHARGE, CAPACITOR_BLACKLIGHTNING,
|
||||
TAU_URANIUM,
|
||||
COIL_TUNGSTEN, COIL_FERROURANIUM,
|
||||
NUKE_STANDARD, NUKE_DEMO, NUKE_HIGH, NUKE_TOTS, NUKE_HIVE,
|
||||
M44_EQUESTRIAN, G12_EQUESTRIAN, BMG50_EQUESTRIAN
|
||||
}
|
||||
}
|
||||
|
||||
@ -8,10 +8,12 @@ import static com.hbm.items.weapon.sedna.factory.XFactory40mm.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactory44.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactory50.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactory556mm.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactory75Bolt.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactory762mm.*;
|
||||
import static com.hbm.items.weapon.sedna.factory.XFactory9mm.*;
|
||||
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.XFactoryRocket.*;
|
||||
|
||||
@ -64,6 +66,11 @@ public class GunFactoryClient {
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_tesla_cannon, new ItemRenderTeslaCannon());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_stg77, new ItemRenderSTG77());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_tau, new ItemRenderTau());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_fatman, new ItemRenderFatMan());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_lasrifle, new ItemRenderLasrifle());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_coilgun, new ItemRenderCoilgun());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_hangman, new ItemRenderHangman());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_bolter, new ItemRenderBolter());
|
||||
//PROJECTILES
|
||||
ammo_debug.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
ammo_debug_buckshot.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
@ -72,13 +79,15 @@ public class GunFactoryClient {
|
||||
flint.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
iron.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
shot.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
|
||||
|
||||
m357_bp.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
m357_sp.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
m357_fmj.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
m357_jhp.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
m357_ap.setRenderer(LegoClient.RENDER_AP_BULLET);
|
||||
m357_express.setRenderer(LegoClient.RENDER_EXPRESS_BULLET);
|
||||
|
||||
|
||||
m44_bp.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
m44_sp.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
m44_fmj.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
m44_jhp.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
@ -112,6 +121,10 @@ public class GunFactoryClient {
|
||||
bmg50_jhp.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
bmg50_ap.setRenderer(LegoClient.RENDER_AP_BULLET);
|
||||
bmg50_du.setRenderer(LegoClient.RENDER_DU_BULLET);
|
||||
|
||||
b75.setRenderer(LegoClient.RENDER_AP_BULLET);
|
||||
b75_inc.setRenderer(LegoClient.RENDER_AP_BULLET);
|
||||
b75_exp.setRenderer(LegoClient.RENDER_EXPRESS_BULLET);
|
||||
|
||||
g12_bp.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
g12_bp_magnum.setRenderer(LegoClient.RENDER_STANDARD_BULLET);
|
||||
@ -134,10 +147,18 @@ public class GunFactoryClient {
|
||||
setRendererBulk(LegoClient.RENDER_RPZB, rocket_rpzb);
|
||||
setRendererBulk(LegoClient.RENDER_QD, rocket_qd);
|
||||
setRendererBulk(LegoClient.RENDER_ML, rocket_ml);
|
||||
|
||||
setRendererBulk(LegoClient.RENDER_NUKE, nuke_standard, nuke_demo, nuke_high);
|
||||
nuke_tots.setRenderer(LegoClient.RENDER_GRENADE);
|
||||
nuke_hive.setRenderer(LegoClient.RENDER_HIVE);
|
||||
|
||||
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);
|
||||
|
||||
setRendererBulk(LegoClient.RENDER_AP_BULLET, coil_tungsten, coil_ferrouranium);
|
||||
|
||||
//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);
|
||||
@ -170,6 +191,11 @@ public class GunFactoryClient {
|
||||
((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);
|
||||
((ItemGunBaseNT) ModItems.gun_tau) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_fatman) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((ItemGunBaseNT) ModItems.gun_lasrifle) .getConfig(null, 0).hud(LegoClient.HUD_COMPONENT_DURABILITY, LegoClient.HUD_COMPONENT_AMMO);
|
||||
((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_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);
|
||||
|
||||
@ -64,6 +64,10 @@ public class Lego {
|
||||
ItemGunBaseNT.playAnimation(player, stack, AnimType.RELOAD, ctx.configIndex);
|
||||
} else {
|
||||
ItemGunBaseNT.playAnimation(player, stack, AnimType.INSPECT, ctx.configIndex);
|
||||
if(!ctx.config.getInspectCancel(stack)) {
|
||||
ItemGunBaseNT.setState(stack, ctx.configIndex, GunState.DRAWING);
|
||||
ItemGunBaseNT.setTimer(stack, ctx.configIndex, ctx.config.getInspectDuration(stack));
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
@ -248,8 +252,8 @@ public class Lego {
|
||||
double sideOffset = ItemGunBaseNT.getIsAiming(stack) ? 0 : offset.zCoord;
|
||||
|
||||
/*forwardOffset = 0.75;
|
||||
heightOffset = 0;
|
||||
sideOffset = -0.375D;*/
|
||||
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);
|
||||
|
||||
@ -10,6 +10,7 @@ import com.hbm.items.weapon.sedna.hud.HUDComponentAmmoCounter;
|
||||
import com.hbm.items.weapon.sedna.hud.HUDComponentDurabilityBar;
|
||||
import com.hbm.lib.RefStrings;
|
||||
import com.hbm.main.ResourceManager;
|
||||
import com.hbm.render.tileentity.RenderArcFurnace;
|
||||
import com.hbm.render.util.BeamPronter;
|
||||
import com.hbm.render.util.BeamPronter.EnumBeamType;
|
||||
import com.hbm.render.util.BeamPronter.EnumWaveType;
|
||||
@ -124,6 +125,7 @@ public class LegoClient {
|
||||
|
||||
if(bullet.ticksExisted < 2) return;
|
||||
|
||||
RenderArcFurnace.fullbright(true);
|
||||
GL11.glPushMatrix();
|
||||
GL11.glEnable(GL11.GL_BLEND);
|
||||
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE);
|
||||
@ -170,6 +172,7 @@ 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) -> {
|
||||
@ -231,7 +234,8 @@ public class LegoClient {
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBeamBase, Float> RENDER_LIGHTNING = (bullet, interp) -> {
|
||||
|
||||
|
||||
RenderArcFurnace.fullbright(true);
|
||||
GL11.glPushMatrix();
|
||||
GL11.glRotatef(180 - bullet.rotationYaw, 0, 1F, 0);
|
||||
GL11.glRotatef(-bullet.rotationPitch - 90, 1F, 0, 0);
|
||||
@ -245,10 +249,12 @@ public class LegoClient {
|
||||
BeamPronter.prontBeam(delta, EnumWaveType.RANDOM, EnumBeamType.SOLID, colorOuter, colorOuter, bullet.ticksExisted, (int)(bullet.beamLength / 2 + 1), (float)scale * 7F, 2, 0.0625F);
|
||||
BeamPronter.prontBeam(delta, EnumWaveType.RANDOM, EnumBeamType.SOLID, colorOuter, colorOuter, bullet.ticksExisted / 2, (int)(bullet.beamLength / 2 + 1), (float)scale * 7F, 2, 0.0625F);
|
||||
GL11.glPopMatrix();
|
||||
RenderArcFurnace.fullbright(false);
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBeamBase, Float> RENDER_TAU = (bullet, interp) -> {
|
||||
|
||||
RenderArcFurnace.fullbright(true);
|
||||
double age = MathHelper.clamp_double(1D - ((double) bullet.ticksExisted - 2 + interp) / (double) bullet.getBulletConfig().expires, 0, 1);
|
||||
|
||||
GL11.glPushMatrix();
|
||||
@ -269,10 +275,12 @@ public class LegoClient {
|
||||
renderBulletStandard(Tessellator.instance, 0xFFBF00, 0xFFFFFF, bullet.beamLength, true);
|
||||
|
||||
GL11.glPopMatrix();
|
||||
RenderArcFurnace.fullbright(false);
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBeamBase, Float> RENDER_TAU_CHARGE = (bullet, interp) -> {
|
||||
|
||||
RenderArcFurnace.fullbright(true);
|
||||
double age = MathHelper.clamp_double(1D - ((double) bullet.ticksExisted - 2 + interp) / (double) bullet.getBulletConfig().expires, 0, 1);
|
||||
|
||||
GL11.glPushMatrix();
|
||||
@ -293,5 +301,47 @@ public class LegoClient {
|
||||
renderBulletStandard(Tessellator.instance, 0xFFF0A0, 0xFFFFFF, bullet.beamLength, true);
|
||||
|
||||
GL11.glPopMatrix();
|
||||
RenderArcFurnace.fullbright(false);
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBeamBase, Float> RENDER_LASER = (bullet, interp) -> {
|
||||
|
||||
RenderArcFurnace.fullbright(true);
|
||||
GL11.glPushMatrix();
|
||||
GL11.glRotatef(180 - bullet.rotationYaw, 0, 1F, 0);
|
||||
GL11.glRotatef(-bullet.rotationPitch - 90, 1F, 0, 0);
|
||||
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);
|
||||
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<EntityBulletBaseMK4, Float> RENDER_NUKE = (bullet, interp) -> {
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glScalef(0.125F, 0.125F, 0.125F);
|
||||
GL11.glRotated(-90, 0, 1, 0);
|
||||
GL11.glTranslatef(0, -1, 1F);
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
Minecraft.getMinecraft().getTextureManager().bindTexture(ResourceManager.fatman_mininuke_tex);
|
||||
ResourceManager.fatman.renderPart("MiniNuke");
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
GL11.glPopMatrix();
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBaseMK4, Float> RENDER_HIVE = (bullet, interp) -> {
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glScalef(0.125F, 0.125F, 0.125F);
|
||||
GL11.glRotated(90, 0, -1, 0);
|
||||
GL11.glTranslatef(0, 0, 3.5F);
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
Minecraft.getMinecraft().getTextureManager().bindTexture(ResourceManager.panzerschreck_tex);
|
||||
ResourceManager.panzerschreck.renderPart("Rocket");
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
GL11.glPopMatrix();
|
||||
};
|
||||
}
|
||||
|
||||
@ -16,11 +16,15 @@ import com.hbm.particle.SpentCasing;
|
||||
import com.hbm.particle.helper.CasingCreator;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
import com.hbm.sound.AudioWrapper;
|
||||
import com.hbm.util.EntityDamageUtil;
|
||||
|
||||
import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
|
||||
/** Orchestras are server-side components that run along client-side animations.
|
||||
* The orchestra only knows what animation is or was playing and how long it started, but not if it is still active.
|
||||
@ -623,6 +627,10 @@ public class Orchestras {
|
||||
if(casing != null) CasingCreator.composeEffect(entity.worldObj, entity, 0.375, aiming ? 0 : -0.125, 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.shotgunCock", 1F, 1F);
|
||||
}
|
||||
if(type == AnimType.RELOAD) {
|
||||
IMagazine mag = ctx.config.getReceivers(stack)[0].getMagazine(stack);
|
||||
if(mag.getAmount(stack, ctx.inventory) == 0) {
|
||||
@ -634,6 +642,15 @@ public class Orchestras {
|
||||
if(type == AnimType.RELOAD_CYCLE) {
|
||||
if(timer == 5) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.shotgunReload", 1F, 1F);
|
||||
}
|
||||
if(type == AnimType.INSPECT) {
|
||||
if(timer == 5) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.shotgunCockOpen", 1F, 1F);
|
||||
if(timer == 18) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.shotgunCockClose", 1F, 1F);
|
||||
}
|
||||
if(type == AnimType.JAMMED) {
|
||||
if(timer == 18) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.foley.gunWhack", 1F, 1F);
|
||||
if(timer == 25) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.foley.gunWhack", 1F, 1F);
|
||||
if(timer == 29) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.shotgunCockClose", 1F, 1F);
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_PANERSCHRECK = (stack, ctx) -> {
|
||||
@ -880,27 +897,61 @@ public class Orchestras {
|
||||
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 == 40) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 0.25F, 1.25F);
|
||||
}
|
||||
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.pistolCock", 1F, 0.9F);
|
||||
if(timer == 40) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 0.25F, 1.25F);
|
||||
}
|
||||
if(type == AnimType.RELOAD) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 0.9F);
|
||||
if(timer == 10) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magRemove", 1F, 1F);
|
||||
if(timer == 24) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magInsert", 1F, 1F);
|
||||
if(timer == 34) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
}
|
||||
if(type == AnimType.INSPECT) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 0.9F);
|
||||
if(timer == 10) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallRemove", 1F, 1F);
|
||||
|
||||
if(timer == 114) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallInsert", 1F, 1F);
|
||||
if(timer == 124) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
if(ClientConfig.GUN_ANIMS_LEGACY.get()) {
|
||||
if(type == AnimType.CYCLE) {
|
||||
if(timer == 0) {
|
||||
SpentCasing casing = ctx.config.getReceivers(stack)[0].getMagazine(stack).getCasing(stack, ctx.inventory);
|
||||
if(casing != null) CasingCreator.composeEffect(entity.worldObj, entity, aiming ? 0.125 : 0.125, aiming ? -0.125 : -0.25, aiming ? -0.125 : -0.25D, 0, 0.18, -0.12, 0.01, casing.getName());
|
||||
}
|
||||
if(timer == 40) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 0.25F, 1.25F);
|
||||
}
|
||||
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.pistolCock", 1F, 0.9F);
|
||||
if(timer == 40) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 0.25F, 1.25F);
|
||||
}
|
||||
if(type == AnimType.RELOAD) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 0.9F);
|
||||
if(timer == 10) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magRemove", 1F, 1F);
|
||||
if(timer == 24) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magInsert", 1F, 1F);
|
||||
if(timer == 34) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
}
|
||||
if(type == AnimType.INSPECT) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 0.9F);
|
||||
if(timer == 10) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallRemove", 1F, 1F);
|
||||
|
||||
if(timer == 114) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallInsert", 1F, 1F);
|
||||
if(timer == 124) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
}
|
||||
} else {
|
||||
if(type == AnimType.CYCLE) {
|
||||
if(timer == 0) {
|
||||
SpentCasing casing = ctx.config.getReceivers(stack)[0].getMagazine(stack).getCasing(stack, ctx.inventory);
|
||||
if(casing != null) CasingCreator.composeEffect(entity.worldObj, entity, aiming ? 0.125 : 0.25, aiming ? -0.125 : -0.25, aiming ? -0.125 : -0.25D, 0, 0.18, -0.12, 0.01, casing.getName());
|
||||
}
|
||||
if(timer == 40) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 0.25F, 1.25F);
|
||||
}
|
||||
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.pistolCock", 1F, 0.9F);
|
||||
if(timer == 40) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 0.25F, 1.25F);
|
||||
}
|
||||
if(type == AnimType.RELOAD) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 0.9F);
|
||||
if(timer == 16) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magRemove", 1F, 1F);
|
||||
if(timer == 32) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.impact", 0.25F, 1.25F);
|
||||
if(timer == 38) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magInsert", 1F, 1F);
|
||||
if(timer == 43) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
}
|
||||
if(type == AnimType.INSPECT) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 0.9F);
|
||||
if(timer == 11) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallRemove", 1F, 1F);
|
||||
|
||||
if(timer == 72) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallInsert", 1F, 1F);
|
||||
if(timer == 84) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
@ -979,4 +1030,125 @@ public class Orchestras {
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_FATMAN = (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 == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.fatmanFull", 1F, 1F);
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_LASRIFLE = (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 == 2) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallRemove", 1F, 1F);
|
||||
if(timer == 18) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.impact", 0.25F, 1F);
|
||||
if(timer == 30) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magInsert", 1F, 1F);
|
||||
if(timer == 38) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
}
|
||||
|
||||
if(type == AnimType.INSPECT) {
|
||||
if(timer == 2) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallRemove", 1F, 1F);
|
||||
if(timer == 12) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magInsert", 1F, 1F);
|
||||
if(timer == 20) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
}
|
||||
|
||||
if(type == AnimType.JAMMED) {
|
||||
if(timer == 2) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallRemove", 1F, 1F);
|
||||
if(timer == 22) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magInsert", 1F, 1F);
|
||||
if(timer == 30) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_COILGUN = (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 == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.coilgunReload", 1F, 1F);
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_HANGMAN = (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.CYCLE_DRY) {
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.dryFireClick", 1F, 1F);
|
||||
}
|
||||
|
||||
if(type == AnimType.RELOAD) {
|
||||
|
||||
if(timer == 0) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverCock", 1F, 0.8F);
|
||||
if(timer == 5) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallRemove", 1F, 0.8F);
|
||||
if(timer == 25) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
if(timer == 35) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverCock", 1F, 0.75F);
|
||||
|
||||
if(timer == 10) {
|
||||
Receiver rec = ctx.config.getReceivers(stack)[0];
|
||||
IMagazine mag = rec.getMagazine(stack);
|
||||
SpentCasing casing = mag.getCasing(stack, ctx.inventory);
|
||||
if(casing != null) for(int i = 0; i < mag.getCapacity(stack); i++) CasingCreator.composeEffect(entity.worldObj, entity, 0.25, -0.25, -0.125, -0.05, 0, 0, 0.01, casing.getName());
|
||||
}
|
||||
}
|
||||
|
||||
if(type == AnimType.INSPECT) {
|
||||
if(timer == 16 && ctx.getPlayer() != null) {
|
||||
MovingObjectPosition mop = EntityDamageUtil.getMouseOver(ctx.getPlayer(), 3.0D);
|
||||
if(mop != null) {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY) {
|
||||
float damage = 10F;
|
||||
mop.entityHit.attackEntityFrom(DamageSource.causePlayerDamage(ctx.getPlayer()), damage);
|
||||
mop.entityHit.motionX *= 2;
|
||||
mop.entityHit.motionZ *= 2;
|
||||
entity.worldObj.playSoundAtEntity(mop.entityHit, "hbm:weapon.fire.smack", 1F, 0.9F + entity.getRNG().nextFloat() * 0.2F);
|
||||
}
|
||||
if(mop.typeOfHit == mop.typeOfHit.BLOCK) {
|
||||
Block b = entity.worldObj.getBlock(mop.blockX, mop.blockY, mop.blockZ);
|
||||
entity.worldObj.playSoundEffect(mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, b.stepSound.getStepResourcePath(), 2F, 0.9F + entity.getRNG().nextFloat() * 0.2F);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(type == AnimType.JAMMED) {
|
||||
if(timer == 10) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverCock", 1F, 0.8F);
|
||||
if(timer == 15) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.magSmallRemove", 1F, 0.8F);
|
||||
if(timer == 20) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverClose", 1F, 1F);
|
||||
if(timer == 25) entity.worldObj.playSoundAtEntity(entity, "hbm:weapon.reload.revolverCock", 1F, 0.75F);
|
||||
}
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> ORCHESTRA_BOLTER = (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.5, aiming ? 0 : -0.125, aiming ? -0.0625 : -0.25D, 0, 0.18, -0.12, 0.01, casing.getName());
|
||||
}
|
||||
}
|
||||
|
||||
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);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
@ -119,7 +119,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(24).sound("hbm:weapon.shotgunShoot", 1.0F, 1.0F)
|
||||
.dmg(12F).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))
|
||||
@ -348,14 +348,15 @@ public class XFactory12ga {
|
||||
case EQUIP: return new BusAnimation()
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(-60, 0, 0, 0).addPos(0, 0, -3, 500, IType.SIN_DOWN));
|
||||
case CYCLE: return ResourceManager.spas_12_anim.get("Fire");
|
||||
case CYCLE_DRY: return new BusAnimation();
|
||||
case CYCLE_DRY: return ResourceManager.spas_12_anim.get("FireDry");
|
||||
case ALT_CYCLE: return ResourceManager.spas_12_anim.get("FireAlt");
|
||||
case RELOAD:
|
||||
boolean empty = ((ItemGunBaseNT) stack.getItem()).getConfig(stack, 0).getReceivers(stack)[0].getMagazine(stack).getAmount(stack, MainRegistry.proxy.me().inventory) <= 0;
|
||||
return ResourceManager.spas_12_anim.get(empty ? "ReloadEmptyStart" : "ReloadStart");
|
||||
case RELOAD_CYCLE: return ResourceManager.spas_12_anim.get("Reload");
|
||||
case RELOAD_END: return ResourceManager.spas_12_anim.get("ReloadEnd");
|
||||
case JAMMED: return new BusAnimation();
|
||||
case INSPECT: return new BusAnimation();
|
||||
case JAMMED: return ResourceManager.spas_12_anim.get("Jammed");
|
||||
case INSPECT: return ResourceManager.spas_12_anim.get("Inspect");
|
||||
}
|
||||
|
||||
return null;
|
||||
|
||||
@ -20,6 +20,7 @@ import net.minecraft.item.ItemStack;
|
||||
|
||||
public class XFactory357 {
|
||||
|
||||
public static BulletConfig m357_bp;
|
||||
public static BulletConfig m357_sp;
|
||||
public static BulletConfig m357_fmj;
|
||||
public static BulletConfig m357_jhp;
|
||||
@ -27,6 +28,7 @@ public class XFactory357 {
|
||||
public static BulletConfig m357_express;
|
||||
|
||||
public static void init() {
|
||||
m357_bp = new BulletConfig().setItem(EnumAmmo.M357_BP).setDamage(0.5F).setBlackPowder(true);
|
||||
m357_sp = new BulletConfig().setItem(EnumAmmo.M357_SP);
|
||||
m357_fmj = new BulletConfig().setItem(EnumAmmo.M357_FMJ).setDamage(0.8F).setArmorPiercing(0.1F);
|
||||
m357_jhp = new BulletConfig().setItem(EnumAmmo.M357_JHP).setDamage(1.5F).setArmorPiercing(-0.25F);
|
||||
@ -37,7 +39,7 @@ public class XFactory357 {
|
||||
.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)
|
||||
.mag(new MagazineFullReload(0, 6).addConfigs(m357_sp, m357_fmj, m357_jhp, m357_ap, m357_express))
|
||||
.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()
|
||||
@ -48,7 +50,7 @@ public class XFactory357 {
|
||||
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)
|
||||
.mag(new MagazineFullReload(0, 6).addConfigs(m357_sp, m357_fmj, m357_jhp, m357_ap, m357_express))
|
||||
.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))
|
||||
.pp(Lego.LAMBDA_STANDARD_CLICK_PRIMARY).pr(Lego.LAMBDA_STANDARD_RELOAD)
|
||||
@ -57,7 +59,7 @@ public class XFactory357 {
|
||||
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)
|
||||
.mag(new MagazineFullReload(1, 6).addConfigs(m357_sp, m357_fmj, m357_jhp, m357_ap, m357_express))
|
||||
.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))
|
||||
.ps(Lego.LAMBDA_STANDARD_CLICK_PRIMARY).pr(Lego.LAMBDA_STANDARD_RELOAD)
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
package com.hbm.items.weapon.sedna.factory;
|
||||
|
||||
import java.util.function.BiConsumer;
|
||||
import java.util.function.BiFunction;
|
||||
|
||||
import com.hbm.items.ModItems;
|
||||
@ -8,10 +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.items.weapon.sedna.mags.MagazineSingleReload;
|
||||
import com.hbm.lib.RefStrings;
|
||||
import com.hbm.particle.SpentCasing;
|
||||
import com.hbm.particle.SpentCasing.CasingType;
|
||||
import com.hbm.render.anim.BusAnimation;
|
||||
@ -20,9 +24,13 @@ import com.hbm.render.anim.BusAnimationKeyframe.IType;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
public class XFactory44 {
|
||||
|
||||
public static final ResourceLocation scope_lilmac = new ResourceLocation(RefStrings.MODID, "textures/misc/scope_44.png");
|
||||
|
||||
public static BulletConfig m44_bp;
|
||||
public static BulletConfig m44_sp;
|
||||
public static BulletConfig m44_fmj;
|
||||
public static BulletConfig m44_jhp;
|
||||
@ -32,6 +40,8 @@ public class XFactory44 {
|
||||
|
||||
public static void init() {
|
||||
SpentCasing casing44 = new SpentCasing(CasingType.STRAIGHT).setColor(SpentCasing.COLOR_CASE_BRASS).setupSmoke(1F, 0.5D, 60, 20);
|
||||
m44_bp = new BulletConfig().setItem(EnumAmmo.M44_BP).setDamage(0.5F).setBlackPowder(true)
|
||||
.setCasing(casing44.clone().register("m44bp"));
|
||||
m44_sp = new BulletConfig().setItem(EnumAmmo.M44_SP)
|
||||
.setCasing(casing44.clone().register("m44"));
|
||||
m44_fmj = new BulletConfig().setItem(EnumAmmo.M44_FMJ).setDamage(0.8F).setArmorPiercing(0.1F)
|
||||
@ -49,7 +59,7 @@ public class XFactory44 {
|
||||
.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)
|
||||
.mag(new MagazineSingleReload(0, 14).addConfigs(m44_sp, m44_fmj, m44_jhp, m44_ap, m44_express))
|
||||
.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))
|
||||
.setupStandardConfiguration()
|
||||
@ -60,25 +70,42 @@ public class XFactory44 {
|
||||
.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)
|
||||
.mag(new MagazineFullReload(0, 6).addConfigs(m44_sp, m44_fmj, m44_jhp, m44_ap, m44_express))
|
||||
.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))
|
||||
.pp(Lego.LAMBDA_STANDARD_CLICK_PRIMARY) .pr(Lego.LAMBDA_STANDARD_RELOAD) .pt(Lego.LAMBDA_TOGGLE_AIM)
|
||||
.decider(GunStateDecider.LAMBDA_STANDARD_DECIDER)
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_NOPIP_ANIMS).orchestra(Orchestras.ORCHESTRA_NOPIP)
|
||||
).setUnlocalizedName("gun_heavy_revolver");
|
||||
ModItems.gun_heavy_revolver_lilmac = new ItemGunBaseNT(WeaponQuality.LEGENDARY, new GunConfig()
|
||||
.dura(31_000).draw(10).inspect(23).crosshair(Crosshair.L_CLASSIC).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.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)
|
||||
.mag(new MagazineFullReload(0, 6).addConfigs(m44_equestrian, m44_sp, m44_fmj, m44_jhp, m44_ap, m44_express))
|
||||
.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))
|
||||
.pp(Lego.LAMBDA_STANDARD_CLICK_PRIMARY) .pr(Lego.LAMBDA_STANDARD_RELOAD) .pt(Lego.LAMBDA_TOGGLE_AIM)
|
||||
.decider(GunStateDecider.LAMBDA_STANDARD_DECIDER)
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_LILMAC_ANIMS).orchestra(Orchestras.ORCHESTRA_NOPIP)
|
||||
).setUnlocalizedName("gun_heavy_revolver_lilmac");
|
||||
|
||||
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)
|
||||
.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))
|
||||
.setupStandardConfiguration().ps(SMACK_A_FUCKER)
|
||||
.anim(LAMBDA_HANGMAN_ANIMS).orchestra(Orchestras.ORCHESTRA_HANGMAN)
|
||||
).setUnlocalizedName("gun_hangman");
|
||||
}
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> SMACK_A_FUCKER = (stack, ctx) -> {
|
||||
if(ItemGunBaseNT.getState(stack, ctx.configIndex) == GunState.IDLE || ItemGunBaseNT.getLastAnim(stack, ctx.configIndex) == AnimType.CYCLE) {
|
||||
ItemGunBaseNT.setState(stack, ctx.configIndex, GunState.DRAWING);
|
||||
ItemGunBaseNT.setTimer(stack, ctx.configIndex, ctx.config.getInspectDuration(stack));
|
||||
ItemGunBaseNT.playAnimation(ctx.getPlayer(), stack, AnimType.INSPECT, ctx.configIndex);
|
||||
}
|
||||
};
|
||||
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_HENRY_ANIMS = (stack, type) -> {
|
||||
switch(type) {
|
||||
@ -122,6 +149,7 @@ public class XFactory44 {
|
||||
|
||||
return null;
|
||||
};
|
||||
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_NOPIP_ANIMS = (stack, type) -> {
|
||||
switch(type) {
|
||||
case CYCLE: return new BusAnimation()
|
||||
@ -154,4 +182,29 @@ public class XFactory44 {
|
||||
|
||||
return LAMBDA_NOPIP_ANIMS.apply(stack, type);
|
||||
};
|
||||
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_HANGMAN_ANIMS = (stack, type) -> {
|
||||
switch(type) {
|
||||
case EQUIP: return new BusAnimation().addBus("EQUIP", new BusAnimationSequence().addPos(60, 0, 0, 0).addPos(0, 0, 0, 500, IType.SIN_DOWN));
|
||||
case CYCLE: return new BusAnimation()
|
||||
.addBus("RECOIL", new BusAnimationSequence().addPos(0, 0, 0, 50).addPos(0, 0, -3, 50).addPos(0, 0, 0, 250));
|
||||
case RELOAD: return new BusAnimation()
|
||||
.addBus("LID", new BusAnimationSequence().addPos(0, 0, -90, 250).addPos(0, 0, -90, 1500).addPos(0, 0, 0, 250))
|
||||
.addBus("MAG", new BusAnimationSequence().addPos(0, 0, 0, 250).addPos(0, -10, 0, 250, IType.SIN_UP).addPos(0, -10, 0, 500).addPos(0, 0, 0, 350, IType.SIN_FULL))
|
||||
.addBus("BULLETS", new BusAnimationSequence().addPos(1, 1, 1, 0).addPos(0, 0, 0, 500))
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(-15, 0, 0, 500, IType.SIN_FULL).addPos(-15, 0, 0, 850).addPos(-25, 0, 0, 100, IType.SIN_DOWN).addPos(0, 0, 0, 350, IType.SIN_FULL))
|
||||
.addBus("ROLL", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(0, 0, 25, 250, IType.SIN_FULL).addPos(0, 0, 25, 1000).addPos(0, 0, 0, 250, IType.SIN_FULL));
|
||||
case INSPECT: return new BusAnimation()
|
||||
.addBus("TURN", new BusAnimationSequence().addPos(0, 170, 0, 500, IType.SIN_UP).addPos(0, 170, 0, 550).addPos(0, 0, 0, 500, IType.SIN_FULL))
|
||||
.addBus("ROLL", new BusAnimationSequence().addPos(0, 0, 110, 500, IType.SIN_FULL).addPos(0, 0, 110, 550).addPos(0, 0, 0, 500, IType.SIN_FULL))
|
||||
.addBus("SMACK", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(0, 0, 1, 150, IType.SIN_DOWN).addPos(0, 0, -3, 150, IType.SIN_UP).addPos(0, 0, 0, 350, IType.SIN_FULL));
|
||||
case JAMMED: return new BusAnimation()
|
||||
.addBus("LID", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(0, 0, -90, 250).addPos(0, 0, -90, 300).addPos(0, 0, 0, 250))
|
||||
.addBus("MAG", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(0, 0, 0, 250).addPos(0, -3, 0, 150, IType.SIN_UP).addPos(0, 0, 0, 150, IType.SIN_FULL))
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(0, 0, 0, 1000).addPos(-10, 0, 0, 100, IType.SIN_DOWN).addPos(0, 0, 0, 350, IType.SIN_FULL))
|
||||
.addBus("ROLL", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(0, 0, 25, 250, IType.SIN_FULL).addPos(0, 0, 25, 300).addPos(0, 0, 0, 250, IType.SIN_FULL));
|
||||
}
|
||||
|
||||
return null;
|
||||
};
|
||||
}
|
||||
|
||||
@ -3,6 +3,7 @@ package com.hbm.items.weapon.sedna.factory;
|
||||
import java.util.function.BiConsumer;
|
||||
import java.util.function.BiFunction;
|
||||
|
||||
import com.hbm.config.ClientConfig;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.weapon.sedna.BulletConfig;
|
||||
import com.hbm.items.weapon.sedna.Crosshair;
|
||||
@ -15,6 +16,7 @@ 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;
|
||||
@ -56,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(37).jam(0).sound("hbm:weapon.fire.blackPowder", 1.0F, 1.0F)
|
||||
.dmg(15F).delay(2).dry(15).auto(true).spread(0.0F).reload(46).jam(0).sound("hbm:weapon.fire.blackPowder", 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))
|
||||
@ -132,28 +134,42 @@ public class XFactory556mm {
|
||||
};
|
||||
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_STG77_ANIMS = (stack, type) -> {
|
||||
switch(type) {
|
||||
case EQUIP: return new BusAnimation()
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(45, 0, 0, 0).addPos(0, 0, 0, 500, IType.SIN_FULL));
|
||||
case CYCLE: return new BusAnimation()
|
||||
.addBus("RECOIL", new BusAnimationSequence().addPos(0, 0, ItemGunBaseNT.getIsAiming(stack) ? -0.125 : -0.375, 25, IType.SIN_DOWN).addPos(0, 0, 0, 75, IType.SIN_FULL))
|
||||
.addBus("SAFETY", new BusAnimationSequence().addPos(0.25, 0, 0, 0).addPos(0.25, 0, 0, 2000).addPos(0, 0, 0, 50));
|
||||
case CYCLE_DRY: return new BusAnimation()
|
||||
.addBus("BOLT", new BusAnimationSequence().addPos(0, 0, 0, 250).addPos(0, 0, -2, 150).addPos(0, 0, 0, 100, IType.SIN_UP))
|
||||
.addBus("SAFETY", new BusAnimationSequence().addPos(0.25, 0, 0, 0).addPos(0.25, 0, 0, 2000).addPos(0, 0, 0, 50));
|
||||
case RELOAD: return new BusAnimation()
|
||||
.addBus("BOLT", new BusAnimationSequence().addPos(0, 0, -2, 150).addPos(0, 0, -2, 1600).addPos(0, 0, 0, 100, IType.SIN_UP))
|
||||
.addBus("HANDLE", new BusAnimationSequence().addPos(0, 0, 0, 150).addPos(0, 0, 20, 50).addPos(0, 0, 20, 1500).addPos(0, 0, 0, 50))
|
||||
.addBus("LIFT", new BusAnimationSequence().addPos(0, 0, 0, 200).addPos(-2, 0, 0, 100, IType.SIN_DOWN).addPos(0, 0, 0, 100, IType.SIN_FULL));
|
||||
case INSPECT: return new BusAnimation()
|
||||
.addBus("BOLT", new BusAnimationSequence().addPos(0, 0, -2, 150).addPos(0, 0, -2, 6100).addPos(0, 0, 0, 100, IType.SIN_UP))
|
||||
.addBus("HANDLE", new BusAnimationSequence().addPos(0, 0, 0, 150).addPos(0, 0, 20, 50).addPos(0, 0, 20, 6000).addPos(0, 0, 0, 50))
|
||||
.addBus("INSPECT_LEVER", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(0, 0, -10, 100).addPos(0, 0, -10, 100).addPos(0, 0, 0, 100))
|
||||
.addBus("INSPECT_BARREL", new BusAnimationSequence().addPos(0, 0, 0, 600).addPos(0, 0, 20, 150).addPos(0, 0, 0, 400).addPos(0, 0, 0, 500).addPos(15, 0, 0, 500).addPos(15, 0, 0, 2000).addPos(0, 0, 0, 500).addPos(0, 0, 0, 500).addPos(0, 0, 20, 200).addPos(0, 0, 20, 400).addPos(0, 0, 0, 150))
|
||||
.addBus("INSPECT_MOVE", new BusAnimationSequence().addPos(0, 0, 0, 750).addPos(0, 0, 6, 1000).addPos(2, 0, 3, 500, IType.SIN_FULL).addPos(2, 0.75, 0, 500, IType.SIN_FULL).addPos(2, 0.75, 0, 1000).addPos(2, 0, 3, 500, IType.SIN_FULL).addPos(0, 0, 6, 500).addPos(0, 0, 0, 1000))
|
||||
.addBus("INSPECT_GUN", new BusAnimationSequence().addPos(0, 0, 0, 1750).addPos(15, 0, -70, 500, IType.SIN_FULL).addPos(15, 0, -70, 1500).addPos(0, 0, 0, 500, IType.SIN_FULL));
|
||||
if(ClientConfig.GUN_ANIMS_LEGACY.get()) {
|
||||
switch(type) {
|
||||
case EQUIP: return new BusAnimation()
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(45, 0, 0, 0).addPos(0, 0, 0, 500, IType.SIN_FULL));
|
||||
case CYCLE: return new BusAnimation()
|
||||
.addBus("RECOIL", new BusAnimationSequence().addPos(0, 0, ItemGunBaseNT.getIsAiming(stack) ? -0.125 : -0.375, 25, IType.SIN_DOWN).addPos(0, 0, 0, 75, IType.SIN_FULL))
|
||||
.addBus("SAFETY", new BusAnimationSequence().addPos(0.25, 0, 0, 0).addPos(0.25, 0, 0, 2000).addPos(0, 0, 0, 50));
|
||||
case CYCLE_DRY: return new BusAnimation()
|
||||
.addBus("BOLT", new BusAnimationSequence().addPos(0, 0, 0, 250).addPos(0, 0, -2, 150).addPos(0, 0, 0, 100, IType.SIN_UP))
|
||||
.addBus("SAFETY", new BusAnimationSequence().addPos(0.25, 0, 0, 0).addPos(0.25, 0, 0, 2000).addPos(0, 0, 0, 50));
|
||||
case RELOAD: return new BusAnimation()
|
||||
.addBus("BOLT", new BusAnimationSequence().addPos(0, 0, -2, 150).addPos(0, 0, -2, 1600).addPos(0, 0, 0, 100, IType.SIN_UP))
|
||||
.addBus("HANDLE", new BusAnimationSequence().addPos(0, 0, 0, 150).addPos(0, 0, 20, 50).addPos(0, 0, 20, 1500).addPos(0, 0, 0, 50))
|
||||
.addBus("LIFT", new BusAnimationSequence().addPos(0, 0, 0, 200).addPos(-2, 0, 0, 100, IType.SIN_DOWN).addPos(0, 0, 0, 100, IType.SIN_FULL));
|
||||
case INSPECT: return new BusAnimation()
|
||||
.addBus("BOLT", new BusAnimationSequence().addPos(0, 0, -2, 150).addPos(0, 0, -2, 6100).addPos(0, 0, 0, 100, IType.SIN_UP))
|
||||
.addBus("HANDLE", new BusAnimationSequence().addPos(0, 0, 0, 150).addPos(0, 0, 20, 50).addPos(0, 0, 20, 6000).addPos(0, 0, 0, 50))
|
||||
.addBus("INSPECT_LEVER", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(0, 0, -10, 100).addPos(0, 0, -10, 100).addPos(0, 0, 0, 100))
|
||||
.addBus("INSPECT_BARREL", new BusAnimationSequence().addPos(0, 0, 0, 600).addPos(0, 0, 20, 150).addPos(0, 0, 0, 400).addPos(0, 0, 0, 500).addPos(15, 0, 0, 500).addPos(15, 0, 0, 2000).addPos(0, 0, 0, 500).addPos(0, 0, 0, 500).addPos(0, 0, 20, 200).addPos(0, 0, 20, 400).addPos(0, 0, 0, 150))
|
||||
.addBus("INSPECT_MOVE", new BusAnimationSequence().addPos(0, 0, 0, 750).addPos(0, 0, 6, 1000).addPos(2, 0, 3, 500, IType.SIN_FULL).addPos(2, 0.75, 0, 500, IType.SIN_FULL).addPos(2, 0.75, 0, 1000).addPos(2, 0, 3, 500, IType.SIN_FULL).addPos(0, 0, 6, 500).addPos(0, 0, 0, 1000))
|
||||
.addBus("INSPECT_GUN", new BusAnimationSequence().addPos(0, 0, 0, 1750).addPos(15, 0, -70, 500, IType.SIN_FULL).addPos(15, 0, -70, 1500).addPos(0, 0, 0, 500, IType.SIN_FULL));
|
||||
}
|
||||
} else {
|
||||
switch(type) {
|
||||
case EQUIP: return new BusAnimation()
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(45, 0, 0, 0).addPos(0, 0, 0, 500, IType.SIN_FULL));
|
||||
case CYCLE: return new BusAnimation()
|
||||
.addBus("RECOIL", new BusAnimationSequence().addPos(0, 0, ItemGunBaseNT.getIsAiming(stack) ? -0.125 : -0.375, 25, IType.SIN_DOWN).addPos(0, 0, 0, 75, IType.SIN_FULL))
|
||||
.addBus("SAFETY", new BusAnimationSequence().addPos(0.25, 0, 0, 0).addPos(0.25, 0, 0, 2000).addPos(0, 0, 0, 50));
|
||||
case CYCLE_DRY: return ResourceManager.stg77_anim.get("FireDry");
|
||||
case RELOAD: return ResourceManager.stg77_anim.get("Reload");
|
||||
case INSPECT: return ResourceManager.stg77_anim.get("Inspect");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return null;
|
||||
};
|
||||
}
|
||||
|
||||
@ -0,0 +1,70 @@
|
||||
package com.hbm.items.weapon.sedna.factory;
|
||||
|
||||
import java.util.function.BiConsumer;
|
||||
import java.util.function.BiFunction;
|
||||
|
||||
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.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.particle.SpentCasing;
|
||||
import com.hbm.particle.SpentCasing.CasingType;
|
||||
import com.hbm.render.anim.BusAnimation;
|
||||
import com.hbm.render.anim.BusAnimationSequence;
|
||||
import com.hbm.render.anim.HbmAnimations.AnimType;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class XFactory75Bolt {
|
||||
|
||||
public static BulletConfig b75;
|
||||
public static BulletConfig b75_inc;
|
||||
public static BulletConfig b75_exp;
|
||||
|
||||
public static void init() {
|
||||
SpentCasing casing75 = new SpentCasing(CasingType.STRAIGHT).setColor(SpentCasing.COLOR_CASE_BRASS).setScale(2F, 2F, 1.5F);
|
||||
|
||||
b75 = new BulletConfig().setItem(EnumAmmo.B75)
|
||||
.setCasing(casing75.clone().register("b75"));
|
||||
b75_inc = new BulletConfig().setItem(EnumAmmo.B75_INC).setDamage(0.8F).setArmorPiercing(0.1F)
|
||||
.setCasing(casing75.clone().register("b75inc"));
|
||||
b75_exp = new BulletConfig().setItem(EnumAmmo.B75_EXP).setDamage(1.5F).setArmorPiercing(-0.25F)
|
||||
.setCasing(casing75.clone().register("b75exp"));
|
||||
|
||||
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)
|
||||
.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))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_BOLTER_ANIMS).orchestra(Orchestras.ORCHESTRA_BOLTER)
|
||||
).setUnlocalizedName("gun_bolter");
|
||||
}
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> LAMBDA_SMOKE = (stack, ctx) -> {
|
||||
Lego.handleStandardSmoke(ctx.entity, stack, 2000, 0.05D, 1.1D, 0);
|
||||
};
|
||||
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_BOLTER_ANIMS = (stack, type) -> {
|
||||
switch(type) {
|
||||
case CYCLE: return new BusAnimation()
|
||||
.addBus("RECOIL", new BusAnimationSequence().addPos(1, 0, 0, 25).addPos(0, 0, 0, 75));
|
||||
case RELOAD: return new BusAnimation()
|
||||
.addBus("TILT", new BusAnimationSequence().addPos(1, 0, 0, 250).addPos(1, 0, 0, 1500).addPos(0, 0, 0, 250))
|
||||
.addBus("MAG", new BusAnimationSequence().addPos(0, 0, 1, 500).addPos(1, 0, 1, 500).addPos(0, 0, 0, 500));
|
||||
case JAMMED: return new BusAnimation()
|
||||
.addBus("TILT", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(1, 0, 0, 250).addPos(1, 0, 0, 700).addPos(0, 0, 0, 250))
|
||||
.addBus("MAG", new BusAnimationSequence().addPos(0, 0, 0, 750).addPos(0.6, 0, 0, 250).addPos(0, 0, 0, 250));
|
||||
}
|
||||
|
||||
return null;
|
||||
};
|
||||
}
|
||||
@ -2,6 +2,7 @@ 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.projectile.EntityBulletBeamBase;
|
||||
import com.hbm.items.ModItems;
|
||||
@ -14,13 +15,19 @@ 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.MagazineBelt;
|
||||
import com.hbm.items.weapon.sedna.mags.MagazineSingleReload;
|
||||
import com.hbm.main.MainRegistry;
|
||||
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 net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.Vec3;
|
||||
|
||||
public class XFactoryAccelerator {
|
||||
@ -29,6 +36,46 @@ public class XFactoryAccelerator {
|
||||
|
||||
public static BulletConfig tau_uranium;
|
||||
public static BulletConfig tau_uranium_charge;
|
||||
|
||||
public static BulletConfig coil_tungsten;
|
||||
public static BulletConfig coil_ferrouranium;
|
||||
|
||||
public static Consumer<Entity> LAMBDA_UPDATE_TUNGSTEN = (entity) -> {breakInPath(entity, 1.25F); };
|
||||
public static Consumer<Entity> LAMBDA_UPDATE_FERRO = (entity) -> { breakInPath(entity, 2.5F); };
|
||||
|
||||
public static void breakInPath(Entity entity, float threshold) {
|
||||
|
||||
Vec3 vec = Vec3.createVectorHelper(entity.posX - entity.prevPosX, entity.posY - entity.prevPosY, entity.posZ - entity.prevPosZ);
|
||||
double motion = Math.max(vec.lengthVector(), 0.1);
|
||||
vec = vec.normalize();
|
||||
|
||||
for(double d = 0; d < motion; d += 0.5) {
|
||||
|
||||
double dX = entity.posX - vec.xCoord * d;
|
||||
double dY = entity.posY - vec.yCoord * d;
|
||||
double dZ = entity.posZ - vec.zCoord * d;
|
||||
|
||||
if(entity.worldObj.isRemote) {
|
||||
NBTTagCompound nbt = new NBTTagCompound();
|
||||
nbt.setString("type", "vanillaExt");
|
||||
nbt.setString("mode", "fireworks");
|
||||
nbt.setDouble("posX", dX);
|
||||
nbt.setDouble("posY", dY);
|
||||
nbt.setDouble("posZ", dZ);
|
||||
MainRegistry.proxy.effectNT(nbt);
|
||||
|
||||
} else {
|
||||
int x = (int) Math.floor(dX);
|
||||
int y = (int) Math.floor(dY);
|
||||
int z = (int) Math.floor(dZ);
|
||||
Block b = entity.worldObj.getBlock(x, y, z);
|
||||
float hardness = b.getBlockHardness(entity.worldObj, x, y, z);
|
||||
if(b.getMaterial() != Material.air && hardness >= 0 && hardness < threshold) {
|
||||
entity.worldObj.func_147480_a(x, y, z, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static void init() {
|
||||
|
||||
@ -36,6 +83,11 @@ public class XFactoryAccelerator {
|
||||
.setOnBeamImpact(BulletConfig.LAMBDA_BEAM_HIT);
|
||||
tau_uranium_charge = new BulletConfig().setItem(EnumAmmo.TAU_URANIUM).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)
|
||||
.setOnUpdate(LAMBDA_UPDATE_TUNGSTEN);
|
||||
coil_ferrouranium = new BulletConfig().setItem(EnumAmmo.COIL_FERROURANIUM).setVel(7.5F).setLife(50).setDoesPenetrate(true).setDamageFalloutByPen(false).setSpectral(true)
|
||||
.setOnUpdate(LAMBDA_UPDATE_FERRO);
|
||||
|
||||
tauChargeMag.addConfigs(tau_uranium_charge);
|
||||
|
||||
@ -54,15 +106,27 @@ public class XFactoryAccelerator {
|
||||
.decider(GunStateDecider.LAMBDA_STANDARD_DECIDER)
|
||||
.anim(LAMBDA_TAU_ANIMS).orchestra(Orchestras.ORCHESTRA_TAU)
|
||||
).setUnlocalizedName("gun_tau");
|
||||
|
||||
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)
|
||||
.mag(new MagazineSingleReload(0, 1).addConfigs(coil_tungsten, coil_ferrouranium))
|
||||
.offset(0.75, -0.0625, -0.1875D)
|
||||
.setupStandardFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_COILGUN_ANIMS).orchestra(Orchestras.ORCHESTRA_COILGUN)
|
||||
).setUnlocalizedName("gun_coilgun");
|
||||
}
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> LAMBDA_TAU_PRIMARY_RELEASE = (stack, ctx) -> {
|
||||
if(ctx.getPlayer() == null) return;
|
||||
if(ctx.getPlayer() == null || ItemGunBaseNT.getLastAnim(stack, ctx.configIndex) != AnimType.CYCLE) return;
|
||||
ctx.getPlayer().worldObj.playSoundEffect(ctx.getPlayer().posX, ctx.getPlayer().posY, ctx.getPlayer().posZ, "hbm:weapon.fire.tauRelease", 1F, 1F);
|
||||
};
|
||||
|
||||
public static BiConsumer<ItemStack, LambdaContext> LAMBDA_TAU_SECONDARY_PRESS = (stack, ctx) -> {
|
||||
if(ctx.getPlayer() == null) return;
|
||||
if(ctx.config.getReceivers(stack)[0].getMagazine(stack).getAmount(stack, ctx.inventory) <= 0) return;
|
||||
ItemGunBaseNT.playAnimation(ctx.getPlayer(), stack, AnimType.SPINUP, ctx.configIndex);
|
||||
tauChargeMag.getMagType(stack); //caches the last loaded ammo
|
||||
};
|
||||
@ -71,7 +135,7 @@ public class XFactoryAccelerator {
|
||||
if(ctx.getPlayer() == null) return;
|
||||
int timer = ItemGunBaseNT.getAnimTimer(stack, ctx.configIndex);
|
||||
|
||||
if(timer >= 10) {
|
||||
if(timer >= 10 && ItemGunBaseNT.getLastAnim(stack, ctx.configIndex) == AnimType.SPINUP) {
|
||||
ItemGunBaseNT.playAnimation(ctx.getPlayer(), stack, AnimType.ALT_CYCLE, ctx.configIndex);
|
||||
int unitsUsed = 1 + Math.min(12, timer / 10);
|
||||
|
||||
@ -112,11 +176,18 @@ public class XFactoryAccelerator {
|
||||
case CYCLE_DRY: return new BusAnimation();
|
||||
case INSPECT: return new BusAnimation()
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(2, 0, 0, 150, IType.SIN_DOWN).addPos(0, 0, 0, 100, IType.SIN_FULL))
|
||||
.addBus("ROTATE", new BusAnimationSequence().addPos(0, 0, -360, 500, IType.SIN_DOWN));
|
||||
.addBus("ROTATE", new BusAnimationSequence().addPos(0, 0, -360 * 3, 500 * 3, IType.SIN_DOWN));
|
||||
case SPINUP: return new BusAnimation()
|
||||
.addBus("ROTATE", new BusAnimationSequence().addPos(0, 0, 360 * 6, 3000, IType.SIN_UP).addPos(0, 0, 0, 0).addPos(0, 0, 360 * 40, 500 * 20));
|
||||
}
|
||||
|
||||
return null;
|
||||
};
|
||||
|
||||
public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_COILGUN_ANIMS = (stack, type) -> {
|
||||
if(type == AnimType.EQUIP) return new BusAnimation().addBus("RELOAD", new BusAnimationSequence().addPos(1, 0, 0, 0).addPos(0, 0, 0, 250));
|
||||
if(type == AnimType.CYCLE) return new BusAnimation().addBus("RECOIL", new BusAnimationSequence().addPos(ItemGunBaseNT.getIsAiming(stack) ? 0.5 : 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));
|
||||
return null;
|
||||
};
|
||||
}
|
||||
|
||||
@ -0,0 +1,176 @@
|
||||
package com.hbm.items.weapon.sedna.factory;
|
||||
|
||||
import java.util.Random;
|
||||
import java.util.function.BiConsumer;
|
||||
import java.util.function.BiFunction;
|
||||
|
||||
import com.hbm.entity.logic.EntityNukeExplosionMK5;
|
||||
import com.hbm.entity.projectile.EntityBulletBaseMK4;
|
||||
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.handler.radiation.ChunkRadiationManager;
|
||||
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.WeaponQuality;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmo;
|
||||
import com.hbm.items.weapon.sedna.mags.MagazineSingleReload;
|
||||
import com.hbm.main.MainRegistry;
|
||||
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 cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class XFactoryCatapult {
|
||||
|
||||
public static BulletConfig nuke_standard;
|
||||
public static BulletConfig nuke_demo;
|
||||
public static BulletConfig nuke_high;
|
||||
public static BulletConfig nuke_tots;
|
||||
public static BulletConfig nuke_hive;
|
||||
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_NUKE_STANDARD = (bullet, mop) -> {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 3) return;
|
||||
if(bullet.isDead) return;
|
||||
bullet.setDead();
|
||||
|
||||
ExplosionVNT vnt = new ExplosionVNT(bullet.worldObj, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, 10);
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(2, bullet.damage).withRangeMod(1.5F));
|
||||
vnt.setPlayerProcessor(new PlayerProcessorStandard());
|
||||
vnt.explode();
|
||||
|
||||
incrementRad(bullet.worldObj, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, 1F);
|
||||
spawnMush(bullet, mop);
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_NUKE_DEMO = (bullet, mop) -> {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 3) return;
|
||||
if(bullet.isDead) return;
|
||||
bullet.setDead();
|
||||
|
||||
ExplosionVNT vnt = new ExplosionVNT(bullet.worldObj, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, 10);
|
||||
vnt.setBlockAllocator(new BlockAllocatorStandard(64));
|
||||
vnt.setBlockProcessor(new BlockProcessorStandard());
|
||||
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(2, bullet.damage).withRangeMod(1.5F));
|
||||
vnt.setPlayerProcessor(new PlayerProcessorStandard());
|
||||
vnt.explode();
|
||||
|
||||
incrementRad(bullet.worldObj, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, 1.5F);
|
||||
spawnMush(bullet, mop);
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_NUKE_HIGH = (bullet, mop) -> {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 3) return;
|
||||
if(bullet.isDead) return;
|
||||
bullet.setDead();
|
||||
bullet.worldObj.spawnEntityInWorld(EntityNukeExplosionMK5.statFac(bullet.worldObj, 35, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord));
|
||||
spawnMush(bullet, mop);
|
||||
};
|
||||
|
||||
public static void incrementRad(World world, double posX, double posY, double posZ, float mult) {
|
||||
for(int i = -2; i <= 2; i++) { for(int j = -2; j <= 2; j++) {
|
||||
if(Math.abs(i) + Math.abs(j) < 4) {
|
||||
ChunkRadiationManager.proxy.incrementRad(world, (int) Math.floor(posX + i * 16), (int) Math.floor(posY), (int) Math.floor(posZ + j * 16), 50F / (Math.abs(i) + Math.abs(j) + 1) * mult);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static void spawnMush(EntityBulletBaseMK4 bullet, MovingObjectPosition mop) {
|
||||
bullet.worldObj.playSoundEffect(mop.hitVec.xCoord, mop.hitVec.yCoord + 0.5, mop.hitVec.zCoord, "hbm:weapon.mukeExplosion", 15.0F, 1.0F);
|
||||
NBTTagCompound data = new NBTTagCompound();
|
||||
data.setString("type", "muke");
|
||||
data.setBoolean("balefire", MainRegistry.polaroidID == 11 || bullet.worldObj.rand.nextInt(100) == 0);
|
||||
PacketDispatcher.wrapper.sendToAllAround(new AuxParticlePacketNT(data, mop.hitVec.xCoord, mop.hitVec.yCoord + 0.5, mop.hitVec.zCoord), new TargetPoint(bullet.dimension, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, 250));
|
||||
}
|
||||
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_NUKE_TINYTOT = (bullet, mop) -> {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 3) return;
|
||||
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.setPlayerProcessor(new PlayerProcessorStandard());
|
||||
vnt.explode();
|
||||
|
||||
incrementRad(bullet.worldObj, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, 0.25F);
|
||||
bullet.worldObj.playSoundEffect(mop.hitVec.xCoord, mop.hitVec.yCoord + 0.5, mop.hitVec.zCoord, "hbm:weapon.mukeExplosion", 15.0F, 1.0F);
|
||||
NBTTagCompound data = new NBTTagCompound();
|
||||
data.setString("type", "tinytot");
|
||||
data.setBoolean("balefire", MainRegistry.polaroidID == 11 || bullet.worldObj.rand.nextInt(100) == 0);
|
||||
PacketDispatcher.wrapper.sendToAllAround(new AuxParticlePacketNT(data, mop.hitVec.xCoord, mop.hitVec.yCoord + 0.5, mop.hitVec.zCoord), new TargetPoint(bullet.dimension, mop.hitVec.xCoord, mop.hitVec.yCoord, mop.hitVec.zCoord, 250));
|
||||
};
|
||||
|
||||
public static BiConsumer<EntityBulletBaseMK4, MovingObjectPosition> LAMBDA_NUKE_HIVE = (bullet, mop) -> {
|
||||
if(mop.typeOfHit == mop.typeOfHit.ENTITY && bullet.ticksExisted < 3) return;
|
||||
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.setPlayerProcessor(new PlayerProcessorStandard());
|
||||
vnt.setSFX(new ExplosionEffectWeapon(10, 2.5F, 1F));
|
||||
vnt.explode();
|
||||
};
|
||||
|
||||
public static void init() {
|
||||
|
||||
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);
|
||||
|
||||
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)
|
||||
.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))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_FATMAN_ANIMS).orchestra(Orchestras.ORCHESTRA_FATMAN)
|
||||
).setUnlocalizedName("gun_fatman");
|
||||
}
|
||||
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_FATMAN_ANIMS = (stack, type) -> {
|
||||
switch(type) {
|
||||
case EQUIP: return new BusAnimation()
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(60, 0, 0, 0).addPos(0, 0, 0, 1000, IType.SIN_DOWN));
|
||||
case CYCLE:
|
||||
Random rand = MainRegistry.proxy.me().getRNG();
|
||||
return new BusAnimation()
|
||||
.addBus("GAUGE", new BusAnimationSequence().addPos(0, 0, 135 + rand.nextInt(136), 100, IType.SIN_DOWN).addPos(0, 0, 0, 500, IType.SIN_DOWN))
|
||||
.addBus("PISTON", new BusAnimationSequence().addPos(0, 0, 3, 100, IType.SIN_UP))
|
||||
.addBus("NUKE", new BusAnimationSequence().addPos(0, 0, 3, 100, IType.SIN_UP).addPos(0, 0, 0, 0));
|
||||
case RELOAD: return new BusAnimation()
|
||||
.addBus("LID", new BusAnimationSequence().addPos(0, 0, 0, 250).addPos(0, 0, -45, 250, IType.SIN_UP).addPos(0, 0, -45, 1200).addPos(0, 0, 0, 250, IType.SIN_UP))
|
||||
.addBus("HANDLE", new BusAnimationSequence().addPos(0, 0, -2, 500, IType.SIN_FULL).addPos(0, 0, -2, 1700).addPos(0, 0, 0, 750, IType.SIN_FULL))
|
||||
.addBus("NUKE", new BusAnimationSequence().addPos(5, -4, 3, 0).addPos(5, -4, 3, 750).addPos(2, 0.5, 3, 500, IType.SIN_UP).addPos(1, 0.5, 3, 100).addPos(0, 0, 3, 100).addPos(0, 0, 3, 750).addPos(0, 0, 0, 750, IType.SIN_FULL))
|
||||
.addBus("PISTON", new BusAnimationSequence().addPos(0, 0, 3, 0).addPos(0, 0, 3, 2200).addPos(0, 0, 0, 750, IType.SIN_FULL))
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(5, 0, 0, 500, IType.SIN_FULL).addPos(0, 0, 0, 500, IType.SIN_FULL).addPos(0, 0, 0, 450).addPos(3, 0, 0, 100, IType.SIN_DOWN).addPos(0, 0, 0, 100, IType.SIN_FULL).addPos(0, 0, 0, 500).addPos(-10, 0, 0, 375, IType.SIN_DOWN).addPos(0, 0, 0, 375, IType.SIN_UP));
|
||||
case JAMMED: return new BusAnimation()
|
||||
.addBus("HANDLE", new BusAnimationSequence().addPos(0, 0, 0, 750).addPos(0, 0, -2, 250, IType.SIN_FULL).addPos(0, 0, 0, 250, IType.SIN_FULL).addPos(0, 0, -2, 250, IType.SIN_FULL).addPos(0, 0, 0, 250, IType.SIN_FULL))
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(-15, 0, 0, 250, IType.SIN_FULL).addPos(-15, 0, 0, 1000).addPos(0, 0, 0, 250, IType.SIN_FULL));
|
||||
case INSPECT: return new BusAnimation()
|
||||
.addBus("HANDLE", new BusAnimationSequence().addPos(0, 0, 0, 250).addPos(0, 0, -2, 250, IType.SIN_FULL).addPos(0, 0, 0, 250, IType.SIN_FULL).addPos(0, 0, -2, 250, IType.SIN_FULL).addPos(0, 0, 0, 250, IType.SIN_FULL))
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(-15, 0, 0, 250, IType.SIN_FULL).addPos(-15, 0, 0, 1000).addPos(0, 0, 0, 250, IType.SIN_FULL));
|
||||
}
|
||||
return null;
|
||||
};
|
||||
}
|
||||
@ -16,6 +16,8 @@ import com.hbm.items.weapon.sedna.Receiver;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT.WeaponQuality;
|
||||
import com.hbm.items.weapon.sedna.factory.GunFactory.EnumAmmo;
|
||||
import com.hbm.items.weapon.sedna.mags.MagazineBelt;
|
||||
import com.hbm.items.weapon.sedna.mags.MagazineFullReload;
|
||||
import com.hbm.lib.RefStrings;
|
||||
import com.hbm.main.MainRegistry;
|
||||
import com.hbm.packet.PacketDispatcher;
|
||||
import com.hbm.packet.toclient.AuxParticlePacketNT;
|
||||
@ -31,13 +33,20 @@ 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.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
public class XFactoryEnergy {
|
||||
|
||||
public static final ResourceLocation scope_luna = new ResourceLocation(RefStrings.MODID, "textures/misc/scope_luna.png");
|
||||
|
||||
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 BiConsumer<EntityBulletBeamBase, MovingObjectPosition> LAMBDA_LIGHTNING_HIT = (beam, mop) -> {
|
||||
|
||||
@ -86,8 +95,12 @@ public class XFactoryEnergy {
|
||||
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);
|
||||
|
||||
ModItems.gun_tesla_cannon = new ItemGunBaseNT(WeaponQuality.A_SIDE, new GunConfig()
|
||||
.dura(2_000).draw(10).inspect(33).reloadSequential(true).crosshair(Crosshair.CIRCLE).smoke(Lego.LAMBDA_STANDARD_SMOKE)
|
||||
.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))
|
||||
@ -96,6 +109,17 @@ public class XFactoryEnergy {
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_TESLA_ANIMS).orchestra(Orchestras.ORCHESTRA_TESLA)
|
||||
).setUnlocalizedName("gun_tesla_cannon");
|
||||
|
||||
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))
|
||||
.offset(0.75, -0.0625 * 1.5, -0.1875)
|
||||
.setupBeamFire().recoil(Lego.LAMBDA_STANDARD_RECOIL))
|
||||
.setupStandardConfiguration()
|
||||
.anim(LAMBDA_LASRIFLE).orchestra(Orchestras.ORCHESTRA_LASRIFLE)
|
||||
).setUnlocalizedName("gun_lasrifle");
|
||||
}
|
||||
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_TESLA_ANIMS = (stack, type) -> {
|
||||
@ -116,4 +140,30 @@ public class XFactoryEnergy {
|
||||
|
||||
return null;
|
||||
};
|
||||
|
||||
@SuppressWarnings("incomplete-switch") public static BiFunction<ItemStack, AnimType, BusAnimation> LAMBDA_LASRIFLE = (stack, type) -> {
|
||||
int amount = ((ItemGunBaseNT) stack.getItem()).getConfig(stack, 0).getReceivers(stack)[0].getMagazine(stack).getAmount(stack, MainRegistry.proxy.me().inventory);
|
||||
switch(type) {
|
||||
case EQUIP: return new BusAnimation()
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(60, 0, 0, 0).addPos(0, 0, 0, 500, IType.SIN_DOWN));
|
||||
case CYCLE: return new BusAnimation()
|
||||
.addBus("RECOIL", new BusAnimationSequence().addPos(0, 0, -0.5, 50, IType.SIN_DOWN).addPos(0, 0, 0, 150, IType.SIN_FULL))
|
||||
.addBus("CYCLE", new BusAnimationSequence().addPos(0, 0, 0, 150).addPos(0, 0, 22.5, 350))
|
||||
.addBus("COUNT", new BusAnimationSequence().addPos(amount, 0, 0, 0));
|
||||
case RELOAD: return new BusAnimation()
|
||||
.addBus("LEVER", new BusAnimationSequence().addPos(-90, 0, 0, 350, IType.SIN_UP).addPos(-90, 0, 0, 1500).addPos(0, 0, 0, 350, IType.SIN_UP))
|
||||
.addBus("MAG", new BusAnimationSequence().addPos(0, 0, 0, 350).addPos(0, -5, 0, 350, IType.SIN_UP).addPos(0, -5, 0, 500).addPos(0, -0.25, 0, 500, IType.SIN_FULL).addPos(0, -0.25, 0, 150).addPos(0, 0, 0, 350))
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(0, 0, 0, 1700).addPos(-2, 0, 0, 100, IType.SIN_DOWN).addPos(0, 0, 0, 100, IType.SIN_FULL));
|
||||
case JAMMED: return new BusAnimation()
|
||||
.addBus("LEVER", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(-90, 0, 0, 350, IType.SIN_UP).addPos(-90, 0, 0, 600).addPos(0, 0, 0, 350, IType.SIN_UP))
|
||||
.addBus("MAG", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(0, 0, 0, 350).addPos(0, -2, 0, 200, IType.SIN_UP).addPos(0, -0.25, 0, 250, IType.SIN_FULL).addPos(0, -0.25, 0, 150).addPos(0, 0, 0, 350))
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(0, 0, 0, 500).addPos(0, 0, 0, 800).addPos(-2, 0, 0, 100, IType.SIN_DOWN).addPos(0, 0, 0, 100, IType.SIN_FULL));
|
||||
case INSPECT: return new BusAnimation()
|
||||
.addBus("LEVER", new BusAnimationSequence().addPos(-90, 0, 0, 350, IType.SIN_UP).addPos(-90, 0, 0, 600).addPos(0, 0, 0, 350, IType.SIN_UP))
|
||||
.addBus("MAG", new BusAnimationSequence().addPos(0, 0, 0, 350).addPos(0, -2, 0, 200, IType.SIN_UP).addPos(0, -0.25, 0, 250, IType.SIN_FULL).addPos(0, -0.25, 0, 150).addPos(0, 0, 0, 350))
|
||||
.addBus("EQUIP", new BusAnimationSequence().addPos(0, 0, 0, 800).addPos(-2, 0, 0, 100, IType.SIN_DOWN).addPos(0, 0, 0, 100, IType.SIN_FULL));
|
||||
}
|
||||
|
||||
return null;
|
||||
};
|
||||
}
|
||||
|
||||
@ -541,7 +541,6 @@ public class ClientProxy extends ServerProxy {
|
||||
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_fatman, new ItemRenderFatMan());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_proto, new ItemRenderFatMan());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_mirv, new ItemRenderMIRVLauncher());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_bf, new ItemRenderBFLauncher());
|
||||
@ -583,7 +582,6 @@ public class ClientProxy extends ServerProxy {
|
||||
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, new ItemRenderWeaponBolter());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_bolter_digamma, new ItemRenderWeaponBolter());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_fireext, new ItemRenderFireExt());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_ar15, new ItemRenderWeaponAR15());
|
||||
@ -598,7 +596,6 @@ public class ClientProxy extends ServerProxy {
|
||||
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_coilgun, new ItemRenderWeaponCoilgun());
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.gun_cryocannon, new ItemRenderWeaponCryoCannon());
|
||||
//multitool
|
||||
MinecraftForgeClient.registerItemRenderer(ModItems.multitool_dig, new ItemRenderMultitool());
|
||||
|
||||
@ -25,6 +25,7 @@ import com.hbm.items.machine.ItemDepletedFuel;
|
||||
import com.hbm.items.machine.ItemFluidDuct;
|
||||
import com.hbm.items.machine.ItemRBMKPellet;
|
||||
import com.hbm.items.weapon.ItemGunBase;
|
||||
import com.hbm.items.weapon.sedna.GunConfig;
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT;
|
||||
import com.hbm.lib.Library;
|
||||
import com.hbm.lib.RefStrings;
|
||||
@ -34,6 +35,7 @@ import com.hbm.packet.toserver.GunButtonPacket;
|
||||
import com.hbm.render.anim.HbmAnimations;
|
||||
import com.hbm.render.anim.HbmAnimations.Animation;
|
||||
import com.hbm.render.block.ct.CTStitchReceiver;
|
||||
import com.hbm.render.item.weapon.sedna.ItemRenderWeaponBase;
|
||||
import com.hbm.render.util.RenderAccessoryUtility;
|
||||
import com.hbm.render.util.RenderOverhead;
|
||||
import com.hbm.render.util.RenderScreenOverlay;
|
||||
@ -96,6 +98,7 @@ import net.minecraft.util.*;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.WorldProviderSurface;
|
||||
import net.minecraftforge.client.GuiIngameForge;
|
||||
import net.minecraftforge.client.IItemRenderer;
|
||||
import net.minecraftforge.client.IRenderHandler;
|
||||
import net.minecraftforge.client.event.*;
|
||||
import net.minecraftforge.client.event.RenderGameOverlayEvent.ElementType;
|
||||
@ -321,6 +324,15 @@ public class ModEventHandlerClient {
|
||||
}
|
||||
}
|
||||
|
||||
if(held != null && held.getItem() instanceof ItemGunBaseNT && ItemGunBaseNT.aimingProgress == ItemGunBaseNT.prevAimingProgress && ItemGunBaseNT.aimingProgress == 1F && event.type == event.type.HOTBAR) {
|
||||
ItemGunBaseNT gun = (ItemGunBaseNT) held.getItem();
|
||||
GunConfig cfg = gun.getConfig(held, 0);
|
||||
if(cfg.getScopeTexture(held) != null) {
|
||||
ScaledResolution resolution = event.resolution;
|
||||
RenderScreenOverlay.renderScope(resolution, cfg.getScopeTexture(held));
|
||||
}
|
||||
}
|
||||
|
||||
/// HANDLE FSB HUD ///
|
||||
ItemStack helmet = player.inventory.armorInventory[3];
|
||||
|
||||
@ -456,6 +468,20 @@ public class ModEventHandlerClient {
|
||||
}
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
public void setupNewFOV(FOVUpdateEvent event) {
|
||||
|
||||
EntityPlayer player = Minecraft.getMinecraft().thePlayer;
|
||||
ItemStack held = player.getHeldItem();
|
||||
|
||||
if(held == null) return;
|
||||
|
||||
IItemRenderer customRenderer = MinecraftForgeClient.getItemRenderer(held, IItemRenderer.ItemRenderType.EQUIPPED);
|
||||
if(!(customRenderer instanceof ItemRenderWeaponBase)) return;
|
||||
ItemRenderWeaponBase renderGun = (ItemRenderWeaponBase) customRenderer;
|
||||
event.newfov = renderGun.getViewFOV(held, event.fov);
|
||||
}
|
||||
|
||||
public static boolean ducked = false;
|
||||
|
||||
@SubscribeEvent
|
||||
|
||||
@ -861,6 +861,9 @@ public class ResourceManager {
|
||||
public static final IModelCustom tesla_cannon = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/weapons/tesla_cannon.obj")).asVBO();
|
||||
public static final IModelCustom stg77 = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/weapons/stg77.obj")).asVBO();
|
||||
public static final IModelCustom tau = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/weapons/tau.obj")).asVBO();
|
||||
public static final IModelCustom fatman = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/weapons/fatman.obj")).asVBO();
|
||||
public static final IModelCustom lasrifle = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/weapons/lasrifle.obj")).asVBO();
|
||||
public static final IModelCustom hangman = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/weapons/hangman.obj")).asVBO();
|
||||
|
||||
public static final HashMap<String, BusAnimation> python_anim = AnimationLoader.load(new ResourceLocation(RefStrings.MODID, "models/weapons/animations/python.json"));
|
||||
public static final HashMap<String, BusAnimation> cursed_anim = AnimationLoader.load(new ResourceLocation(RefStrings.MODID, "models/weapons/animations/cursed.json"));
|
||||
@ -872,6 +875,7 @@ public class ResourceManager {
|
||||
public static final HashMap<String, BusAnimation> congolake_anim = AnimationLoader.load(new ResourceLocation(RefStrings.MODID, "models/weapons/animations/congolake.json"));
|
||||
public static final HashMap<String, BusAnimation> am180_anim = AnimationLoader.load(new ResourceLocation(RefStrings.MODID, "models/weapons/animations/am180.json"));
|
||||
public static final HashMap<String, BusAnimation> flamethrower_anim = AnimationLoader.load(new ResourceLocation(RefStrings.MODID, "models/weapons/animations/flamethrower.json"));
|
||||
public static final HashMap<String, BusAnimation> stg77_anim = AnimationLoader.load(new ResourceLocation(RefStrings.MODID, "models/weapons/animations/stg77.json"));
|
||||
|
||||
public static final IModelCustom lance = new HFRWavefrontObject(new ResourceLocation(RefStrings.MODID, "models/weapons/lance.obj"));
|
||||
|
||||
@ -994,6 +998,10 @@ public class ResourceManager {
|
||||
public static final ResourceLocation tesla_cannon_tex = new ResourceLocation(RefStrings.MODID, "textures/models/weapons/tesla_cannon.png");
|
||||
public static final ResourceLocation stg77_tex = new ResourceLocation(RefStrings.MODID, "textures/models/weapons/stg77.png");
|
||||
public static final ResourceLocation tau_tex = new ResourceLocation(RefStrings.MODID, "textures/models/weapons/tau.png");
|
||||
public static final ResourceLocation fatman_tex = new ResourceLocation(RefStrings.MODID, "textures/models/weapons/fatman.png");
|
||||
public static final ResourceLocation fatman_mininuke_tex = new ResourceLocation(RefStrings.MODID, "textures/models/weapons/fatman_mininuke.png");
|
||||
public static final ResourceLocation lasrifle_tex = new ResourceLocation(RefStrings.MODID, "textures/models/weapons/lasrifle.png");
|
||||
public static final ResourceLocation hangman_tex = new ResourceLocation(RefStrings.MODID, "textures/models/weapons/hangman.png");
|
||||
|
||||
public static final ResourceLocation lance_tex = new ResourceLocation(RefStrings.MODID, "textures/models/weapons/lance.png");
|
||||
|
||||
|
||||
@ -62,7 +62,7 @@ public class ParticleBlackPowderSmoke extends EntityFXRotating {
|
||||
|
||||
double ageScaled = (double) (this.particleAge + interp) / (double) this.particleMaxAge;
|
||||
|
||||
Color color = Color.getHSBColor(hue / 255F, Math.max(1F - (float) ageScaled * 2F, 0), MathHelper.clamp_float(1.25F - (float) ageScaled * 2F, 0.7F, 1F));
|
||||
Color color = Color.getHSBColor(hue / 255F, Math.max(1F - (float) ageScaled * 4F, 0), MathHelper.clamp_float(1.25F - (float) ageScaled * 2F, 0.7F, 1F));
|
||||
this.particleRed = color.getRed() / 255F;
|
||||
this.particleGreen = color.getGreen() / 255F;
|
||||
this.particleBlue = color.getBlue() / 255F;
|
||||
|
||||
@ -54,27 +54,29 @@ public class ParticleMukeCloud extends EntityFX {
|
||||
return 3;
|
||||
}
|
||||
|
||||
public void onUpdate() {
|
||||
|
||||
this.prevPosX = this.posX;
|
||||
this.prevPosY = this.posY;
|
||||
this.prevPosZ = this.posZ;
|
||||
public void onUpdate() {
|
||||
|
||||
this.noClip = this.particleAge <= 2;
|
||||
|
||||
if (this.particleAge++ >= this.particleMaxAge - 2) {
|
||||
this.setDead();
|
||||
}
|
||||
this.prevPosX = this.posX;
|
||||
this.prevPosY = this.posY;
|
||||
this.prevPosZ = this.posZ;
|
||||
|
||||
this.motionY -= 0.04D * (double)this.particleGravity;
|
||||
this.moveEntity(this.motionX, this.motionY, this.motionZ);
|
||||
this.motionX *= friction;
|
||||
this.motionY *= friction;
|
||||
this.motionZ *= friction;
|
||||
if(this.particleAge++ >= this.particleMaxAge - 2) {
|
||||
this.setDead();
|
||||
}
|
||||
|
||||
if (this.onGround) {
|
||||
this.motionX *= 0.7D;
|
||||
this.motionZ *= 0.7D;
|
||||
}
|
||||
}
|
||||
this.motionY -= 0.04D * (double) this.particleGravity;
|
||||
this.moveEntity(this.motionX, this.motionY, this.motionZ);
|
||||
this.motionX *= friction;
|
||||
this.motionY *= friction;
|
||||
this.motionZ *= friction;
|
||||
|
||||
if(this.onGround) {
|
||||
this.motionX *= 0.7D;
|
||||
this.motionZ *= 0.7D;
|
||||
}
|
||||
}
|
||||
|
||||
public void renderParticle(Tessellator tess, float interp, float x, float y, float z, float tx, float tz) {
|
||||
|
||||
|
||||
@ -75,8 +75,7 @@ public class ItemRenderWeaponBolter implements IItemRenderer {
|
||||
GL11.glRotated(mag[0] * 60 * (mag[2] == 1 ? 2.5 : 1), -1, 0, 0);
|
||||
GL11.glTranslated(0, 0, -5);
|
||||
ResourceManager.bolter.renderPart("Mag");
|
||||
if(mag[2] != 1)
|
||||
ResourceManager.bolter.renderPart("Bullet");
|
||||
if(mag[2] != 1) ResourceManager.bolter.renderPart("Bullet");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glPushMatrix();
|
||||
|
||||
@ -15,6 +15,12 @@ public class ItemRenderAm180 extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -14,6 +14,12 @@ public class ItemRenderAtlas extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -0,0 +1,119 @@
|
||||
package com.hbm.render.item.weapon.sedna;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT;
|
||||
import com.hbm.main.ResourceManager;
|
||||
import com.hbm.render.anim.HbmAnimations;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.FontRenderer;
|
||||
import net.minecraft.client.renderer.OpenGlHelper;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class ItemRenderBolter extends ItemRenderWeaponBase {
|
||||
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
float offset = 0.8F;
|
||||
standardAimingTransform(stack,
|
||||
-1.5F * offset, -2F * offset, 2.5F * offset,
|
||||
0, -10.5 / 8D, 1.25);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderFirstPerson(ItemStack stack) {
|
||||
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.bolter_tex);
|
||||
double scale = 0.5D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
|
||||
GL11.glRotated(180, 0, 1, 0);
|
||||
|
||||
double[] recoil = HbmAnimations.getRelevantTransformation("RECOIL");
|
||||
GL11.glRotated(recoil[0] * 5, 1, 0, 0);
|
||||
GL11.glTranslated(0, 0, recoil[0]);
|
||||
|
||||
double[] tilt = HbmAnimations.getRelevantTransformation("TILT");
|
||||
GL11.glTranslated(0, tilt[0], 3);
|
||||
GL11.glRotated(tilt[0] * 35, 1, 0, 0);
|
||||
GL11.glTranslated(0, 0, -3);
|
||||
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
ResourceManager.bolter.renderPart("Body");
|
||||
|
||||
double[] mag = HbmAnimations.getRelevantTransformation("MAG");
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(0, 0, 5);
|
||||
GL11.glRotated(mag[0] * 60 * (mag[2] == 1 ? 2.5 : 1), -1, 0, 0);
|
||||
GL11.glTranslated(0, 0, -5);
|
||||
ResourceManager.bolter.renderPart("Mag");
|
||||
if(mag[2] != 1) ResourceManager.bolter.renderPart("Bullet");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glPushAttrib(GL11.GL_LIGHTING_BIT);
|
||||
GL11.glDisable(GL11.GL_LIGHTING);
|
||||
GL11.glDisable(GL11.GL_CULL_FACE);
|
||||
OpenGlHelper.glBlendFunc(770, 771, 1, 0);
|
||||
OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, 240F, 240F);
|
||||
|
||||
FontRenderer font = Minecraft.getMinecraft().fontRenderer;
|
||||
ItemGunBaseNT gun = (ItemGunBaseNT) stack.getItem();
|
||||
String s = gun.getConfig(stack, 0).getReceivers(stack)[0].getMagazine(stack).getAmount(stack, null) + "";
|
||||
float f3 = 0.04F;
|
||||
GL11.glTranslatef(0.025F - (font.getStringWidth(s) / 2) * 0.04F, 2.11F, 2.91F);
|
||||
GL11.glScalef(f3, -f3, f3);
|
||||
GL11.glRotatef(45, 1, 0, 0);
|
||||
GL11.glNormal3f(0.0F, 0.0F, -1.0F * f3);
|
||||
font.drawString(s, 0, 0, 0xff0000);
|
||||
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
GL11.glPopAttrib();
|
||||
GL11.glPopMatrix();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupThirdPerson(ItemStack stack) {
|
||||
super.setupThirdPerson(stack);
|
||||
double scale = 3D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
GL11.glTranslated(0, 0.25, 1.25);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupInv(ItemStack stack) {
|
||||
super.setupInv(stack);
|
||||
double scale = 2.75D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
GL11.glRotated(25, 1, 0, 0);
|
||||
GL11.glRotated(45, 0, 1, 0);
|
||||
GL11.glTranslated(-0.25, -0.5, 0);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderOther(ItemStack stack, ItemRenderType type) {
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
|
||||
GL11.glRotated(180, 0, 1, 0);
|
||||
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.bolter_tex);
|
||||
ResourceManager.bolter.renderAll();
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}
|
||||
}
|
||||
@ -14,6 +14,12 @@ public class ItemRenderCarbine extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -0,0 +1,88 @@
|
||||
package com.hbm.render.item.weapon.sedna;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT;
|
||||
import com.hbm.main.ResourceManager;
|
||||
import com.hbm.render.anim.HbmAnimations;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class ItemRenderCoilgun extends ItemRenderWeaponBase {
|
||||
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
float offset = 0.8F;
|
||||
standardAimingTransform(stack,
|
||||
-1.25F * offset, -1.5F * offset, 2.5F * offset,
|
||||
0, -7.5 / 8D, 1);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderFirstPerson(ItemStack stack) {
|
||||
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.flaregun_tex);
|
||||
double scale = 0.75D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
|
||||
GL11.glRotated(-90, 0, 1, 0);
|
||||
|
||||
double[] recoil = HbmAnimations.getRelevantTransformation("RECOIL");
|
||||
GL11.glTranslated(-1.5 - recoil[0] * 0.5, 0, 0);
|
||||
GL11.glRotated(recoil[0] * 45, 0, 0, 1);
|
||||
GL11.glTranslated(1.5, 0, 0);
|
||||
|
||||
double[] reload = HbmAnimations.getRelevantTransformation("RELOAD");
|
||||
GL11.glTranslated(-2.5, 0, 0);
|
||||
GL11.glRotated(reload[0] * -45, 0, 0, 1);
|
||||
GL11.glTranslated(2.5, 0, 0);
|
||||
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.coilgun_tex);
|
||||
ResourceManager.coilgun.renderAll();
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupThirdPerson(ItemStack stack) {
|
||||
super.setupThirdPerson(stack);
|
||||
double scale = 3D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
GL11.glTranslated(0, 0.25, 1.25);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupInv(ItemStack stack) {
|
||||
super.setupInv(stack);
|
||||
double scale = 4D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
GL11.glRotated(25, 1, 0, 0);
|
||||
GL11.glRotated(45, 0, 1, 0);
|
||||
GL11.glTranslated(-0.25, -0.25, 0);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderOther(ItemStack stack, ItemRenderType type) {
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
|
||||
GL11.glRotated(-90, 0, 1, 0);
|
||||
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.coilgun_tex);
|
||||
ResourceManager.coilgun.renderAll();
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}
|
||||
}
|
||||
@ -20,6 +20,12 @@ public class ItemRenderCongoLake extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
@ -27,7 +33,7 @@ public class ItemRenderCongoLake extends ItemRenderWeaponBase {
|
||||
float offset = 0.8F;
|
||||
standardAimingTransform(stack,
|
||||
-1.5F * offset, -2F * offset, 1.25F * offset,
|
||||
0, -9 / 8D, 0.25);
|
||||
0, -10 / 8D, 0.25);
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -52,7 +58,11 @@ public class ItemRenderCongoLake extends ItemRenderWeaponBase {
|
||||
|
||||
GL11.glPushMatrix();
|
||||
{
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
HbmAnimations.applyRelevantTransformation("Sight");
|
||||
GL11.glTranslated(0, 2.125, 3);
|
||||
GL11.glRotated(aimingProgress * -90, 1, 0, 0);
|
||||
GL11.glTranslated(0, -2.125, -3);
|
||||
ResourceManager.congolake.renderPart("Sight");
|
||||
}
|
||||
GL11.glPopMatrix();
|
||||
|
||||
@ -0,0 +1,130 @@
|
||||
package com.hbm.render.item.weapon.sedna;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT;
|
||||
import com.hbm.main.ResourceManager;
|
||||
import com.hbm.render.anim.HbmAnimations;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class ItemRenderFatMan extends ItemRenderWeaponBase {
|
||||
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
float offset = 0.8F;
|
||||
standardAimingTransform(stack,
|
||||
-1.5F * offset, -1.25F * offset, 0.5F * offset,
|
||||
-1F * offset, -1.25F * offset, 0F * offset);
|
||||
}
|
||||
|
||||
protected static String label = "AUTO";
|
||||
|
||||
@Override
|
||||
public void renderFirstPerson(ItemStack stack) {
|
||||
|
||||
ItemGunBaseNT gun = (ItemGunBaseNT) stack.getItem();
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.fatman_tex);
|
||||
double scale = 0.5D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
|
||||
boolean isLoaded = gun.getConfig(stack, 0).getReceivers(stack)[0].getMagazine(stack).getAmount(stack, null) > 0;
|
||||
|
||||
double[] equip = HbmAnimations.getRelevantTransformation("EQUIP");
|
||||
double[] lid = HbmAnimations.getRelevantTransformation("LID");
|
||||
double[] nuke = HbmAnimations.getRelevantTransformation("NUKE");
|
||||
double[] piston = HbmAnimations.getRelevantTransformation("PISTON");
|
||||
double[] handle = HbmAnimations.getRelevantTransformation("HANDLE");
|
||||
double[] gauge = HbmAnimations.getRelevantTransformation("GAUGE");
|
||||
|
||||
GL11.glTranslated(0, 1, -2);
|
||||
GL11.glRotated(equip[0], 1, 0, 0);
|
||||
GL11.glTranslated(0, -1, 2);
|
||||
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
|
||||
ResourceManager.fatman.renderPart("Launcher");
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(0, 0, handle[2]);
|
||||
ResourceManager.fatman.renderPart("Handle");
|
||||
|
||||
GL11.glTranslated(0.4375, -0.875, 0);
|
||||
GL11.glRotated(gauge[2], 0, 0, 1);
|
||||
GL11.glTranslated(-0.4375, 0.875, 0);
|
||||
ResourceManager.fatman.renderPart("Gauge");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(0.25, 0.125, 0);
|
||||
GL11.glRotated(lid[2], 0, 0, 1);
|
||||
GL11.glTranslated(-0.25, -0.125, 0);
|
||||
ResourceManager.fatman.renderPart("Lid");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(0, 0, piston[2]);
|
||||
if(!isLoaded && piston[2] == 0) GL11.glTranslated(0, 0, 3);
|
||||
ResourceManager.fatman.renderPart("Piston");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
if(isLoaded || nuke[0] != 0 || nuke[1] != 0 || nuke[2] != 0) {
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.fatman_mininuke_tex);
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(nuke[0], nuke[1], nuke[2]);
|
||||
ResourceManager.fatman.renderPart("MiniNuke");
|
||||
GL11.glPopMatrix();
|
||||
}
|
||||
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupThirdPerson(ItemStack stack) {
|
||||
super.setupThirdPerson(stack);
|
||||
double scale = 2.5D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
GL11.glTranslated(-0.5, 0.5, -3);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupInv(ItemStack stack) {
|
||||
super.setupInv(stack);
|
||||
double scale = 1.375D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
GL11.glRotated(25, 1, 0, 0);
|
||||
GL11.glRotated(45, 0, 1, 0);
|
||||
GL11.glTranslated(0, -0.5, 0);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderOther(ItemStack stack, ItemRenderType type) {
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.fatman_tex);
|
||||
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
ResourceManager.fatman.renderPart("Launcher");
|
||||
ResourceManager.fatman.renderPart("Handle");
|
||||
ResourceManager.fatman.renderPart("Gauge");
|
||||
ResourceManager.fatman.renderPart("Lid");
|
||||
ResourceManager.fatman.renderPart("Piston");
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.fatman_mininuke_tex);
|
||||
ItemGunBaseNT gun = (ItemGunBaseNT) stack.getItem();
|
||||
if(gun.getConfig(stack, 0).getReceivers(stack)[0].getMagazine(stack).getAmount(stack, null) > 0) ResourceManager.fatman.renderPart("MiniNuke");
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}
|
||||
}
|
||||
@ -16,6 +16,12 @@ public class ItemRenderFlamer extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -14,6 +14,12 @@ public class ItemRenderFlaregun extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
@ -21,7 +27,7 @@ public class ItemRenderFlaregun extends ItemRenderWeaponBase {
|
||||
float offset = 0.8F;
|
||||
standardAimingTransform(stack,
|
||||
-1.25F * offset, -1.5F * offset, 2F * offset,
|
||||
0, -5.5 / 8D, 1);
|
||||
0, -5.5 / 8D, 0.5);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@ -14,6 +14,12 @@ public class ItemRenderG3 extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
@ -21,7 +27,7 @@ public class ItemRenderG3 extends ItemRenderWeaponBase {
|
||||
float offset = 0.8F;
|
||||
standardAimingTransform(stack,
|
||||
-1.25F * offset, -1F * offset, 2.75F * offset,
|
||||
0, -3.625 / 8D, 1.75);
|
||||
0, -3.5625 / 8D, 1.75);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@ -14,6 +14,12 @@ public class ItemRenderGreasegun extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -0,0 +1,132 @@
|
||||
package com.hbm.render.item.weapon.sedna;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT;
|
||||
import com.hbm.main.ResourceManager;
|
||||
import com.hbm.render.anim.HbmAnimations;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class ItemRenderHangman extends ItemRenderWeaponBase {
|
||||
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
float offset = 0.8F;
|
||||
standardAimingTransform(stack,
|
||||
-1.5F * offset, -0.875F * offset, 1.75F * offset,
|
||||
0, -1.5 / 8D, 1.25);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderFirstPerson(ItemStack stack) {
|
||||
|
||||
ItemGunBaseNT gun = (ItemGunBaseNT) stack.getItem();
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.hangman_tex);
|
||||
float offset = 0.8F;
|
||||
|
||||
double[] equip = HbmAnimations.getRelevantTransformation("EQUIP");
|
||||
double[] recoil = HbmAnimations.getRelevantTransformation("RECOIL");
|
||||
double[] roll = HbmAnimations.getRelevantTransformation("ROLL");
|
||||
double[] turn = HbmAnimations.getRelevantTransformation("TURN");
|
||||
double[] smack = HbmAnimations.getRelevantTransformation("SMACK");
|
||||
double[] lid = HbmAnimations.getRelevantTransformation("LID");
|
||||
double[] mag = HbmAnimations.getRelevantTransformation("MAG");
|
||||
double[] bullets = HbmAnimations.getRelevantTransformation("BULLETS");
|
||||
|
||||
GL11.glTranslated(1.5F * offset, 0, -1);
|
||||
GL11.glRotated(turn[1], 0, 1, 0);
|
||||
GL11.glTranslated(-1.5F * offset, 0, 1);
|
||||
|
||||
GL11.glRotated(roll[2], 0, 0, 1);
|
||||
GL11.glTranslated(smack[0], smack[1], smack[2]);
|
||||
|
||||
double scale = 0.125D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
|
||||
GL11.glTranslated(0, -4, -10);
|
||||
GL11.glRotated(equip[0], 1, 0, 0);
|
||||
GL11.glTranslated(0, 4, 10);
|
||||
|
||||
GL11.glTranslated(0, 0, recoil[2]);
|
||||
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
|
||||
ResourceManager.hangman.renderPart("Rifle");
|
||||
ResourceManager.hangman.renderPart("Internals");
|
||||
|
||||
GL11.glPushMatrix();
|
||||
//i give the fuck up
|
||||
GL11.glTranslated(-2.1875, -1.75, 0);
|
||||
GL11.glRotated(lid[2], 0, 0, 1);
|
||||
GL11.glTranslated(2.1875, 1.75, 0);
|
||||
ResourceManager.hangman.renderPart("Lid");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(mag[0], mag[1], mag[2]);
|
||||
ResourceManager.hangman.renderPart("Magazine");
|
||||
if(bullets[0] == 0) ResourceManager.hangman.renderPart("Bullets");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
double smokeScale = 1.5;
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(0, 0, 29);
|
||||
GL11.glRotated(90, 0, 1, 0);
|
||||
GL11.glScaled(smokeScale, smokeScale, smokeScale);
|
||||
this.renderSmokeNodes(gun.getConfig(stack, 0).smokeNodes, 0.5D);
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(0, 0, 29);
|
||||
GL11.glRotated(90, 0, 1, 0);
|
||||
GL11.glRotated(90 * gun.shotRand, 1, 0, 0);
|
||||
GL11.glScaled(2, 2, 2);
|
||||
this.renderMuzzleFlash(gun.lastShot[0], 75, 7.5);
|
||||
GL11.glPopMatrix();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupThirdPerson(ItemStack stack) {
|
||||
super.setupThirdPerson(stack);
|
||||
double scale = 0.375D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
GL11.glTranslated(0, 4.25, 8);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupInv(ItemStack stack) {
|
||||
super.setupInv(stack);
|
||||
double scale = 0.375D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
GL11.glRotated(25, 1, 0, 0);
|
||||
GL11.glRotated(45, 0, 1, 0);
|
||||
GL11.glTranslated(-0.5, 2.5, 0);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderOther(ItemStack stack, ItemRenderType type) {
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.hangman_tex);
|
||||
ResourceManager.hangman.renderAll();
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}
|
||||
}
|
||||
@ -22,6 +22,12 @@ public class ItemRenderHeavyRevolver extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * (isScoped(stack) ? 0.66F : 0.33F));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 1);
|
||||
@ -38,7 +44,7 @@ public class ItemRenderHeavyRevolver extends ItemRenderWeaponBase {
|
||||
public void renderFirstPerson(ItemStack stack) {
|
||||
|
||||
boolean isScoped = this.isScoped(stack);
|
||||
if(this.isScoped(stack) && ItemGunBaseNT.prevAimingProgress == 1 && ItemGunBaseNT.aimingProgress == 1) return;
|
||||
if(isScoped && ItemGunBaseNT.prevAimingProgress == 1 && ItemGunBaseNT.aimingProgress == 1) return;
|
||||
ItemGunBaseNT gun = (ItemGunBaseNT) stack.getItem();
|
||||
|
||||
double scale = 0.125D;
|
||||
|
||||
@ -14,6 +14,12 @@ public class ItemRenderHenry extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -13,6 +13,12 @@ public class ItemRenderLAG extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -0,0 +1,107 @@
|
||||
package com.hbm.render.item.weapon.sedna;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import com.hbm.items.weapon.sedna.ItemGunBaseNT;
|
||||
import com.hbm.main.ResourceManager;
|
||||
import com.hbm.render.anim.HbmAnimations;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class ItemRenderLasrifle extends ItemRenderWeaponBase {
|
||||
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.75F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
float offset = 0.8F;
|
||||
standardAimingTransform(stack,
|
||||
-1.5F * offset, -1.5F * offset, 2.5F * offset,
|
||||
0, -7.375 / 8D, 0.75);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderFirstPerson(ItemStack stack) {
|
||||
|
||||
if(ItemGunBaseNT.prevAimingProgress == 1 && ItemGunBaseNT.aimingProgress == 1) return;
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.lasrifle_tex);
|
||||
double scale = 0.3125D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
|
||||
double[] equip = HbmAnimations.getRelevantTransformation("EQUIP");
|
||||
double[] recoil = HbmAnimations.getRelevantTransformation("RECOIL");
|
||||
double[] lever = HbmAnimations.getRelevantTransformation("LEVER");
|
||||
double[] mag = HbmAnimations.getRelevantTransformation("MAG");
|
||||
|
||||
GL11.glTranslated(0, -1, -6);
|
||||
GL11.glRotated(equip[0], 1, 0, 0);
|
||||
GL11.glTranslated(0, 1, 6);
|
||||
|
||||
GL11.glTranslated(0, 0, recoil[2]);
|
||||
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
|
||||
ResourceManager.lasrifle.renderPart("Gun");
|
||||
ResourceManager.lasrifle.renderPart("Barrel");
|
||||
ResourceManager.lasrifle.renderPart("Stock");
|
||||
ResourceManager.lasrifle.renderPart("Scope");
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(0, -0.375, 2.375);
|
||||
GL11.glRotated(lever[0], 1, 0, 0);
|
||||
GL11.glTranslated(0, 0.375, -2.375);
|
||||
ResourceManager.lasrifle.renderPart("Lever");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(mag[0], mag[1], mag[2]);
|
||||
ResourceManager.lasrifle.renderPart("Battery");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupThirdPerson(ItemStack stack) {
|
||||
super.setupThirdPerson(stack);
|
||||
double scale = 1.25D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
GL11.glTranslated(0, 0, 4);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupInv(ItemStack stack) {
|
||||
super.setupInv(stack);
|
||||
double scale = 1.0625D;
|
||||
GL11.glScaled(scale, scale, scale);
|
||||
GL11.glRotated(25, 1, 0, 0);
|
||||
GL11.glRotated(45, 0, 1, 0);
|
||||
GL11.glTranslated(0.5, 0, 0);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderOther(ItemStack stack, ItemRenderType type) {
|
||||
GL11.glEnable(GL11.GL_LIGHTING);
|
||||
|
||||
GL11.glShadeModel(GL11.GL_SMOOTH);
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(ResourceManager.lasrifle_tex);
|
||||
ResourceManager.lasrifle.renderPart("Gun");
|
||||
ResourceManager.lasrifle.renderPart("Barrel");
|
||||
ResourceManager.lasrifle.renderPart("Stock");
|
||||
ResourceManager.lasrifle.renderPart("Scope");
|
||||
ResourceManager.lasrifle.renderPart("Lever");
|
||||
ResourceManager.lasrifle.renderPart("Battery");
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}
|
||||
}
|
||||
@ -15,6 +15,12 @@ public class ItemRenderLiberator extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -14,6 +14,12 @@ public class ItemRenderM2 extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -22,6 +22,12 @@ public class ItemRenderMaresleg extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -14,6 +14,12 @@ public class ItemRenderMinigun extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -14,6 +14,12 @@ public class ItemRenderPanzerschreck extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -14,6 +14,12 @@ public class ItemRenderPepperbox extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 1.5);
|
||||
|
||||
@ -18,6 +18,12 @@ public class ItemRenderSPAS12 extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -24,6 +24,18 @@ public class ItemRenderSTG77 extends ItemRenderWeaponBase {
|
||||
0, -5.75 / 8D, 1);
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.66F);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected float getBaseFOV(ItemStack stack) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return 70F - aimingProgress * 55;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void renderFirstPerson(ItemStack stack) {
|
||||
|
||||
@ -63,25 +75,36 @@ public class ItemRenderSTG77 extends ItemRenderWeaponBase {
|
||||
GL11.glRotated(inspectGun[2], 0, 0, 1);
|
||||
GL11.glRotated(inspectGun[0], 1, 0, 0);
|
||||
|
||||
HbmAnimations.applyRelevantTransformation("Gun");
|
||||
ResourceManager.stg77.renderPart("Gun");
|
||||
|
||||
GL11.glPushMatrix();
|
||||
HbmAnimations.applyRelevantTransformation("Magazine");
|
||||
ResourceManager.stg77.renderPart("Magazine");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glRotated(inspectLever[2], 0, 0, 1);
|
||||
HbmAnimations.applyRelevantTransformation("Lever");
|
||||
ResourceManager.stg77.renderPart("Lever");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(0, 0, bolt[2]);
|
||||
GL11.glPushMatrix();
|
||||
HbmAnimations.applyRelevantTransformation("Breech");
|
||||
ResourceManager.stg77.renderPart("Breech");
|
||||
GL11.glPopMatrix();
|
||||
GL11.glTranslated(0.125, 0, 0);
|
||||
GL11.glRotated(handle[2], 0, 0, 1);
|
||||
GL11.glTranslated(-0.125, 0, 0);
|
||||
HbmAnimations.applyRelevantTransformation("Handle");
|
||||
ResourceManager.stg77.renderPart("Handle");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(safety[0], 0, 0);
|
||||
HbmAnimations.applyRelevantTransformation("Safety");
|
||||
ResourceManager.stg77.renderPart("Safety");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
@ -95,6 +118,8 @@ public class ItemRenderSTG77 extends ItemRenderWeaponBase {
|
||||
GL11.glTranslated(inspectMove[0], inspectMove[1], inspectMove[2]);
|
||||
GL11.glRotated(inspectBarrel[0], 1, 0, 0);
|
||||
GL11.glRotated(inspectBarrel[2], 0, 0, 1);
|
||||
HbmAnimations.applyRelevantTransformation("Gun");
|
||||
HbmAnimations.applyRelevantTransformation("Barrel");
|
||||
ResourceManager.stg77.renderPart("Barrel");
|
||||
GL11.glPopMatrix();
|
||||
|
||||
|
||||
@ -28,6 +28,12 @@ public class ItemRenderShredder extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -16,6 +16,12 @@ public class ItemRenderStinger extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.5F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -16,6 +16,12 @@ public class ItemRenderTeslaCannon extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.5F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -14,6 +14,12 @@ public class ItemRenderUzi extends ItemRenderWeaponBase {
|
||||
@Override
|
||||
protected float getTurnMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 2.5F : -0.25F; }
|
||||
|
||||
@Override
|
||||
public float getViewFOV(ItemStack stack, float fov) {
|
||||
float aimingProgress = ItemGunBaseNT.prevAimingProgress + (ItemGunBaseNT.aimingProgress - ItemGunBaseNT.prevAimingProgress) * interp;
|
||||
return fov * (1 - aimingProgress * 0.33F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setupFirstPerson(ItemStack stack) {
|
||||
GL11.glTranslated(0, 0, 0.875);
|
||||
|
||||
@ -98,7 +98,7 @@ public abstract class ItemRenderWeaponBase implements IItemRenderer {
|
||||
|
||||
Minecraft mc = Minecraft.getMinecraft();
|
||||
EntityLivingBase entityplayer = (EntityLivingBase) mc.renderViewEntity;
|
||||
float fov = 70.0F;
|
||||
float fov = getBaseFOV(entityplayer.getHeldItem());
|
||||
|
||||
if(useFOVSetting) fov = mc.gameSettings.fovSetting;
|
||||
|
||||
@ -113,6 +113,8 @@ public abstract class ItemRenderWeaponBase implements IItemRenderer {
|
||||
return fov;
|
||||
}
|
||||
|
||||
protected float getBaseFOV(ItemStack stack) { return 70F; }
|
||||
public float getViewFOV(ItemStack stack, float fov) { return fov; }
|
||||
protected float getSwayMagnitude(ItemStack stack) { return ItemGunBaseNT.getIsAiming(stack) ? 0.1F : 0.5F; }
|
||||
protected float getSwayPeriod(ItemStack stack) { return 0.75F; }
|
||||
protected float getTurnMagnitude(ItemStack stack) { return 2.75F; }
|
||||
@ -159,7 +161,7 @@ public abstract class ItemRenderWeaponBase implements IItemRenderer {
|
||||
GL11.glPushMatrix();
|
||||
|
||||
//swing
|
||||
float swing = player.getSwingProgress(interp);
|
||||
/*float swing = player.getSwingProgress(interp);
|
||||
float swingZ = MathHelper.sin(swing * (float) Math.PI);
|
||||
float swingX = MathHelper.sin(MathHelper.sqrt_float(swing) * (float) Math.PI);
|
||||
GL11.glTranslatef(-swingX * 0.4F, MathHelper.sin(MathHelper.sqrt_float(swing) * (float) Math.PI * 2.0F) * 0.2F, -swingZ * 0.2F);
|
||||
@ -169,8 +171,10 @@ public abstract class ItemRenderWeaponBase implements IItemRenderer {
|
||||
float swingPitchRoll = MathHelper.sin(MathHelper.sqrt_float(swing) * (float) Math.PI);
|
||||
GL11.glRotatef(-swingYaw * 20.0F, 0.0F, 1.0F, 0.0F);
|
||||
GL11.glRotatef(-swingPitchRoll * 20.0F, 0.0F, 0.0F, 1.0F);
|
||||
GL11.glRotatef(-swingPitchRoll * 80.0F, 1.0F, 0.0F, 0.0F);
|
||||
GL11.glRotatef(-swingPitchRoll * 80.0F, 1.0F, 0.0F, 0.0F);*/
|
||||
|
||||
GL11.glEnable(GL12.GL_RESCALE_NORMAL); //!
|
||||
|
||||
GL11.glRotated(180, 0, 1, 0);
|
||||
|
||||
//viewbob
|
||||
@ -232,6 +236,9 @@ public abstract class ItemRenderWeaponBase implements IItemRenderer {
|
||||
}
|
||||
|
||||
public void setupInv(ItemStack stack) {
|
||||
GL11.glAlphaFunc(GL11.GL_GREATER, 0F);
|
||||
GL11.glEnable(GL11.GL_ALPHA_TEST);
|
||||
|
||||
GL11.glScaled(1, 1, -1);
|
||||
GL11.glTranslated(8, 8, 0);
|
||||
GL11.glRotated(225, 0, 0, 1);
|
||||
|
||||
@ -6,9 +6,7 @@ import org.lwjgl.opengl.GL12;
|
||||
import com.hbm.blocks.generic.BlockLoot.TileEntityLoot;
|
||||
import com.hbm.items.ModItems;
|
||||
import com.hbm.items.armor.ArmorTrenchmaster;
|
||||
import com.hbm.lib.RefStrings;
|
||||
import com.hbm.main.ResourceManager;
|
||||
import com.hbm.render.model.ModelFatman;
|
||||
import com.hbm.render.model.ModelLeverAction;
|
||||
import com.hbm.util.Tuple.Quartet;
|
||||
|
||||
@ -22,7 +20,6 @@ import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
|
||||
public class RenderLoot extends TileEntitySpecialRenderer {
|
||||
|
||||
@ -45,9 +42,6 @@ public class RenderLoot extends TileEntitySpecialRenderer {
|
||||
if(stack.getItem() == ModItems.ammo_nuke) {
|
||||
renderNuke();
|
||||
|
||||
} else if(stack.getItem() == ModItems.gun_fatman || stack.getItem() == ModItems.gun_proto || stack.getItem() == ModItems.gun_mirv) {
|
||||
renderLauncher();
|
||||
|
||||
} else if(stack.getItem() == ModItems.gun_lever_action) {
|
||||
renderShotgun();
|
||||
|
||||
@ -123,20 +117,6 @@ public class RenderLoot extends TileEntitySpecialRenderer {
|
||||
GL11.glShadeModel(GL11.GL_FLAT);
|
||||
}
|
||||
|
||||
protected ModelFatman launcher;
|
||||
private void renderLauncher() {
|
||||
|
||||
if(launcher == null)
|
||||
launcher = new ModelFatman();
|
||||
|
||||
GL11.glRotated(180, 1, 0, 0);
|
||||
GL11.glRotated(3, 0, 0, 1);
|
||||
GL11.glTranslated(0.5, -0.3751, -0.625);
|
||||
|
||||
bindTexture(new ResourceLocation(RefStrings.MODID +":textures/models/FatmanLauncher.png"));
|
||||
launcher.render(null, 0F, 0F, 0F, 0F, 0F, 0.0625F, new ItemStack(ModItems.gun_fatman));
|
||||
}
|
||||
|
||||
protected ModelLeverAction shotgun;
|
||||
private void renderShotgun() {
|
||||
|
||||
|
||||
@ -50,7 +50,7 @@ public class RenderInfoSystem {
|
||||
if(event.type != ElementType.CROSSHAIRS)
|
||||
return;
|
||||
|
||||
//this.messages.put(-666, new InfoEntry("Halloween Preview", 666_666));
|
||||
//this.messages.put(-666, new InfoEntry("Monarch celebratory special edition (balls tuah director's cut)", 666_666));
|
||||
|
||||
if(this.messages.isEmpty())
|
||||
return;
|
||||
|
||||
@ -95,6 +95,28 @@ public class TileEntityMachineAmmoPress extends TileEntityMachineBase implements
|
||||
}
|
||||
}
|
||||
|
||||
public int[] access = new int[] { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 };
|
||||
|
||||
@Override
|
||||
public int[] getAccessibleSlotsFromSide(int side) {
|
||||
return access;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canExtractItem(int i, ItemStack stack, int j) {
|
||||
return i == 9;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isItemValidForSlot(int slot, ItemStack stack) {
|
||||
if(slot > 8) return false;
|
||||
if(selectedRecipe < 0 || selectedRecipe >= AmmoPressRecipes.recipes.size()) return false;
|
||||
|
||||
AmmoPressRecipe recipe = AmmoPressRecipes.recipes.get(selectedRecipe);
|
||||
if(recipe.input[slot] == null) return false;
|
||||
return recipe.input[slot].matchesRecipe(stack, true);
|
||||
}
|
||||
|
||||
@Override public void serialize(ByteBuf buf) {
|
||||
super.serialize(buf);
|
||||
buf.writeInt(this.selectedRecipe);
|
||||
|
||||
@ -1,5 +1,8 @@
|
||||
package com.hbm.util;
|
||||
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.List;
|
||||
|
||||
import cpw.mods.fml.relauncher.ReflectionHelper;
|
||||
import net.minecraft.enchantment.EnchantmentHelper;
|
||||
import net.minecraft.entity.Entity;
|
||||
@ -8,11 +11,13 @@ import net.minecraft.entity.SharedMonsterAttributes;
|
||||
import net.minecraft.entity.passive.EntityTameable;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.potion.Potion;
|
||||
import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraft.util.DamageSource;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
import net.minecraft.util.Vec3;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeHooks;
|
||||
|
||||
import java.lang.reflect.Method;
|
||||
|
||||
public class EntityDamageUtil {
|
||||
|
||||
/**
|
||||
@ -270,4 +275,74 @@ public class EntityDamageUtil {
|
||||
public static void setBeenAttacked(EntityLivingBase living) {
|
||||
living.velocityChanged = living.getRNG().nextDouble() >= living.getEntityAttribute(SharedMonsterAttributes.knockbackResistance).getAttributeValue();
|
||||
}
|
||||
|
||||
public static MovingObjectPosition getMouseOver(EntityPlayer attacker, double reach) {
|
||||
|
||||
World world = attacker.worldObj;
|
||||
MovingObjectPosition objectMouseOver = null;
|
||||
Entity pointedEntity = null;
|
||||
|
||||
objectMouseOver = rayTrace(attacker, reach, 1F);
|
||||
|
||||
Vec3 pos = getPosition(attacker);
|
||||
Vec3 look = attacker.getLook(1F);
|
||||
Vec3 end = pos.addVector(look.xCoord * reach, look.yCoord * reach, look.zCoord * reach);
|
||||
Vec3 hitvec = null;
|
||||
float grace = 1.0F;
|
||||
List list = world.getEntitiesWithinAABBExcludingEntity(attacker, attacker.boundingBox.addCoord(look.xCoord * reach, look.yCoord * reach, look.zCoord * reach).expand(grace, grace, grace));
|
||||
|
||||
double closest = reach;
|
||||
|
||||
for(int i = 0; i < list.size(); ++i) {
|
||||
Entity entity = (Entity) list.get(i);
|
||||
|
||||
if(entity.canBeCollidedWith()) {
|
||||
|
||||
float borderSize = entity.getCollisionBorderSize();
|
||||
AxisAlignedBB axisalignedbb = entity.boundingBox.expand(borderSize, borderSize, borderSize);
|
||||
MovingObjectPosition movingobjectposition = axisalignedbb.calculateIntercept(pos, end);
|
||||
|
||||
if(axisalignedbb.isVecInside(pos)) {
|
||||
if(0.0D <= closest) {
|
||||
pointedEntity = entity;
|
||||
hitvec = movingobjectposition == null ? pos : movingobjectposition.hitVec;
|
||||
closest = 0.0D;
|
||||
}
|
||||
|
||||
} else if(movingobjectposition != null) {
|
||||
double dist = pos.distanceTo(movingobjectposition.hitVec);
|
||||
|
||||
if(dist < closest || closest == 0.0D) {
|
||||
if(entity == attacker.ridingEntity && !entity.canRiderInteract()) {
|
||||
if(closest == 0.0D) {
|
||||
pointedEntity = entity;
|
||||
hitvec = movingobjectposition.hitVec;
|
||||
}
|
||||
} else {
|
||||
pointedEntity = entity;
|
||||
hitvec = movingobjectposition.hitVec;
|
||||
closest = dist;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(pointedEntity != null && (closest < reach || objectMouseOver == null)) {
|
||||
objectMouseOver = new MovingObjectPosition(pointedEntity, hitvec);
|
||||
}
|
||||
|
||||
return objectMouseOver;
|
||||
}
|
||||
|
||||
public static MovingObjectPosition rayTrace(EntityPlayer player, double dist, float interp) {
|
||||
Vec3 pos = getPosition(player);
|
||||
Vec3 look = player.getLook(interp);
|
||||
Vec3 end = pos.addVector(look.xCoord * dist, look.yCoord * dist, look.zCoord * dist);
|
||||
return player.worldObj.func_147447_a(pos, end, false, false, true);
|
||||
}
|
||||
|
||||
public static Vec3 getPosition(EntityPlayer player) {
|
||||
return Vec3.createVectorHelper(player.posX, player.posY + player.getEyeHeight(), player.posZ);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1179,16 +1179,23 @@ item.ammo_standard.g40_he.name=40mm Sprenggranate
|
||||
item.ammo_standard.g40_heat.name=40mm Hohlladungsgranate
|
||||
item.ammo_standard.g40_inc.name=40mm Brandgranate
|
||||
item.ammo_standard.m357_ap.name=.357 Magnumkugel (Panzerbrechend)
|
||||
item.ammo_standard.m357_bp.name=.357 Magnumkugel (Schwarzpulver)
|
||||
item.ammo_standard.m357_express.name=.357 Magnumkugel (VMG Express)
|
||||
item.ammo_standard.m357_fmj.name=.357 Magnumkugel (Vollmantelgeschoss)
|
||||
item.ammo_standard.m357_jhp.name=.357 Magnumkugel (Hohlspitz)
|
||||
item.ammo_standard.m357_sp.name=.357 Magnumkugel (Teilmantelgeschoss)
|
||||
item.ammo_standard.m44_ap.name=.44 Magnumkugel (Panzerbrechend)
|
||||
item.ammo_standard.m44_bp.name=.44 Magnumkugel (Schwarzpulver)
|
||||
item.ammo_standard.m44_equestrian.name=.44 Magnum Schädelsprenger
|
||||
item.ammo_standard.m44_express.name=.44 Magnumkugel (VMG Express)
|
||||
item.ammo_standard.m44_fmj.name=.44 Magnumkugel (Vollmantelgeschoss)
|
||||
item.ammo_standard.m44_jhp.name=.44 Magnumkugel (Hohlspitz)
|
||||
item.ammo_standard.m44_sp.name=.44 Magnumkugel (Teilmantelgeschoss)
|
||||
item.ammo_standard.nuke_demo.name=Miniatombombe, Abriss
|
||||
item.ammo_standard.nuke_high.name=Miniatombombe, hoher Ertrag
|
||||
item.ammo_standard.nuke_hive.name=Raketenschwarm
|
||||
item.ammo_standard.nuke_standard.name=Miniatombombe
|
||||
item.ammo_standard.nuke_tots.name=Miniatombombe, kleine Knirpse
|
||||
item.ammo_standard.p22_ap.name=.22 lfB Patrone (Panzerbrechend)
|
||||
item.ammo_standard.p22_fmj.name=.22 lfB Patrone (Vollmantelgeschoss)
|
||||
item.ammo_standard.p22_jhp.name=.22 lfB Patrone (Hohlspitz)
|
||||
@ -2167,6 +2174,7 @@ item.gun_flechette.name=Flechet-Gewehr
|
||||
item.gun_folly.name=Prototyp Digamma "Irrsinn"
|
||||
item.gun_g3.name=Sturmgewehr
|
||||
item.gun_greasegun.name=Grease Gun
|
||||
item.gun_hangman.name=Hangman
|
||||
item.gun_heavy_revolver.name=Schwerer Revolver
|
||||
item.gun_heavy_revolver_lilmac.name=Little Macintosh
|
||||
item.gun_henry.name=Repetiergewehr
|
||||
@ -2184,6 +2192,7 @@ item.gun_ks23.name=Samuel die dicke Flinte
|
||||
item.gun_lacunae.name=CZ33 Abaddon
|
||||
item.gun_lacunae_ammo.name=5mm Patrone (LEGACY)
|
||||
item.gun_lag.name=Komisch lange Pistole
|
||||
item.gun_lasrifle.name=Lasergewehr
|
||||
item.gun_lever_action.name=Mare's Leg (Original)
|
||||
item.gun_lever_action_ammo.name=12x74 Schrotmunition (LEGACY)
|
||||
item.gun_lever_action_dark.name=Mare's Leg (Dunkel)
|
||||
@ -2252,6 +2261,7 @@ item.gun_stinger.name=FIM-92 Stinger
|
||||
item.gun_stinger_ammo.name=Stinger-Rakete (LEGACY)
|
||||
item.gun_super_shotgun.name=Super Shotgun
|
||||
item.gun_supershotgun.name=Super Shotgun
|
||||
item.gun_tau.name=Taukanone
|
||||
item.gun_tesla_cannon.name=Teslakanone
|
||||
item.gun_thompson.name=Thompson Maschinenpistole
|
||||
item.gun_uac_pistol.name=UAC .45 Pistole
|
||||
|
||||
@ -1902,16 +1902,23 @@ item.ammo_standard.g40_he.name=40mm Grenade, High-Explosive
|
||||
item.ammo_standard.g40_heat.name=40mm Grenade, Shaped Charge
|
||||
item.ammo_standard.g40_inc.name=40mm Grenade, Incendiary
|
||||
item.ammo_standard.m357_ap.name=.357 Magnum Round (Armor Piercing)
|
||||
item.ammo_standard.m357_bp.name=.357 Magnum Round (Black Powder)
|
||||
item.ammo_standard.m357_express.name=.357 Magnum Round (FMJ Express)
|
||||
item.ammo_standard.m357_fmj.name=.357 Magnum Round (Full Metal Jacket)
|
||||
item.ammo_standard.m357_jhp.name=.357 Magnum Round (Jacketed Hollow Point)
|
||||
item.ammo_standard.m357_sp.name=.357 Magnum Round (Soft Point)
|
||||
item.ammo_standard.m44_ap.name=.44 Magnum Round (Armor Piercing)
|
||||
item.ammo_standard.m44_bp.name=.44 Magnum Round (Black Powder)
|
||||
item.ammo_standard.m44_equestrian.name=.44 Magnum Head-Exploder
|
||||
item.ammo_standard.m44_express.name=.44 Magnum Round (FMJ Express)
|
||||
item.ammo_standard.m44_fmj.name=.44 Magnum Round (Full Metal Jacket)
|
||||
item.ammo_standard.m44_jhp.name=.44 Magnum Round (Jacketed Hollow Point)
|
||||
item.ammo_standard.m44_sp.name=.44 Magnum Round (Soft Point)
|
||||
item.ammo_standard.nuke_demo.name=Mini Nuke, Demolition
|
||||
item.ammo_standard.nuke_high.name=Mini Nuke, High Yield
|
||||
item.ammo_standard.nuke_hive.name=Rocket Hive
|
||||
item.ammo_standard.nuke_standard.name=Mini Nuke
|
||||
item.ammo_standard.nuke_tots.name=Mini Nuke, Tiny Tots
|
||||
item.ammo_standard.p22_ap.name=.22 LR Round (Armor Piercing)
|
||||
item.ammo_standard.p22_fmj.name=.22 LR Round (Full Metal Jacket)
|
||||
item.ammo_standard.p22_jhp.name=.22 LR Round (Jacketed Hollow Point)
|
||||
@ -2976,6 +2983,7 @@ item.gun_folly.name=Prototype Digamma "Folly"
|
||||
item.gun_g3.name=Assault Rifle
|
||||
item.gun_glass_cannon.name=The Glass Cannon
|
||||
item.gun_greasegun.name=Grease Gun
|
||||
item.gun_hangman.name=Hangman
|
||||
item.gun_heavy_revolver.name=Heavy Revolver
|
||||
item.gun_heavy_revolver_lilmac.name=Little Macintosh
|
||||
item.gun_henry.name=Lever Action Rifle
|
||||
@ -2993,6 +3001,7 @@ item.gun_ks23.name=Samuel the Big Shotgun
|
||||
item.gun_lacunae.name=CZ33 Abaddon
|
||||
item.gun_lacunae_ammo.name=5mm Round (LEGACY)
|
||||
item.gun_lag.name=Comically Long Pistol
|
||||
item.gun_lasrifle.name=Laser Rifle
|
||||
item.gun_lever_action.name=Mare's Leg (Original)
|
||||
item.gun_lever_action_ammo.name=12x74 Buckshot (LEGACY)
|
||||
item.gun_lever_action_dark.name=Mare's Leg (Dark)
|
||||
@ -3062,6 +3071,7 @@ item.gun_stinger_ammo.name=Stinger Rocket (LEGACY)
|
||||
item.gun_super_shotgun.name=Super Shotgun
|
||||
item.gun_super_shotgun.desc=It's super broken!
|
||||
item.gun_supershotgun.name=Super Shotgun
|
||||
item.gun_tau.name=Tau Cannon
|
||||
item.gun_tesla_cannon.name=Tesla Cannon
|
||||
item.gun_thompson.name=Thompson Submachine Gun
|
||||
item.gun_uac_pistol.name=UAC .45 Pistol
|
||||
|
||||
3404
src/main/resources/assets/hbm/models/weapons/fatman.obj
Normal file
5413
src/main/resources/assets/hbm/models/weapons/hangman.obj
Normal file
@ -3411,9 +3411,9 @@ vt 0.170455 0.180723
|
||||
vt 0.174242 0.144578
|
||||
vt 0.136364 0.150602
|
||||
vt 0.174242 0.192771
|
||||
vt 0.886904 0.951811
|
||||
vt 0.939394 0.807222
|
||||
vt 0.991884 0.951811
|
||||
vt 0.830355 0.927716
|
||||
vt 0.909091 0.710833
|
||||
vt 0.987826 0.927716
|
||||
vt 0.640152 0.662651
|
||||
vt 0.715909 0.662651
|
||||
vt 0.753788 0.662651
|
||||
@ -3579,15 +3579,15 @@ vt 0.151515 0.536145
|
||||
vt 0.189394 0.156627
|
||||
vt 0.178030 0.180723
|
||||
vt 0.136364 0.186747
|
||||
vt 0.969699 0.987093
|
||||
vt 0.939394 1.000007
|
||||
vt 0.909088 0.987093
|
||||
vt 0.878783 0.903614
|
||||
vt 0.886904 0.855418
|
||||
vt 0.909089 0.820136
|
||||
vt 0.969699 0.820136
|
||||
vt 0.991884 0.855418
|
||||
vt 1.000005 0.903614
|
||||
vt 0.954549 0.980639
|
||||
vt 0.909091 1.000011
|
||||
vt 0.863633 0.980639
|
||||
vt 0.818175 0.855421
|
||||
vt 0.830355 0.783127
|
||||
vt 0.863633 0.730204
|
||||
vt 0.954549 0.730204
|
||||
vt 0.987826 0.783127
|
||||
vt 1.000007 0.855422
|
||||
vt 0.074559 0.941663
|
||||
vt 0.075631 0.945782
|
||||
vt 0.074559 0.949902
|
||||
|
||||
@ -224,13 +224,15 @@
|
||||
"weapon.switchmode1": {"category": "player", "sounds": [{"name": "weapon/switchmode1", "stream": false}]},
|
||||
"weapon.switchmode2": {"category": "player", "sounds": [{"name": "weapon/switchmode2", "stream": false}]},
|
||||
|
||||
"weapon.fire.blackPowder": {"category": "player", "sounds": [{"name": "weapon/fire/blackPowder", "stream": false}]},
|
||||
"weapon.fire.flameLoop": {"category": "player", "sounds": [{"name": "weapon/fire/flameLoop", "stream": false}]},
|
||||
"weapon.fire.lockon": {"category": "player", "sounds": [{"name": "weapon/fire/lockon", "stream": false}]},
|
||||
"weapon.fire.shredderCycle": {"category": "player", "sounds": [{"name": "weapon/fire/shredderCycle", "stream": false}]},
|
||||
"weapon.fire.tau": {"category": "player", "sounds": [{"name": "weapon/fire/tau", "stream": false}]},
|
||||
"weapon.fire.tauLoop": {"category": "player", "sounds": [{"name": "weapon/fire/tauLoop", "stream": false}]},
|
||||
"weapon.fire.blackPowder": {"category": "player", "sounds": ["weapon/fire/blackPowder"]},
|
||||
"weapon.fire.flameLoop": {"category": "player", "sounds": ["weapon/fire/flameLoop"]},
|
||||
"weapon.fire.lockon": {"category": "player", "sounds": ["weapon/fire/lockon"]},
|
||||
"weapon.fire.shredderCycle": {"category": "player", "sounds": ["weapon/fire/shredderCycle"]},
|
||||
"weapon.fire.tau": {"category": "player", "sounds": ["weapon/fire/tau"]},
|
||||
"weapon.fire.tauLoop": {"category": "player", "sounds": ["weapon/fire/tauLoop"]},
|
||||
"weapon.fire.tauRelease": {"category": "player", "sounds": ["weapon/fire/tauRelease1", "weapon/fire/tauRelease2", "weapon/fire/tauRelease3"]},
|
||||
"weapon.fire.fatman": {"category": "player", "sounds": ["weapon/fire/fatman"]},
|
||||
"weapon.fire.smack": {"category": "player", "sounds": ["weapon/fire/smack"]},
|
||||
|
||||
"weapon.reload.boltClose": {"category": "player", "sounds": ["weapon/reload/boltClose"]},
|
||||
"weapon.reload.boltOpen": {"category": "player", "sounds": ["weapon/reload/boltOpen"]},
|
||||
@ -253,9 +255,14 @@
|
||||
"weapon.reload.revolverSpin": {"category": "player", "sounds": ["weapon/reload/revolverSpin"]},
|
||||
"weapon.reload.rifleCock": {"category": "player", "sounds": ["weapon/reload/rifleCock"]},
|
||||
"weapon.reload.shotgunCock": {"category": "player", "sounds": ["weapon/reload/shotgunCock"]},
|
||||
"weapon.reload.shotgunCockOpen": {"category": "player", "sounds": ["weapon/reload/shotgunCockOpen"]},
|
||||
"weapon.reload.shotgunCockClose": {"category": "player", "sounds": ["weapon/reload/shotgunCockClose"]},
|
||||
"weapon.reload.shotgunReload": {"category": "player", "sounds": ["weapon/reload/shotgunReload1", "weapon/reload/shotgunReload2", "weapon/reload/shotgunReload3"]},
|
||||
"weapon.reload.tubeFwoomp": {"category": "player", "sounds": ["weapon/reload/tubeFwoomp"]},
|
||||
"weapon.reload.impact": {"category": "player", "sounds": ["weapon/reload/impact1", "weapon/reload/impact2", "weapon/reload/impact3"]},
|
||||
"weapon.reload.fatmanFull": {"category": "player", "sounds": ["weapon/reload/fatmanFull"]},
|
||||
|
||||
"weapon.foley.gunWhack": {"category": "player", "sounds": ["weapon/foley/gunWhack", "weapon/foley/gunWhack2"]},
|
||||
|
||||
"turret.chekhov_fire": {"category": "block", "sounds": [{"name": "turret/chekhov_fire", "stream": false}]},
|
||||
"turret.jeremy_fire": {"category": "block", "sounds": ["turret/jeremy_fire1", "turret/jeremy_fire2", "turret/jeremy_fire3", "turret/jeremy_fire4", "turret/jeremy_fire5"]},
|
||||
|
||||
BIN
src/main/resources/assets/hbm/sounds/weapon/fire/fatman.ogg
Normal file
BIN
src/main/resources/assets/hbm/sounds/weapon/fire/smack.ogg
Normal file
BIN
src/main/resources/assets/hbm/sounds/weapon/foley/gunWhack.ogg
Normal file
BIN
src/main/resources/assets/hbm/sounds/weapon/foley/gunWhack2.ogg
Normal file
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 308 B |
|
After Width: | Height: | Size: 269 B |
|
After Width: | Height: | Size: 300 B |
|
After Width: | Height: | Size: 264 B |
|
After Width: | Height: | Size: 253 B |
|
After Width: | Height: | Size: 348 B |
|
After Width: | Height: | Size: 379 B |
|
After Width: | Height: | Size: 393 B |
|
After Width: | Height: | Size: 392 B |
|
After Width: | Height: | Size: 296 B |
|
After Width: | Height: | Size: 392 B |
|
After Width: | Height: | Size: 411 B |
BIN
src/main/resources/assets/hbm/textures/models/weapons/fatman.png
Normal file
|
After Width: | Height: | Size: 4.7 KiB |
|
After Width: | Height: | Size: 1.0 KiB |
|
After Width: | Height: | Size: 28 KiB |
|
Before Width: | Height: | Size: 2.4 KiB After Width: | Height: | Size: 4.4 KiB |
|
Before Width: | Height: | Size: 5.0 KiB After Width: | Height: | Size: 5.0 KiB |