1
Fork 0
mirror of https://github.com/redstrate/Kawari.git synced 2025-04-19 22:36:49 +00:00

Fix various Clippy warnings

This commit is contained in:
Joshua Goins 2025-04-14 16:24:46 -04:00
parent 79f3ac73b6
commit ba91ca4291
4 changed files with 8 additions and 12 deletions

View file

@ -189,7 +189,7 @@ async fn account(State(state): State<LoginServerState>, jar: CookieJar) -> Html<
}
}
async fn logout(State(state): State<LoginServerState>, jar: CookieJar) -> (CookieJar, Redirect) {
async fn logout(jar: CookieJar) -> (CookieJar, Redirect) {
let config = get_config();
// TODO: remove session from database
(

View file

@ -25,7 +25,7 @@ use kawari::world::{
ChatHandler, Zone, ZoneConnection,
ipc::{
ActorControlCategory, ActorControlSelf, CommonSpawn, PlayerEntry, PlayerSetup, PlayerSpawn,
PlayerStats, SocialList,
SocialList,
},
};
@ -238,11 +238,8 @@ async fn client_server_loop(
mut data: Receiver<FromServer>,
internal_send: UnboundedSender<FromServer>,
) {
loop {
match data.recv().await {
Some(msg) => internal_send.send(msg).unwrap(),
None => break,
}
while let Some(msg) = data.recv().await {
internal_send.send(msg).unwrap()
}
}
@ -446,17 +443,17 @@ async fn client_loop(
connection.handle.send(ToServer::ActorSpawned(connection.id, Actor { id: ObjectId(connection.player_data.actor_id), hp: 100, spawn_index: 0 }, connection.get_player_common_spawn(None, None))).await;
}
ClientZoneIpcData::Unk1 {
category, param1, ..
category, ..
} => {
tracing::info!("Recieved Unk1! {category:#?}");
match category {
/*match category {
3 => {
// set target
tracing::info!("Targeting actor {param1}");
}
_ => {}
}
}*/
}
ClientZoneIpcData::Unk2 { .. } => {
tracing::info!("Recieved Unk2!");

View file

@ -99,7 +99,7 @@ pub(crate) fn write_packed_rotation_float(float: &f32) -> u8 {
(0x80 as f32 * (float + pi) / pi) as u8
}
pub(crate) fn read_packed_rotation_float(packed: u8) -> f32 {
pub(crate) fn read_packed_rotation_float(_packed: u8) -> f32 {
0.0
}

View file

@ -300,7 +300,6 @@ impl ZoneConnection {
speed: 0x3C,
unk1: 0xEA,
position,
..Default::default()
}),
..Default::default()
};