diff --git a/worldsrv/player.go b/worldsrv/player.go index 09c34d2..9e83981 100644 --- a/worldsrv/player.go +++ b/worldsrv/player.go @@ -320,6 +320,15 @@ func (this *Player) OnLogined() { this.VIP = rand.Int31n(6) + 1 //机器人随机vip和头像 this.RobRandVip() + //随机机器人宠物技能等级 + if this.Pets.SkillInfo == nil { + this.Pets.SkillInfo = make(map[int32]map[int32]int32) + for petId, _ := range this.Pets.ModUnlock { + skillLevel := rand.Int31n(10) + 1 + this.Pets.SkillInfo[petId] = make(map[int32]int32) + this.Pets.SkillInfo[petId][10001] = skillLevel + } + } } this.VipExtra = VipMgrSington.GetVipPointsExtra(this.Platform, this.VIP)