Download version 2.5 (mirror)
View source code and progress
Supports
Version Checker
This mod requires
LazyLib to function!
Trying to calculate direction using vanilla’s system of icons around the edge of a rectangular screen can be frustrating, and forget about judging relative positions at a glance. Tired of being forced to constantly check the tactical map to obtain basic situational awareness? Ever wish that Starsector would just include a normal radar view? Then this mod is for you. It does exactly as its name implies: adds a more familiar circular radar view to your combat HUD to make keeping track of the battle map on the fly much easier. It also includes an easily-parsed combat readiness meter for the piloted ship as well as a simple overview of how the battle is going for your side.
The radar’s zoom level can be changed using +/- and toggled with K, and has three zoom levels by default. These options can be changed by modifying the .json files in data/config/radar/, along with other settings such as UI/contact colors, radar sight radius, etc.
Compatibility:
The radar should work with any other mod on the forum and doesn’t require a new game. As the radar is display-only and doesn’t change anything in your game, you can deactivate this mod at will.
Legend (combat):
Legend (campaign):
All colors listed above can be customized in the radar config files. Nebulae are not included in the radar view due to API limitations.
Please let me know if you spot any issues, especially alongside other mods that use OpenGL such as ShaderLib.
Changelog:
That’s something I’ve wanted in this game for, like, ever.
Just my $0.02 on what we’re seeing (for what it’s worth, given that I am just yapping):
1. A square presentation using the same colors as the UI would fit better visually.
2. I’d place it in the right corner, so that it’s out of the way but isn’t in a zone that’s too busy with other information.
3. I’m sure a fair amount of the CPU time is spent on drawing the vector’d triangles.
Perhaps not bothering, or depicting velocity by storing two update cycles-worth of past ship movement and drawing with less alpha (i.e., last update, 128, update 2, 64, so that it fades out and dynamically shows movement) using circle bitmaps might help save CPU while accomplishing the goal? The other big saver would be to not show every single Fighter, but merely a symbol for the group, centered on the leader, and Drones definitely don’t need a complex presentation- moving dots are totally sufficient.
4. For the issues with menus… probably:
A. A simple global that could be set / unset in a singleton; this would require minor touchup to the Dialog and Battle code (one-liners to set said value true false), not too scary but it’d require people to compile a .jar atm.
B. Give users a key that can turn it on / off in any context.
Just my $0.02 on what we’re seeing (for what it’s worth, given that I am just yapping):
1. A square presentation using the same colors as the UI would fit better visually.
I originally tried this as a square box, but IMO rectangular radars are ugly. Definitely agree on matching the UI colors, though. Luckily that’s pretty trivial to change.
2. I’d place it in the right corner, so that it’s out of the way but isn’t in a zone that’s too busy with other information.
It’s in the lower right due to the ‘rendering over menus’ issue. If I moved it to the top right it’d render over a lot of the tactical map’s buttons.
3. I’m sure a fair amount of the CPU time is spent on drawing the vector’d triangles.
I wouldn’t worry about the triangles, that’ll be a non-issue once I optimize.
B. Give users a key that can turn it on / off in any context.
That’s next on my list!
As for the aesthetics, the rest of the UI is angular, so it’s standing out. A box around it, perhaps, and fade the outer circles, something like this?

Changes in this update:
- Radar positioning is still a placeholder, but I moved the radar to the absolute lower right so it wouldn’t overlap the UI when using a 1024×768 resolution.
- I upped the number of segments on the circles to make them look smoother. I also changed the colors to match what’s set for the UI in settings.json (“textFriendColor” is used for the UI, “iconFriendColor”/”iconEnemyColor” for radar contacts).
- Finally, the mod should have significantly better performance in large battles as I reduced trig calls by 60% (I told you it needed optimization).
Sorry about the lack of actual progress. I’ve been busy with holiday stuff.
Nicely done! I was wondering about the primitive draw methods you put in LazyLib…
I actually added those methods after stumbling across a page that described drawing circles using a simple repeated rotation. At the time I didn’t even know rendering in combat was possible and was planning on making a campaign-level radar.
I meant squared up with the menu edge.
As for the aesthetics, the rest of the UI is angular, so it’s standing out. A box around it, perhaps, and fade the outer circles, something like this?
Yeah, the current positioning is just an arbitrary guess until I can spend the time getting it right. I don’t think the combat UI is scaled, so once I measure the existing UI getting the radar to look good will be easy. I’m considering leaving a bit of extra space for potentially implementing
this suggestion, though.
Also, I really like that mock-up. You’re right, with the darkened edges it matches the UI much better. Consider it added to the to-do list.
Honestly this feature should become part of the main code, the current radar system…doesn’t give quite a satisfactory amount of real time information. Are you able to have different size and different colour vectors as proposed by Xenoargh, that would be invaluable in larger battles.
Maybe as a toggleable option, though I personally prefer the triangles. The trick is including as much information as possible without it being an indecipherable mess, and blurred points take longer to mentally process than distinct shapes. Plus, I think in most battles knowing a ship’s facing is more important than their current velocity.
Damn useful indeed. I hope you’ll also manage to implement the missiles detection into the radar too, i hate being surprised by Pilums lrm storms.
I’m planning on displaying ships (including phased status and a marker around your current target), missiles, asteroids, and maybe shield arcs. There will be a settings file to toggle these on/off.
‘Sucuse my silliness, but all-in-all, nice work! You could call it the “LazyTweaks” mod if you combine it with other non-combat focused mods in the future. Just sayin’.
Second, isnt it possible using the ships bounds to create a shape of the ship instead of a triangle shape?
Also as Uomoz was suggesting, different shapes based on different hull types. check the icons in
http://fractalsoftworks.com/forum/index.php?topic=6906.msg112651#msg112651