Sure, here's a very simple version.
This one moves the cursor 10000 counts to the right when G1 is pressed on the keyboard. It does 100 repetitions of the MoveMouseRelative with 10 ms delay between each, and each of these moves the mouse 100 counts.
function OnEvent(event, arg)
if (event == "G_PRESSED" and arg == 1) and GetMKeyState() == 1 then
for i = 0, 99 do
MoveMouseRelative(100,0)
Sleep(10)
end
end
end