fixed message while changing levels

This commit is contained in:
Joachim Lusiardi 2024-10-23 15:53:28 +02:00
parent 9fb3c83b67
commit 5111fec1fa
1 changed files with 2 additions and 2 deletions

View File

@ -131,7 +131,7 @@ impl Game {
let (next_level, x, y) = self.next_start(); let (next_level, x, y) = self.next_start();
player_level = next_level; player_level = next_level;
self.messages self.messages
.insert(0, format!("you climb down to level {}.", next_level)); .insert(0, format!("you climb down to level {}.", next_level + 1));
self.get_mutable_player() self.get_mutable_player()
.get_position() .get_position()
.set(next_level, x, y); .set(next_level, x, y);
@ -141,7 +141,7 @@ impl Game {
let (next_level, x, y) = self.prev_end(); let (next_level, x, y) = self.prev_end();
player_level = next_level; player_level = next_level;
self.messages self.messages
.insert(0, format!("you climb up to level {}.", next_level)); .insert(0, format!("you climb up to level {}.", next_level + 1));
self.get_mutable_player() self.get_mutable_player()
.get_position() .get_position()
.set(next_level, x, y); .set(next_level, x, y);