示例#1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Portal"/> class.
 /// </summary>
 /// <param name="adjRoom">The <see cref="Room"/> this <see cref="Portal"/> leads to</param>
 /// <param name="norm">Which way the <see cref="Portal"/> faces</param>
 /// <param name="vert">The 4 corners of the <see cref="Portal"/></param>
 public Portal(ushort adjRoom, Vertex norm, IEnumerable<Vertex> vert)
 {
     AdjoiningRoom = adjRoom;
     Normal = norm;
     Vertices = vert.ToArray();
 }
示例#2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Light"/> class.
 /// </summary>
 public Light(byte lightType, Vertex position, ByteColor color, float intensity = 0.0f, ushort intensity1 = 0,
     ushort intensity2 = 0, uint fade1 = 0, uint fade2 = 0, byte unknown = 255, float hotspot = 0.0f,
     float falloff = 0.0f, float length = 0.0f,
     float cutoff = 0.0f, Vertex direction = default(Vertex), Vertex position2 = default(Vertex),
     Vertex direction2 = default(Vertex), float radInput = 0.0f, float radOutput = 0.0f, float range = 0.0f)
 {
     this.lightType = lightType;
     Position = position;
     Color = color;
     Intensity = intensity;
     Intensity1 = intensity1;
     Intensity2 = intensity2;
     Fade1 = fade1;
     Fade2 = fade2;
     Unknown = unknown;
     R_Inner = hotspot;
     R_Outer = falloff;
     Length = length;
     Cutoff = cutoff;
     Direction = direction;
     Position2 = position2;
     Direction2 = direction2;
     RadianInput = radInput;
     RadianOutput = radOutput;
     Range = range;
 }
示例#3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="MeshTree"/> class.
 /// </summary>
 public MeshTree(uint flags, Vertex offset)
 {
     Flags = flags;
     Offset = offset;
 }
示例#4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="StaticMesh"/> class.
 /// </summary>
 public StaticMesh(uint objectId, ushort mesh, Vertex[] visibilityBox, Vertex[] collisionBox, ushort flags)
 {
     ObjectID = objectId;
     Mesh = mesh;
     VisibilityBox = visibilityBox;
     CollisionBox = collisionBox;
     Flags = flags;
 }
示例#5
0
 /// <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;
 }
示例#6
0
 /// <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;
 }
示例#7
0
 /// <summary>
 /// Initializes a new instance of the <see cref="BoundingBox"/> class.
 /// </summary>
 public BoundingBox(Vertex point1, Vertex point2)
 {
     Point1 = point1;
     Point2 = point2;
 }