Пример #1
0
        public override void DoBeforeNextExecute()
        {
            if (Wheelturn != 0)
            {
                setPressedStrategy.Add(Wheelturn < 0 ? (int)Mouse.WheelBwd : (int)Mouse.WheelFwd);
                Wheelturn -= Math.Sign(Wheelturn);
            }

            if (Tempo != null && Tempo[0].GetLapse() >= Tempo[1])
            {
                Tempo[0] = StopTimer();
                Tempo    = null;
                foreach (var code in Codes.Reverse())
                {
                    KeyOrButtonUp(code);
                }
                Codes = null;
            }

            setPressedStrategy.Do();

            CheckScriptTimer();
            KeysPressed.Clear();
            for (int i = 1; i < 238; i++)
            {
                if (IsDown(i))
                {
                    KeysPressed.Add(i);
                }
            }

            if ((WheelValue = (IsDown((int)Mouse.WheelFwd) ? 1 : 0) + (IsDown((int)Mouse.WheelBwd) ? -1 : 0)) != 0)
            {
                setBit((int)(WheelValue < 0 ? Mouse.WheelBwd : Mouse.WheelFwd), false);
            }

            if (cmd == 'H')
            {
                if (SF == null)
                {
                    SF = new ScriptHook(this);
                }

                SF.Hook();
            }
        }