mirror of
https://github.com/Jackzmc/sourcemod-plugins.git
synced 2025-05-07 15:43:21 +00:00
Misc
This commit is contained in:
parent
4e97e7a9fa
commit
88b7ac09fc
4 changed files with 82 additions and 63 deletions
|
@ -355,7 +355,7 @@ Action Event_OnTakeDamage(int victim, int& attacker, int& inflictor, float& dam
|
|||
// Auto reverse ff logic
|
||||
if(isDamageDirect) {
|
||||
// Decrease the RFF scale based on how long since their last FF and an amount
|
||||
float minutesSinceiLastFFTime = (time - pData[attacker].lastFFTime) / 60.0;
|
||||
float minutesSinceiLastFFTime = pData[attacker].lastFFTime > 0 ? ((time - pData[attacker].lastFFTime) / 60.0) : 0.1;
|
||||
pData[attacker].autoRFFScaleFactor -= minutesSinceiLastFFTime * hFFAutoScaleForgivenessAmount.FloatValue;
|
||||
if(pData[attacker].autoRFFScaleFactor < 0.0) {
|
||||
pData[attacker].autoRFFScaleFactor = 0.0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue