Freeciv21
Develop your civilization from humble roots to a global empire
advtools.cpp File Reference
#include <cmath>
#include "advtools.h"
+ Include dependency graph for advtools.cpp:

Go to the source code of this file.

Functions

adv_want amortize (adv_want benefit, int delay)
 Amortize means gradually paying off a cost or debt over time. More...
 

Function Documentation

◆ amortize()

adv_want amortize ( adv_want  benefit,
int  delay 
)

Amortize means gradually paying off a cost or debt over time.

In freeciv terms this means we calculate how much less worth something is to us depending on how long it will take to complete.

This is based on a global interest rate as defined by the MORT value.

Definition at line 25 of file advtools.cpp.

Referenced by adv_best_government(), autosettler_tile_behavior(), dai_gov_value(), dai_hunter_guess_best(), dai_hunter_missile_want(), dai_war_desire(), military_amortize(), settler_evaluate_improvements(), and settler_map_iterate().