Human AI with pathfinding and room hazard avoidance
This commit is contained in:
@@ -45,7 +45,7 @@ namespace Barotrauma
|
||||
|
||||
position.X += Rand.Range(-0.5f, 0.5f);
|
||||
position.Y += Rand.Range(-0.5f, 0.5f);
|
||||
monsters[i] = new AICharacter(characterFile, position);
|
||||
monsters[i] = Character.Create(characterFile, position);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ namespace Barotrauma
|
||||
{
|
||||
Vector2 position = level.PositionsOfInterest[Rand.Int(level.PositionsOfInterest.Count, false)];
|
||||
|
||||
monster = new AICharacter(monsterFile, ConvertUnits.ToSimUnits(position+level.Position));
|
||||
monster = Character.Create(monsterFile, ConvertUnits.ToSimUnits(position+level.Position));
|
||||
}
|
||||
|
||||
public override void Update(float deltaTime)
|
||||
|
||||
Reference in New Issue
Block a user