This commit is contained in:
flswld committed 2024-04-24 18:36:32 +08:00
1 parent 721a871890
commit 2cb9f89cae
1 file changed
+4 -1
+4 -1
View File
@@ -1273,7 +1273,10 @@ func (g *Game) CreateConfigEntity(scene *Scene, groupId uint32, entityConfig any
monster := entityConfig.(*gdconf.Monster)
// TODO 怪物等级与世界等级的关联
worldLevel := owner.PropMap[constant.PLAYER_PROP_PLAYER_WORLD_LEVEL]
monsterLevel := uint8(float32(monster.Level) * float32(worldLevel+1) * 0.25)
monsterLevel := uint8(monster.Level) * uint8(worldLevel+1)
if monsterLevel > 100 {
monsterLevel = 100
}
return scene.CreateEntityMonster(
&model.Vector{X: float64(monster.Pos.X), Y: float64(monster.Pos.Y), Z: float64(monster.Pos.Z)},
&model.Vector{X: float64(monster.Rot.X), Y: float64(monster.Rot.Y), Z: float64(monster.Rot.Z)},