fix for HP
This commit is contained in:
parent
12447f634e
commit
49d4dcd483
@ -1114,6 +1114,13 @@ bool BossInit(CBoss _Boss)
|
|||||||
int iCounterOnHitMaxCount = GetOutputCount(iCounterEnt, "m_OnHitMax");
|
int iCounterOnHitMaxCount = GetOutputCount(iCounterEnt, "m_OnHitMax");
|
||||||
|
|
||||||
Config.bCounterReverse = iCounterOnHitMaxCount > iCounterOnHitMinCount;
|
Config.bCounterReverse = iCounterOnHitMaxCount > iCounterOnHitMinCount;
|
||||||
|
|
||||||
|
if(iCounterOnHitMaxCount == iCounterOnHitMinCount)
|
||||||
|
{
|
||||||
|
int iMaxDiff = RoundFloat(GetEntPropFloat(iCounterEnt, Prop_Data, "m_flMax") - GetOutputValueFloat(iCounterEnt, "m_OutValue"));
|
||||||
|
int iMinDiff = RoundFloat(GetOutputValueFloat(iCounterEnt, "m_OutValue") - GetEntPropFloat(iCounterEnt, Prop_Data, "m_flMin"));
|
||||||
|
Config.bCounterReverse = iMaxDiff > iMinDiff;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if(_Boss.IsHPBar)
|
else if(_Boss.IsHPBar)
|
||||||
{
|
{
|
||||||
@ -1201,11 +1208,25 @@ bool BossInit(CBoss _Boss)
|
|||||||
int iIteratorOnHitMaxCount = GetOutputCount(iIteratorEnt, "m_OnHitMax");
|
int iIteratorOnHitMaxCount = GetOutputCount(iIteratorEnt, "m_OnHitMax");
|
||||||
|
|
||||||
Config.bIteratorReverse = iIteratorOnHitMaxCount > iIteratorOnHitMinCount;
|
Config.bIteratorReverse = iIteratorOnHitMaxCount > iIteratorOnHitMinCount;
|
||||||
|
|
||||||
|
if(iIteratorOnHitMaxCount == iIteratorOnHitMinCount)
|
||||||
|
{
|
||||||
|
int iIteratorMaxDiff = RoundFloat(GetEntPropFloat(iIteratorEnt, Prop_Data, "m_flMax") - GetOutputValueFloat(iIteratorEnt, "m_OutValue"));
|
||||||
|
int iIteratorMinDiff = RoundFloat(GetOutputValueFloat(iIteratorEnt, "m_OutValue") - GetEntPropFloat(iIteratorEnt, Prop_Data, "m_flMin"));
|
||||||
|
Config.bCounterReverse = iIteratorMaxDiff > iIteratorMinDiff;
|
||||||
|
}
|
||||||
|
|
||||||
int iCounterOnHitMinCount = GetOutputCount(iCounterEnt, "m_OnHitMin");
|
int iCounterOnHitMinCount = GetOutputCount(iCounterEnt, "m_OnHitMin");
|
||||||
int iCounterOnHitMaxCount = GetOutputCount(iCounterEnt, "m_OnHitMax");
|
int iCounterOnHitMaxCount = GetOutputCount(iCounterEnt, "m_OnHitMax");
|
||||||
|
|
||||||
Config.bCounterReverse = iCounterOnHitMaxCount > iCounterOnHitMinCount;
|
Config.bCounterReverse = iCounterOnHitMaxCount > iCounterOnHitMinCount;
|
||||||
|
|
||||||
|
if(iCounterOnHitMaxCount == iCounterOnHitMinCount)
|
||||||
|
{
|
||||||
|
int iMaxDiff = RoundFloat(GetEntPropFloat(iCounterEnt, Prop_Data, "m_flMax") - GetOutputValueFloat(iCounterEnt, "m_OutValue"));
|
||||||
|
int iMinDiff = RoundFloat(GetOutputValueFloat(iCounterEnt, "m_OutValue") - GetEntPropFloat(iCounterEnt, Prop_Data, "m_flMin"));
|
||||||
|
Config.bCounterReverse = iMaxDiff > iMinDiff;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
_Boss.bActive = true;
|
_Boss.bActive = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user