From f98949201942fa15e53a71adcc08914837f55358 Mon Sep 17 00:00:00 2001 From: sk <123456@qq.com> Date: Thu, 14 Nov 2024 15:07:51 +0800 Subject: [PATCH] =?UTF-8?q?tienlen=E6=88=BF=E5=8D=A1=E5=9C=BA=E4=B8=8D?= =?UTF-8?q?=E8=83=BD=E4=B8=AD=E9=80=94=E7=A6=BB=E5=BC=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- gamesrv/tienlen/scenepolicy_tienlen.go | 6 ++++-- worldsrv/addmail.go | 4 ++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/gamesrv/tienlen/scenepolicy_tienlen.go b/gamesrv/tienlen/scenepolicy_tienlen.go index 7283010..5a249ae 100644 --- a/gamesrv/tienlen/scenepolicy_tienlen.go +++ b/gamesrv/tienlen/scenepolicy_tienlen.go @@ -591,8 +591,10 @@ func (this *SceneBaseStateTienLen) CanChangeTo(s base.SceneState) bool { // 当前状态能否换桌 func (this *SceneBaseStateTienLen) CanChangeCoinScene(s *base.Scene, p *base.Player) bool { - if s.IsCustom() && s.GetNumOfGames() > 0 { - return false + if s.IsCustom() { + if s.NumOfGames > 0 && s.NumOfGames < int(s.TotalOfGames) { + return false + } } return !p.IsGameing() || s.GetDestroyed() || !s.GetGaming() } diff --git a/worldsrv/addmail.go b/worldsrv/addmail.go index 379b81d..dc48d36 100644 --- a/worldsrv/addmail.go +++ b/worldsrv/addmail.go @@ -41,6 +41,10 @@ func AddMail(param *AddMailParam) { return } + if param.SrcName == "" { + param.SrcName = "{\"zh\":\"系统\",\"vi\":\"GM\",\"en\":\"GM\",\"kh\":\"GM\"}" + } + opener := int32(1) if param.SrcId <= 0 { opener = 0