//constructer, it determines a few things to get length.
 public Parameter(Int16 hsh, byte n, string nme, Int32 vlen, bbreader binr)
 {
     this.hash = hsh;
     this.nb = n;
     this.name = nme;
     this.valueLength = vlen;
     switch (vlen)
     {
         case 4:
             if (!this.name.Contains("Color"))
             {
                 this.flag = valueType.unk;
                 this.fourVal = binr.ReadBytes(4);
                 Array.Reverse(this.fourVal);
                 this.intValue = BitConverter.ToInt32(this.fourVal, 0);
                 this.dubValue = BitConverter.ToSingle(this.fourVal, 0);
                 Array.Reverse(this.fourVal);
             }
             else {
                 flag = valueType.color;
                 this.colorVal = binr.readRgba();
             }
             break;
         case 2:
             flag = valueType.integer;
             this.intValue = binr.ReadInt16();
             break;
         case 1:
             flag = valueType.integer;
             this.intValue = binr.ReadByte();
             break;
         case 12:
             flag = valueType.vec;
             this.vec = new math.vector(binr.ReadSingle(), binr.ReadSingle(), binr.ReadSingle());
             break;
         default:
             Console.Write("Unknown Value Length {0} at offset {1}", this.valueLength, binr.BaseStream.Position);
             break;
     }
 }