fix:游戏记录时长

This commit is contained in:
sk 2024-12-16 15:43:06 +08:00
parent 31794d1f1e
commit 71f07c2e5e
1 changed files with 2 additions and 2 deletions

View File

@ -658,7 +658,7 @@ func (this *Player) ReportGameEvent(param *ReportGameEventParam) *ReportGameEven
isNew = 1
}
if param.GameTime < 0 {
if param.GameTime <= 0 {
param.GameTime = int64(time.Now().Sub(this.scene.GameNowTime).Seconds())
}
if param.GameTime < 0 {
@ -679,7 +679,7 @@ func (this *Player) ReportGameEvent(param *ReportGameEventParam) *ReportGameEven
ModeId: this.scene.GameMode,
Tax: param.Tax,
Amount: param.Change,
CreateTime: this.CreateTime.Unix(),
CreateTime: time.Now().Unix(),
CreateDayTime: tCreateDay.Unix(),
Out: param.Out,
In: param.In,