mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-12 05:21:29 +00:00
[Cleanup] Explicitly cast to float for more precision in Bot::GenerateBastHitPoints() (#3238)
# Notes - Not casting explicitly we lost precision.
This commit is contained in:
parent
60091015d3
commit
26eabcd7a4
@ -1184,9 +1184,9 @@ int32 Bot::GenerateBaseHitPoints() {
|
|||||||
if (GetOwner() && GetOwner()->CastToClient() && GetOwner()->CastToClient()->ClientVersion() >= EQ::versions::ClientVersion::SoD && RuleB(Character, SoDClientUseSoDHPManaEnd)) {
|
if (GetOwner() && GetOwner()->CastToClient() && GetOwner()->CastToClient()->ClientVersion() >= EQ::versions::ClientVersion::SoD && RuleB(Character, SoDClientUseSoDHPManaEnd)) {
|
||||||
float SoDPost255;
|
float SoDPost255;
|
||||||
if (((NormalSTA - 255) / 2) > 0)
|
if (((NormalSTA - 255) / 2) > 0)
|
||||||
SoDPost255 = ((NormalSTA - 255) / 2);
|
SoDPost255 = ((static_cast<float>(NormalSTA) - 255.0f) / 2.0f);
|
||||||
else
|
else
|
||||||
SoDPost255 = 0;
|
SoDPost255 = 0.0f;
|
||||||
|
|
||||||
int hp_factor = GetClassHPFactor();
|
int hp_factor = GetClassHPFactor();
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user