From f19683c1b19282b1b1aee22a9b86a2e95c4b38e0 Mon Sep 17 00:00:00 2001 From: griffi-gh Date: Mon, 13 Feb 2023 02:01:25 +0100 Subject: [PATCH] remove `pub` from functions --- kubi/src/networking.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/kubi/src/networking.rs b/kubi/src/networking.rs index fb8f53e..8c50747 100644 --- a/kubi/src/networking.rs +++ b/kubi/src/networking.rs @@ -1,4 +1,4 @@ -use shipyard::{Unique, AllStoragesView, UniqueView, UniqueViewMut, Workload, IntoWorkload, EntitiesViewMut, Component, ViewMut, SystemModificator}; +use shipyard::{Unique, AllStoragesView, UniqueView, UniqueViewMut, Workload, IntoWorkload, EntitiesViewMut, Component, ViewMut, SystemModificator, View, IntoIter}; use glium::glutin::event_loop::ControlFlow; use std::net::SocketAddr; use kubi_udp::client::{Client, ClientConfig, ClientEvent}; @@ -24,7 +24,7 @@ pub struct UdpClient(pub Client); #[derive(Component)] pub struct NetworkEvent(pub ClientEvent); -pub fn create_client( +fn create_client( storages: AllStoragesView ) { log::info!("Creating client"); @@ -36,7 +36,7 @@ pub fn create_client( storages.add_unique(ClientJoinState::Disconnected); } -pub fn connect_client_if_needed( +fn connect_client_if_needed( mut client: UniqueViewMut ) { //NOTE: this used to be a condition function @@ -47,13 +47,13 @@ pub fn connect_client_if_needed( } } -pub fn update_client( +fn update_client( mut client: UniqueViewMut, ) { client.0.update().unwrap(); } -pub fn insert_client_events( +fn insert_client_events( mut client: UniqueViewMut, mut entities: EntitiesViewMut, mut events: ViewMut,