add MapWindow.cs; don't show resources in levels menu
[weland.git] / Line.cs
blobe82339e23edfe9f185ee4c335bb9c152bfb7894f
1 using System.IO;
3 namespace Weland {
4 public class Line {
5 public const uint Tag = 0x4c494e53; // LINS
6 public const int Size = 32;
8 public short[] EndpointIndexes = new short[2];
9 public ushort Flags;
11 public short ClockwisePolygonSideIndex;
12 public short CounterclockwisePolygonSideIndex;
13 public short ClockwisePolygonOwner;
14 public short CounterclockwisePolygonOwner;
16 public void Load(BinaryReaderBE reader) {
17 EndpointIndexes[0] = reader.ReadInt16();
18 EndpointIndexes[1] = reader.ReadInt16();
19 Flags = reader.ReadUInt16();
20 reader.ReadInt16(); // length
21 reader.ReadInt16(); // highest_adjacent_floor
22 reader.ReadInt16(); // lowest_adjacent_floor
23 ClockwisePolygonSideIndex = reader.ReadInt16();
24 CounterclockwisePolygonSideIndex = reader.ReadInt16();
25 ClockwisePolygonOwner = reader.ReadInt16();
26 CounterclockwisePolygonOwner = reader.ReadInt16();
27 reader.BaseStream.Seek(12, SeekOrigin.Current);