diff --git a/modules/hero/module.go b/modules/hero/module.go index 0ac2c5d5a..b4e7c279d 100644 --- a/modules/hero/module.go +++ b/modules/hero/module.go @@ -1035,6 +1035,12 @@ func (this *Hero) PassonHero(session comm.IUserSession, heroObjID map[string]boo return } +// 构建一个虚拟等级的英雄 func (this *Hero) GetVirtualHero(hero *pb.DBHero, lv int32) (vHero *pb.DBHero) { + if vHero == nil || lv <= 0 { + return nil + } + hero.Lv = lv + this.modelHero.PropertyCompute(hero) return hero }