Health bars and selection rings become dots when zoomed out and giants when zoomed in
Small markers that belong to units must follow the zoom, but only partly. Scaled exactly with the world they vanish far away and swallow the screen up close. Here is the size rule with a floor and a ceiling, how thin lines stay thin, and why sizes should land on whole pixels.
Why this works
What the player needs is a marker they can read on the screen, not one that is truthful to the map. So its size is set in screen terms, kept between a smallest and a largest, while thin lines stay the same width at every zoom.
When not to use it
Keep markers at their true size when their size carries meaning, such as an area of effect, a sight range or a blast circle. Those must grow and shrink with the map, or the player misjudges distances.
In the full entry
- What to build, step by step
- Starting values and the reason for each
- 3 common mistakes and the fix
- 24 lines of example code with 4 checks that pass
- How your AI shows you that it works
Say this to your AI
Use the Spielerando entry "Health bars and selection rings become dots when zoomed out and giants when zoomed in" (read_entry strategy-markers-stay-readable-when-zooming) in my game. Build it step by step, and show me how you checked that it works.Or skip this and connect the MCP: your AI then finds all of this by itself.Connect the MCP