using System;
using System.Collections.Generic;
using System.Text;
using Halo3Map.Data;

namespace Halo3Map.Tags.Layouts
{
    [Tag("shade45", "sbsp", 0.1)]
    public class sbsp : H3Tag
    {
        public int Unknown;
        public int Unknown4;
        [Size(16)]
        public byte[] Unused8;

        public H3Reflexive<Unknown24> unknown24;
        [Size(4)]
        public class Unknown24 : Chunk
        {
            public int Unknown;
        }

        public H3Reflexive<Unknown36> unknown36;
        [Size(24)]
        public class Unknown36 : Chunk
        {
            public TagReference rmsh;
            public short Unknown16;
            public short Unknown18;
            public short Unknown20;
            public short Unknown22;
        }

        [Size(12)]
        public byte[] unknown48; //This reflex is padded will leave out for now

        //World Bounds
        public float WorldBoundsXMin;
        public float WorldBoundsXMax;
        public float WorldBoundsYMin;
        public float WorldBoundsYMax;
        public float WorldBoundsZMin;
        public float WorldBoundsZMax;

        public H3Reflexive<Unknown84> unknown84;
        [Size(4)]
        public class Unknown84 : Chunk
        {
            public short Unknown;
            public short Unknown2;
        }

        public H3Reflexive<Unknown96> unknown96;
        [Size(4)]
        public class Unknown96 : Chunk
        {
            public short Unknown;
            public short Unknown2;
        }

        public H3Reflexive<Unknown108> unknown108;
        [Size(40)]
        public class Unknown108 : Chunk
        {
            public short Unknown;
            public short Unknown2;
            public int Unknown4;
            public float Unknown8;
            public float Unknown12;
            public float Unknown16;
            public float Unknown20;
            public int Unknown24;

            public H3Reflexive<Unknown28> unknown28;
            [Size(12)]
            public class Unknown28 : Chunk
            {
                public float Unknown;
                public float Unknown4;
                public float Unknown8;
            }
        }

        [Size(72)]
        public byte[] Unknown120; //2 reflexives in this block, I cant figure out thier sizes

        public H3Reflexive<Unknown192> unknown192;
        [Size(36)]
        public class Unknown192 : Chunk
        {
            public TagReference rmsh;
            public int Unknown16;
            public int Unknown20;
            public int Unknown24;
            public int Unknown28;
            public int Unknown32;
        }

        public H3Reflexive<Unknown204> unknown204;
        [Size(2)]
        public class Unknown204 : Chunk
        {
            public short Unknown;
        }

        [Size(48)]
        public byte[] Unknown216;

        public H3Reflexive<Sounds264> sounds;
        [Size(84)]
        public class Sounds264 : Chunk
        {
            public int Unknown;
            public TagReference SoundEnvironment;
            public int Unknown20;
            public int Unknown24;
            public TagReference LoopingSound;
            public int Unknown44;
            public int Unknown48;
            public int Unknown52;
            public int Unknown56;
            public int Unknown60;
            public int Unknown64;
            public int Unknown68;
            public int Unknown72;
            public int Unknown76;
            public int Unknown80;
        }

        [Size(80)]
        public byte[] Unknown276;

        public H3Reflexive<Unknown356> unknown356;
        [Size(36)]
        public class Unknown356 : Chunk
        {
            public int Unknown;
            public int Unknown4;
            public int Unknown8;
            public int Unknown12;
            public int Unknown16;
            public int Unknown20;
            public int Unknown24;
            public int Unknown28;
            public int Unknown32;
        }

        [Size(76)]
        public byte[] Unknown368;

        public H3Reflexive<Decorators> decorators;
        [Size(16)]
        public class Decorators : Chunk
        {
            public TagReference decorator;
        }
    }
}
