From 0fedd1b30b07576e8cf7850658a617e5533a653d Mon Sep 17 00:00:00 2001 From: Serkyo Date: Fri, 10 Jul 2026 17:38:07 +0200 Subject: [PATCH] chore(workspace): refactored the way some comments were written across the repository --- crates/client/src/camera.rs | 4 +--- crates/client/src/main.rs | 6 ++---- crates/server/src/main.rs | 3 +-- crates/server/src/save.rs | 7 ++----- crates/shared/src/lib.rs | 3 +-- 5 files changed, 7 insertions(+), 16 deletions(-) diff --git a/crates/client/src/camera.rs b/crates/client/src/camera.rs index 1d67ba2..6c32a2d 100644 --- a/crates/client/src/camera.rs +++ b/crates/client/src/camera.rs @@ -2,9 +2,7 @@ //! Free-fly camera used to observe the world. //! -//! The camera stores a world-space position and an orientation expressed as yaw and pitch -//! angles. A view matrix is derived on demand from these values, and the orientation and -//! position are advanced each frame from accumulated keyboard and mouse input. +//! The camera stores a world-space position and an orientation expressed as yaw and pitch angles. A view matrix is derived on demand from these values, and the orientation and position are advanced each frame from accumulated keyboard and mouse input. use glam::{Mat4, Vec3}; diff --git a/crates/client/src/main.rs b/crates/client/src/main.rs index 6846350..1231e40 100644 --- a/crates/client/src/main.rs +++ b/crates/client/src/main.rs @@ -2,8 +2,7 @@ //! Main entry point for the Synvael client. //! -//! This crate handles window creation, input processing, and drives the -//! renderer to display the game world. +//! This crate handles window creation, input processing, and drives the renderer to display the game world. mod camera; mod meshing; @@ -22,8 +21,7 @@ use winit::window::{CursorGrabMode, Window, WindowId}; /// Transient per-frame input state sampled from window and device events. /// -/// Keyboard fields hold whether a movement key is currently pressed. `mouse_delta` accumulates -/// raw pointer motion between frames and is consumed (reset to zero) once applied to the camera. +/// Keyboard fields hold whether a movement key is currently pressed. `mouse_delta` accumulates raw pointer motion between frames and is consumed (reset to zero) once applied to the camera. // The bools are independent per-key held states, for which a flat struct is the clearest form. #[expect(clippy::struct_excessive_bools)] #[derive(Default)] diff --git a/crates/server/src/main.rs b/crates/server/src/main.rs index 3fa8377..6f967ac 100644 --- a/crates/server/src/main.rs +++ b/crates/server/src/main.rs @@ -2,8 +2,7 @@ //! Dedicated server for Synvael. //! -//! The server handles the authoritative game simulation, including world -//! management, physics, and combat. +//! The server handles the authoritative game simulation, including world management, physics, and combat. /// A bounded LRU cache of regenerated chunk baselines, shared across the worker pool. pub mod chunk_cache; diff --git a/crates/server/src/save.rs b/crates/server/src/save.rs index a217fa4..9f6781d 100644 --- a/crates/server/src/save.rs +++ b/crates/server/src/save.rs @@ -2,11 +2,8 @@ //! Server-side persistence: the durability layer over the `shared` save format. //! -//! `shared::save` owns the pure, in-memory framing (the `SYNR` index and `SYNC` records). This -//! module owns the filesystem side: reading a `.region` file into memory, mutating its chunks, and -//! flushing it back to disk crash-safely. The write strategy is a whole-file atomic rewrite -//! (`.tmp` + fsync + rename); the on-disk format is unchanged, so a later slice can switch to an -//! append-in-place strategy without a format change. +//! `shared::save` owns the pure, in-memory framing (the `SYNR` index and `SYNC` records). +//! This module owns the filesystem side: reading a `.region` file into memory, mutating its chunks, and flushing it back to disk crash-safely. The write strategy is a whole-file atomic rewrite (`.tmp` + fsync + rename); the on-disk format is unchanged. mod region_actor; mod region_file; diff --git a/crates/shared/src/lib.rs b/crates/shared/src/lib.rs index 9d0b525..cfa695b 100644 --- a/crates/shared/src/lib.rs +++ b/crates/shared/src/lib.rs @@ -2,8 +2,7 @@ //! Shared types and logic for Synvael. //! -//! This crate contains data structures and constants that are used by both -//! the client and the server. +//! This crate contains data structures and constants that are used by both the client and the server. pub mod generator; pub mod save;