summaryrefslogtreecommitdiff
path: root/src/company_cmd.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/company_cmd.cpp')
-rw-r--r--src/company_cmd.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/company_cmd.cpp b/src/company_cmd.cpp
index 39a889e5e..ba52c61eb 100644
--- a/src/company_cmd.cpp
+++ b/src/company_cmd.cpp
@@ -159,6 +159,11 @@ void InvalidateCompanyWindows(const Company *company)
SetWindowDirty(WC_FINANCES, cid);
}
+/**
+ * Verify whether the company can pay the bill.
+ * @param cost [inout] Money to pay, is changed to an error if the company does not have enough money.
+ * @return Function returns \c true if the company has enough money, else it returns \c false.
+ */
bool CheckCompanyHasMoney(CommandCost &cost)
{
if (cost.GetCost() > 0) {