Skip to content

Commit

Permalink
fix: #406
Browse files Browse the repository at this point in the history
  • Loading branch information
Snowiiii committed Dec 24, 2024
1 parent 1d96701 commit 5394910
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions pumpkin/src/entity/player.rs
Original file line number Diff line number Diff line change
Expand Up @@ -562,8 +562,6 @@ impl Player {
"Setting the same gamemode as already is"
);
self.gamemode.store(gamemode);
// The client is using the same method for setting abilities when receiving the CGameEvent ChangeGameMode packet.
// So we can just update the abilities without sending them.
{
// use another scope so we instantly unlock abilities
let mut abilities = self.abilities.lock().await;
Expand All @@ -587,6 +585,7 @@ impl Player {
}
}
}
self.send_abilities_update().await;
self.living_entity
.entity
.world
Expand Down Expand Up @@ -796,7 +795,7 @@ impl Default for Abilities {
flying: false,
allow_flying: false,
creative: false,
fly_speed: 0.4,
fly_speed: 0.05,
walk_speed_fov: 0.1,
}
}
Expand Down

0 comments on commit 5394910

Please sign in to comment.