An NPC subclass defining the Ao Nyobo character. It sets model path and movement/vision parameters and adjusts world scale on start.
using Sandbox;
namespace BrickJam;
[Title( "Ao Nyobo" )]
[Category( "NPC" )]
public sealed partial class AoNyobo : NPC
{
public override string ModelPath { get; set; } = "models/nyobo/nyobo.vmdl";
public override float WalkSpeed { get; set; } = 80f;
public override float RunSpeed { get; set; } = 260f;
public override float MaxVisionAngle { get; set; } = 240f;
public override float MaxVisionRange { get; set; } = 700f;
// Chasing vision must be LONGER than normal (it was 600 < 700, so a locked-on target - especially a
// fast-fleeing Doob - slipped out of sight at 600u and the monster gave up the chase).
public override float MaxVisionRangeWhenChasing { get; set; } = 1500f;
public override float MaxVisionAngleWhenChasing { get; set; } = 180f;
protected override void OnStart()
{
base.OnStart();
GameObject.WorldScale = 1.1f;
}
}