From e224d2a4bd7733cb4bc2b9f545fa616c45bfd4ef Mon Sep 17 00:00:00 2001 From: sk <123456@qq.com> Date: Tue, 8 Oct 2024 15:44:16 +0800 Subject: [PATCH 1/2] no message --- shell/update_deploy.bat | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/shell/update_deploy.bat b/shell/update_deploy.bat index c96763a..9d1ec6c 100644 --- a/shell/update_deploy.bat +++ b/shell/update_deploy.bat @@ -2,11 +2,11 @@ set deployDir="..\deploy" xcopy .\data\* %deployDir%\data\ /s /e /y -for /f "tokens=*" %%a in (programs.txt) do ( +for /f "tokens=*" %%a in (shell/programs.txt) do ( xcopy .\%%a\%%a %deployDir% /y del .\%%a\%%a ) -for /f "tokens=*" %%f in (exclude.txt) do ( +for /f "tokens=*" %%f in (shell/exclude.txt) do ( if exist "%deployDir%\data\%%f" (del "%deployDir%\data\%%f") ) \ No newline at end of file From d5332ddb3463aa2d3361b8e1cb7c55b5017d3bcd Mon Sep 17 00:00:00 2001 From: sk <123456@qq.com> Date: Tue, 8 Oct 2024 16:05:47 +0800 Subject: [PATCH 2/2] no message --- worldsrv/player.go | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/worldsrv/player.go b/worldsrv/player.go index 067e9bc..cd1d6bd 100644 --- a/worldsrv/player.go +++ b/worldsrv/player.go @@ -2033,19 +2033,21 @@ func (this *Player) ResetPermit() { // 清理数据 bag := BagMgrSingleton.GetBagInfo(this.SnId) if bag != nil { - BagMgrSingleton.AddItems(&model.AddItemParam{ - Platform: this.Platform, - SnId: this.SnId, - Change: []*model.Item{ - { - ItemId: common.ItemIDPermit, - ItemNum: -bag.BagItem[common.ItemIDPermit].ItemNum, + if bag.BagItem[common.ItemIDPermit] != nil { + BagMgrSingleton.AddItems(&model.AddItemParam{ + Platform: this.Platform, + SnId: this.SnId, + Change: []*model.Item{ + { + ItemId: common.ItemIDPermit, + ItemNum: -bag.BagItem[common.ItemIDPermit].ItemNum, + }, }, - }, - GainWay: common.GainWayPermitReset, - Operator: "system", - Remark: "赛季积分清理", - }) + GainWay: common.GainWayPermitReset, + Operator: "system", + Remark: "赛季积分清理", + }) + } if model.GameParamData.PermitInitScore > 0 { bagInfo := BagMgrSingleton.GetBagInfo(this.SnId)