コード例 #1
0
ファイル: DataTypes.cs プロジェクト: zdimension/FreeRaider
 /// <summary>
 /// Initializes a new instance of the <see cref="RoomVertex"/> class.
 /// </summary>
 public RoomVertex(Vertex vertex, short lighting1,
     SpecialRenderingEffects attributes = SpecialRenderingEffects.Normal, short lighting2 = 0,
     Vertex normal = default(Vertex), FloatColor color = default(FloatColor))
 {
     Vertex = vertex;
     Lighting1 = lighting1;
     Attributes = attributes;
     Lighting2 = lighting2;
     Normal = normal;
     Color = color;
 }
コード例 #2
0
ファイル: DataTypes.cs プロジェクト: zdimension/FreeRaider
 /// <summary>
 /// Initializes a new instance of the <see cref="RoomStaticMesh"/> class.
 /// </summary>
 public RoomStaticMesh(Vertex position, float rotation, short intensity1, short intensity2, ushort objectId,
     FloatColor tint)
 {
     Position = position;
     Rotation = rotation;
     Intensity1 = originalI1 = intensity1;
     Intensity2 = originalI2 = intensity2;
     ObjectID = objectId;
     Tint = tint;
 }
コード例 #3
0
ファイル: Resource.cs プロジェクト: zdimension/FreeRaider
        // Helper functions to convert legacy TR structs to native OpenTomb structs.

        /// <summary>
        /// v[] of length 4
        /// </summary>
        public static float[] TR_color_to_arr(FloatColor tr_c)
        {
            return new[] {tr_c.R * 2, tr_c.G * 2, tr_c.B * 2, tr_c.A * 2};
        }