Bug 4908 - Show BP from marked buildables on the HUD
Status: RESOLVED FIXED
Alias: None
Product: Tremulous
Classification: Unclassified
Component: Misc
Version: SVN HEAD
Hardware: All All
: P3 enhancement
Assignee: Tim Angus
QA Contact: Tremulous Bugs
URL:
Depends on:
Blocks:
 
Reported: 2011-02-16 11:20 EST by Chris "Lakitu7" Schwarz
Modified: 2011-02-21 03:37:19 EST
0 users

See Also:


Attachments
Show marked BP on the HUD (6.88 KB, patch)
2011-02-16 11:23 EST, Chris "Lakitu7" Schwarz
Show marked BP on the HUD (6.88 KB, patch)
2011-02-16 17:24 EST, Chris "Lakitu7" Schwarz

Description Chris "Lakitu7" Schwarz 2011-02-16 11:20:07 EST
It is confusing that as a builder you can build things while the HUD says you have zero BP, because the HUD is not aware of marked BP. The HUD should show available BP from marked structures. From user request http://tremulous.net/forum/index.php?topic=15172.0
Comment 1 Chris "Lakitu7" Schwarz 2011-02-16 11:23:51 EST
Created attachment 2614 [details]
Show marked BP on the HUD

Patch does as intended, with the caveat that the display draw code a bit hackish and has a bunch of little numbers that I had to hand-tune, which frankly was a pain. It is so because the current HUD has no real place for it so I had to squish it in as best possible, because I wanted to preserve the appearance in most other cases, and because the text align/width functions aren't remotely precise enough to do it elegantly. When someone designs/codes an official NEW HUD, if ever, I will happily rip out all of that code and add a separate ownerdraw.
Comment 2 Chris "Lakitu7" Schwarz 2011-02-16 11:24:41 EST
Forgot to mention that I also removed a completely unused parameter from G_GetBuildPoints();
Comment 3 Chris "Lakitu7" Schwarz 2011-02-16 17:24:09 EST
Created attachment 2615 [details]
Show marked BP on the HUD

Change one char in the patch to fix using an ununitialized value in a rare case. Thanks benmachine.
Comment 4 Chris "Lakitu7" Schwarz 2011-02-21 03:37:19 EST
In at r2176.