Exemple #1
0
        public void FrameAdvance(bool render, bool rendersound = true)
        {
            Frame++;
            IsLagFrame = true;

            if (Controller["Power"])
            {
                BizSwan.bizswan_reset(Core);
            }

            bool rotate        = false;
            int  soundbuffsize = sbuff.Length;

            IsLagFrame = BizSwan.bizswan_advance(Core, GetButtons(), !render, vbuff, sbuff, ref soundbuffsize, ref rotate);
            if (soundbuffsize == sbuff.Length)
            {
                throw new Exception();
            }
            sbuffcontains = soundbuffsize;
            InitVideo(rotate);

            if (IsLagFrame)
            {
                LagCount++;
            }
        }
        public bool FrameAdvance(IController controller, bool render, bool rendersound = true)
        {
            IsLagFrame = true;

            if (controller.IsPressed("Power"))
            {
                BizSwan.bizswan_reset(Core);
            }

            bool rotate        = false;
            int  soundbuffsize = sbuff.Length;

            IsLagFrame = BizSwan.bizswan_advance(Core, GetButtons(controller), !render, vbuff, sbuff, ref soundbuffsize, ref rotate);
            if (soundbuffsize == sbuff.Length)
            {
                throw new Exception();
            }
            sbuffcontains = soundbuffsize;
            InitVideo(rotate);

            if (IsLagFrame)
            {
                LagCount++;
            }

            Frame++;

            return(true);
        }