Example, if the weapon has no more magazines (MagCount ==0), I want both AkiFrearm and SkorpFirearm to not be able to reload. If SkorpFirearm is jammed (bJammed), I want it to not be able to reload as well.
Of course I could copy all conditions of AkiFirearm into SkorpFirearm's state, but if I change something in AkiFirearm, I'd have to change all it's subclasses.
AkiFirearm
Code: Select all
simulated function ReloadCheck()
{
if (MagCount == 0 || bIsReloading || bSightTransition)
bCanReload=false;
else
bCanReload=true;
}
Code: Select all
simulated function ReloadCheck()
{
Super.ReloadCheck();
if (bJammed || bUnjamming || !bCanReload)
bCanReload=false;
else
bCanReload=true;
}