比赛场优化
This commit is contained in:
parent
4c4af75a76
commit
f0f2831ba0
|
@ -2059,17 +2059,17 @@ func (this *Tournament) OnHourTimer() {
|
|||
}
|
||||
}
|
||||
for sortId := range this.players {
|
||||
has := false
|
||||
for _, tm := range this.matches {
|
||||
if _, ok := tm[sortId]; !ok {
|
||||
for _, v := range this.players[sortId] {
|
||||
if v != nil {
|
||||
logger.Logger.Errorf("比赛异常,比赛已经不存在了 %v", v.tm)
|
||||
}
|
||||
break
|
||||
}
|
||||
this.StopMatch(0, sortId)
|
||||
if _, ok := tm[sortId]; ok {
|
||||
has = true
|
||||
break
|
||||
}
|
||||
}
|
||||
if !has {
|
||||
logger.Logger.Errorf("比赛异常,比赛已经不存在了 %v", sortId)
|
||||
delete(this.players, sortId)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue