Rank badges and level equipment; no edge scrolling before the mouse has moved

- Military rank badges instead of level numbers: Lv 2-4 bronze chevrons, Lv 5-7 silver bars,
  Lv 8-9 gold stars, Lv 10 gold star in a wreath; rank names in the unit info (EN/DE)
- Equipment grows with the level: shoulder pieces (bronze/silver/gold), helmets with horns
  (creatures) or plumes (heroes), capes from Lv 7, glowing ring from Lv 9, aura at Lv 10
- Fix: before the first mouse move the pointer counts as (0, 0) and the edge scrolling
  moved the camera at the start and after loading a savegame

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Richard ZinkandClaude Opus 5.5 committed 2026-11-03 12:47:34 +01:00
1 parent 52d49b0243
commit 729dd4fe4c
6 files changed
+170 -5

No files matched your search

+1
View File
@@ -1023,6 +1023,7 @@ pub fn hover_info(g: &Game, ent: Option<usize>, tile: Option<(i32, i32)>) -> Vec
let e = &g.ents[j];
let s = st(e.kind);
out.push((trf("info.level", &[tr(s.name), e.level.to_string()]), if e.hero { BLUE } else { FRAME_HI }));
out.push((trf("info.rank", &[tr(&format!("rank.{}", e.level.clamp(1, 10)))]), GOLD));
out.push((trf("info.hp", &[(e.hp.max(0.0) as i32).to_string(), (e.max_hp as i32).to_string()]), GREEN));
if e.hero && e.captive != 0 {
out.push((tr(["", "info.unconscious", "info.carried", "info.tortured"][e.captive.min(3) as usize]), RED));