fix: change reliable flag to false in BroadcastToPresences function
This commit is contained in:
parent
7ee2d7b3b8
commit
75b5ccd2e3
2 changed files with 3 additions and 1 deletions
|
|
@ -97,7 +97,7 @@ func BroadcastToPresences(tick int64, lobbyState *MatchState, logger *runtime.Lo
|
||||||
if err != nil {
|
if err != nil {
|
||||||
(*logger).Error("Error marshalling bullet data", err)
|
(*logger).Error("Error marshalling bullet data", err)
|
||||||
} else {
|
} else {
|
||||||
reliable := true
|
reliable := false
|
||||||
(*dispatcher).BroadcastMessage(STATE_UPDATE, data, nil, nil, reliable)
|
(*dispatcher).BroadcastMessage(STATE_UPDATE, data, nil, nil, reliable)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import (
|
||||||
"danmaku/ffi"
|
"danmaku/ffi"
|
||||||
"math"
|
"math"
|
||||||
"slices"
|
"slices"
|
||||||
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
type PlayerStageState struct {
|
type PlayerStageState struct {
|
||||||
|
|
@ -110,6 +111,7 @@ func (s *PlayerStageState) MakeServerTick(tick int64, serializedNewBullets []map
|
||||||
ForcePlayerPos: s.updatePlayerPos,
|
ForcePlayerPos: s.updatePlayerPos,
|
||||||
DeathTimer: s.deathTimer,
|
DeathTimer: s.deathTimer,
|
||||||
Graze: s.graze,
|
Graze: s.graze,
|
||||||
|
UTCTime: float64(time.Now().UnixMilli()) / 1000.0,
|
||||||
}
|
}
|
||||||
|
|
||||||
// When this is called, we want to transmit updatePlayerPos if it's true once and then reset
|
// When this is called, we want to transmit updatePlayerPos if it's true once and then reset
|
||||||
|
|
|
||||||
Reference in a new issue