Skip to content

Commit

Permalink
simplify
Browse files Browse the repository at this point in the history
  • Loading branch information
KilledByAPixel committed Nov 25, 2024
1 parent 6fd7bad commit 9a97f92
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/platformer/gameCharacter.js
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ class Character extends GameObject

// apply movement acceleration and clamp
const maxCharacterSpeed = .2;
this.velocity.x = clamp(this.velocity.x + moveInput.x * .042, -maxCharacterSpeed, maxCharacterSpeed);
this.velocity.x = clamp(this.velocity.x + moveInput.x * .04, -maxCharacterSpeed, maxCharacterSpeed);

// track last pos for ladder collision code
this.lastPos = this.pos.copy();
Expand Down

0 comments on commit 9a97f92

Please sign in to comment.