Convert game loggers to observers

These functions don't really do anything, I just want to have the code in place for reference
This commit is contained in:
Michael Bradley 2025-10-18 17:49:56 -04:00
parent af11fa97fb
commit 46f00e2047
Signed by: MichaelBradley
SSH key fingerprint: SHA256:BKO2eI2LPsCbQS3n3i5SdwZTAIV3F1lHezR07qP+Ob0
2 changed files with 13 additions and 26 deletions

View file

@ -74,20 +74,13 @@ impl Plugin for GamePlugin {
)
.add_systems(
OnEnter(AppState::InGame),
(
setup_from_seed,
(setup_player, setup_balls, setup_walls).after(setup_from_seed),
),
(setup_from_seed, (setup_player, setup_balls, setup_walls)).chain(),
)
.add_systems(
FixedUpdate,
(
check_for_seed.run_if(in_state(AppState::Loading)),
(
handle_new_peer,
handle_deleted_peer,
handle_incoming_packets,
),
handle_incoming_packets,
),
)
.add_systems(
@ -103,7 +96,9 @@ impl Plugin for GamePlugin {
),
quit.run_if(input_pressed(KeyCode::KeyQ)),
),
);
)
.add_observer(handle_new_peer)
.add_observer(handle_deleted_peer);
match self.source {
DataSource::Address(peer) => {