wip
This commit is contained in:
+1
-7
@@ -100,13 +100,7 @@ int main() {
|
||||
player.get_horizontal_collision(wall_list);
|
||||
player.horizontal_no_out_of_bounds(line);
|
||||
|
||||
if(player.get_velocity().x > 4) {
|
||||
player.set_velocity_x(player.get_velocity().x - player.m_acceleration);
|
||||
}
|
||||
|
||||
// Handle Vertical movement and collisions
|
||||
player.set_velocity_y(player.get_velocity().y + player.m_acceleration);
|
||||
player.rect.move({0, player.get_velocity().y});
|
||||
player.handle_gravity();
|
||||
|
||||
if(!player.get_vertical_bottom_collision(wall_list)) {
|
||||
player.get_vertical_top_collision(wall_list);
|
||||
|
||||
Reference in New Issue
Block a user