Battlefield 1/ (Comfortable game) Spot, NO Recoil, Rapid Fire. Logitech mice.

byk

Coder
Joined
Jun 10, 2014
Messages
320
Reaction score
36
Points
28
this code in debug mode now... :)
jism

PHP:
function OnEvent(event, arg)
    OutputLogMessage("event = %s, arg = %d\n", event, arg)
    if (event == "PROFILE_ACTIVATED") then
        EnablePrimaryMouseButtonEvents(true)
    elseif event == "PROFILE_DEACTIVATED" then
        ReleaseMouseButton(2)
    end
    -- no recoil enable
    if (event == "MOUSE_BUTTON_PRESSED" and arg == 4) then
        recoil = not recoil
    end
    if (event == "MOUSE_BUTTON_PRESSED" and arg == 1 and recoil) then
        if recoil then
           OutputLogMessage("debug: no recoil enable ") --debug
            repeat
                  -- spot enable   
              if(IsKeyLockOn("numlock")) then
                OutputLogMessage("debug: spot enable ") --debug
                PressKey("Q")
                Sleep(math.random(5,35))
                ReleaseKey("Q")
              end
                Sleep(30)
                MoveMouseRelative(0, 2)
                Sleep(30)
                MoveMouseRelative(-1, 0)
                MoveMouseRelative(1, 0)
                Sleep(30)
                MoveMouseRelative(0, 1)
                Sleep(30)
                MoveMouseRelative(0, 2)
                Sleep(30)
            until not IsMouseButtonPressed(1)
        end
    end

    --debug rapid fire
    if (event == "MOUSE_BUTTON_PRESSED" and arg == 5) then
        repeat
             if(IsKeyLockOn("numlock")) then
                 OutputLogMessage("debug: spot enable ") --debug
                PressKey("Q")
                 Sleep(math.random(5,35))
                    ReleaseKey("Q")
               end
               PressMouseButton(1)
               Sleep(30)
               ReleaseMouseButton(1)
               MoveMouseRelative(-1, 1)
               Sleep(30)
               MoveMouseRelative(1, 1)
            until not IsMouseButtonPressed(5)
        end
end
 
Last edited:
  • Like
Reactions: pupkin

tuxtos

Registered
Joined
Nov 27, 2017
Messages
3
Reaction score
0
Points
1
Age
47
How it works? It works only sometimes the script and when it works it works very well but there are times when nothing happens -...
 

Codmania

Registered
Joined
Dec 25, 2018
Messages
1
Reaction score
0
Points
1
Age
38
On Battlefield 1 does not work with a G502 logitech