Maverick L (laser guided AGM) (#5364)

* Initial commit

* Initial commit

* Initial Commit

ACE-Coding-Guidelines compatible version of http://steamcommunity.com/sharedfiles/filedetails/?id=943852645

* Changes to realisticnames, readme.md, added to authors.

* Dependency on ace_missileguidance

* readme

* Use ACE-AMG for ammo

* Use macros in all configs

* Use own attackProfile to prevent climbing at start even in low-flight-conditions.

* include HUD from ace_hellfire

* fix missing semicolon

* Add missing defines, makes HUD work for now.

* Readme

* replace tabs with spaces

* replace tabs with spaces 2

* replace tabs with spaces 3

* Use missileguidance's DIR-Profile instead of own. Keep profiles config for name and nameLocked values necessary for HUD

* Use showHud from ace_laser

* Minor Cleanup
This commit is contained in:
xrufix 2017-09-16 22:25:20 +02:00 committed by jonpas
parent b0c27d1071
commit 31b1050f3b
12 changed files with 295 additions and 3 deletions

View File

@ -130,4 +130,5 @@ Valentin Torikian <valentin.torikian@gmail.com>
voiper
VyMajoris(W-Cephei)<vycanismajoriscsa@gmail.com>
Winter <simon@agius-muscat.net>
xrufix
zGuba

View File

@ -0,0 +1 @@
z\ace\addons\maverick

View File

@ -0,0 +1,7 @@
class EGVAR(missileguidance,AttackProfiles) {
class maverick {
name = "LOAL-DIR";
nameLocked = "LOBL-DIR";
functionName = QEFUNC(missileguidance,attackProfile_DIR);
};
};

View File

@ -0,0 +1,42 @@
class CfgAmmo {
class MissileCore;
class MissileBase : MissileCore {
class Components;
};
class Missile_AGM_02_F : MissileBase {};
class GVAR(L) : Missile_AGM_02_F {
author = "rufix";
autoSeekTarget = 0;
irLock = 0;
laserLock = 0;
manualControl = 0;
missileLockMaxDistance = 16000;
weaponLockSystem = 4;
class ace_missileguidance {
enabled = 1;
minDeflection = 0.0005;
maxDeflection = 0.01;
incDeflection = 0.005;
canVanillaLock = 0;
defaultSeekerType = "SALH";
seekerTypes[] = {"SALH"};
defaultSeekerLockMode = "LOAL";
seekerLockModes[] = {"LOAL","LOBL"};
seekLastTargetPos = 1;
seekerAngle = 60;
seekerAccuracy = 1;
seekerMinRange = 1;
seekerMaxRange = 16000;
defaultAttackProfile = "maverick";
attackProfiles[] = {"maverick"};
};
};
};

View File

@ -0,0 +1,74 @@
class CfgMagazines {
class CA_Magazine;
class VehicleMagazine : CA_Magazine {};
class magazine_Missile_AGM_02_x1 : VehicleMagazine {};
class PylonMissile_Missile_AGM_02_x1 : magazine_Missile_AGM_02_x1 {};
class PylonMissile_Missile_AGM_02_x2 : magazine_Missile_AGM_02_x1 {};
class 6Rnd_Missile_AGM_02_F : VehicleMagazine {};
class PylonRack_1Rnd_Missile_AGM_02_F : 6Rnd_Missile_AGM_02_F {};
class PylonRack_3Rnd_Missile_AGM_02_F : PylonRack_1Rnd_Missile_AGM_02_F{};
class PylonRack_Missile_AGM_02_x1 : magazine_Missile_AGM_02_x1 {};
class PylonRack_Missile_AGM_02_x2 : magazine_Missile_AGM_02_x1 {};
class GVAR(L_magazine_x1) : magazine_Missile_AGM_02_x1 {
ammo = QGVAR(L);
author = "xrufix";
descriptionShort = CSTRING(L_MAG_DESCR);
displayName = CSTRING(L_MAG_x1);
displayNameShort = CSTRING(L_MAG_short);
};
class GVAR(L_pylonmissile_x1) : PylonMissile_Missile_AGM_02_x1 {
ammo = QGVAR(L);
author = "xrufix";
descriptionShort = CSTRING(L_MAG_DESCR);
displayName = CSTRING(L_MAG_x1);
displayNameShort = CSTRING(L_MAG_short);
pylonWeapon = QGVAR(L_Launcher);
};
class GVAR(L_pylonmissile_x2) : PylonMissile_Missile_AGM_02_x2 {
ammo = QGVAR(L);
author = "xrufix";
descriptionShort = CSTRING(L_MAG_DESCR);
displayName = CSTRING(L_MAG_x1);
displayNameShort = CSTRING(L_MAG_short);
pylonWeapon = QGVAR(L_Launcher);
};
class GVAR(L_pylonRack_1Rnd) : PylonRack_1Rnd_Missile_AGM_02_F {
ammo = QGVAR(L);
author = "xrufix";
descriptionShort = CSTRING(L_MAG_DESCR);
displayName = CSTRING(L_MAG_x1);
displayNameShort = CSTRING(L_MAG_short);
pylonWeapon = QGVAR(L_Launcher_Plane);
};
class GVAR(L_PylonRack_3Rnd) : PylonRack_3Rnd_Missile_AGM_02_F {
ammo = QGVAR(L);
author = "xrufix";
descriptionShort = CSTRING(L_MAG_DESCR);
displayName = CSTRING(L_MAG_x3);
displayNameShort = CSTRING(L_MAG_short);
pylonWeapon = QGVAR(L_Launcher_Plane);
};
class GVAR(L_PylonRack_x1) : PylonRack_Missile_AGM_02_x1 {
ammo = QGVAR(L);
author = "xrufix";
descriptionShort = CSTRING(L_MAG_DESCR);
displayName = CSTRING(L_MAG_x1);
displayNameShort = CSTRING(L_MAG_short);
pylonWeapon = QGVAR(L_Launcher);
};
class GVAR(L_PylonRack_x2) : PylonRack_Missile_AGM_02_x2 {
ammo = QGVAR(L);
author = "xrufix";
descriptionShort = CSTRING(L_MAG_DESCR);
displayName = CSTRING(L_MAG_x2);
displayNameShort = CSTRING(L_MAG_short);
pylonWeapon = QGVAR(L_Launcher);
};
};

View File

@ -0,0 +1,48 @@
class CfgWeapons {
class LauncherCore;
class RocketPods : LauncherCore {};
class weapon_AGM_65Launcher : RocketPods{};
class MissileLauncher : LauncherCore {};
class Missile_AGM_02_Plane_CAS_01_F : MissileLauncher {};
class GVAR(L_Launcher) : weapon_AGM_65Launcher {
author = "xrufix";
displayname = CSTRING(L);
magazines[] = {
QGVAR(L_magazine_x1),
QGVAR(L_pylonmissile_x1),
QGVAR(L_pylonmissile_x2),
QGVAR(L_pylonRack_1Rnd),
QGVAR(L_PylonRack_3Rnd),
QGVAR(L_PylonRack_x1),
QGVAR(L_PylonRack_x2)
};
weaponLockDelay = 0.1;
weaponLockSystem = 0;
EGVAR(laser,canSelect) = 1; // can ace_laser lock (allows switching laser code)
EGVAR(laser,showHud) = 1; // show attack profile / lock on hud
GVAR(enabled) = 1;
};
class GVAR(L_Launcher_Plane) : Missile_AGM_02_Plane_CAS_01_F {
author = "xrufix";
displayname = CSTRING(L);
magazines[] = {
QGVAR(L_magazine_x1),
QGVAR(L_pylonmissile_x1),
QGVAR(L_pylonmissile_x2),
QGVAR(L_pylonRack_1Rnd),
QGVAR(L_PylonRack_3Rnd),
QGVAR(L_PylonRack_x1),
QGVAR(L_PylonRack_x2)
};
weaponLockDelay = 0.1;
weaponLockSystem = 0;
EGVAR(laser,canSelect) = 1; // can ace_laser lock (allows switching laser code)
EGVAR(laser,showHud) = 1; // show attack profile / lock on hud
GVAR(enabled) = 1;
};
};

16
addons/maverick/README.md Normal file
View File

@ -0,0 +1,16 @@
ace_maverick
==========
Adds pylon magazines with laser guided AGM-65 Maverick L.
* The magazines can be added to every plane the vanilla Macer II can be added to.
* The missile uses laser guidance based on ACE's Advanced Missile Guidance framework.
* The PylonWeapon from CfgWeapons is added to planes with pylons automatically.
![Laser guided Maverick](https://upload.wikimedia.org/wikipedia/commons/thumb/c/c3/US_Navy_041128-N-5345W-016_Aviation_Ordnanceman_3rd_Class_William_Miller_arms_a_AGM-65_Maverick_laser-guided_missile.jpg/1280px-US_Navy_041128-N-5345W-016_Aviation_Ordnanceman_3rd_Class_William_Miller_arms_a_AGM-65_Maverick_laser-guided_missile.jpg)
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [xrufix](https://github.com/xrufix)

View File

@ -0,0 +1,38 @@
#include "script_component.hpp"
class CfgPatches {
class ADDON {
name = COMPONENT_NAME;
requiredVersion = REQUIRED_VERSION;
requiredAddons[] = {"ace_hellfire"};
author = ECSTRING(common,ACETeam);
authors[] = {"xrufix"};
url = ECSTRING(main,URL);
VERSION_CONFIG;
ammo[] = {
GVAR(L)
};
magazines[] = {
QGVAR(L_magazine_x1),
QGVAR(L_pylonmissile_x1),
QGVAR(L_pylonmissile_x2),
QGVAR(L_pylonRack_1Rnd),
QGVAR(L_PylonRack_3Rnd),
QGVAR(L_PylonRack_x1),
QGVAR(L_PylonRack_x2)
};
weapons[] = {
GVAR(L_Launcher_Plane),
GVAR(L_Launcher)
};
units[] = {};
};
};
class SensorTemplateLaser;
#include "CfgAmmo.hpp"
#include "CfgMagazines.hpp"
#include "CfgWeapons.hpp"
#include "ACE_GuidanceConfig.hpp"

View File

@ -0,0 +1,17 @@
#define COMPONENT maverick
#define COMPONENT_BEAUTIFIED Maverick
#include "\z\ace\addons\main\script_mod.hpp"
// #define DEBUG_MODE_FULL
// #define DISABLE_COMPILE_CACHE
// #define ENABLE_PERFORMANCE_COUNTERS
#ifdef DEBUG_ENABLED_MAIN
#define DEBUG_MODE_FULL
#endif
#ifdef DEBUG_SETTINGS_MAIN
#define DEBUG_SETTINGS DEBUG_SETTINGS_MAIN
#endif
#include "\z\ace\addons\main\script_macros.hpp"

View File

@ -0,0 +1,33 @@
<?xml version="1.0" encoding="utf-8"?>
<Project name="ace_Maverick">
<Package name="main">
<Container name="magazines">
<Key ID="str_ace_maverick_l_mag_descr">
<English>AGM-65 Maverick L, Laser Guided Anti-Ground-Missile</English>
<German>AGM-65 Maverick L, lasergelenkte Luft-Boden-Rakete</German>
</Key>
<Key ID="str_ace_maverick_l_mag_x1">
<English>AGM-65 Maverick L x1</English>
<German>AGM-65 Maverick L x1</German>
</Key>
<Key ID="str_ace_maverick_l_mag_x2">
<English>AGM-65 Maverick L x2</English>
<German>AGM-65 Maverick L x2</German>
</Key>
<Key ID="str_ace_maverick_l_mag_x3">
<English>AGM-65 Maverick L x3</English>
<German>AGM-65 Maverick L x3</German>
</Key>
<Key ID="str_ace_maverick_l_mag_short">
<English>Laser Guided</English>
<German>Lasergelenkt</German>
</Key>
</Container>
<Container name="weapons">
<Key ID="str_ace_maverick_l">
<English>AGM-65 Maverick L</English>
<German>AGM-65 Maverick L</German>
</Key>
</Container>
</Package>
</Project>

View File

@ -434,10 +434,25 @@ class CfgMagazines {
};
class 6Rnd_Missile_AGM_02_F;
class PylonRack_1Rnd_Missile_AGM_02_F: 6Rnd_Missile_AGM_02_F {
displayName = "AGM-65 Maverick"; // [vanilla: Macer - Missile_AGM_02_Plane_CAS_01_F]
displayName = "AGM-65 Maverick G"; // [vanilla: Macer - Missile_AGM_02_Plane_CAS_01_F]
};
class PylonRack_3Rnd_Missile_AGM_02_F: PylonRack_1Rnd_Missile_AGM_02_F {
displayName = "AGM-65 Maverick 3x"; // [vanilla: Macer 3x - Missile_AGM_02_Plane_CAS_01_F]
displayName = "AGM-65 Maverick G 3x"; // [vanilla: Macer 3x - Missile_AGM_02_Plane_CAS_01_F]
};
class magazine_Missile_AGM_02_x1 : VehicleMagazine {
displayName = "AGM-65 Maverick G"; // [vanilla: Macer - Missile_AGM_02_Plane_CAS_01_F]
};
class PylonMissile_Missile_AGM_02_x1 : magazine_Missile_AGM_02_x1 {
displayName = "AGM-65 Maverick G"; // [vanilla: Macer - Missile_AGM_02_Plane_CAS_01_F]
};
class PylonMissile_Missile_AGM_02_x2 : magazine_Missile_AGM_02_x1 {
displayName = "AGM-65 Maverick G 2x"; // [vanilla: Macer 2x - Missile_AGM_02_Plane_CAS_01_F]
};
class PylonRack_Missile_AGM_02_x1 : magazine_Missile_AGM_02_x1 {
displayName = "AGM-65 Maverick G"; // [vanilla: Macer - Missile_AGM_02_Plane_CAS_01_F]
};
class PylonRack_Missile_AGM_02_x2 : magazine_Missile_AGM_02_x1 {
displayName = "AGM-65 Maverick G 2x"; // [vanilla: Macer 2x - Missile_AGM_02_Plane_CAS_01_F]
};
class 2Rnd_LG_scalpel;
class PylonRack_1Rnd_LG_scalpel: 2Rnd_LG_scalpel {

View File

@ -354,7 +354,7 @@ class CfgWeapons {
class MissileLauncher;
class Missile_AGM_02_Plane_CAS_01_F: MissileLauncher {
displayName = "AGM-65 Maverick";
displayName = "AGM-65 Maverick G";
};
class Missile_AGM_01_Plane_CAS_02_F: Missile_AGM_02_Plane_CAS_01_F {
displayName = "Kh-25MTP";