From ee30cf90bf032b9dcf422ea5a35af73090ea3982 Mon Sep 17 00:00:00 2001 From: shenjack-mac <3695888@qq.com> Date: Thu, 2 Feb 2023 22:44:24 +0800 Subject: [PATCH] sr_ship --- Difficult_Rocket/client/render/sr1_ship.py | 4 ++-- configs/main.toml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Difficult_Rocket/client/render/sr1_ship.py b/Difficult_Rocket/client/render/sr1_ship.py index bda9077..5748fb1 100644 --- a/Difficult_Rocket/client/render/sr1_ship.py +++ b/Difficult_Rocket/client/render/sr1_ship.py @@ -116,7 +116,7 @@ class SR1ShipRender(BaseScreen): self.parts_sprite: Dict[int, Sprite] = {} if DR_option.use_DR_rust: self.camera_rs = Camera_rs(main_window, - min_zoom=(1/2) ** 4, max_zoom=1 << 5) + min_zoom=(1/2) ** 4, max_zoom=10) self.rust_parts = None def load_xml(self, file_path: str) -> bool: @@ -238,7 +238,7 @@ class SR1ShipRender(BaseScreen): mouse_dx = x - (self.window_pointer.width / 2) mouse_dy = y - (self.window_pointer.height / 2) self.debug_mouse_line.x2, self.debug_mouse_line.y2 = x, y - if self.scale * (0.5**scroll_y) < 10: + if self.camera_rs.zoom * (0.5**scroll_y) < 10: self.camera_rs.zoom = self.camera_rs.zoom * (0.5 ** scroll_y) self.camera_rs.dx += (mouse_dx - self.camera_rs.dx) * (1 - (0.5 ** scroll_y)) self.camera_rs.dy += (mouse_dy - self.camera_rs.dy) * (1 - (0.5 ** scroll_y)) diff --git a/configs/main.toml b/configs/main.toml index 4f6943e..c51bf2d 100644 --- a/configs/main.toml +++ b/configs/main.toml @@ -8,8 +8,8 @@ fonts_folder = "libs/fonts" [window] style = "None" -width = 2336 -height = 1621 +width = 1439 +height = 969 visible = true gui_scale = 1 caption = "Difficult Rocket v{DR_version}|DR_rs v{DR_Rust_get_version}"