(svn r21156) -Codechange: Introduce EconomyIsInRecession().

This commit is contained in:
alberth
2010-11-13 09:45:20 +00:00
parent 582a75e052
commit b698045b82
5 changed files with 15 additions and 6 deletions

View File

@@ -42,4 +42,13 @@ void InitializeEconomy();
void RecomputePrices();
void AddInflation(bool check_year = true);
/**
* Is the economy in recession?
* @return \c True if economy is in recession, \c false otherwise.
*/
static inline bool EconomyIsInRecession()
{
return _economy.fluct <= 0;
}
#endif /* ECONOMY_FUNC_H */