Skip to content
Open
Show file tree
Hide file tree
Changes from 14 commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
252140b
Add veterancy threshold check for TechnoClass objects
Flactine Dec 17, 2025
8a983da
Add veterancy threshold checks for weapons and warheads
Flactine Dec 17, 2025
78305e1
Add debug logs and use float suffixes for veterancy values
Flactine Dec 17, 2025
dd1c9b8
Fix incorrect INI keys for veterancy percent loading
Flactine Dec 17, 2025
63dd822
Add veterancy threshold checks to targeting logic
Flactine Dec 17, 2025
8e7926a
Document veterancy-based targeting and warhead logic
Flactine Dec 17, 2025
0e57ed6
Update Whats-New.md
Flactine Dec 17, 2025
583a4da
Merge branch 'develop' into CanTarget-MaxLevel
Flactine Dec 17, 2025
28cf3b2
Use dynamic veterancy cap for target filtering
Flactine Dec 17, 2025
4a9d466
Cast VeteranCap to float in WarheadType and WeaponType
Flactine Dec 17, 2025
db04976
Switch veterancy fields to Nullable<float> in WarheadType and WeaponType
Flactine Dec 17, 2025
986d768
Refactor veterancy threshold handling for warheads and weapons
Flactine Dec 17, 2025
acd4885
Fix veterancy cap comparison logic in INI loading
Flactine Dec 17, 2025
1a4e160
Docs
Flactine Dec 18, 2025
ddd6d06
Refactor veterancy threshold types to double
Flactine Dec 18, 2025
084f720
Fix logic and type for veterancy and health checks
Flactine Dec 18, 2025
9eb972d
Clarify data types for Veterancy fields in docs
Flactine Dec 18, 2025
f814cad
Clarify veterancy parameter documentation
Flactine Dec 18, 2025
176f860
Fix alignment and spacing in logic documentation
Flactine Dec 18, 2025
aaa1f96
Update src/Ext/Techno/Body.cpp
Flactine Dec 18, 2025
0d47524
Update CREDITS.md
Flactine Dec 18, 2025
a050f51
Update Whats-New.md
Flactine Dec 18, 2025
3731407
Adjust veterancy threshold logic for warheads and weapons
Flactine Dec 18, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion CREDITS.md
Original file line number Diff line number Diff line change
Expand Up @@ -656,7 +656,9 @@ This page lists all the individual contributions to the project by their author.
- **solar-III (凤九歌)**
- Target scanning delay customization (documentation)
- Skip target scanning function calling for unarmed technos (documentation)
- **Flactine** - add target filtering options to attacheffect system
- **Flactine**
- add target filtering options to attacheffect system
- add veterancy-based target filtering for weapons and warheads
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Capitalization please.

- **tyuah8**:
- Drive/Jumpjet/Ship/Teleport locomotor did not power on when it is un-piggybacked bugfix
- Destroyed unit leaves sensors bugfix
Expand Down
8 changes: 8 additions & 0 deletions docs/Fixed-or-Improved-Logics.md
Original file line number Diff line number Diff line change
Expand Up @@ -2312,6 +2312,12 @@ Conventional.IgnoreUnits=false ; boolean
### Customizable Warhead trigger conditions

- `AffectsBelowPercent` and `AffectsAbovePercent` can be used to set the health percentage thresholds that target needs to be below/equal and/or above of for the Warhead to detonate. If target has zero health left this check is bypassed.
- `AffectsAboveVeterancy` and `AffectsBelowVeterancy` can be used to set the veterancy thresholds that target needs to be below/equal and/or above of for the Warhead to detonate.
- Veterancy values are interpreted as follows:
- `0.0` = Rookie
- `1.0` = Veteran
- `2.0` = Elite
- TechnoTypes with `Trainable=no` are always treated as having a veterancy level of `0.0` (Rookie) for the purpose of this check.
- If set to `false`, `AffectsNeutral` makes the warhead can't damage or affect target that belongs to neutral house.
- If set to `false`, `EffectsRequireVerses` makes the Phobos-introduced warhead effects trigger even if it can't damage the target because of it's current ArmorType (e.g. 0% in `Verses`).

