Ejemplo n.º 1
0
        public DynaHudMeterFont(Section_AHDR AHDR, Game game, Endianness endianness) : base(AHDR, DynaType.hud__meter__font, game, endianness)
        {
            using (var reader = new EndianBinaryReader(AHDR.data, endianness))
            {
                reader.BaseStream.Position = dynaHudMeterEnd;

                Font          = (FontEnum)reader.ReadInt32();
                FontJustify   = reader.ReadInt32();
                FontWidth     = reader.ReadSingle();
                FontHeight    = reader.ReadSingle();
                FontSpace     = reader.ReadSingle();
                ShadowXOffset = reader.ReadSingle();
                ShadowYOffset = reader.ReadSingle();
                Color         = reader.ReadColor();
                ShadowColor   = reader.ReadColor();

                if (Version == 3)
                {
                    CounterModeFlag = reader.ReadByte();
                    reader.ReadByte();
                    reader.ReadByte();
                    reader.ReadByte();
                }
            }
        }
        public DynaGObjectTrainJunction(Section_AHDR AHDR, Game game, Endianness endianness) : base(AHDR, DynaType.game_object__train_junction, game, endianness)
        {
            using (var reader = new EndianBinaryReader(AHDR.data, endianness))
            {
                reader.BaseStream.Position = dynaDataStartPosition;

                InSpline_AssetID            = reader.ReadUInt32();
                IsInFromForward             = reader.ReadByte();
                reader.BaseStream.Position += 3;
                Out1Spline_AssetID          = reader.ReadUInt32();
                Out1IsForward = reader.ReadByte();
                reader.BaseStream.Position += 3;
                Out2Spline_AssetID          = reader.ReadUInt32();
                Out2IsForward = reader.ReadByte();
            }
        }
        public DynaEffectRumbleSphere(Section_AHDR AHDR, Game game, Endianness endianness) : base(AHDR, DynaType.effect__RumbleSphericalEmitter, game, endianness)
        {
            using (var reader = new EndianBinaryReader(AHDR.data, endianness))
            {
                reader.BaseStream.Position = dynaDataStartPosition;

                Rumble_AssetID = reader.ReadUInt32();
                Radius         = reader.ReadSingle();
                _position      = new Vector3(reader.ReadSingle(), reader.ReadSingle(), reader.ReadSingle());
                OnlyRumbleOnY  = reader.ReadByte();
                FallOff        = reader.ReadByte();
                OnlyOnFloor    = reader.ReadByte();

                CreateTransformMatrix();
                AddToRenderableAssets(this);
            }
        }
        public DynaLogicFunctionGenerator(Section_AHDR AHDR, Game game, Endianness endianness) : base(AHDR, DynaType.logic__FunctionGenerator, game, endianness)
        {
            using (var reader = new EndianBinaryReader(AHDR.data, endianness))
            {
                reader.BaseStream.Position = dynaDataStartPosition;

                StartCycleWidth  = reader.ReadSingle();
                MiddleCycleWidth = reader.ReadSingle();
                EndCycleWidth    = reader.ReadSingle();
                StartPulseWidth  = reader.ReadSingle();
                MiddlePulseWidth = reader.ReadSingle();
                EndPulseWidth    = reader.ReadSingle();
                MiddleTime       = reader.ReadSingle();
                EndTime          = reader.ReadSingle();
                MiddleEnabled    = reader.ReadByte();
                EndEnabled       = reader.ReadByte();
            }
        }
Ejemplo n.º 5
0
        public DynaEffectRumble(Section_AHDR AHDR, Game game, Endianness endianness) : base(AHDR, DynaType.effect__Rumble, game, endianness)
        {
            using (var reader = new EndianBinaryReader(AHDR.data, endianness))
            {
                reader.BaseStream.Position = dynaDataStartPosition;

                Time          = reader.ReadSingle();
                Intensity     = reader.ReadSingle();
                ID            = reader.ReadSingle();
                Priority      = reader.ReadByte();
                RumbleType    = reader.ReadByte();
                RumbleInPause = reader.ReadByte();
                reader.ReadByte();
                Param1                   = reader.ReadSingle();
                Param2                   = reader.ReadSingle();
                ShakeMagnitude           = reader.ReadSingle();
                ShakeCycleMax            = reader.ReadSingle();
                ShakeRotationalMagnitude = reader.ReadSingle();
                ShakeY                   = reader.ReadByte();
            }
        }