Exemple #1
0
        public MoveAI(ServerNpc parentNpc)
        {
            _parentNpc = parentNpc;

            var size = parentNpc.DynamicEntity.DefaultSize;
            var bb   = new BoundingBox(Vector3.Zero, size);

            size.Y = 0;
            bb     = bb.Offset(-size / 2);

            VerletSimulator = new VerletSimulator(ref bb);
            VerletSimulator.ConstraintFct += Npc.Server.LandscapeManager.IsCollidingWithTerrain;
            VerletSimulator.StartSimulation(parentNpc.DynamicEntity.Position);

            FollowKeepDistance = 3;
            FollowStayDistance = 5;
        }
Exemple #2
0
 public FocusAI(ServerNpc parentNpc)
 {
     _parentNpc = parentNpc;
 }