From 2775fbd9101127d9e4c8c03458461d54f636ab41 Mon Sep 17 00:00:00 2001 From: Alma Dejus Date: Mon, 11 Dec 2023 10:03:12 +0100 Subject: [PATCH] cleanup in Player.cc file, Alma och Malin --- src/Player.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Player.cc b/src/Player.cc index cec7c49..670f05e 100644 --- a/src/Player.cc +++ b/src/Player.cc @@ -4,7 +4,7 @@ #include "Context.h" #include "constants.h" -Player::Player(sf::Texture& player_txtr, sf::Texture& sack_txtr, json& params) : +Player::Player(sf::Texture& player_txtr, sf::Texture& sack_txtr, json& params): collected{0}, rotation{params["degrees_per_second"]}, tumble_degrees{0}, @@ -93,7 +93,7 @@ void Player::update(Context& context) void Player::move(bool forward) { - position += static_cast(pow(-1, forward - 1)) * max_speed * direction; + position += static_cast(pow(-1, forward - 1)) * max_speed*direction; sprite.setPosition(position); sack.setPosition(position + sack_offset); } -- 2.30.2