Bestiary room pictures from the high-res atlas in the high-res style

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Richard ZinkandClaude Opus 5.5 committed 2026-11-07 23:36:17 +01:00
1 parent 0ada04f4fb
commit 37e5250c52
2 files changed
+3 -2

No files matched your search

+2 -1
View File
@@ -178,7 +178,8 @@ impl Menu {
Entry::Rank(l) => draw_sprite(gfx, EK::Ogre, l, x + k, y + k, pic),
Entry::Building(i) => {
let icon = tool_info(TOOLS[i]).icon;
draw_texture_ex(&gfx.atlas, x + k * 2.0, y + k * 2.0, WHITE, DrawTextureParams { source: Some(Gfx::cell(icon)), dest_size: Some(vec2(pic - 2.0 * k, pic - 2.0 * k)), ..Default::default() });
// (draw_cell: the high-res style shows the high-res atlas)
gfx.draw_cell(icon, x + k * 2.0, y + k * 2.0, pic - 2.0 * k, pic - 2.0 * k, WHITE);
}
}
// level selector with the rank badge under the picture
+1 -1
View File
@@ -990,7 +990,7 @@ impl Ui {
draw_rectangle(r.x, r.y, r.w, r.h, if hovered || self.show_talents { Color::new(0.18, 0.13, 0.1, 1.0) } else { Color::new(0.1, 0.07, 0.07, 1.0) });
draw_rectangle_lines(r.x, r.y, r.w, r.h, 2.0 * px, if glow { GOLD } else if self.show_talents { FRAME_HI } else { Color::new(0.35, 0.28, 0.2, 1.0) });
let isz = 2.0 * CH() - 2.0 * px;
draw_texture_ex(&gfx.atlas, bx + (bw - isz) * 0.5, by + 2.0 * px, WHITE, DrawTextureParams { source: Some(Gfx::cell(I_RUNE)), dest_size: Some(vec2(isz, isz)), ..Default::default() });
gfx.draw_cell(I_RUNE, bx + (bw - isz) * 0.5, by + 2.0 * px, isz, isz, WHITE);
if free > 0 {
gfx.text(&free.to_string(), r.x + 3.0 * px, r.y + 3.0 * px, SMALL(), if glow { WHITE } else { GOLD });
}