Is your feature request related to a problem? Please describe.
Currently, agent::eat has these magic constants:
// Focal agent will eat the prey
// As in any food chain, energy is lost: the predator gains less energy
// than the prey gains
m_health += 0.2;
m_stamina += 0.2;
other.set_health(other.get_health() - 2.0);
One should avoid magic constants (e.g. an
Also, we cannot test for the sanity of these consants
Is your feature request related to a problem? Please describe.
Currently,
agent::eat
has these magic constants:One should avoid magic constants (e.g. an
Also, we cannot test for the sanity of these consants
Describe the solution you'd like
agent::eat
For example:
should become:
Describe alternatives you've considered
None.
Additional context
None.