ACE3/addons/hot/CfgAmmo.hpp

142 lines
4.4 KiB
C++
Raw Normal View History

SACLOS and HOT Missiles (#6708) * abc * Revert "abc" This reverts commit bcb4214bd99bba3fec692efa4dca950323da582d. * Update to current commit * Added HOT1 Missile and SACLOS/Wire guidance * Added all HOT variants. Added polish to code * Fixed bug with pylons * Changed how seeker angle is calculated. When the wire snaps the missile goes haywire. Fixed bug where HOT2/3 missiles weren't getting missile guidance * Replaced Wiesel FireFIST launcher with HOT Launcher * Remove debug defines * Tweak thrust * Fix formatting issues. Added true randomness. Added ACE prefixes. Added string table. Tweaked missile dynamics * Fix bug where attack profile correction was wrong due to magnitude always being 50. Add stringtable values for relevant strings. Added reload time to Wiesel ATGM. Added "onFired" to initialize values * Moved wire-snapping logic to attack profile * Missile flight dynamics tweaked * Add a crosshair offset. The missile sits in this offset relative to the crosshair * Add LOS checks. Fix bug where wire-cutting didnt work. * Tweak explosive range for a kill radius of ~20m. Add fragmentation * Add AI Flags * Person in control of missile may not be the shooter * Fix RPT spam on missile out of LOS. Tweak missile dynamics. Add wire break sound cue * Fix bug where missile didn't go to a fake target in front of it when out of LOS * Use a better, more generic way to calculate direction camera is facing * Use ACE Macros for frag values. Get config entry with CBA * Add Wiki entry * Add new lines to wiki. Allow for SQF expressions in config for maxCorrectableDistance * Add CPP code tag * Fix wiki grammer error * Re-convert back to CBA_fnc_getConfigEntry * UAV Gunner support, cleanup * Fix bug where SACLOS for launcher guided weapons was off * Add the ability to define how far ahead of the missile the attack profile will seek toward
2018-12-07 02:27:30 +00:00
class CfgAmmo {
class M_Scalpel_AT;
class ammo_Penetrator_Base;
class GVAR(ammo_Penetrator_HOT1): ammo_Penetrator_Base {
caliber = 60;
warheadName = "HEAT";
hit = 720;
};
class GVAR(ammo_Penetrator_HOT2): ammo_Penetrator_Base {
caliber = 65;
warheadName = "HEAT";
hit = 900;
};
class GVAR(ammo_Penetrator_HOT3): ammo_Penetrator_Base {
caliber = 80;
warheadName = "TandemHEAT";
hit = 1000;
};
class GVAR(HOT1): M_Scalpel_AT {
aiAmmoUsageFlags = "128+512";
model = "\A3\Weapons_F_Tank\Launchers\Vorona\Vorona_missile_heat_fly";
proxyShape = "\A3\Weapons_F\Ammo\Missile_AT_03_F";
submunitionAmmo = QGVAR(ammo_Penetrator_HOT1);
submunitionDirectionType = "SubmunitionModelDirection";
submunitionInitSpeed = 1000;
submunitionParentSpeedCoef = 0;
submunitionInitialOffset[] = { 0, 0, -0.2 };
hit = 150;
warheadName = "HEAT";
indirectHit = 25;
indirectHitRange = 3.5;
explosive = 0.8;
displayName = CSTRING(hot1);
displayNameShort = CSTRING(hot1);
description = CSTRING(missileType_Description);
descriptionShort = CSTRING(missileType);
effectsMissile = "missile2";
irLock = 0;
laserLock = 0;
manualControl = 0;
maxSpeed = 240;
thrustTime = 17;
thrust = 125;
timeToLive = 40;
initTime = 0.3;
EGVAR(rearm,caliber) = 178;
Add Vehicle Damage (ACE2 port) & Enhance Cook-Off (#7565) * Initital port of ACE2 Vehicle Damage * Add fire damage and burning people * Migrate vehicle damge stuff from cookoff. Change cookoff function to enhance effect. * Minor tweaks * Add incendiary values to all applicable ammunition. Add engine fire/smoke if hit enough * Handle car damage more elegantly. * Added ability to create fire sources arbitrarily * tweaks * Add chance to detonate after cookoff * disable compile cache * Move blown-off turret config to vehicle damage. Add settings inititalized EH for initializing off settings * tabs->spaces * Various code improvements * Change to count loop for deleting effects * update addon requirements * remove vanilla config requirements * Add RHS compatability * RHS compat. Various QOL fixes/changes * Various tweaks to compats and code. * High-Explosive damage tweak * Change how penetration is calculated for parts * Fix RHS compat * Create setting for flare effect * increase burning scream sounds * swap out file name for snake_case * move incendiary values out of vehicle damage. remove medical dependency * vehicle_dammage - update all refs to snake * sqf fixes * fix fire string package caps * fix pboprefix * Default setting to on * Add variables to enable/disable ring fire to avoid goofy looking vehicles. Enhance how particles are cleaned up. Remove advanced penetration simulation. Change how fire intensity is calculated. Add setting to "disable" vehicle after cookoff * Fix bug where event handler wasn't giving the damage last. * change to snake * fix build errors * Fix UBC * Fix Order of Operations * avoid O^2 events * Make sure that no damage processing happens on dead units * Change some if statements * Keep track of player's death to stop various things * add quotes to right middle wheen * Add VD documentation * fire docs * Code quality fixes * Clarify documentation * define IDD * switch global -> server * Add newline between header and first code statement * stop the dead from suffering Its hard to tell when a unit is dead or in spectator, so check the config of the unit to determine it. * Add settings to disable cook-off effects * Delete effects if vehicle is deleted before cookoff occurs. Don't cookoff player ammo. Throw weapon better * Move fire into own PR * fix tabs and macro * Shuffle crew indices so that a random person is first on the list to be injured each time * fix effects not clearing Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2021-10-14 15:49:27 +00:00
EGVAR(vehicle_damage,incendiary) = 1.0;
SACLOS and HOT Missiles (#6708) * abc * Revert "abc" This reverts commit bcb4214bd99bba3fec692efa4dca950323da582d. * Update to current commit * Added HOT1 Missile and SACLOS/Wire guidance * Added all HOT variants. Added polish to code * Fixed bug with pylons * Changed how seeker angle is calculated. When the wire snaps the missile goes haywire. Fixed bug where HOT2/3 missiles weren't getting missile guidance * Replaced Wiesel FireFIST launcher with HOT Launcher * Remove debug defines * Tweak thrust * Fix formatting issues. Added true randomness. Added ACE prefixes. Added string table. Tweaked missile dynamics * Fix bug where attack profile correction was wrong due to magnitude always being 50. Add stringtable values for relevant strings. Added reload time to Wiesel ATGM. Added "onFired" to initialize values * Moved wire-snapping logic to attack profile * Missile flight dynamics tweaked * Add a crosshair offset. The missile sits in this offset relative to the crosshair * Add LOS checks. Fix bug where wire-cutting didnt work. * Tweak explosive range for a kill radius of ~20m. Add fragmentation * Add AI Flags * Person in control of missile may not be the shooter * Fix RPT spam on missile out of LOS. Tweak missile dynamics. Add wire break sound cue * Fix bug where missile didn't go to a fake target in front of it when out of LOS * Use a better, more generic way to calculate direction camera is facing * Use ACE Macros for frag values. Get config entry with CBA * Add Wiki entry * Add new lines to wiki. Allow for SQF expressions in config for maxCorrectableDistance * Add CPP code tag * Fix wiki grammer error * Re-convert back to CBA_fnc_getConfigEntry * UAV Gunner support, cleanup * Fix bug where SACLOS for launcher guided weapons was off * Add the ability to define how far ahead of the missile the attack profile will seek toward
2018-12-07 02:27:30 +00:00
class ace_missileguidance {
enabled = 1;
minDeflection = 0; // Minium flap deflection for guidance
maxDeflection = 0.0030; // Maximum flap deflection for guidance
incDeflection = 0.0005; // The incrmeent in which deflection adjusts.
canVanillaLock = 0; // Can this default vanilla lock? Only applicable to non-cadet mode
// Guidance type for munitions
defaultSeekerType = "SACLOS";
seekerTypes[] = { "SACLOS" };
defaultSeekerLockMode = "LOAL";
seekerLockModes[] = { "LOAL", "LOBL" };
seekLastTargetPos = 0; // seek last target position [if seeker loses LOS of target, continue to last known pos]
seekerAngle = 30; // Angle from the shooter's view that can track the missile
seekerAccuracy = 1; // seeker accuracy multiplier
seekerMinRange = 75;
seekerMaxRange = 4000; // Range from the missile which the seeker can visually search
correctionDistance = 8; // distance from center of crosshair where missile slows down
SACLOS and HOT Missiles (#6708) * abc * Revert "abc" This reverts commit bcb4214bd99bba3fec692efa4dca950323da582d. * Update to current commit * Added HOT1 Missile and SACLOS/Wire guidance * Added all HOT variants. Added polish to code * Fixed bug with pylons * Changed how seeker angle is calculated. When the wire snaps the missile goes haywire. Fixed bug where HOT2/3 missiles weren't getting missile guidance * Replaced Wiesel FireFIST launcher with HOT Launcher * Remove debug defines * Tweak thrust * Fix formatting issues. Added true randomness. Added ACE prefixes. Added string table. Tweaked missile dynamics * Fix bug where attack profile correction was wrong due to magnitude always being 50. Add stringtable values for relevant strings. Added reload time to Wiesel ATGM. Added "onFired" to initialize values * Moved wire-snapping logic to attack profile * Missile flight dynamics tweaked * Add a crosshair offset. The missile sits in this offset relative to the crosshair * Add LOS checks. Fix bug where wire-cutting didnt work. * Tweak explosive range for a kill radius of ~20m. Add fragmentation * Add AI Flags * Person in control of missile may not be the shooter * Fix RPT spam on missile out of LOS. Tweak missile dynamics. Add wire break sound cue * Fix bug where missile didn't go to a fake target in front of it when out of LOS * Use a better, more generic way to calculate direction camera is facing * Use ACE Macros for frag values. Get config entry with CBA * Add Wiki entry * Add new lines to wiki. Allow for SQF expressions in config for maxCorrectableDistance * Add CPP code tag * Fix wiki grammer error * Re-convert back to CBA_fnc_getConfigEntry * UAV Gunner support, cleanup * Fix bug where SACLOS for launcher guided weapons was off * Add the ability to define how far ahead of the missile the attack profile will seek toward
2018-12-07 02:27:30 +00:00
offsetFromCrosshair[] = { 0, 0, 0.5 }; // where the missile wants to stay in relation to the center of the crosshair.
// Attack profile type selection
defaultAttackProfile = "WIRE";
attackProfiles[] = {"WIRE"};
};
};
class GVAR(HOT2): GVAR(HOT1) {
submunitionAmmo = QGVAR(ammo_Penetrator_HOT2);
displayName = CSTRING(hot2);
displayNameShort = CSTRING(hot2);
class ace_missileguidance: ace_missileguidance {
enabled = 1;
};
};
class GVAR(HOT2MP): GVAR(HOT2) {
aiAmmoUsageFlags = "64+128";
submunitionAmmo = "";
warheadName = "HE";
allowAgainstInfantry = 1;
hit = 200;
indirectHit = 200;
indirectHitRange = 5;
explosionEffects = "BombExplosion";
explosive = 0.7;
EGVAR(frag,enabled) = 1;
EGVAR(frag,metal) = 7100; // 1000 steel balls
EGVAR(frag,charge) = 4100;
EGVAR(frag,gurney_c) = 2700;
EGVAR(frag,gurney_k) = 3/5;
EGVAR(frag,classes)[] = {"ACE_frag_small"};
displayName = CSTRING(hot2mp);
displayNameShort = CSTRING(hot2mp);
description = CSTRING(missileType_Description_AP);
Add Vehicle Damage (ACE2 port) & Enhance Cook-Off (#7565) * Initital port of ACE2 Vehicle Damage * Add fire damage and burning people * Migrate vehicle damge stuff from cookoff. Change cookoff function to enhance effect. * Minor tweaks * Add incendiary values to all applicable ammunition. Add engine fire/smoke if hit enough * Handle car damage more elegantly. * Added ability to create fire sources arbitrarily * tweaks * Add chance to detonate after cookoff * disable compile cache * Move blown-off turret config to vehicle damage. Add settings inititalized EH for initializing off settings * tabs->spaces * Various code improvements * Change to count loop for deleting effects * update addon requirements * remove vanilla config requirements * Add RHS compatability * RHS compat. Various QOL fixes/changes * Various tweaks to compats and code. * High-Explosive damage tweak * Change how penetration is calculated for parts * Fix RHS compat * Create setting for flare effect * increase burning scream sounds * swap out file name for snake_case * move incendiary values out of vehicle damage. remove medical dependency * vehicle_dammage - update all refs to snake * sqf fixes * fix fire string package caps * fix pboprefix * Default setting to on * Add variables to enable/disable ring fire to avoid goofy looking vehicles. Enhance how particles are cleaned up. Remove advanced penetration simulation. Change how fire intensity is calculated. Add setting to "disable" vehicle after cookoff * Fix bug where event handler wasn't giving the damage last. * change to snake * fix build errors * Fix UBC * Fix Order of Operations * avoid O^2 events * Make sure that no damage processing happens on dead units * Change some if statements * Keep track of player's death to stop various things * add quotes to right middle wheen * Add VD documentation * fire docs * Code quality fixes * Clarify documentation * define IDD * switch global -> server * Add newline between header and first code statement * stop the dead from suffering Its hard to tell when a unit is dead or in spectator, so check the config of the unit to determine it. * Add settings to disable cook-off effects * Delete effects if vehicle is deleted before cookoff occurs. Don't cookoff player ammo. Throw weapon better * Move fire into own PR * fix tabs and macro * Shuffle crew indices so that a random person is first on the list to be injured each time * fix effects not clearing Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2021-10-14 15:49:27 +00:00
EGVAR(vehicle_damage,incendiary) = 0.1;
SACLOS and HOT Missiles (#6708) * abc * Revert "abc" This reverts commit bcb4214bd99bba3fec692efa4dca950323da582d. * Update to current commit * Added HOT1 Missile and SACLOS/Wire guidance * Added all HOT variants. Added polish to code * Fixed bug with pylons * Changed how seeker angle is calculated. When the wire snaps the missile goes haywire. Fixed bug where HOT2/3 missiles weren't getting missile guidance * Replaced Wiesel FireFIST launcher with HOT Launcher * Remove debug defines * Tweak thrust * Fix formatting issues. Added true randomness. Added ACE prefixes. Added string table. Tweaked missile dynamics * Fix bug where attack profile correction was wrong due to magnitude always being 50. Add stringtable values for relevant strings. Added reload time to Wiesel ATGM. Added "onFired" to initialize values * Moved wire-snapping logic to attack profile * Missile flight dynamics tweaked * Add a crosshair offset. The missile sits in this offset relative to the crosshair * Add LOS checks. Fix bug where wire-cutting didnt work. * Tweak explosive range for a kill radius of ~20m. Add fragmentation * Add AI Flags * Person in control of missile may not be the shooter * Fix RPT spam on missile out of LOS. Tweak missile dynamics. Add wire break sound cue * Fix bug where missile didn't go to a fake target in front of it when out of LOS * Use a better, more generic way to calculate direction camera is facing * Use ACE Macros for frag values. Get config entry with CBA * Add Wiki entry * Add new lines to wiki. Allow for SQF expressions in config for maxCorrectableDistance * Add CPP code tag * Fix wiki grammer error * Re-convert back to CBA_fnc_getConfigEntry * UAV Gunner support, cleanup * Fix bug where SACLOS for launcher guided weapons was off * Add the ability to define how far ahead of the missile the attack profile will seek toward
2018-12-07 02:27:30 +00:00
class ace_missileguidance: ace_missileguidance {
enabled = 1;
};
};
class GVAR(HOT3): GVAR(HOT2) {
submunitionAmmo = QGVAR(ammo_Penetrator_HOT3);
warheadName = "TandemHEAT";
displayName = CSTRING(hot3);
displayNameShort = CSTRING(hot3);
class ace_missileguidance: ace_missileguidance {
enabled = 1;
seekerMaxRange = 4300;
};
};
};