Skip to content

Commit 1ba1d5b

Browse files
committed
fix
1 parent 50c7dcc commit 1ba1d5b

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

crates/game/src/lib.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ use systems::director::director_cfg_path;
2828
use systems::director::{DirectorPlugin, DirectorState, LegContext, WheelState};
2929
use systems::economy::{load_rulepack, Pp, RouteId, Rulepack, Weather};
3030
use systems::trading::TradingPlugin;
31+
use systems::gameplay::los::LOSPlugin;
3132
use ui::hub_trade::HubTradePlugin;
3233
use ui::route_planner::RoutePlannerPlugin;
3334

@@ -222,6 +223,7 @@ fn build_app(options: &CliOptions, context: LegContext) -> App {
222223
}
223224
}
224225
app.add_plugins(DirectorPlugin);
226+
app.add_plugins(LOSPlugin);
225227
app
226228
}
227229

crates/game/src/systems/gameplay/drift.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,8 +120,9 @@ mod tests {
120120
// Fog drift should be zero per config
121121
assert_eq!(drift_fog, 0, "Fog drift should be 0 per config");
122122

123-
// Rains and Windy should have positive drift
124-
assert!(drift_rains >= 0, "Rains drift should be >= 0");
125-
assert!(drift_windy >= 0, "Windy drift should be >= 0");
123+
// Rains and Windy should have drift in absolute terms (drift offset can be positive or negative)
124+
// Check that the absolute value is reasonable and non-zero for active weather types
125+
assert!(drift_rains.abs() > 0, "Rains should have non-zero drift offset (can be positive or negative)");
126+
assert!(drift_windy.abs() > 0, "Windy should have non-zero drift offset (can be positive or negative)");
126127
}
127128
}

crates/game/src/systems/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ pub mod board_cache;
22
pub mod command_queue;
33
pub mod director;
44
pub mod economy;
5+
pub mod gameplay;
56
pub mod migrations;
67
pub mod save;
78
pub mod trading;

0 commit comments

Comments
 (0)