Pixel art style coarser: 270 world rows
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
807a124a0b
commit
76f3b3c7b2
4 files changed
+10
-10
No files matched your search
+7
-7
@@ -151,7 +151,7 @@ pub struct Settings {
|
||||
pub ui_factor: u8, // old interface size (2 large, 3 medium, 4 small; only read to carry old settings over)
|
||||
pub ui_size: u16, // interface size in percent of the standard (100 = 1080 interface rows), 0 = automatic
|
||||
pub render_scale: u8, // old pixel-look divisor (no longer used, kept for old settings files)
|
||||
pub pixel_rows: u16, // graphics style: rows of the world on every screen (360 pixel art, 1080 high-res)
|
||||
pub pixel_rows: u16, // graphics style: rows of the world on every screen (270 pixel art, 1080 high-res)
|
||||
pub touch_ui: u8, // touch interface: 0 = automatic (after the first touch), 1 = on, 2 = off
|
||||
pub debug_fps: bool, // show FPS and rendering backend
|
||||
pub debug_frame_time: bool, // show the frame-time line and graph
|
||||
@@ -192,7 +192,7 @@ impl Default for Settings {
|
||||
ui_factor: 0,
|
||||
ui_size: 0,
|
||||
render_scale: 1,
|
||||
pixel_rows: 360,
|
||||
pixel_rows: PIXEL_ART_ROWS,
|
||||
touch_ui: 0,
|
||||
debug_fps: false,
|
||||
debug_frame_time: false,
|
||||
@@ -264,10 +264,10 @@ impl Settings {
|
||||
}
|
||||
}
|
||||
|
||||
// the graphics styles of the settings menu as the world's pixel rows: pixel art (360 rows, the
|
||||
// the graphics styles of the settings menu as the world's pixel rows: pixel art (270 rows, the
|
||||
// small hand-made sprites) and high-res (1080 rows, detailed sprites; other values from older
|
||||
// settings files count as pixel art)
|
||||
pub const PIXEL_ART_ROWS: u16 = 360;
|
||||
pub const PIXEL_ART_ROWS: u16 = 270;
|
||||
pub const HIGH_RES_ROWS: u16 = 1080;
|
||||
pub const STYLES: [u16; 2] = [PIXEL_ART_ROWS, HIGH_RES_ROWS];
|
||||
|
||||
@@ -326,10 +326,10 @@ mod tests {
|
||||
#[test]
|
||||
fn graphics_styles() {
|
||||
assert_eq!(pixel_rows(1080), 1080);
|
||||
assert_eq!(pixel_rows(360), 360);
|
||||
assert_eq!(pixel_rows(270), 270);
|
||||
// older pixel-look values count as pixel art
|
||||
for old in [270u16, 480, 540, 0] {
|
||||
assert_eq!(pixel_rows(old), 360);
|
||||
for old in [360u16, 480, 540, 0] {
|
||||
assert_eq!(pixel_rows(old), 270);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user