Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: Player/Player.cpp
- Revision:
- 14:58887d7e1072
- Parent:
- 11:b3024ab59fa5
--- a/Player/Player.cpp Wed May 27 04:36:22 2020 +0000
+++ b/Player/Player.cpp Wed May 27 07:48:27 2020 +0000
@@ -27,7 +27,6 @@
{
if(_dir == E) {
Bitmap bit_player(s_player, 8, 9);
- Bitmap bit_player2(s_player2, 8, 9);
bit_player.render(lcd, _playerX, _playerY);
}
@@ -59,7 +58,7 @@
case 0:
//FREE FALL
if( fall == true) {
- _playerY = _playerY + 4;
+ _playerY = _playerY + GRAVITY ;
}
//FLOOR COLLISION
@@ -70,7 +69,7 @@
case 1:
//JUMP UNTIL TWICE PLAYER HEIGHT
- _playerY -= 5;
+ _playerY -= GRAVITY +1;
break;