diff --git a/comm/const.go b/comm/const.go index 074b386fb..73391a68a 100644 --- a/comm/const.go +++ b/comm/const.go @@ -674,6 +674,7 @@ const ( Rtype186 TaskType = 186 //武馆的派遣悬赏X次(接取任务后开始计算,当玩家的派遣完成1次,进度便加一,不领奖也算一次,只要倒计时结束即可) Rtype187 TaskType = 187 Rtype188 TaskType = 188 //玩家创建1个工会 + Rtype189 TaskType = 189 //铁匠铺进行一次定制 ) const ( diff --git a/modules/smithy/api_forgeequip.go b/modules/smithy/api_forgeequip.go index 7af50b54a..582907e5a 100644 --- a/modules/smithy/api_forgeequip.go +++ b/modules/smithy/api_forgeequip.go @@ -309,6 +309,23 @@ func (this *apiComp) ForgeEquip(session comm.IUserSession, req *pb.SmithyForgeEq }(v.CId, equipConf.Star, int32(len(v.AdverbEntry)+1)) // 品质按副词条数+1 来算 } } - this.module.SendRdTask(session, atno) + var equip map[int32]int32 // key xingji value 数量 + equip = make(map[int32]int32, 0) + tasks := make([]*pb.BuriedParam, 0) + for _, v := range atno { + if cfg := this.module.configure.GetEquipmentConfigureById(v.T); cfg != nil { + equip[cfg.Star]++ + } + } + for k, v := range equip { + tasks = append(tasks, comm.GetBuriedParam(comm.Rtype51, v, k)) + } + // 定制 + if req.SuiteId != 0 { + tasks = append(tasks, comm.GetBuriedParam(comm.Rtype189, req.Count)) // 进行N次定制打造 + } + tasks = append(tasks, comm.GetBuriedParam(comm.Rtype148, int32(len(equip)))) + this.module.ModuleBuried.TriggerBuried(session.GetUserId(), tasks...) + return } diff --git a/modules/smithy/module.go b/modules/smithy/module.go index 8bb3a4e8b..d4a53720c 100644 --- a/modules/smithy/module.go +++ b/modules/smithy/module.go @@ -119,21 +119,3 @@ func (this *Smithy) CheckActivateAtlasCollect(uid string, id string) { } return } - -func (this *Smithy) SendRdTask(session comm.IUserSession, Items []*pb.UserAtno) { - var equip map[int32]int32 // key xingji value 数量 - equip = make(map[int32]int32, 0) - tasks := make([]*pb.BuriedParam, 0) - for _, v := range Items { - if cfg := this.configure.GetEquipmentConfigureById(v.T); cfg != nil { - equip[cfg.Star]++ - } - } - for k, v := range equip { - tasks = append(tasks, comm.GetBuriedParam(comm.Rtype51, v, k)) - - // this.ModuleBuried.SendToRtask(session, comm.Rtype148, v, k) - } - tasks = append(tasks, comm.GetBuriedParam(comm.Rtype148, int32(len(equip)))) - this.ModuleBuried.TriggerBuried(session.GetUserId(), tasks...) -}