示例#1
0
        private void AddAndTrackNpcs()
        {
            IList <NpcRecord> records = TileMatrix.GetNpcLocations();

            foreach (NpcRecord record in records)
            {
                Npc npc = (Npc)Activator.CreateInstance(record.Type);
                npc.StartPosition = record.Position;
                game.AddAndTrack(npc);
            }
        }