add player state tracking: introduce State field to room struct, include state in player updates
All checks were successful
Dynamic Branch Deploy / build-and-deploy (push) Successful in 1m52s
All checks were successful
Dynamic Branch Deploy / build-and-deploy (push) Successful in 1m52s
This commit is contained in:
@@ -30,6 +30,7 @@ type ServerPlayer struct {
|
||||
BonusScore int // Score aus Coins und anderen Boni
|
||||
IsAlive bool
|
||||
IsSpectator bool
|
||||
State string // Aktueller State (z.B. Emote)
|
||||
|
||||
// Powerups
|
||||
HasDoubleJump bool // Doppelsprung aktiv?
|
||||
@@ -913,6 +914,7 @@ func (r *Room) Broadcast() {
|
||||
Y: p.Y,
|
||||
VX: p.VX,
|
||||
VY: p.VY,
|
||||
State: p.State,
|
||||
OnGround: p.OnGround,
|
||||
OnWall: p.OnWall,
|
||||
LastInputSeq: p.LastInputSeq,
|
||||
|
||||
Reference in New Issue
Block a user