diff --git a/bin/json/game_opencond.json b/bin/json/game_opencond.json index f8415a0a6..84b104f5e 100644 --- a/bin/json/game_opencond.json +++ b/bin/json/game_opencond.json @@ -74,11 +74,11 @@ "main": [ { "key": 1, - "param": 1 + "param": 30 } ], "optional": "", - "wkqbx": 0, + "wkqbx": 2, "kqbx": 0, "img": "zc_icon_01", "prompt": { @@ -844,7 +844,7 @@ "main": [ { "key": 1, - "param": 1 + "param": 100 } ], "optional": "", diff --git a/modules/gateway/agent.go b/modules/gateway/agent.go index 600707451..ef6f7f6e0 100644 --- a/modules/gateway/agent.go +++ b/modules/gateway/agent.go @@ -97,12 +97,6 @@ locp: code, err = this.secAuth(msg) if err == nil { this.gateway.Debugf("----------2 agent:%s uId:%s MainType:%s SubType:%s ", this.sessionId, this.uId, msg.MainType, msg.SubType) - - if err := this.messageDistribution(msg); err != nil { - this.gateway.Errorf("messageDistribution err:%v", err) - go this.Close() - break locp - } if this.uId != "" { key := this.uId + msg.MainType + msg.SubType // 加锁 if v, ok := this.protoMsg[key]; ok { @@ -111,7 +105,6 @@ locp: this.hlock.Lock() this.protoMsg[key] = configure.Now().Unix() this.hlock.Unlock() - data, _ := anypb.New(&pb.NotifyErrorNotifyPush{ ReqMainType: msg.MainType, ReqSubType: msg.SubType, @@ -122,7 +115,7 @@ locp: SubType: comm.SubTypeErrorNotify, Data: data, }) - return + continue } } this.hlock.Lock() @@ -130,6 +123,12 @@ locp: this.hlock.Unlock() } + if err := this.messageDistribution(msg); err != nil { + this.gateway.Errorf("messageDistribution err:%v", err) + go this.Close() + break locp + } + } else { this.gateway.Errorf("agent:%s uId:%s 密钥无效 err:%v", this.sessionId, this.uId, err) data, _ := anypb.New(&pb.NotifyErrorNotifyPush{ReqMainType: msg.MainType, ReqSubType: msg.SubType, Code: code, Message: err.Error()})