mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Merge branch 'master' of https://github.com/KoffeinFlummi/ACE3 into windWeatherOverhaul
This commit is contained in:
commit
e7bc0c26bc
Binary file not shown.
Binary file not shown.
BIN
ace_fcs.dll
BIN
ace_fcs.dll
Binary file not shown.
@ -33,6 +33,7 @@ GVAR(AtmosphericDensitySimulationEnabled) = true;
|
||||
GVAR(currentGrid) = 0;
|
||||
GVAR(INIT_MESSAGE_ENABLED) = false;
|
||||
|
||||
/* @TODO: Remove this until verisoning is in sync with cmake/build versioning
|
||||
GVAR(extensionVersion) = ("ace_advanced_ballistics" callExtension "version");
|
||||
GVAR(extensionAvailable) = (GVAR(extensionVersion) == EXTENSION_REQUIRED_VERSION);
|
||||
if (!GVAR(extensionAvailable)) exitWith {
|
||||
@ -42,5 +43,5 @@ if (!GVAR(extensionAvailable)) exitWith {
|
||||
diag_log text "[ACE] ERROR: ace_advanced_ballistics.dll is incompatible";
|
||||
};
|
||||
};
|
||||
|
||||
*/
|
||||
[] call FUNC(initializeTerrainExtension);
|
||||
|
@ -5,6 +5,7 @@ class CfgWeapons {
|
||||
|
||||
class ACE_IR_Strobe_Item: ACE_ItemCore {
|
||||
ACE_attachable = "ACE_IR_Strobe_Effect";
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
scope = 2;
|
||||
displayName = "$STR_ACE_IrStrobe_Name";
|
||||
descriptionShort = "$STR_ACE_IrStrobe_Description";
|
||||
|
@ -129,10 +129,10 @@ class CfgAmmo {
|
||||
class ACE_65x39_Caseless_green_Tracer_Dim : B_65x39_Caseless_green {
|
||||
nvgOnly = 1;
|
||||
};
|
||||
class ACE_65x47_Ball_Scenar: B_65x39_Caseless
|
||||
{
|
||||
class ACE_65x47_Ball_Scenar: B_65x39_Caseless {
|
||||
airFriction=-0.00078;
|
||||
typicalSpeed=820 ;
|
||||
caliber=0.6;
|
||||
ACE_caliber=0.264;
|
||||
ACE_bulletLength=1.364;
|
||||
ACE_bulletMass=139;
|
||||
@ -144,6 +144,21 @@ class CfgAmmo {
|
||||
ACE_muzzleVelocities[]={730, 760, 790, 820, 830};
|
||||
ACE_barrelLengths[]={10, 16, 20, 24, 26};
|
||||
};
|
||||
class ACE_65_Creedmor_Ball: B_65x39_Caseless {
|
||||
airFriction=-0.00078;
|
||||
typicalSpeed=860 ;
|
||||
caliber=0.7;
|
||||
ACE_caliber=0.264;
|
||||
ACE_bulletLength=1.426;
|
||||
ACE_bulletMass=140;
|
||||
ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19};
|
||||
ACE_ballisticCoefficients[]={0.317};
|
||||
ACE_velocityBoundaries[]={};
|
||||
ACE_standardAtmosphere="ICAO";
|
||||
ACE_dragModel=7;
|
||||
ACE_muzzleVelocities[]={750, 830, 850, 860, 865};
|
||||
ACE_barrelLengths[]={10, 16, 20, 24, 26};
|
||||
};
|
||||
class B_762x51_Ball : BulletBase {
|
||||
airFriction=-0.001035;
|
||||
typicalSpeed=833;
|
||||
@ -211,6 +226,54 @@ class CfgAmmo {
|
||||
ACE_muzzleVelocities[]={305, 325, 335, 340};
|
||||
ACE_barrelLengths[]={16, 20, 24, 26};
|
||||
};
|
||||
class ACE_30_06_M1_Ball : B_762x51_Ball {
|
||||
airFriction=-0.0009;
|
||||
typicalSpeed=800;
|
||||
caliber=1.3;
|
||||
hit=10;
|
||||
ACE_caliber=0.308;
|
||||
ACE_bulletLength=1.21;
|
||||
ACE_bulletMass=174;
|
||||
ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19};
|
||||
ACE_ballisticCoefficients[]={0.494};
|
||||
ACE_velocityBoundaries[]={};
|
||||
ACE_standardAtmosphere="ASM";
|
||||
ACE_dragModel=1;
|
||||
ACE_muzzleVelocities[]={700, 785, 800, 830, 840};
|
||||
ACE_barrelLengths[]={10, 16, 20, 24, 26};
|
||||
};
|
||||
class ACE_7_Remington_Magnum_Ball : B_762x51_Ball {
|
||||
airFriction=-0.0008;
|
||||
typicalSpeed=820;
|
||||
caliber=1.4;
|
||||
hit=8;
|
||||
ACE_caliber=0.284;
|
||||
ACE_bulletLength=1.529;
|
||||
ACE_bulletMass=180;
|
||||
ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19};
|
||||
ACE_ballisticCoefficients[]={0.345};
|
||||
ACE_velocityBoundaries[]={};
|
||||
ACE_standardAtmosphere="ICAO";
|
||||
ACE_dragModel=7;
|
||||
ACE_muzzleVelocities[]={720, 780, 812, 822, 830};
|
||||
ACE_barrelLengths[]={10, 16, 20, 24, 26};
|
||||
};
|
||||
class ACE_243_Winchester_Ball : B_762x51_Ball {
|
||||
airFriction=-0.00095;
|
||||
typicalSpeed=915;
|
||||
caliber=0.8;
|
||||
hit=6;
|
||||
ACE_caliber=0.243;
|
||||
ACE_bulletLength=1.282;
|
||||
ACE_bulletMass=180;
|
||||
ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19};
|
||||
ACE_ballisticCoefficients[]={0.278};
|
||||
ACE_velocityBoundaries[]={};
|
||||
ACE_standardAtmosphere="ICAO";
|
||||
ACE_dragModel=7;
|
||||
ACE_muzzleVelocities[]={830, 875, 900, 915, 920};
|
||||
ACE_barrelLengths[]={10, 16, 20, 24, 26};
|
||||
};
|
||||
class ACE_762x67_Ball_Mk248_Mod_0 : B_762x51_Ball {
|
||||
airFriction=-0.000830;
|
||||
caliber=1.08;
|
||||
|
@ -42,9 +42,9 @@ class CfgMagazines {
|
||||
class ACE_30Rnd_65x39_caseless_green_mag_Tracer_Dim: 30Rnd_65x39_caseless_green_mag_Tracer {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
ammo = "ACE_65x39_Caseless_green_Tracer_Dim";
|
||||
displayName = "$STR_ACE_30Rnd_65x39_caseless_mag_Tracer_DimName";
|
||||
displayNameShort = "$STR_ACE_30Rnd_65x39_caseless_mag_Tracer_DimNameShort";
|
||||
descriptionShort = "$STR_ACE_30Rnd_65x39_caseless_mag_Tracer_DimDescription";
|
||||
displayName = "$STR_ACE_30Rnd_65x39_caseless_green_mag_Tracer_DimName";
|
||||
displayNameShort = "$STR_ACE_30Rnd_65x39_caseless_green_mag_Tracer_DimNameShort";
|
||||
descriptionShort = "$STR_ACE_30Rnd_65x39_caseless_green_mag_Tracer_DimDescription";
|
||||
};
|
||||
|
||||
class 30Rnd_556x45_Stanag: CA_Magazine {
|
||||
@ -179,6 +179,13 @@ class CfgMagazines {
|
||||
displayNameShort = "$STR_ACE_30Rnd_65x47_Scenar_mag_NameShort";
|
||||
descriptionShort = "$STR_ACE_30Rnd_65x47_Scenar_mag_Description";
|
||||
};
|
||||
class ACE_30Rnd_65_Creedmor_mag: 30Rnd_65x39_caseless_mag {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
ammo = "ACE_65_Creedmor_Ball";
|
||||
displayName = "$STR_ACE_30Rnd_65_Creedmor_mag_Name";
|
||||
displayNameShort = "$STR_ACE_30Rnd_65_Creedmor_mag_NameShort";
|
||||
descriptionShort = "$STR_ACE_30Rnd_65_Creedmor_mag_Description";
|
||||
};
|
||||
class 10Rnd_338_Mag;
|
||||
class ACE_10Rnd_338_300gr_HPBT_Mag: 10Rnd_338_Mag {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
|
@ -14,6 +14,7 @@ class CfgVehicles {
|
||||
class Box_NATO_Wps_F: NATO_Box_Base {
|
||||
class TransportMagazines {
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65x47_Scenar_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65_Creedmor_mag,4);
|
||||
};
|
||||
};
|
||||
|
||||
@ -33,6 +34,7 @@ class CfgVehicles {
|
||||
class Box_NATO_Ammo_F: NATO_Box_Base {
|
||||
class TransportMagazines {
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65x47_Scenar_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65_Creedmor_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_10Rnd_762x51_M118LR_Mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_20Rnd_762x51_M118LR_Mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_10Rnd_762x51_Mk319_Mod_0_Mag,4);
|
||||
@ -64,6 +66,7 @@ class CfgVehicles {
|
||||
class B_supplyCrate_F: ReammoBox_F {
|
||||
class TransportMagazines {
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65x47_Scenar_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65_Creedmor_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_10Rnd_762x51_M118LR_Mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_20Rnd_762x51_M118LR_Mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_10Rnd_762x51_Mk319_Mod_0_Mag,4);
|
||||
@ -76,6 +79,7 @@ class CfgVehicles {
|
||||
class Box_East_Wps_F: EAST_Box_Base {
|
||||
class TransportMagazines {
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65x47_Scenar_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65_Creedmor_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_10Rnd_762x54_Tracer_mag,4);
|
||||
};
|
||||
};
|
||||
@ -85,6 +89,7 @@ class CfgVehicles {
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_556x45_Stanag_Tracer_Dim,1);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65x39_caseless_green_mag_Tracer_Dim,4);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65x47_Scenar_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65_Creedmor_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_10Rnd_762x54_Tracer_mag,4);
|
||||
};
|
||||
};
|
||||
@ -92,6 +97,7 @@ class CfgVehicles {
|
||||
class Box_East_Ammo_F: EAST_Box_Base {
|
||||
class TransportMagazines {
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65x47_Scenar_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65_Creedmor_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_10Rnd_762x54_Tracer_mag,4);
|
||||
};
|
||||
};
|
||||
@ -99,6 +105,7 @@ class CfgVehicles {
|
||||
class Box_East_Support_F: EAST_Box_Base {
|
||||
class TransportMagazines {
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65x47_Scenar_mag,6);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65_Creedmor_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_20Rnd_762x51_Mag_SD,3);
|
||||
MACRO_ADDMAGAZINE(ACE_10Rnd_762x54_Tracer_mag,4);
|
||||
};
|
||||
@ -157,6 +164,7 @@ class CfgVehicles {
|
||||
class C_supplyCrate_F: ReammoBox_F {
|
||||
class TransportMagazines {
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65x47_Scenar_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65_Creedmor_mag,4);
|
||||
};
|
||||
};
|
||||
|
||||
@ -164,7 +172,7 @@ class CfgVehicles {
|
||||
scope = 2;
|
||||
accuracy = 1000;
|
||||
displayName = "[ACE] Ammo Supply Crate";
|
||||
// TODO: model = "...";
|
||||
model = "\A3\weapons_F\AmmoBoxes\AmmoBox_F";
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
class TransportMagazines {
|
||||
MACRO_ADDMAGAZINE(ACE_20Rnd_762x51_Mag_SD,4);
|
||||
@ -185,6 +193,7 @@ class CfgVehicles {
|
||||
MACRO_ADDMAGAZINE(ACE_100Rnd_65x39_caseless_mag_Tracer_Dim,4);
|
||||
MACRO_ADDMAGAZINE(ACE_200Rnd_65x39_cased_Box_Tracer_Dim,4);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65x47_Scenar_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_30Rnd_65_Creedmor_mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_10Rnd_338_300gr_HPBT_Mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_10Rnd_338_API526_Mag,4);
|
||||
MACRO_ADDMAGAZINE(ACE_5Rnd_127x99_Mag,4);
|
||||
|
@ -88,7 +88,8 @@ class CfgWeapons {
|
||||
"30Rnd_65x39_caseless_mag",
|
||||
"30Rnd_65x39_caseless_mag_Tracer",
|
||||
"ACE_30Rnd_65x39_caseless_mag_Tracer_Dim",
|
||||
"ACE_30Rnd_65x47_Scenar_mag"
|
||||
"ACE_30Rnd_65x47_Scenar_mag",
|
||||
"ACE_30Rnd_65_Creedmor_mag"
|
||||
};
|
||||
initSpeed = -1.018;
|
||||
ACE_barrelTwist=9;
|
||||
|
@ -743,7 +743,7 @@
|
||||
<Russian>6,5 мм ИК-трассирующие</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_100Rnd_65x39_caseless_mag_Tracer_DimDescription">
|
||||
<English>6.5mm 100Rnd Tracer IR-DIM Mag</English>
|
||||
<English>6.5mm 100Rnd Tracer IR-DIM Mag<br />Rounds: 100<br />Used in: MX LSW</English>
|
||||
<Polish>Magazynek 6,5mm 100rd Smugacz IR-DIM</Polish>
|
||||
<French>Chargeur 6.5mm 100Rnd Traçante IR-DIM</French>
|
||||
<Spanish>Cargador de 100 balas trazadoras IR-DIM de 6.5mm</Spanish>
|
||||
@ -764,7 +764,7 @@
|
||||
<Russian>6,5 мм ИК-трассирующие</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_200Rnd_65x39_cased_Box_Tracer_DimDescription">
|
||||
<English>6.5mm 200Rnd Tracer IR-DIM Belt</English>
|
||||
<English>6.5mm 200Rnd Tracer IR-DIM Belt<br />Rounds: 200<br />Used in: Stoner 99 LMG</English>
|
||||
<Polish>Magazynek 6,5mm 200rd Smugacz IR-DIM</Polish>
|
||||
<French>Bande 6.5mm 200Cps Traçante IR-DIM</French>
|
||||
<Spanish>Cinta de 200 balas trazadoras IR-DIM de 6.5mm</Spanish>
|
||||
@ -967,19 +967,32 @@
|
||||
<Russian>Магазин из 30-ти 6,5x47 мм (HPBT Scenar)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_30Rnd_65x47_Scenar_mag_NameShort">
|
||||
<English>6.5mm Scenar</English>
|
||||
<French>6.5mm Scenar</French>
|
||||
<Spanish>6.5mm Scenar</Spanish>
|
||||
<Polish>6,5mm Scenar</Polish>
|
||||
<Russian>6,5 мм Scenar</Russian>
|
||||
<English>6.5mm Lapua</English>
|
||||
<French>6.5mm Lapua</French>
|
||||
<Spanish>6.5mm Lapua</Spanish>
|
||||
<Polish>6,5mm Lapua</Polish>
|
||||
<Russian>6,5 мм Lapua</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_30Rnd_65x47_Scenar_mag_Description">
|
||||
<English>Caliber: 6.5x47mm (HPBT Scenar)<br />Rounds: 30</English>
|
||||
<English>Caliber: 6.5x47mm (HPBT Scenar)<br />Rounds: 30<br />Used in: MXM</English>
|
||||
<French>Calibre: 6.5x47mm (HPBT Scenar)<br />Cartouches: 30</French>
|
||||
<Spanish>Calibre: 6.5x47mm (HPBT Scenar)<br />Balas: 30</Spanish>
|
||||
<Polish>Kaliber: 6,5x47 mm (HPBT Scenar)<br />Pociski: 30</Polish>
|
||||
<Russian>Калибр: 6,5x47 мм (HPBT Scenar)<br />Патронов: 30</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_30Rnd_65_Creedmor_mag_Name">
|
||||
<English>6.5mm Creedmor 30Rnd Mag</English>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_30Rnd_65_Creedmor_mag_NameShort">
|
||||
<English>6.5mm CM</English>
|
||||
<French>6.5mm CM</French>
|
||||
<Spanish>6.5mm CM</Spanish>
|
||||
<Polish>6,5mm CM</Polish>
|
||||
<Russian>6,5 мм CM</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_30Rnd_65_Creedmor_mag_Description">
|
||||
<English>Caliber: 6.5mm Creedmor<br />Rounds: 30<br />Used in: MXM</English>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_10Rnd_338_300gr_HPBT_Mag_Name">
|
||||
<English>.338 10Rnd Mag (300gr Sierra MatchKing HPBT)</English>
|
||||
<French>.338 10 Cps (300gr Sierra MatchKing HPBT)</French>
|
||||
|
@ -2,7 +2,6 @@
|
||||
class CfgWeapons {
|
||||
class ItemCore;
|
||||
class ACE_ItemCore: ItemCore {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
type = 4096;//4;
|
||||
detectRange = -1;
|
||||
simulation = "ItemMineDetector";
|
||||
@ -14,7 +13,6 @@ class CfgWeapons {
|
||||
};
|
||||
|
||||
class ACE_FakePrimaryWeapon: Rifle_Base_F {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
scope = 2;
|
||||
scopeCurator = 1;
|
||||
|
||||
@ -32,6 +30,7 @@ class CfgWeapons {
|
||||
|
||||
class InventoryItem_Base_F;
|
||||
class ACE_Banana: ACE_ItemCore {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
scope = 2;
|
||||
displayName = "$STR_ACE_Common_bananaDisplayName";
|
||||
descriptionShort = "$STR_ACE_Common_bananaDescr";
|
||||
|
@ -22,4 +22,4 @@ if !([_unit, _target, []] call EFUNC(common,canInteractWith)) exitWith {false};
|
||||
// a static weapon has to be empty for dragging
|
||||
if ((typeOf _target) isKindOf "StaticWeapon" && {count crew _target > 0}) exitWith {false};
|
||||
|
||||
alive _target && {_target getVariable [QGVAR(canCarry), false]} && {animationState _target in ["", "unconscious"] || (_target getvariable ["ACE_isUnconscious", false]) || (_target isKindOf "CAManBase" && {(_target getHitPointDamage "HitLeftLeg") + (_target getHitPointDamage "HitRightLeg") > 0.4})}
|
||||
alive _target && {_target getVariable [QGVAR(canCarry), false]} && {animationState _target in ["", "unconscious"] || (_target getvariable ["ACE_isUnconscious", false]) || (_target isKindOf "CAManBase" && {(_target getHitPointDamage "HitLegs") > 0.4})}
|
||||
|
@ -22,4 +22,4 @@ if !([_unit, _target, []] call EFUNC(common,canInteractWith)) exitWith {false};
|
||||
// a static weapon has to be empty for dragging
|
||||
if ((typeOf _target) isKindOf "StaticWeapon" && {count crew _target > 0}) exitWith {false};
|
||||
|
||||
alive _target && {_target getVariable [QGVAR(canDrag), false]} && {animationState _target in ["", "unconscious"] || (_target getvariable ["ACE_isUnconscious", false]) || (_target isKindOf "CAManBase" && {(_target getHitPointDamage "HitLeftLeg") + (_target getHitPointDamage "HitRightLeg") > 0.4})};
|
||||
alive _target && {_target getVariable [QGVAR(canDrag), false]} && {animationState _target in ["", "unconscious"] || (_target getvariable ["ACE_isUnconscious", false]) || (_target isKindOf "CAManBase" && {(_target getHitPointDamage "HitLegs") > 0.4})};
|
@ -50,7 +50,7 @@ class CfgVehicles {
|
||||
class Items_base_F;
|
||||
class ACE_DefuseObject: Items_base_F {
|
||||
XEH_ENABLED;
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
author = "ACE";
|
||||
_generalMacro = "ACE_DefuseObject";
|
||||
displayName = "ACE Defuse Helper";
|
||||
mapSize = 0.2;
|
||||
@ -80,7 +80,7 @@ class CfgVehicles {
|
||||
};
|
||||
class ACE_Explosives_Place: Items_base_F {
|
||||
XEH_ENABLED;
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
author = "ACE";
|
||||
_generalMacro = "ACE_Explosives_Place";
|
||||
displayName = "Multi-meter";
|
||||
mapSize = 0.2;
|
||||
|
@ -1,7 +1,7 @@
|
||||
class CfgMagazines {
|
||||
class HandGrenade;
|
||||
class ACE_HandFlare_Base: HandGrenade {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
scope = 1;
|
||||
value = 2;
|
||||
nameSoundWeapon = "smokeshell";
|
||||
nameSound = "smokeshell";
|
||||
@ -9,6 +9,8 @@ class CfgMagazines {
|
||||
initSpeed = 22;
|
||||
};
|
||||
class ACE_HandFlare_White: ACE_HandFlare_Base {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
scope = 2;
|
||||
ammo = "ACE_F_Hand_White";
|
||||
displayname = "$STR_ACE_Grenades_M127A1_White_Name";
|
||||
descriptionshort = "$STR_ACE_Grenades_M127A1_White_Description";
|
||||
@ -17,6 +19,8 @@ class CfgMagazines {
|
||||
picture = "\A3\Weapons_F\Data\UI\gear_flare_white_ca.paa";
|
||||
};
|
||||
class ACE_HandFlare_Red: ACE_HandFlare_Base {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
scope = 2;
|
||||
ammo = "ACE_F_Hand_Red";
|
||||
displayname = "$STR_ACE_Grenades_M127A1_Red_Name";
|
||||
descriptionshort = "$STR_ACE_Grenades_M127A1_Red_Description";
|
||||
@ -25,6 +29,8 @@ class CfgMagazines {
|
||||
picture = "\A3\Weapons_F\Data\UI\gear_flare_red_ca.paa";
|
||||
};
|
||||
class ACE_HandFlare_Green: ACE_HandFlare_Base {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
scope = 2;
|
||||
ammo = "ACE_F_Hand_Green";
|
||||
displayname = "$STR_ACE_Grenades_M127A1_Green_Name";
|
||||
descriptionshort = "$STR_ACE_Grenades_M127A1_Green_Description";
|
||||
@ -33,6 +39,8 @@ class CfgMagazines {
|
||||
picture = "\A3\Weapons_F\Data\UI\gear_flare_green_ca.paa";
|
||||
};
|
||||
class ACE_HandFlare_Yellow: ACE_HandFlare_Base {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
scope = 2;
|
||||
ammo = "ACE_F_Hand_Yellow";
|
||||
displayname = "$STR_ACE_Grenades_M127A1_Yellow_Name";
|
||||
descriptionshort = "$STR_ACE_Grenades_M127A1_Yellow_Description";
|
||||
@ -41,8 +49,8 @@ class CfgMagazines {
|
||||
picture = "\A3\Weapons_F\Data\UI\gear_flare_yellow_ca.paa";
|
||||
};
|
||||
class ACE_M84: HandGrenade {
|
||||
ammo = "ACE_G_M84";
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
ammo = "ACE_G_M84";
|
||||
displayname = "$STR_ACE_Grenades_M84_Name";
|
||||
descriptionshort = "$STR_ACE_Grenades_M84_Description";
|
||||
displayNameShort = "M84";
|
||||
|
@ -3,6 +3,15 @@
|
||||
|
||||
if (!hasInterface) exitWith {};
|
||||
|
||||
//Setup text/shadow color matrix
|
||||
[] call FUNC(setupTextColors);
|
||||
["SettingChanged", {
|
||||
PARAMS_2(_name,_value);
|
||||
if ((_name == QGVAR(colorTextMax)) || {_name == QGVAR(colorTextMin)} || {_name == QGVAR(colorShadowMax)} || {_name == QGVAR(colorShadowMin)}) then {
|
||||
[] call FUNC(setupTextColors);
|
||||
};
|
||||
}] call EFUNC(common,addEventhandler);
|
||||
|
||||
// Install the render EH on the main display
|
||||
addMissionEventHandler ["Draw3D", DFUNC(render)];
|
||||
|
||||
|
@ -21,6 +21,7 @@ PREP(renderBaseMenu);
|
||||
PREP(renderIcon);
|
||||
PREP(renderMenu);
|
||||
PREP(renderSelector);
|
||||
PREP(setupTextColors);
|
||||
PREP(splitPath);
|
||||
|
||||
GVAR(keyDown) = false;
|
||||
|
@ -37,6 +37,30 @@ class ACE_Settings {
|
||||
isClientSettable = 1;
|
||||
displayName = "$STR_ACE_Interact_Menu_UseListMenu";
|
||||
};
|
||||
class GVAR(colorTextMax) {
|
||||
value[] = {1, 1, 1, 1};
|
||||
typeName = "COLOR";
|
||||
isClientSettable = 1;
|
||||
displayName = "$STR_ACE_Interact_Menu_ColorTextMax";
|
||||
};
|
||||
class GVAR(colorTextMin) {
|
||||
value[] = {1, 1, 1, 0.25};
|
||||
typeName = "COLOR";
|
||||
isClientSettable = 1;
|
||||
displayName = "$STR_ACE_Interact_Menu_ColorTextMin";
|
||||
};
|
||||
class GVAR(colorShadowMax) {
|
||||
value[] = {1, 1, 1, 1};
|
||||
typeName = "COLOR";
|
||||
isClientSettable = 1;
|
||||
displayName = "$STR_ACE_Interact_Menu_ColorShadowMax";
|
||||
};
|
||||
class GVAR(colorShadowMin) {
|
||||
value[] = {1, 1, 1, 0.25};
|
||||
typeName = "COLOR";
|
||||
isClientSettable = 1;
|
||||
displayName = "$STR_ACE_Interact_Menu_ColorShadowMin";
|
||||
};
|
||||
};
|
||||
|
||||
class ACE_Extensions {
|
||||
|
@ -4,12 +4,11 @@
|
||||
*
|
||||
* Argument:
|
||||
* 0: Text <STRING>
|
||||
* 1: Color <STRING>
|
||||
* 1: Icon <STRING>
|
||||
* 2: 2d position <ARRAY>
|
||||
* 3: ?
|
||||
* 4: ?
|
||||
* 5: ?
|
||||
* 6: Icon <STRING>
|
||||
* 3: Color <STRING>
|
||||
* 4: Shadow Color <STRING>
|
||||
* 5: Icon Color <STRING>
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
@ -18,11 +17,8 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
#define DEFAULT_ICON QUOTE(\z\ace\addons\interaction\ui\dot_ca.paa)
|
||||
private ["_color", "_sPos", "_ctrl", "_icon"];
|
||||
_text = _this select 0;
|
||||
_color = _this select 1;
|
||||
_sPos = _this select 2;
|
||||
_icon = _this select 6;
|
||||
private ["_ctrl"];
|
||||
PARAMS_6(_text,_icon,_sPos,_textColor,_shadowColor,_iconColor);
|
||||
|
||||
//systemChat format ["Icon %1 - %2,%3", _text, _sPos select 0, _sPos select 1];
|
||||
|
||||
@ -37,16 +33,15 @@ if(_icon == "") then {
|
||||
};
|
||||
|
||||
_text = if (GVAR(UseListMenu)) then {
|
||||
format ["<img image='%1' color='%2' align='left'/><t color='%3' size='0.80' shadow='1' shadowColor='#000000' shadowOffset='0.07'>%4</t>", _icon, _color, _color, _text]
|
||||
format ["<img image='%1' color='%2' align='left'/><t color='%3' size='0.80' shadow='1' shadowColor='%4' shadowOffset='0.06'>%5</t>", _icon, _iconColor, _textColor, _shadowColor, _text]
|
||||
} else {
|
||||
format ["<img image='%1' color='%2' align='center'/><br/><t color='%3' size='0.80' align='center' shadow='1' shadowColor='#000000' shadowOffset='0.07'>%4</t>", _icon, _color, _color, "ace_breakLine" callExtension _text];
|
||||
format ["<img image='%1' color='%2' align='center'/><br/><t color='%3' size='0.80' align='center' shadow='1' shadowColor='%4' shadowOffset='0.06'>%5</t>", _icon, _iconColor, _textColor, _shadowColor, "ace_breakLine" callExtension _text];
|
||||
};
|
||||
|
||||
_ctrl ctrlSetStructuredText (parseText _text);
|
||||
_text = if (GVAR(UseListMenu)) then {
|
||||
_ctrl ctrlSetPosition [(_sPos select 0)-(0.0095*SafeZoneW), (_sPos select 1)-(0.0095*SafeZoneW), 0.20*SafeZoneW, 0.035*SafeZoneW];
|
||||
_ctrl ctrlSetPosition [(_sPos select 0)-(0.0095*SafeZoneW), (_sPos select 1)-(0.0095*SafeZoneW), 0.20*SafeZoneW, 0.035*SafeZoneW];
|
||||
} else {
|
||||
_ctrl ctrlSetPosition [(_sPos select 0)-(0.0750*SafeZoneW), (_sPos select 1)-(0.0095*SafeZoneW), 0.15*SafeZoneW, 0.100*SafeZoneW];
|
||||
_ctrl ctrlSetPosition [(_sPos select 0)-(0.0750*SafeZoneW), (_sPos select 1)-(0.0095*SafeZoneW), 0.15*SafeZoneW, 0.100*SafeZoneW];
|
||||
};
|
||||
//_ctrl ctrlSetBackgroundColor [0, 1, 0, 0.1];
|
||||
_ctrl ctrlCommit 0;
|
||||
|
@ -45,19 +45,17 @@ _menuInSelectedPath = true;
|
||||
|
||||
// Render icon
|
||||
// ARGB Color (First Hex Pair is transparancy)
|
||||
_color = "#FFFFFFFF";
|
||||
_textColor = GVAR(colorSelected);
|
||||
_shadowColor = GVAR(colorSelectedShadow);
|
||||
if(!_menuInSelectedPath) then {
|
||||
if (_menuDepth > 0) then {
|
||||
_color = format ["#%1FFFFFF", [255 * ((((count _path) - 1)/_menuDepth) max 0.25)] call EFUNC(common,toHex)];
|
||||
} else {
|
||||
_color = format ["#%1FFFFFF", [255 * 0.75] call EFUNC(common,toHex)];
|
||||
};
|
||||
_textColor = (GVAR(colorNotSelectedMatrix) select (count _path)) select _menuDepth;
|
||||
_shadowColor = (GVAR(colorShadowNotSelectedMatrix) select (count _path)) select _menuDepth;
|
||||
};
|
||||
|
||||
//END_COUNTER(constructing_colors);
|
||||
//BEGIN_COUNTER(fnc_renderIcons);
|
||||
|
||||
[_actionData select 1, _color, _sPos, 1, 1, 0, _actionData select 2, 0.5, 0.025, "TahomaB"] call FUNC(renderIcon);
|
||||
[_actionData select 1, _actionData select 2, _sPos, _textColor, _shadowColor, "#FFFFFFFF"] call FUNC(renderIcon);
|
||||
|
||||
//END_COUNTER(fnc_renderIcons);
|
||||
|
||||
|
52
addons/interact_menu/functions/fnc_setupTextColors.sqf
Normal file
52
addons/interact_menu/functions/fnc_setupTextColors.sqf
Normal file
@ -0,0 +1,52 @@
|
||||
/*
|
||||
* Author: PabstMirror
|
||||
* Builds color strings needed for displaying interaction text
|
||||
*
|
||||
* Argument:
|
||||
* None
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_mixColor", "_rowT", "_rowS", "_menuDepth", "_pathCount", "_menuInSelectedPath", "_color", "_path"];
|
||||
|
||||
//Mixes 2 colors (number arrays) and makes a color string "#AARRGGBB" for structured text
|
||||
_mixColor = {
|
||||
PARAMS_3(_color1,_color2,_ratio);
|
||||
private ["_return", "_mix", "_index"];
|
||||
_return = "";
|
||||
for "_index" from 0 to 3 do {
|
||||
_mix = linearConversion [0, 1, _ratio, (_color1 select _index), (_color2 select _index)];
|
||||
if (_index != 3) then {
|
||||
_return = _return + ([255 * _mix] call EFUNC(common,toHex));
|
||||
} else {
|
||||
_return = "#" + ([255 * _mix] call EFUNC(common,toHex)) + _return;
|
||||
};
|
||||
};
|
||||
_return
|
||||
};
|
||||
|
||||
GVAR(colorSelected) = [GVAR(colorTextMin), GVAR(colorTextMax), 1] call _mixColor;
|
||||
GVAR(colorSelectedShadow) = [GVAR(colorShadowMin), GVAR(colorShadowMax), 1] call _mixColor;
|
||||
GVAR(colorNotSelectedMatrix) = [];
|
||||
GVAR(colorShadowNotSelectedMatrix) = [];
|
||||
|
||||
for "_pathCount" from 0 to 15 do {
|
||||
_rowT = [];
|
||||
_rowS = [];
|
||||
for "_menuDepth" from 0 to 15 do {
|
||||
if (_menuDepth > 0) then {
|
||||
_rowT pushBack ([GVAR(colorTextMin), GVAR(colorTextMax), (((_pathCount - 1) / _menuDepth) max 0.25)] call _mixColor);
|
||||
_rowS pushBack ([GVAR(colorShadowMin), GVAR(colorShadowMax), (((_pathCount - 1) / _menuDepth) max 0.25)] call _mixColor);
|
||||
} else {
|
||||
_rowT pushBack ([GVAR(colorTextMin), GVAR(colorTextMax), 0] call _mixColor);
|
||||
_rowS pushBack ([GVAR(colorShadowMin), GVAR(colorShadowMax), 0] call _mixColor);
|
||||
};
|
||||
};
|
||||
GVAR(colorNotSelectedMatrix) pushBack _rowT;
|
||||
GVAR(colorShadowNotSelectedMatrix) pushBack _rowS;
|
||||
};
|
@ -71,5 +71,17 @@
|
||||
<Hungarian>Járműves cselekvések</Hungarian>
|
||||
<Italian>Interazioni con veicoli</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Interact_Menu_ColorTextMax">
|
||||
<English>Interaction - Text Max</English>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Interact_Menu_ColorTextMin">
|
||||
<English>Interaction - Text Min</English>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Interact_Menu_ColorShadowMax">
|
||||
<English>Interaction - Shadow Max</English>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Interact_Menu_ColorShadowMin">
|
||||
<English>Interaction - Shadow Min</English>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
||||
</Project>
|
@ -3,6 +3,7 @@ class CfgWeapons {
|
||||
class ACE_ItemCore;
|
||||
|
||||
class ACE_wirecutter: ACE_ItemCore {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
displayName = "$STR_ACE_logistics_wirecutter_wirecutterName";
|
||||
descriptionShort = "$STR_ACE_logistics_wirecutter_wirecutterDescription";
|
||||
model = "\A3\weapons_F\ammo\mag_univ.p3d";
|
||||
|
@ -1,4 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Edited with tabler. -->
|
||||
<Project name="ACE">
|
||||
<Package name="MagazineRepack">
|
||||
<Key ID="STR_ACE_MagazineRepack_RepackMagazines">
|
||||
@ -66,7 +67,7 @@
|
||||
<German>%1 volle(s) Magazin(e) und %2 übrig gebliebene Patrone(n)</German>
|
||||
<Spanish>%1 cargador(es) completo(s) y %2 bala(s) extra(s)</Spanish>
|
||||
<French>%1 chargeur(s) plein(s) et %2 cartouche(s) en rab</French>
|
||||
<Polish>Pełnych magazynków: %1.<br /> Dodatkowych naboi: %2.</Polish>
|
||||
<Polish>Pełnych magazynków: %1.<br/>Dodatkowych naboi: %2.</Polish>
|
||||
<Czech>%1 plný zásobník(y) a %2 munice navíc</Czech>
|
||||
<Italian>%1 caricatore/i pieno e %2 munizioni extra</Italian>
|
||||
<Portuguese>%1 carregador(es) cheio(s) e %2 disparo(s) a mais</Portuguese>
|
||||
@ -102,9 +103,9 @@
|
||||
<Spanish>%1 Total y %2 Parcial</Spanish>
|
||||
<Russian>%1 полных и %2 неполных</Russian>
|
||||
<Czech>%1 plný a %2 částečně</Czech>
|
||||
<Polish>Pełnych: %1.<br />Częściowo pełnych: %2.</Polish>
|
||||
<Polish>Pełnych: %1.<br/>Częściowo pełnych: %2.</Polish>
|
||||
<Hungarian>%1 teljes és %2 részleges</Hungarian>
|
||||
<Italian>%1 pieno e %2 parziale</Italian>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
||||
</Project>
|
||||
|
@ -72,7 +72,7 @@ _vehicle = vehicle _unit;
|
||||
// Do not obscure the map if the player is on a enclosed vehicle (assume internal illumination)
|
||||
if (_vehicle != _unit) then {
|
||||
// Player is in a vehicle
|
||||
if (isTurnedOut _unit && {_vehicle isKindOf "Tank" || {_vehicle isKindOf "Wheeled_APC"}}) then {
|
||||
if (isTurnedOut _unit && { _vehicle isKindOf "Tank" || { ( _vehicle isKindOf "Helicopter" || _vehicle isKindOf "Plane" ) && { (driver _vehicle) == _unit || { (gunner _vehicle) == _unit } } } || {_vehicle isKindOf "Wheeled_APC"}}) then {
|
||||
_isEnclosed = true;
|
||||
};
|
||||
};
|
||||
|
@ -1,12 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project name="ACE">
|
||||
<Package name="Medical">
|
||||
<Key ID="TR_ACE_Medical_litterSimulationDetail">
|
||||
<Key ID="STR_ACE_Medical_litterSimulationDetail">
|
||||
<English>Litter Simulation Detail</English>
|
||||
<Polish>Detale zużytych medykamentów</Polish>
|
||||
<Spanish>Detalle de simulación de basura</Spanish>
|
||||
</Key>
|
||||
<Key ID="TR_ACE_Medical_litterSimulationDetail_Desc">
|
||||
<Key ID="STR_ACE_Medical_litterSimulationDetail_Desc">
|
||||
<English>Litter simulation detail level sets the number of litter items which will be locally spawned in the client. Excessive amounts in local areas could cause FPS lag, so this is a client only setting.</English>
|
||||
<Polish>Opcja ta ustawia liczbę zużytych medykamentów, jakie pojawiają się lokalnie wokół gracza. Ich zbyt duża ilość może spowodować spadki FPS, dlatego jest to ustawienie tylko po stronie klienta.</Polish>
|
||||
<Spanish>Detalle simulación de basura establece el número de artículos de basura que se generan a nivel local en el cliente. Las cantidades excesivas en áreas locales podrían causar caída de rendimiento, así que esto es un ajuste de cliente únicamente.</Spanish>
|
||||
|
@ -3,6 +3,7 @@ class CfgWeapons {
|
||||
class InventoryItem_Base_F;
|
||||
|
||||
class ACE_microDAGR: ACE_ItemCore {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
scope = 2;
|
||||
displayName = "$STR_ACE_microdagr_itemName";
|
||||
descriptionShort = "$STR_ACE_microdagr_itemDescription";
|
||||
|
@ -20,7 +20,7 @@ class CfgVehicles {
|
||||
|
||||
class ACE_Comanche_Test : B_Heli_Attack_01_F {
|
||||
displayName = "ACE_Comanche_Test";
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
author = "ACE Team";
|
||||
class Library {
|
||||
libTextDesc = "ACE_Comanche_Test";
|
||||
};
|
||||
|
@ -5,10 +5,35 @@ class CfgMovesBasic {
|
||||
};
|
||||
|
||||
class Actions {
|
||||
class RifleStandActionsNoAdjust;
|
||||
class RifleLowStandActionsNoAdjust;
|
||||
class RifleBaseStandActions;
|
||||
class RifleKneelActions: RifleBaseStandActions {
|
||||
Civil = "AmovPknlMstpSnonWnonDnon";
|
||||
};
|
||||
class RifleProneActions: RifleBaseStandActions {
|
||||
Civil = "AmovPpneMstpSnonWnonDnon";
|
||||
SecondaryWeapon = "AmovPpneMstpSrasWlnrDnon";
|
||||
};
|
||||
|
||||
class PistolStandActions;
|
||||
class PistolProneActions: PistolStandActions {
|
||||
SecondaryWeapon = "AmovPpneMstpSrasWlnrDnon";
|
||||
};
|
||||
|
||||
class LauncherKneelActions;
|
||||
/*class LauncherStandActions: LauncherKneelActions {
|
||||
PlayerProne = "AmovPpneMstpSrasWlnrDnon";
|
||||
Down = "AmovPpneMstpSrasWlnrDnon";
|
||||
};*/
|
||||
|
||||
class LauncherProneActions: LauncherKneelActions {
|
||||
TurnL = "AmovPpneMstpSrasWlnrDnon_turnl";
|
||||
TurnLRelaxed = "AmovPpneMstpSrasWlnrDnon_turnl";
|
||||
TurnR = "AmovPpneMstpSrasWlnrDnon_turnr";
|
||||
TurnRRelaxed = "AmovPpneMstpSrasWlnrDnon_turnr";
|
||||
};
|
||||
|
||||
// WEAPON RAISED - RUNNING
|
||||
class RifleStandActionsNoAdjust;
|
||||
class RifleStandActionsRunF: RifleStandActionsNoAdjust {
|
||||
getOver = "AovrPercMrunSrasWrflDf";
|
||||
};
|
||||
@ -18,6 +43,7 @@ class CfgMovesBasic {
|
||||
class RifleStandActionsRunFR: RifleStandActionsNoAdjust {
|
||||
getOver = "AovrPercMrunSrasWrflDf";
|
||||
};
|
||||
|
||||
// WEAPON RAISED - SPRINTING
|
||||
class RifleStandEvasiveActionsF: RifleStandActionsNoAdjust {
|
||||
getOver = "AovrPercMrunSrasWrflDf";
|
||||
@ -28,7 +54,9 @@ class CfgMovesBasic {
|
||||
class RifleStandEvasiveActionsFR: RifleStandActionsNoAdjust {
|
||||
getOver = "AovrPercMrunSrasWrflDf";
|
||||
};
|
||||
|
||||
// WEAPON LOWERED - RUNNING
|
||||
class RifleLowStandActionsNoAdjust;
|
||||
class RifleLowStandActionsRunF: RifleLowStandActionsNoAdjust {
|
||||
getOver = "AovrPercMrunSrasWrflDf";
|
||||
};
|
||||
|
@ -5,6 +5,7 @@ class CfgWeapons {
|
||||
class ACE_SpareBarrel: ACE_ItemCore {
|
||||
displayname = "$STR_ACE_Overheating_SpareBarrelName";
|
||||
descriptionshort = "$STR_ACE_Overheating_SpareBarrelDescription";
|
||||
//model = "";
|
||||
picture = QUOTE(PATHTOF(UI\spare_barrel_ca.paa));
|
||||
scope = 2;
|
||||
class ItemInfo: InventoryItem_Base_F {
|
||||
|
@ -208,7 +208,7 @@ class CfgWeapons {
|
||||
class srifle_DMR_02_sniper_F: srifle_DMR_02_F {
|
||||
displayName = "$STR_ACE_RealisticNames_srifle_DMR_02_sniper"; //MAR-10 .338 (Sand)";
|
||||
};
|
||||
|
||||
*/
|
||||
class DMR_03_base_F: Rifle_Long_Base_F {
|
||||
displayName = "$STR_ACE_RealisticNames_DMR_03"; //Mk-I EMR 7.62 mm";
|
||||
};
|
||||
@ -236,7 +236,7 @@ class CfgWeapons {
|
||||
class srifle_DMR_03_spotter_F: srifle_DMR_03_F {
|
||||
displayName = "$STR_ACE_RealisticNames_srifle_DMR_03_spotter"; //NATO DMR (provisional) spotter";
|
||||
};
|
||||
|
||||
/*
|
||||
class DMR_04_base_F: Rifle_Long_Base_F {
|
||||
displayName = "$STR_ACE_RealisticNames_DMR_04"; //ASP-1 Kir 12.7 mm";
|
||||
};
|
||||
@ -264,7 +264,7 @@ class CfgWeapons {
|
||||
class srifle_DMR_05_tan_f: srifle_DMR_05_blk_F {
|
||||
displayName = "$STR_ACE_RealisticNames_srifle_DMR_05_tan"; //Cyrus 9.3 mm (Tan)";
|
||||
};
|
||||
|
||||
*/
|
||||
class DMR_06_base_F: Rifle_Long_Base_F {
|
||||
displayName = "$STR_ACE_RealisticNames_DMR_06"; //Mk14 7.62 mm";
|
||||
};
|
||||
@ -278,6 +278,7 @@ class CfgWeapons {
|
||||
};
|
||||
|
||||
// marksmen mgs
|
||||
/*
|
||||
class MMG_01_base_F: Rifle_Long_Base_F {
|
||||
displayName = "$STR_ACE_RealisticNames_MMG_01"; //Navid 9.3 mm";
|
||||
};
|
||||
@ -289,7 +290,7 @@ class CfgWeapons {
|
||||
class MMG_01_tan_F: MMG_01_hex_F {
|
||||
displayName = "$STR_ACE_RealisticNames_MMG_01_tan"; //Navid 9.3 mm (Tan)";
|
||||
};
|
||||
|
||||
*/
|
||||
class MMG_02_base_F: Rifle_Long_Base_F {
|
||||
displayName = "$STR_ACE_RealisticNames_MMG_02"; //SPMG .338";
|
||||
};
|
||||
@ -304,7 +305,7 @@ class CfgWeapons {
|
||||
|
||||
class MMG_02_sand_F: MMG_02_camo_F {
|
||||
displayName = "$STR_ACE_RealisticNames_MMG_02_sand"; //SPMG .338 (Sand)";
|
||||
};*/
|
||||
};
|
||||
|
||||
// vehicle weapons
|
||||
|
||||
|
@ -1135,7 +1135,7 @@
|
||||
<English>Mini-Spike (AT)</English>
|
||||
<German>Mini-Spike (PALR)</German>
|
||||
<Czech>Mini-Spike (PT)</Czech>
|
||||
<Polish>Mini-Spike (AT)</Polish>
|
||||
<Polish>Mini-Spike (AA)</Polish>
|
||||
<French>Mini-Spike (AT)</French>
|
||||
<Hungarian>Mini-Spike (Tankelhárító)</Hungarian>
|
||||
<Spanish>Mini-Spike (AT)</Spanish>
|
||||
@ -1510,53 +1510,53 @@
|
||||
<Russian>TODO: MAR-10 .338 (песочный)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_DMR_03">
|
||||
<English>TODO: Mk-I EMR 7.62 mm</English>
|
||||
<Czech>TODO: Mk-I EMR 7.62 mm</Czech>
|
||||
<French>Mk-l EMR 7.62 mm</French>
|
||||
<Spanish>TODO: Mk-I EMR 7.62 mm</Spanish>
|
||||
<Russian>TODO: Mk-I EMR 7.62 мм</Russian>
|
||||
<English>SG 556 7.62 mm</English>
|
||||
<Czech>SG 556 7.62 mm</Czech>
|
||||
<French>SG 556 7.62 mm</French>
|
||||
<Spanish>SG 556 7.62 mm</Spanish>
|
||||
<Russian>SG 556 7.62 мм</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_srifle_DMR_03">
|
||||
<English>TODO: Mk-I EMR 7.62 mm (Black)</English>
|
||||
<Czech>TODO: Mk-I EMR 7.62 mm (Black)</Czech>
|
||||
<French>Mk-l EMR 7.62 mm (Noir)</French>
|
||||
<Spanish>TODO: Mk-I EMR 7.62 mm (Negro)</Spanish>
|
||||
<Russian>TODO: Mk-I EMR 7.62 мм (черный)</Russian>
|
||||
<English>SG 556 7.62 mm (Black)</English>
|
||||
<Czech>SG 556 7.62 mm (Black)</Czech>
|
||||
<French>SG 556 7.62 mm (Noir)</French>
|
||||
<Spanish>SG 556 7.62 mm (Negro)</Spanish>
|
||||
<Russian>SG 556 7.62 мм (черный)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_srifle_DMR_03_khaki">
|
||||
<English>TODO: Mk-I EMR 7.62 mm (Khaki)</English>
|
||||
<Czech>TODO: Mk-I EMR 7.62 mm (Khaki)</Czech>
|
||||
<French>Mk-l EMR 7.62 mm (Kaki)</French>
|
||||
<Spanish>TODO: Mk-I EMR 7.62 mm (Caqui)</Spanish>
|
||||
<Russian>TODO: Mk-I EMR 7.62 мм (хаки)</Russian>
|
||||
<English>SG 556 7.62 mm (Khaki)</English>
|
||||
<Czech>SG 556 7.62 mm (Khaki)</Czech>
|
||||
<French>SG 556 7.62 mm (Kaki)</French>
|
||||
<Spanish>SG 556 7.62 mm (Caqui)</Spanish>
|
||||
<Russian>SG 556 7.62 мм (хаки)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_srifle_DMR_03_tan">
|
||||
<English>TODO: Mk-I EMR 7.62 mm (Sand)</English>
|
||||
<Czech>TODO: Mk-I EMR 7.62 mm (Sand)</Czech>
|
||||
<French>Mk-l EMR 7.62 mm (Beige)</French>
|
||||
<Spanish>TODO: Mk-I EMR 7.62 mm (Arena)</Spanish>
|
||||
<Russian>TODO: Mk-I EMR 7.62 мм (песочный)</Russian>
|
||||
<English>SG 556 7.62 mm (Sand)</English>
|
||||
<Czech>SG 556 7.62 mm (Sand)</Czech>
|
||||
<French>SG 556 7.62 mm (Beige)</French>
|
||||
<Spanish>SG 556 7.62 mm (Arena)</Spanish>
|
||||
<Russian>SG 556 7.62 мм (песочный)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_srifle_DMR_03_multicam">
|
||||
<English>TODO: Mk-I EMR 7.62 mm (Camo)</English>
|
||||
<Czech>TODO: Mk-I EMR 7.62 mm (Camo)</Czech>
|
||||
<French>Mk-l EMR 7.62 mm (Camo)</French>
|
||||
<Spanish>TODO: Mk-I EMR 7.62 mm (Camuflaje)</Spanish>
|
||||
<Russian>TODO: Mk-I EMR 7.62 мм (камо)</Russian>
|
||||
<English>SG 556 7.62 mm (Camo)</English>
|
||||
<Czech>SG 556 7.62 mm (Camo)</Czech>
|
||||
<French>SG 556 7.62 mm (Camo)</French>
|
||||
<Spanish>SG 556 7.62 mm (Camuflaje)</Spanish>
|
||||
<Russian>SG 556 7.62 мм (камо)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_srifle_DMR_03_woodland">
|
||||
<English>TODO: Mk-I EMR 7.62 mm (Woodland)</English>
|
||||
<Czech>TODO: Mk-I EMR 7.62 mm (Woodland)</Czech>
|
||||
<French>Mk-l EMR 7.62 mm (Woodland)</French>
|
||||
<Spanish>TODO: Mk-I EMR 7.62 mm (Bosque)</Spanish>
|
||||
<Russian>TODO: Mk-I EMR 7.62 мм (лесной)</Russian>
|
||||
<English>SG 556 7.62 mm (Woodland)</English>
|
||||
<Czech>SG 556 7.62 mm (Woodland)</Czech>
|
||||
<French>SG 556 7.62 mm (Woodland)</French>
|
||||
<Spanish>SG 556 7.62 mm (Bosque)</Spanish>
|
||||
<Russian>SG 556 7.62 мм (лесной)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_srifle_DMR_03_spotter">
|
||||
<English>TODO: NATO DMR (provisional) spotter</English>
|
||||
<Czech>TODO: NATO DMR (provisional) spotter</Czech>
|
||||
<French>NATO DMR (provisoire) observateur</French>
|
||||
<Spanish>TODO: NATO DMR (provisional) observador</Spanish>
|
||||
<Russian>TODO: NATO DMR (provisional) корректировщик</Russian>
|
||||
<English>SG 556 7.62 mm (provisional) spotter</English>
|
||||
<Czech>SG 556 7.62 mm (provisional) spotter</Czech>
|
||||
<French>SG 556 7.62 mm (provisoire) Observateur</French>
|
||||
<Spanish>SG 556 7.62 mm (provisional) observador</Spanish>
|
||||
<Russian>SG 556 7.62 мм (provisional) корректировщик</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_DMR_04">
|
||||
<English>TODO: ASP-1 Kir 12.7 mm</English>
|
||||
@ -1608,25 +1608,25 @@
|
||||
<Russian>TODO: Cyrus 9.3 мм (бронза)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_DMR_06">
|
||||
<English>TODO: Mk14 7.62 mm</English>
|
||||
<Czech>TODO: Mk14 7.62 mm</Czech>
|
||||
<French>Mk 14 7.62 mm</French>
|
||||
<Spanish>TODO: Mk14 7.62 mm</Spanish>
|
||||
<Russian>TODO: Mk14 7.62 мм</Russian>
|
||||
<English>M14 7.62 mm</English>
|
||||
<Czech>M14 7.62 mm</Czech>
|
||||
<French>M14 7.62 mm</French>
|
||||
<Spanish>M14 7.62 mm</Spanish>
|
||||
<Russian>M14 7.62 мм</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_srifle_DMR_06_camo">
|
||||
<English>TODO: Mk14 7.62 mm (Camo)</English>
|
||||
<Czech>TODO: Mk14 7.62 mm (Camo)</Czech>
|
||||
<French>Mk 14 7.62 mm (Camo)</French>
|
||||
<Spanish>TODO: Mk14 7.62 mm (Camuflaje)</Spanish>
|
||||
<Russian>TODO: Mk14 7.62 мм (камо)</Russian>
|
||||
<English>M14 7.62 mm (Camo)</English>
|
||||
<Czech>M14 7.62 mm (Camo)</Czech>
|
||||
<French>M14 7.62 mm (Camo)</French>
|
||||
<Spanish>M14 7.62 mm (Camuflaje)</Spanish>
|
||||
<Russian>M14 7.62 мм (Камо)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_srifle_DMR_06_olive">
|
||||
<English>TODO: Mk14 7.62 mm (Olive)</English>
|
||||
<Czech>TODO: Mk14 7.62 mm (Olive)</Czech>
|
||||
<French>Mk 14 7.62 mm (Olive)</French>
|
||||
<Spanish>TODO: Mk14 7.62 mm (Oliva)</Spanish>
|
||||
<Russian>TODO: Mk14 7.62 мм (олива)</Russian>
|
||||
<English>M14 7.62 mm (Olive)</English>
|
||||
<Czech>M14 7.62 mm (Olive)</Czech>
|
||||
<French>M14 7.62 mm (Olive)</French>
|
||||
<Spanish>M14 7.62 mm (Oliva)</Spanish>
|
||||
<Russian>M14 7.62 мм (Олива)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_MMG_01">
|
||||
<English>TODO: Navid 9.3 mm</English>
|
||||
@ -1650,32 +1650,32 @@
|
||||
<Russian>TODO: Navid 9.3 мм (бронза)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_MMG_02">
|
||||
<English>TODO: SPMG .338</English>
|
||||
<Czech>TODO: SPMG .338</Czech>
|
||||
<French>SPMG .338</French>
|
||||
<Spanish>TODO: SPMG .338</Spanish>
|
||||
<Russian>TODO: SPMG .338</Russian>
|
||||
<English>LWMMG .338</English>
|
||||
<Czech>LWMMG .338</Czech>
|
||||
<French>LWMMG .338</French>
|
||||
<Spanish>LWMMG .338</Spanish>
|
||||
<Russian>LWMMG .338</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_MMG_02_camo">
|
||||
<English>TODO: SPMG .338 (MTP)</English>
|
||||
<Czech>TODO: SPMG .338 (MTP)</Czech>
|
||||
<French>SPMG .338 (MTP)</French>
|
||||
<Spanish>TODO: SPMG .338 (MTP)</Spanish>
|
||||
<Russian>TODO: SPMG .338 (MTP)</Russian>
|
||||
<English>LWMMG .338 (MTP)</English>
|
||||
<Czech>LWMMG .338 (MTP)</Czech>
|
||||
<French>LWMMG .338 (MTP)</French>
|
||||
<Spanish>LWMMG .338 (MTP)</Spanish>
|
||||
<Russian>LWMMG .338 (MTP)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_MMG_02_black">
|
||||
<English>TODO: SPMG .338 (Black)</English>
|
||||
<Czech>TODO: SPMG .338 (Black)</Czech>
|
||||
<French>SPMG .338 (Noir)</French>
|
||||
<Spanish>TODO: SPMG .338 (Negro)</Spanish>
|
||||
<Russian>TODO: SPMG .338 (черный)</Russian>
|
||||
<English>LWMMG .338 (Black)</English>
|
||||
<Czech>LWMMG .338 (Black)</Czech>
|
||||
<French>LWMMG .338 (Noir)</French>
|
||||
<Spanish>LWMMG .338 (Negro)</Spanish>
|
||||
<Russian>LWMMG .338 (Черный)</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_RealisticNames_MMG_02_sand">
|
||||
<English>TODO: SPMG .338 (Sand)</English>
|
||||
<Czech>TODO: SPMG .338 (Sand)</Czech>
|
||||
<English>LWMMG .338 (Sand)</English>
|
||||
<Czech>LWMMG .338 (Sand)</Czech>
|
||||
<French>SPMG .338 (Beige)</French>
|
||||
<Spanish>TODO: SPMG .338 (Arena)</Spanish>
|
||||
<Russian>TODO: SPMG .338 (песочный)</Russian>
|
||||
<Spanish>LWMMG .338 (Arena)</Spanish>
|
||||
<Russian>LWMMG .338 (Песочный)</Russian>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
||||
</Project>
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
class CfgActions {
|
||||
class LoadMagazine;
|
||||
class LoadEmptyMagazine : LoadMagazine {
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
class Extended_PreInit_EventHandlers {
|
||||
class ADDON {
|
||||
init = QUOTE(call COMPILE_FILE(XEH_preInit));
|
||||
|
@ -3,13 +3,13 @@ class CfgVehicles {
|
||||
class CAManBase: Man {
|
||||
class ACE_Actions {
|
||||
class ACE_Weapon {
|
||||
class ACE_LinkBelt {
|
||||
class GVAR(LinkBelt) {
|
||||
displayName = "$STR_ACE_Reload_LinkBelt";
|
||||
distance = 2.0;
|
||||
condition = QUOTE([ARR_2(_player, _target)] call FUNC(canLinkBelt));
|
||||
statement = QUOTE([ARR_2(_player, _target)] call FUNC(startLinkingBelt));
|
||||
};
|
||||
class ACE_CheckAmmo {
|
||||
class GVAR(CheckAmmo) {
|
||||
displayName = "$STR_ACE_Reload_checkAmmo";
|
||||
distance = 2.0;
|
||||
condition = QUOTE([ARR_2(_player, _target)] call FUNC(canCheckAmmo));
|
||||
@ -23,7 +23,7 @@ class CfgVehicles {
|
||||
class StaticWeapon: LandVehicle {
|
||||
class ACE_Actions {
|
||||
class ACE_MainActions {
|
||||
class ACE_CheckAmmo {
|
||||
class GVAR(CheckAmmo) {
|
||||
displayName = "$STR_ACE_Reload_checkAmmo";
|
||||
distance = 2.0;
|
||||
condition = QUOTE([ARR_2(_player, _target)] call FUNC(canCheckAmmo));
|
||||
|
@ -7,10 +7,9 @@ if !(hasInterface) exitWith {};
|
||||
["ACE3", QGVAR(checkAmmo), localize "STR_ACE_Reload_checkAmmo",
|
||||
{
|
||||
// Conditions: canInteract
|
||||
if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {false};
|
||||
if !([ACE_player, (vehicle ACE_player), ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false};
|
||||
// Conditions: specific
|
||||
if !([ACE_player] call EFUNC(common,canUseWeapon) ||
|
||||
{(vehicle ACE_player) isKindOf 'StaticWeapon'}) exitWith {false};
|
||||
if !([ACE_player] call EFUNC(common,canUseWeapon) || {(vehicle ACE_player) isKindOf "StaticWeapon"}) exitWith {false};
|
||||
|
||||
// Statement
|
||||
[ACE_player] call FUNC(checkAmmo);
|
||||
|
@ -7,7 +7,12 @@
|
||||
* 1: Target <OBJECT>
|
||||
*
|
||||
* Return value:
|
||||
* Can link belt<BOOL>
|
||||
* Can link belt<BOOL>
|
||||
*
|
||||
* Example:
|
||||
* [player, bob] call ace_reload_fnc_canCheckAmmo
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
|
@ -33,8 +33,6 @@ if (count _this > 1) then {
|
||||
|
||||
if (_unit == _target) then {
|
||||
_unit playActionNow "Gear";
|
||||
} else {
|
||||
_unit playActionNow "PutDown";
|
||||
};
|
||||
|
||||
[FUNC(displayAmmo), [_target], 1, 0.1] call EFUNC(common,waitAndExecute);
|
||||
|
@ -14,7 +14,7 @@
|
||||
|
||||
EXPLODE_1_PVT(_this,_target);
|
||||
|
||||
private ["_weapon","_muzzle","_magazine","_showNumber","_ammo","_maxRounds","_count","_text","_color","_picture", "_a", "_string"];
|
||||
private ["_weapon","_muzzle","_magazine","_showNumber","_ammo","_maxRounds","_count","_text","_color","_picture","_ammoBarsStructuredText", "_a", "_loadedName", "_string"];
|
||||
|
||||
_weapon = currentWeapon _target;
|
||||
_muzzle = currentMuzzle _target;
|
||||
@ -22,23 +22,23 @@ _magazine = currentMagazine _target;
|
||||
|
||||
// currentWeapon returns "" for static weapons before they are shot once
|
||||
if (_target isKindOf "StaticWeapon") then {
|
||||
if (_weapon == "") then {
|
||||
if (count (weapons _target) == 1) then {
|
||||
_weapon = (weapons _target) select 0;
|
||||
_muzzle = _weapon;
|
||||
};
|
||||
};
|
||||
|
||||
if (_magazine == "") then {
|
||||
// Try to get magazine using magazinesAmmoFull
|
||||
private ["_magazines"];
|
||||
_magazines = magazinesAmmoFull _target;
|
||||
{
|
||||
if (_x select 2) exitWith {
|
||||
_magazine = _x select 0;
|
||||
if (_weapon == "") then {
|
||||
if (count (weapons _target) == 1) then {
|
||||
_weapon = (weapons _target) select 0;
|
||||
_muzzle = _weapon;
|
||||
};
|
||||
} forEach _magazines;
|
||||
};
|
||||
};
|
||||
|
||||
if (_magazine == "") then {
|
||||
// Try to get magazine using magazinesAmmoFull
|
||||
private ["_magazines"];
|
||||
_magazines = magazinesAmmoFull _target;
|
||||
{
|
||||
if (_x select 2) exitWith {
|
||||
_magazine = _x select 0;
|
||||
};
|
||||
} forEach _magazines;
|
||||
};
|
||||
};
|
||||
|
||||
if (_magazine == "") exitWith {};
|
||||
@ -52,55 +52,56 @@ _count = 0;
|
||||
|
||||
// not grenade launcher
|
||||
if (_muzzle == _weapon) then {
|
||||
_maxRounds = getNumber (configFile >> "CfgMagazines" >> _magazine >> "count") max 1;
|
||||
_maxRounds = getNumber (configFile >> "CfgMagazines" >> _magazine >> "count") max 1;
|
||||
|
||||
_ammo = _target ammo _weapon;
|
||||
if (_maxRounds >= COUNT_BARS) then {
|
||||
_count = round (COUNT_BARS * _ammo / _maxRounds);
|
||||
_ammo = _target ammo _weapon;
|
||||
if (_maxRounds >= COUNT_BARS) then {
|
||||
_count = round (COUNT_BARS * _ammo / _maxRounds);
|
||||
|
||||
if (_ammo > 0) then {_count = _count max 1};
|
||||
if (_ammo < _maxRounds) then {_count = _count min (COUNT_BARS - 1)};
|
||||
} else {
|
||||
_count = _ammo;
|
||||
};
|
||||
if (_ammo > 0) then {_count = _count max 1};
|
||||
if (_ammo < _maxRounds) then {_count = _count min (COUNT_BARS - 1)};
|
||||
} else {
|
||||
_count = _ammo;
|
||||
};
|
||||
|
||||
// grenade launcher
|
||||
// grenade launcher
|
||||
} else {
|
||||
_showNumber = true;
|
||||
_showNumber = true;
|
||||
|
||||
_count = if (_magazine != "") then {
|
||||
{_x == _magazine} count (magazines _target + [_magazine])
|
||||
} else {
|
||||
{_x in getArray (configFile >> "CfgWeapons" >> _weapon >> _muzzle >> "Magazines")} count magazines _target
|
||||
};
|
||||
_count = if (_magazine != "") then {
|
||||
{_x == _magazine} count (magazines _target + [_magazine])
|
||||
} else {
|
||||
{_x in getArray (configFile >> "CfgWeapons" >> _weapon >> _muzzle >> "Magazines")} count magazines _target
|
||||
};
|
||||
};
|
||||
|
||||
_text = if (_showNumber) then {
|
||||
parseText format ["<t align='center' >%1x</t>", _count]
|
||||
_ammoBarsStructuredText = if (_showNumber) then {
|
||||
parseText format ["<t align='center' >%1x</t>", _count]
|
||||
} else {
|
||||
_color = [
|
||||
2 * (1 - _ammo / _maxRounds) min 1,
|
||||
2 * _ammo / _maxRounds min 1,
|
||||
00
|
||||
];
|
||||
_color = [((2 * (1 - _ammo / _maxRounds)) min 1), ((2 * _ammo / _maxRounds) min 1), 0];
|
||||
|
||||
_string = "";
|
||||
for "_a" from 1 to _count do {
|
||||
_string = _string + "|";
|
||||
};
|
||||
_text = [_string, _color] call EFUNC(common,stringToColoredText);
|
||||
_string = "";
|
||||
for "_a" from 1 to _count do {
|
||||
_string = _string + "|";
|
||||
};
|
||||
_text = [_string, _color] call EFUNC(common,stringToColoredText);
|
||||
|
||||
_string = "";
|
||||
for "_a" from (_count + 1) to (_maxRounds min COUNT_BARS) do {
|
||||
_string = _string + "|";
|
||||
};
|
||||
_string = "";
|
||||
for "_a" from (_count + 1) to (_maxRounds min COUNT_BARS) do {
|
||||
_string = _string + "|";
|
||||
};
|
||||
|
||||
composeText [
|
||||
_text,
|
||||
[_string, [0.5, 0.5, 0.5]] call EFUNC(common,stringToColoredText)
|
||||
]
|
||||
composeText [_text, [_string, [0.5, 0.5, 0.5]] call EFUNC(common,stringToColoredText)];
|
||||
};
|
||||
|
||||
_picture = getText (configFile >> "CfgMagazines" >> _magazine >> "picture");
|
||||
|
||||
[_text, _picture] call EFUNC(common,displayTextPicture);
|
||||
if (_target isKindOf "StaticWeapon") then {
|
||||
//Vehicle mags (usualy) don't have pictures, so just show the text above ammo count
|
||||
_loadedName = getText (configFile >> "CfgMagazines" >> _magazine >> "displaynameshort");
|
||||
_loadedName = parseText format ["<t align='center' >%1</t>", _loadedName];
|
||||
_text = composeText [_loadedName, linebreak, _ammoBarsStructuredText];
|
||||
[_text] call EFUNC(common,displayTextStructured);
|
||||
} else {
|
||||
_picture = getText (configFile >> "CfgMagazines" >> _magazine >> "picture");
|
||||
[_ammoBarsStructuredText, _picture] call EFUNC(common,displayTextPicture);
|
||||
};
|
||||
|
@ -3,6 +3,7 @@ class CfgWeapons {
|
||||
class ACE_ItemCore;
|
||||
|
||||
class ACE_key_master: ACE_ItemCore {
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
displayName = "Vehicle Key: Master";
|
||||
descriptionShort = "$STR_ACE_Vehicle_Item_Master_Description";
|
||||
model = "\A3\weapons_F\ammo\mag_univ.p3d";
|
||||
|
@ -25,6 +25,34 @@ file(GLOB ACE_COMMON_SOURCES common/*.h common/*.hpp common/*.c common/*.cpp)
|
||||
add_library(ace_common STATIC ${ACE_COMMON_SOURCES})
|
||||
include_directories(AFTER "common")
|
||||
|
||||
string(TIMESTAMP ACE_BUILDSTAMP "%Y-%m-%dT%H:%M:%SZ")
|
||||
set(ACE_VERSION_MAJOR 3)
|
||||
set(ACE_VERSION_MINOR 0)
|
||||
set(ACE_VERSION_REVISION 1)
|
||||
EXECUTE_PROCESS(COMMAND git rev-parse --verify HEAD
|
||||
OUTPUT_VARIABLE T_ACE_VERSION_BUILD
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||
)
|
||||
string(SUBSTRING ${T_ACE_VERSION_BUILD} 0 7 ACE_VERSION_BUILD )
|
||||
|
||||
message("Building for: " ${ACE_VERSION_MAJOR}.${ACE_VERSION_MINOR}.${ACE_VERSION_REVISION}-${ACE_VERSION_BUILD})
|
||||
|
||||
configure_file(
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/common/ace_version.hpp.in"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/common/ace_version.hpp"
|
||||
@ONLY)
|
||||
|
||||
if(MSVC)
|
||||
configure_file(
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/common/ace_version_win32.rc.in"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/common/ace_version_win32.rc"
|
||||
@ONLY)
|
||||
set(GLOBAL_RC ${CMAKE_CURRENT_BINARY_DIR}/common/ace_version_win32.rc)
|
||||
endif()
|
||||
|
||||
include_directories(AFTER ${CMAKE_CURRENT_BINARY_DIR}/common)
|
||||
set(GLOBAL_SOURCES ${GLOBAL_RC})
|
||||
|
||||
# Add extensions to build here
|
||||
add_subdirectory(fcs)
|
||||
add_subdirectory(breakLine)
|
||||
|
@ -19,8 +19,6 @@
|
||||
#define STD_AIR_DENSITY_ICAO 1.22498
|
||||
#define STD_AIR_DENSITY_ASM 1.20885
|
||||
|
||||
static char version[] = "1.0";
|
||||
|
||||
struct Bullet {
|
||||
double airFriction;
|
||||
double caliber;
|
||||
@ -242,7 +240,7 @@ void __stdcall RVExtension(char *output, int outputSize, const char *function)
|
||||
{
|
||||
if (!strcmp(function, "version"))
|
||||
{
|
||||
int n = sprintf_s(output, outputSize, "%s", version);
|
||||
int n = sprintf_s(output, outputSize, "%s", ACE_FULL_VERSION_STR);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
set(ACE_EXTENSION_NAME "ace_advanced_ballistics")
|
||||
|
||||
file(GLOB SOURCES *.h *.hpp *.c *.cpp)
|
||||
add_library( ${ACE_EXTENSION_NAME} SHARED ${SOURCES})
|
||||
add_library( ${ACE_EXTENSION_NAME} SHARED ${GLOBAL_SOURCES} ${SOURCES})
|
||||
add_dependencies(${ACE_EXTENSION_NAME} ace_common)
|
||||
SET_TARGET_PROPERTIES(${ACE_EXTENSION_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
set(ACE_EXTENSION_NAME "ace_breakLine")
|
||||
|
||||
file(GLOB SOURCES *.h *.hpp *.c *.cpp)
|
||||
add_library( ${ACE_EXTENSION_NAME} SHARED ${SOURCES})
|
||||
add_library( ${ACE_EXTENSION_NAME} SHARED ${GLOBAL_SOURCES} ${SOURCES})
|
||||
add_dependencies(${ACE_EXTENSION_NAME} ace_common)
|
||||
SET_TARGET_PROPERTIES(${ACE_EXTENSION_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
|
@ -19,8 +19,6 @@
|
||||
|
||||
#define MAXCHARACTERS 14
|
||||
|
||||
static char VERSION[] = "1.0";
|
||||
|
||||
extern "C" {
|
||||
__declspec (dllexport) void __stdcall RVExtension(char *output, int outputSize, const char *function);
|
||||
};
|
||||
@ -39,8 +37,8 @@ std::vector<std::string> splitString(const std::string & input) {
|
||||
|
||||
std::string addLineBreaks(const std::vector<std::string> &words) {
|
||||
std::stringstream sstream;
|
||||
int numChar = 0;
|
||||
int i = 0;
|
||||
size_t numChar = 0;
|
||||
size_t i = 0;
|
||||
|
||||
while (i < words.size()) {
|
||||
if (numChar == 0) {
|
||||
@ -68,7 +66,7 @@ std::string addLineBreaks(const std::vector<std::string> &words) {
|
||||
|
||||
void __stdcall RVExtension(char *output, int outputSize, const char *function) {
|
||||
if (!strcmp(function, "version")) {
|
||||
strncpy(output, VERSION, outputSize);
|
||||
strncpy(output, ACE_FULL_VERSION_STR, outputSize);
|
||||
} else {
|
||||
strncpy(output, addLineBreaks(splitString(function)).c_str(), outputSize);
|
||||
output[outputSize - 1] = '\0';
|
||||
|
@ -1,4 +1,4 @@
|
||||
#pragma once
|
||||
|
||||
#include "targetver.h"
|
||||
|
||||
#include "ace_version.hpp"
|
||||
|
4
extensions/common/ace_version.hpp.in
Normal file
4
extensions/common/ace_version.hpp.in
Normal file
@ -0,0 +1,4 @@
|
||||
#pragma once
|
||||
|
||||
#define ACE_VERSION_STR "@ACE_VERSION_MAJOR@.@ACE_VERSION_MINOR@.@ACE_VERSION_REVISION@"
|
||||
#define ACE_FULL_VERSION_STR "@ACE_VERSION_MAJOR@.@ACE_VERSION_MINOR@.@ACE_VERSION_REVISION@-@ACE_VERSION_BUILD@"
|
47
extensions/common/ace_version_win32.rc.in
Normal file
47
extensions/common/ace_version_win32.rc.in
Normal file
@ -0,0 +1,47 @@
|
||||
#ifdef _WIN32
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
#ifndef DEBUG
|
||||
#define VER_DEBUG 0
|
||||
#else
|
||||
#define VER_DEBUG VS_FF_DEBUG
|
||||
#endif
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION @ACE_VERSION_MAJOR@, @ACE_VERSION_MINOR@, @ACE_VERSION_REVISION@
|
||||
PRODUCTVERSION @ACE_VERSION_MAJOR@, @ACE_VERSION_MINOR@, @ACE_VERSION_REVISION@
|
||||
FILEFLAGSMASK VS_FFI_FILEFLAGSMASK
|
||||
FILEFLAGS (VS_FF_PRIVATEBUILD|VS_FF_PRERELEASE|VER_DEBUG)
|
||||
FILEOS VOS__WINDOWS32
|
||||
FILETYPE VFT_DLL
|
||||
FILESUBTYPE VFT2_UNKNOWN
|
||||
BEGIN
|
||||
BLOCK "StringFileInfo"
|
||||
BEGIN
|
||||
BLOCK "040904E4"
|
||||
BEGIN
|
||||
VALUE "CompanyName", "ACE3 Team"
|
||||
VALUE "FileDescription", "@ACE_VERSION_MAJOR@.@ACE_VERSION_MINOR@.@ACE_VERSION_REVISION@-@ACE_VERSION_BUILD@"
|
||||
VALUE "FileVersion", "@ACE_VERSION_MAJOR@.@ACE_VERSION_MINOR@.@ACE_VERSION_REVISION@-@ACE_VERSION_BUILD@"
|
||||
VALUE "ProductName", "ACE3"
|
||||
VALUE "ProductVersion", "@ACE_VERSION_MAJOR@.@ACE_VERSION_MINOR@.@ACE_VERSION_REVISION@-@ACE_VERSION_BUILD@"
|
||||
VALUE "Build Date", "@ACE_BUILDSTAMP@"
|
||||
END
|
||||
END
|
||||
|
||||
BLOCK "VarFileInfo"
|
||||
BEGIN
|
||||
/* The following line should only be modified for localized versions. */
|
||||
/* It consists of any number of WORD,WORD pairs, with each pair */
|
||||
/* describing a language,codepage combination supported by the file. */
|
||||
/* */
|
||||
/* For example, a file might have values "0x409,1252" indicating that it */
|
||||
/* supports English language (0x409) in the Windows ANSI codepage (1252). */
|
||||
|
||||
VALUE "Translation", 0x409, 1252
|
||||
|
||||
END
|
||||
END
|
||||
|
||||
#endif
|
@ -1,7 +1,7 @@
|
||||
set(ACE_EXTENSION_NAME "ace_fcs")
|
||||
|
||||
file(GLOB SOURCES *.h *.hpp *.c *.cpp)
|
||||
add_library( ${ACE_EXTENSION_NAME} SHARED ${SOURCES})
|
||||
add_library( ${ACE_EXTENSION_NAME} SHARED ${GLOBAL_SOURCES} ${SOURCES})
|
||||
add_dependencies(${ACE_EXTENSION_NAME} ace_common)
|
||||
SET_TARGET_PROPERTIES(${ACE_EXTENSION_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
|
@ -25,8 +25,6 @@
|
||||
#define PRECISION 0.1
|
||||
#define RADIANS(X) (X / (180 / M_PI))
|
||||
|
||||
static char version[] = "1.0";
|
||||
|
||||
extern "C" {
|
||||
__declspec (dllexport) void __stdcall RVExtension(char *output, int outputSize, const char *function);
|
||||
};
|
||||
@ -104,7 +102,7 @@ double getSolution(double initSpeed, double airFriction, double angleTarget, dou
|
||||
|
||||
void __stdcall RVExtension(char *output, int outputSize, const char *function) {
|
||||
if (!strcmp(function, "version")) {
|
||||
strncpy(output, version, outputSize);
|
||||
strncpy(output, ACE_FULL_VERSION_STR, outputSize);
|
||||
} else {
|
||||
std::vector<std::string> argStrings = splitString(function);
|
||||
double initSpeed = std::stod(argStrings[0]);
|
||||
|
Loading…
Reference in New Issue
Block a user