From a7e2c8fbf481d6e6584d0a4518191b141014e85e Mon Sep 17 00:00:00 2001 From: Jeroen Schweitzer Date: Thu, 12 Feb 2026 01:45:47 +0100 Subject: [PATCH] feat(simulation): add proof room with wall and NPC (#357) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Wall at (16,14) and NPC at (16,13) for Sprint 2 fog-of-perception proof. Player starts at (16,16) — NPC hidden behind wall until player moves around it. Co-Authored-By: Claude Opus 4.6 --- server/src/main.rs | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/server/src/main.rs b/server/src/main.rs index 96918aaf8..29ee34cb1 100644 --- a/server/src/main.rs +++ b/server/src/main.rs @@ -7,6 +7,7 @@ use tracing_subscriber::{layer::SubscriberExt, util::SubscriberInitExt}; use settled_reach_server::bridge::tcp::TcpBridge; use settled_reach_server::bridge::{BridgePlugin, BridgeResource, ServerRunning}; use settled_reach_server::knowledge::{KnowledgeGraph, KnowledgePlugin}; +use settled_reach_server::npc::Npc; use settled_reach_server::perception::vision_cone::Facing; use settled_reach_server::simulation::movement::{PlayerCharacter, TilePosition, WalkabilityMap}; use settled_reach_server::simulation::SimulationPlugin; @@ -42,12 +43,22 @@ fn main() { app.add_plugins(KnowledgePlugin); app.insert_resource(BridgeResource::new(bridge)); app.insert_resource(WalkabilityMap::new(32, 32, 1)); + + // Proof room: wall at (16,14) between player and NPC + // NPC at (16,13) hidden behind wall until player moves around it + { + let mut wm = app.world_mut().resource_mut::(); + wm.set_walkable(&TilePosition::new(16, 14, 0), false); + } + app.world_mut().spawn(( PlayerCharacter, TilePosition::new(16, 16, 0), Facing::default(), KnowledgeGraph::new(), )); + app.world_mut() + .spawn((Npc, TilePosition::new(16, 13, 0))); tracing::info!("Simulation initialized, entering game loop");