From 2eef87c8970db643c4ef09e0fd9e8110c8193043 Mon Sep 17 00:00:00 2001 From: jacopo grandi Date: Sat, 20 Feb 2021 00:11:23 +0100 Subject: finish condition and bad cost function --- hud/hud_views.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'hud/hud_views.c') diff --git a/hud/hud_views.c b/hud/hud_views.c index 4828275..046ba53 100644 --- a/hud/hud_views.c +++ b/hud/hud_views.c @@ -14,6 +14,12 @@ void render_view_stats (SDL_Renderer* rend, txtd *t, int px, int py, render_text_scaled(rend, sname, pname, t, 2); h += 35; + float cost = info_unit_get_cost(info, tm); + float pcost[2] = { px+10, py+h }; + char scost[64]; sprintf(scost, "COST: %.2f", cost); + render_text_scaled(rend, scost, pcost, t, 1); + h += 20; + float calcweight = info_unit_get_weight(info, tm); float maxweight = info->chassis[tm->chassis].weight_max[ tm->levels[LEVEL_CHASSIS]]; -- cgit v1.2.3-54-g00ecf