コード例 #1
0
        /// <summary>
        /// Creates a new asteroid belt shape from an MySystemBeltItem
        /// </summary>
        /// <param name="belt">The belt it should create the shape for.</param>
        /// <returns>The shape representation of the given belt</returns>
        public static AsteroidBeltShape CreateFromBeltItem(MySystemBeltItem belt)
        {
            AsteroidBeltShape shape = new AsteroidBeltShape();

            shape.center = Vector3D.Zero;
            shape.radius = belt.Radius;
            shape.width  = belt.Width;
            shape.height = belt.Height;

            return(shape);
        }
コード例 #2
0
        public static AsteroidBeltShape CreateFromRingItem(MySystemBeltItem ring)
        {
            AsteroidBeltShape shape = new AsteroidBeltShape();

            shape.center = Vector3D.Zero;
            shape.radius = ring.Radius;
            shape.width  = ring.Width;
            shape.height = ring.Height;

            return(shape);
        }