update
This commit is contained in:
parent
4de830806d
commit
61daf826cc
@ -146,6 +146,10 @@ func (this *modelStove) StoveToolsQualityProbability(stove *pb.DBStove) int32 {
|
||||
if v, ok := stove.Skill[comm.SmithyToolsSkill1]; ok {
|
||||
if conf := this.module.configure.GetSmithySkill(comm.SmithyToolsSkill1, v); conf != nil {
|
||||
return conf.Value
|
||||
} else {
|
||||
if conf := this.module.configure.GetSmithySkill(comm.SmithyToolsSkill1, 0); conf != nil {
|
||||
return conf.Value
|
||||
}
|
||||
}
|
||||
}
|
||||
return 0
|
||||
@ -153,11 +157,14 @@ func (this *modelStove) StoveToolsQualityProbability(stove *pb.DBStove) int32 {
|
||||
|
||||
// 所有装备售价提升{0}%
|
||||
func (this *modelStove) StoveToolsSellUp(uid string) int32 {
|
||||
stove, err := this.module.modelStove.getSmithyStoveList(uid)
|
||||
if err != nil {
|
||||
if stove, err := this.module.modelStove.getSmithyStoveList(uid); err == nil {
|
||||
if v, ok := stove.Skill[comm.SmithyToolsSkill2]; ok {
|
||||
if conf := this.module.configure.GetSmithySkill(comm.SmithyToolsSkill1, v); conf != nil {
|
||||
return conf.Value
|
||||
} else {
|
||||
if conf := this.module.configure.GetSmithySkill(comm.SmithyToolsSkill1, 0); conf != nil {
|
||||
return conf.Value
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -169,6 +176,10 @@ func (this *modelStove) StoveToolsTemperature(stove *pb.DBStove) int32 {
|
||||
if v, ok := stove.Skill[comm.SmithyToolsSkill3]; ok {
|
||||
if conf := this.module.configure.GetSmithySkill(comm.SmithyToolsSkill1, v); conf != nil {
|
||||
return conf.Value
|
||||
} else {
|
||||
if conf := this.module.configure.GetSmithySkill(comm.SmithyToolsSkill1, 0); conf != nil {
|
||||
return conf.Value
|
||||
}
|
||||
}
|
||||
}
|
||||
return 0
|
||||
@ -176,12 +187,15 @@ func (this *modelStove) StoveToolsTemperature(stove *pb.DBStove) int32 {
|
||||
|
||||
//每日顾客数量提升至{0}人
|
||||
func (this *modelStove) StoveSkillAddCustomer(uid string) int32 {
|
||||
stove, err := this.module.modelStove.getSmithyStoveList(uid)
|
||||
if err != nil {
|
||||
if stove, err := this.module.modelStove.getSmithyStoveList(uid); err == nil {
|
||||
if v, ok := stove.Skill[comm.SmithyToolsSkill4]; ok {
|
||||
if conf := this.module.configure.GetSmithySkill(comm.SmithyToolsSkill1, v); conf != nil {
|
||||
return conf.Value
|
||||
}
|
||||
} else {
|
||||
if conf := this.module.configure.GetSmithySkill(comm.SmithyToolsSkill1, 0); conf != nil {
|
||||
return conf.Value
|
||||
}
|
||||
}
|
||||
}
|
||||
return 0
|
||||
@ -189,8 +203,7 @@ func (this *modelStove) StoveSkillAddCustomer(uid string) int32 {
|
||||
|
||||
//顾客购买装备数量上限提高至{0}件
|
||||
func (this *modelStove) StoveSkillBuyEquip(uid string) int32 {
|
||||
stove, err := this.module.modelStove.getSmithyStoveList(uid)
|
||||
if err != nil {
|
||||
if stove, err := this.module.modelStove.getSmithyStoveList(uid); err == nil {
|
||||
if v, ok := stove.Skill[comm.SmithyToolsSkill5]; ok {
|
||||
if conf := this.module.configure.GetSmithySkill(comm.SmithyToolsSkill1, v); conf != nil {
|
||||
return conf.Value
|
||||
|
Loading…
Reference in New Issue
Block a user