1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-03-17 20:58:07 +02:00

Replace defines with constexpr

This commit is contained in:
Ivan Savenko 2024-11-28 15:08:15 +00:00
parent 40aa49acff
commit 7574842e93
2 changed files with 2 additions and 5 deletions

View File

@ -17,8 +17,7 @@
namespace NKAI
{
#define MIN_AI_STRENGTH (0.5f) //lower when combat AI gets smarter
#define UNGUARDED_OBJECT (100.0f) //we consider unguarded objects 100 times weaker than us
constexpr float MIN_AI_STRENGTH = 0.5f; //lower when combat AI gets smarter
engineBase::engineBase()
{

View File

@ -35,9 +35,7 @@
namespace NKAI
{
#define MIN_AI_STRENGTH (0.5f) //lower when combat AI gets smarter
#define UNGUARDED_OBJECT (100.0f) //we consider unguarded objects 100 times weaker than us
const float MIN_CRITICAL_VALUE = 2.0f;
constexpr float MIN_CRITICAL_VALUE = 2.0f;
EvaluationContext::EvaluationContext(const Nullkiller* ai)
: movementCost(0.0),