* Display estimated costs. * @param cost Estimated cost (or income if negative). * @param x X position of the notification window. * @param y Y position of the notification window. */
| 493 | * @param y Y position of the notification window. |
| 494 | */ |
| 495 | void ShowEstimatedCostOrIncome(Money cost, int x, int y) |
| 496 | { |
| 497 | StringID msg = STR_MESSAGE_ESTIMATED_COST; |
| 498 | |
| 499 | if (cost < 0) { |
| 500 | cost = -cost; |
| 501 | msg = STR_MESSAGE_ESTIMATED_INCOME; |
| 502 | } |
| 503 | ShowErrorMessage(GetEncodedString(msg, cost), {}, WL_INFO, x, y); |
| 504 | } |
| 505 | |
| 506 | /** |
| 507 | * Display animated income or costs on the map. Does nothing if cost is zero. |
no test coverage detected