Phase 1: Core Movement & Rendering
In Phase 1 we build the foundation of the game world: a procedurally generated dungeon that the Miyoo can render efficiently using chunk loading and culling. By the end you will walk around a real dungeon generated on the Rust server.
Implement smooth top-down movement and efficient tile-based rendering with spatial chunking on the Miyoo while the Rust server generates and manages the dungeon.
A Miyoo binary where you can freely walk around a server-generated dungeon (room + corridor style) with responsive controls and low latency over WiFi.
Room + corridor algorithm (simple & reliable)
In the Rust server crate, create a Dungeon struct that generates a grid (e.g. 64Γ64 tiles) using:
// Example skeleton in shared or server
pub struct Dungeon {
pub width: u32,
pub height: u32,
pub tiles: Vec<TileType>,
pub rooms: Vec<Room>,
pub seed: u64,
}
This runs entirely on the server. The client never generates the map β it only receives tile data.
Expand the shared Packet enum to support dungeon loading:
pub enum Packet {
// ... previous packets
EnterDungeon { dungeon_id: u64, seed: u64 },
DungeonData { width: u32, height: u32, tiles: Vec<u8> }, // compressed tile IDs
PlayerPosition { x: f32, y: f32 },
WorldSnapshot { entities: Vec<EntityState> },
}
Use bincode for compact binary serialization to keep WiFi traffic minimal.
This is the most important performance optimization for the Miyoo.
Why chunks matter on Miyoo: Rendering the entire 64Γ64 map every frame would be too slow. Chunking reduces draw calls dramatically.
Implement smooth local movement on the Miyoo while sending inputs to the server:
Create a manager that:
On the client: simple AABB collision against tile data received from server.
Camera follows the player with slight smoothing. Keep the visible world centered.
Key tests to run:
You now have a playable world. Phase 2 (Combat & Abilities) will feel very rewarding after this foundation.