Expand All @@ -2320,6 +2326,8 @@ In `rulesmd.ini`:
[SOMEWARHEAD] ; WarheadType
AffectsBelowPercent=1.0 ; floating point value, percents or absolute
AffectsAbovePercent=0.0 ; floating point value, percents or absolute
AffectsBelowVeterancy=2.0 ; floating point value, percents or absolute, default to [General] -> VeteranCap
AffectsAboveVeterancy=0.0 ; floating point value, percents or absolute
AffectsNeutral=true ; boolean
EffectsRequireVerses=false ; boolean
```
Expand Down
8 changes: 8 additions & 0 deletions docs/New-or-Enhanced-Logics.md
Original file line number Diff line number Diff line change
Expand Up @@ -2848,6 +2848,12 @@ This function is only used as an additional scattering visual display, which is

- You can now specify which targets or houses a weapon can fire at. This also affects weapon selection, other than certain special cases where the selection is fixed.
- `CanTarget.MaxHealth` and `CanTarget.MinHealth` set health percentage thresholds for allowed targets (TechnoTypes only) that the target's health must be above and/or below/equal to, respectively. If target has zero health left this check is bypassed.
- `CanTarget.MinVeterancy` and `CanTarget.MaxVeterancy` define the allowed veterancy range for targets. The target's veterancy must be greater than or equal to `MinVeterancy` and less than or equal to `MaxVeterancy` in order to be considered a valid target.
- Veterancy values are interpreted as follows:
- `0.0` = Rookie
- `1.0` = Veteran
- `2.0` = Elite
- TechnoTypes with `Trainable=no` are always treated as having a veterancy level of `0.0` (Rookie) for the purpose of this check.

In `rulesmd.ini`:
```ini
Expand All @@ -2856,6 +2862,8 @@ CanTarget=all ; List of Affected Target Enumeration (none|land|water|
CanTargetHouses=all ; List of Affected House Enumeration (none|owner/self|allies/ally|team|enemies/enemy|all)
CanTarget.MaxHealth=1.0 ; floating point value, percents or absolute
CanTarget.MinHealth=0.0 ; floating point value, percents or absolute
CanTarget.MaxVeterancy=2.0 ; floating point value, percents or absolute, default to [General] -> VeteranCap
CanTarget.MinVeterancy=0.0 ; floating point value, percents or absolute
```

```{note}
Expand Down
2 changes: 2 additions & 0 deletions docs/Whats-New.md
Original file line number Diff line number Diff line change
Expand Up @@ -465,6 +465,8 @@ New:
- [Customize if cloning need power](Fixed-or-Improved-Logics.md#customize-if-cloning-need-power) (by NetsuNegi)
- [Added Target Filtering Options to AttachEffect System](New-or-Enhanced-Logics.md#attached-effects) (by Flactine)
- [Customize type selection for IFV](Fixed-or-Improved-Logics.md#customize-type-selection-for-ifv) (by NetsuNegi)
- [Weapon target filtering by target veterancy](New-or-Enhanced-Logics.md#weapon-targeting-filter) (by Flactine)
- [Warhead effect filtering by target veterancy](Fixed-or-Improved-Logics.md#customizable-warhead-trigger-conditions) (by Flactine)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these 2 lines should be put at the end of this section

- [CellSpread in cylinder shape](New-or-Enhanced-Logics.md#cellspread-enhancement) (by TaranDahl)
- [CellSpread damage check if victim is in air or on floor](New-or-Enhanced-Logics.md#cellspread-enhancement) (by TaranDahl)
- OpenTopped range bonus and damage multiplier customization for passengers (by Ollerus)
Expand Down
7 changes: 4 additions & 3 deletions src/Ext/Bullet/Hooks.DetonateLogics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ DEFINE_HOOK(0x4690D4, BulletClass_Logics_NewChecks, 0x6)
if (auto const pTarget = abstract_cast<TechnoClass*>(pBullet->Target))
{
// Check if the WH should affect the techno target or skip it
if (!pExt->IsHealthInThreshold(pTarget) || (!pExt->AffectsNeutral && pTarget->Owner->IsNeutral()))
if (!pExt->IsHealthInThreshold(pTarget) || !pExt->IsVeterancyInThreshold(pTarget) || (!pExt->AffectsNeutral && pTarget->Owner->IsNeutral()))
return GoToExtras;
}

Expand Down Expand Up @@ -380,7 +380,7 @@ DEFINE_HOOK(0x469AA4, BulletClass_Logics_Extras, 0x5)
auto const pWHExt = WarheadTypeExt::ExtMap.Find(pWH);
auto const pTarget = abstract_cast<TechnoClass*>(pThis->Target);

if (pTarget && !pWHExt->IsHealthInThreshold(pTarget))
if (pTarget && !pWHExt->IsHealthInThreshold(pTarget) && !pWHExt->IsVeterancyInThreshold(pTarget))
continue;

int damage = defaultDamage;
Expand Down Expand Up @@ -554,7 +554,8 @@ static bool IsAllowedSplitsTarget(TechnoClass* pSource, HouseClass* pOwner, Weap
if (!EnumFunctions::CanTargetHouse(pWeaponExt->CanTargetHouses, pOwner, pTarget->Owner)
|| !EnumFunctions::IsCellEligible(pTarget->GetCell(), pWeaponExt->CanTarget, true, true)
|| !EnumFunctions::IsTechnoEligible(pTarget, pWeaponExt->CanTarget)
|| !pWeaponExt->IsHealthInThreshold(pTarget))
|| !pWeaponExt->IsHealthInThreshold(pTarget)
|| !pWeaponExt->IsVeterancyInThreshold(pTarget))
{
return false;
}
Expand Down
2 changes: 1 addition & 1 deletion src/Ext/Bullet/Hooks.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ DEFINE_HOOK(0x46A4FB, BulletClass_Shrapnel_Targeting, 0x6)
if (!pWeaponExt->SkipWeaponPicking)
{
if (!EnumFunctions::CanTargetHouse(pWeaponExt->CanTargetHouses, pOwner, pTechno->Owner) || !EnumFunctions::IsTechnoEligible(pTechno, pWeaponExt->CanTarget)
|| !pWeaponExt->IsHealthInThreshold(pTechno) || !pWeaponExt->HasRequiredAttachedEffects(pTechno, pSource))
|| !pWeaponExt->IsHealthInThreshold(pTechno) || !pWeaponExt->IsVeterancyInThreshold(pTechno) || !pWeaponExt->HasRequiredAttachedEffects(pTechno, pSource))
{
return SkipObject;
}
Expand Down
10 changes: 10 additions & 0 deletions src/Ext/Techno/Body.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -743,6 +743,16 @@ bool TechnoExt::IsHealthInThreshold(TechnoClass* pObject, double min, double max
return (hp > 0 ? hp > min : hp >= min) && hp <= max;
}

bool TechnoExt::IsVeterancyInThreshold(TechnoClass* pTechno, float min, float max)
{
float veterancy = 0.0f;

if (pTechno->GetTechnoType()->Trainable)
veterancy = pTechno->Veterancy.Veterancy;

return veterancy >= min && veterancy <= max;
}

bool TechnoExt::CannotMove(UnitClass* pThis)
{
const auto loco = pThis->Locomotor;
Expand Down
1 change: 1 addition & 0 deletions src/Ext/Techno/Body.h
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,7 @@ class TechnoExt
static void CreateDelayedFireAnim(TechnoClass* pThis, AnimTypeClass* pAnimType, int weaponIndex, bool attach, bool center, bool removeOnNoDelay, bool onTurret, CoordStruct firingCoords);
static bool HandleDelayedFireWithPauseSequence(TechnoClass* pThis, WeaponTypeClass* pWeapon, int weaponIndex, int frame, int firingFrame);
static bool IsHealthInThreshold(TechnoClass* pObject, double min, double max);
static bool IsVeterancyInThreshold(TechnoClass* pObject, float min, float max);
static UnitTypeClass* GetUnitTypeExtra(UnitClass* pUnit, TechnoTypeExt::ExtData* pData);
static AircraftTypeClass* GetAircraftTypeExtra(AircraftClass* pAircraft);
static bool CannotMove(UnitClass* pThis);
Expand Down
1 change: 1 addition & 0 deletions src/Ext/Techno/Hooks.Firing.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,7 @@ DEFINE_HOOK(0x6FC339, TechnoClass_CanFire, 0x6)
if (!EnumFunctions::IsTechnoEligible(pTargetTechno, pWeaponExt->CanTarget)
|| !EnumFunctions::CanTargetHouse(pWeaponExt->CanTargetHouses, pThis->Owner, pTargetTechno->Owner)
|| !pWeaponExt->IsHealthInThreshold(pTargetTechno)
|| !pWeaponExt->IsVeterancyInThreshold(pTargetTechno)
|| !pWeaponExt->HasRequiredAttachedEffects(pTargetTechno, pThis))
{
return CannotFire;
Expand Down
2 changes: 1 addition & 1 deletion src/Ext/Techno/Hooks.ReceiveDamage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ DEFINE_HOOK(0x701900, TechnoClass_ReceiveDamage_Shield, 0x6)

// AffectsAbove/BelowPercent & AffectsNeutral can ignore IgnoreDefenses like AffectsAllies/Enmies/Owner
// They should be checked here to cover all cases that directly use ReceiveDamage to deal damage
if (!pWHExt->IsHealthInThreshold(pThis) || (!pWHExt->AffectsNeutral && pThis->Owner->IsNeutral()))
if (!pWHExt->IsHealthInThreshold(pThis) || !pWHExt->IsVeterancyInThreshold(pThis) || (!pWHExt->AffectsNeutral && pThis->Owner->IsNeutral()))
{
damage = 0;
return 0;
Expand Down
2 changes: 2 additions & 0 deletions src/Ext/Techno/WeaponHelpers.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ int TechnoExt::PickWeaponIndex(TechnoClass* pThis, TechnoClass* pTargetTechno, A
if (!EnumFunctions::IsTechnoEligible(pTargetTechno, pSecondExt->CanTarget)
|| !EnumFunctions::CanTargetHouse(pSecondExt->CanTargetHouses, pThis->Owner, pTargetTechno->Owner)
|| !pSecondExt->IsHealthInThreshold(pTargetTechno)
|| !pSecondExt->IsVeterancyInThreshold(pTargetTechno)
|| !pSecondExt->HasRequiredAttachedEffects(pTargetTechno, pThis))
{
return weaponIndexOne;
Expand Down Expand Up @@ -73,6 +74,7 @@ int TechnoExt::PickWeaponIndex(TechnoClass* pThis, TechnoClass* pTargetTechno, A
if (!EnumFunctions::IsTechnoEligible(pTargetTechno, pFirstExt->CanTarget)
|| !EnumFunctions::CanTargetHouse(pFirstExt->CanTargetHouses, pThis->Owner, pTargetTechno->Owner)
|| !pFirstExt->IsHealthInThreshold(pTargetTechno)
|| !pFirstExt->IsVeterancyInThreshold(pTargetTechno)
|| !firstAllowedAE)
{
return weaponIndexTwo;
Expand Down
20 changes: 20 additions & 0 deletions src/Ext/WarheadType/Body.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ bool WarheadTypeExt::ExtData::CanAffectTarget(TechnoClass* pTarget) const
if (!IsHealthInThreshold(pTarget))
return false;

if (!IsVeterancyInThreshold(pTarget))
return false;

if (!this->EffectsRequireVerses)
return true;

Expand All @@ -56,6 +59,14 @@ bool WarheadTypeExt::ExtData::IsHealthInThreshold(TechnoClass* pTarget) const
return TechnoExt::IsHealthInThreshold(pTarget, this->AffectsAbovePercent, this->AffectsBelowPercent);
}

bool WarheadTypeExt::ExtData::IsVeterancyInThreshold(TechnoClass* pTarget) const
{
if (!this->VeterancyCheck)
return true;

return TechnoExt::IsVeterancyInThreshold(pTarget, this->AffectsAboveVeterancy, this->AffectsBelowVeterancy.Get(static_cast<float>(RulesClass::Instance->VeteranCap)));
}

// Checks if Warhead can affect target that might or might be currently invulnerable.
bool WarheadTypeExt::ExtData::CanAffectInvulnerable(TechnoClass* pTarget) const
{
Expand Down Expand Up @@ -286,15 +297,21 @@ void WarheadTypeExt::ExtData::LoadFromINIFile(CCINIClass* const pINI)

this->AffectsBelowPercent.Read(exINI, pSection, "AffectsBelowPercent");
this->AffectsAbovePercent.Read(exINI, pSection, "AffectsAbovePercent");
this->AffectsBelowVeterancy.Read(exINI, pSection, "AffectsBelowVeterancy");
this->AffectsAboveVeterancy.Read(exINI, pSection, "AffectsAboveVeterancy");
this->AffectsNeutral.Read(exINI, pSection, "AffectsNeutral");
this->AffectsGround.Read(exINI, pSection, "AffectsGround");
this->AffectsAir.Read(exINI, pSection, "AffectsAir");
this->CellSpread_Cylinder.Read(exINI, pSection, "CellSpread.Cylinder");
this->HealthCheck = this->AffectsBelowPercent > 0.0 || this->AffectsAbovePercent < 1.0;
this->VeterancyCheck = this->AffectsBelowVeterancy.Get(static_cast<float>(RulesClass::Instance->VeteranCap)) > 0.0f || this->AffectsAboveVeterancy < static_cast<float>(RulesClass::Instance->VeteranCap);

if (this->AffectsAbovePercent > this->AffectsBelowPercent)
Debug::Log("[Developer warning][%s] AffectsAbovePercent is bigger than AffectsBelowPercent, the warhead will never activate!\n", pSection);

if (this->AffectsAboveVeterancy > this->AffectsBelowVeterancy.Get(static_cast<float>(RulesClass::Instance->VeteranCap)))
Debug::Log("[Developer warning][%s] AffectsAboveVeterancy is bigger than AffectsBelowVeterancy, the warhead will never activate!\n", pSection);

this->ReverseEngineer.Read(exINI, pSection, "ReverseEngineer");

this->UnlimboDetonate.Read(exINI, pSection, "UnlimboDetonate");
Expand Down Expand Up @@ -538,11 +555,14 @@ void WarheadTypeExt::ExtData::Serialize(T& Stm)

.Process(this->AffectsBelowPercent)
.Process(this->AffectsAbovePercent)
.Process(this->AffectsBelowVeterancy)
.Process(this->AffectsAboveVeterancy)
.Process(this->AffectsNeutral)
.Process(this->AffectsGround)
.Process(this->AffectsAir)
.Process(this->CellSpread_Cylinder)
.Process(this->HealthCheck)
.Process(this->VeterancyCheck)

.Process(this->InflictLocomotor)
.Process(this->RemoveInflictedLocomotor)
Expand Down
7 changes: 7 additions & 0 deletions src/Ext/WarheadType/Body.h
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,8 @@ class WarheadTypeExt

Valueable<double> AffectsBelowPercent;
Valueable<double> AffectsAbovePercent;
Nullable<float> AffectsBelowVeterancy;
Valueable<float> AffectsAboveVeterancy;
Valueable<bool> AffectsNeutral;
Valueable<bool> AffectsGround;
Valueable<bool> AffectsAir;
Expand Down Expand Up @@ -230,6 +232,7 @@ class WarheadTypeExt
int RemainingAnimCreationInterval;
bool PossibleCellSpreadDetonate;
bool HealthCheck;
bool VeterancyCheck;
TechnoClass* DamageAreaTarget;

private:
Expand Down Expand Up @@ -402,6 +405,8 @@ class WarheadTypeExt

, AffectsBelowPercent { 1.0 }
, AffectsAbovePercent { 0.0 }
, AffectsBelowVeterancy {}
, AffectsAboveVeterancy { 0.0f }
, AffectsNeutral { true }
, AffectsGround { true }
, AffectsAir { true }
Expand All @@ -423,6 +428,7 @@ class WarheadTypeExt
, RemainingAnimCreationInterval { 0 }
, PossibleCellSpreadDetonate { false }
, HealthCheck { false }
, VeterancyCheck { false }
, DamageAreaTarget {}

, CanKill { true }
Expand Down Expand Up @@ -457,6 +463,7 @@ class WarheadTypeExt
bool CanAffectInvulnerable(TechnoClass* pTarget) const;
bool EligibleForFullMapDetonation(TechnoClass* pTechno, TechnoTypeClass* pType, HouseClass* pOwner) const;
bool IsHealthInThreshold(TechnoClass* pTarget) const;
bool IsVeterancyInThreshold(TechnoClass* pTarget) const;

virtual ~ExtData() = default;
virtual void LoadFromINIFile(CCINIClass* pINI) override;
Expand Down
10 changes: 10 additions & 0 deletions src/Ext/WeaponType/Body.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,11 @@ bool WeaponTypeExt::ExtData::IsHealthInThreshold(TechnoClass* pTarget) const
return TechnoExt::IsHealthInThreshold(pTarget, this->CanTarget_MinHealth, this->CanTarget_MaxHealth);
}

bool WeaponTypeExt::ExtData::IsVeterancyInThreshold(TechnoClass* pTarget) const
{
return TechnoExt::IsVeterancyInThreshold(pTarget, this->CanTarget_MinVeterancy, this->CanTarget_MaxVeterancy.Get(static_cast<float>(RulesClass::Instance->VeteranCap)));
}

void WeaponTypeExt::ExtData::Initialize()
{
this->RadType = RadTypeClass::FindOrAllocate(GameStrings::Radiation);
Expand Down Expand Up @@ -104,6 +109,8 @@ void WeaponTypeExt::ExtData::LoadFromINIFile(CCINIClass* const pINI)
this->CanTargetHouses.Read(exINI, pSection, "CanTargetHouses");
this->CanTarget_MaxHealth.Read(exINI, pSection, "CanTarget.MaxHealth");
this->CanTarget_MinHealth.Read(exINI, pSection, "CanTarget.MinHealth");
this->CanTarget_MaxVeterancy.Read(exINI, pSection, "CanTarget.MaxVeterancy");
this->CanTarget_MinVeterancy.Read(exINI, pSection, "CanTarget.MinVeterancy");
this->Burst_Delays.Read(exINI, pSection, "Burst.Delays");
this->Burst_FireWithinSequence.Read(exINI, pSection, "Burst.FireWithinSequence");
this->Burst_NoDelay.Read(exINI, pSection, "Burst.NoDelay");
Expand Down Expand Up @@ -157,6 +164,7 @@ void WeaponTypeExt::ExtData::LoadFromINIFile(CCINIClass* const pINI)
// handle SkipWeaponPicking
if (this->CanTarget != AffectedTarget::All || this->CanTargetHouses != AffectedHouse::All
|| this->CanTarget_MaxHealth < 1.0 || this->CanTarget_MinHealth > 0.0
|| this->CanTarget_MaxVeterancy.Get(static_cast<float>(RulesClass::Instance->VeteranCap)) < static_cast<float>(RulesClass::Instance->VeteranCap) || this->CanTarget_MinVeterancy > 0.0f
|| this->AttachEffect_RequiredTypes.size() || this->AttachEffect_RequiredGroups.size()
|| this->AttachEffect_DisallowedTypes.size() || this->AttachEffect_DisallowedGroups.size())
{
Expand Down Expand Up @@ -186,6 +194,8 @@ void WeaponTypeExt::ExtData::Serialize(T& Stm)
.Process(this->CanTargetHouses)
.Process(this->CanTarget_MaxHealth)
.Process(this->CanTarget_MinHealth)
.Process(this->CanTarget_MaxVeterancy)
.Process(this->CanTarget_MinVeterancy)
.Process(this->RadType)
.Process(this->Burst_Delays)
.Process(this->Burst_FireWithinSequence)
Expand Down
5 changes: 5 additions & 0 deletions src/Ext/WeaponType/Body.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ class WeaponTypeExt
Valueable<AffectedHouse> CanTargetHouses;
Valueable<double> CanTarget_MaxHealth;
Valueable<double> CanTarget_MinHealth;
Nullable<float> CanTarget_MaxVeterancy;
Valueable<float> CanTarget_MinVeterancy;
ValueableVector<int> Burst_Delays;
Valueable<bool> Burst_FireWithinSequence;
Valueable<bool> Burst_NoDelay;
Expand Down Expand Up @@ -114,6 +116,8 @@ class WeaponTypeExt
, CanTargetHouses { AffectedHouse::All }
, CanTarget_MaxHealth { 1.0 }
, CanTarget_MinHealth { 0.0 }
, CanTarget_MaxVeterancy {}
, CanTarget_MinVeterancy { 0.0f }
, Burst_Delays {}
, Burst_FireWithinSequence { false }
, Burst_NoDelay { false }
Expand Down Expand Up @@ -169,6 +173,7 @@ class WeaponTypeExt
int GetBurstDelay(int burstIndex) const;
bool HasRequiredAttachedEffects(TechnoClass* pTechno, TechnoClass* pFirer) const;
bool IsHealthInThreshold(TechnoClass* pTarget) const;
bool IsVeterancyInThreshold(TechnoClass* pTarget) const;

virtual ~ExtData() = default;

Expand Down