diff --git a/worldsrv/player.go b/worldsrv/player.go index 52282dc..422de51 100644 --- a/worldsrv/player.go +++ b/worldsrv/player.go @@ -1122,15 +1122,17 @@ func (this *Player) GetMessageAttach(id string) { } if tp != -1 { - giveType := gainWay + giveType := int32(-1) switch gainWay { case common.GainWayItemPermitRank: giveType = model.SystemFreeGive_GiveType_TaskPermitRank case common.GainWayClientUpgrade: giveType = model.SystemFreeGive_ClientUpgrade } - mq.Write(model.GenerateSystemFreeGive(this.SnId, this.Name, this.Platform, this.Channel, - giveType, tp, msg.Params[i+1])) + if giveType != -1 && msg.Oper == 0 && !this.IsRob { + mq.Write(model.GenerateSystemFreeGive(this.SnId, this.Name, this.Platform, this.Channel, + giveType, tp, msg.Params[i+1])) + } } } BagMgrSingleton.AddItems(&model.AddItemParam{