Esempio n. 1
0
        // Note: Properties… if $name= found, then this is name.
        // If name is cargo then this is a cargo bay.
        private void ParseDockPointSection()
        {
            int dockPointCount = reader.ReadInt();

            for (int i = 0; i < dockPointCount; i++)
            {
                DockPoint dockPoint = new DockPoint();
                dockPoint.properties = reader.ReadString();
                dockPoint.pathNumber = reader.ReadIntArray(reader.ReadInt());

                int pointCount = reader.ReadInt();
                dockPoint.points = new PositionNormal[pointCount];

                for (int j = 0; j < pointCount; j++)
                {
                    dockPoint.points[j].point  = reader.ReadVector3();
                    dockPoint.points[j].normal = reader.ReadVector3();
                }

                model.dockPoints.Add(dockPoint);
            }
        }