Private
Public Access
1
0

Refine player movement and physics constants for improved 20 TPS gameplay, add reusable config values, enhance button loading states, and prevent duplicate game starts. Update cache-busting version for client assets.
All checks were successful
Dynamic Branch Deploy / build-and-deploy (push) Successful in 2m3s

This commit is contained in:
Sebastian Unterschütz
2026-01-05 21:04:39 +01:00
parent dc5136ca21
commit 66d7b6d2a5
7 changed files with 106 additions and 32 deletions

View File

@@ -362,11 +362,12 @@ func (g *Game) DrawGame(screen *ebiten.Image) {
sprite := "player" // Default: am Boden
// Nur Jump-Animation wenn wirklich in der Luft
// (nicht auf Boden, nicht auf Platform mit VY ~= 0)
isInAir := !onGround && (vy < -1.0 || vy > 1.0)
// Bei 20 TPS größerer Threshold (3.0 statt 1.0)
// OnGround oder sehr kleine VY = am Boden/Plattform
isInAir := !onGround && (vy < -3.0 || vy > 3.0)
if isInAir {
if vy < -2.0 {
if vy < -5.0 {
// Springt nach oben
sprite = "jump0"
} else {