Клавиша

Артем98

Участник
Автор темы
195
16
Версия SA-MP
  1. Любая
  2. Другая
Ищу названия этой клавиши
Левая 1 боковая на мышке

1

Именно для написания кода на эту клавишу(Просто забиндить шифтуху)
 
Последнее редактирование:

woodware

Потрачен
Проверенный
5,056
1,464
VK_XBUTTON1
 

Артем98

Участник
Автор темы
195
16
VK_XBUTTON1
Не робит либо код дебильный посмотри ты

1:
require 'lib.moonloader'

function main()
    while not isSampLoaded() do wait(100) end
    while true do wait(0)
        if isKeyDown(VK_XBUTTON1) then
            if isKeyDown(VK_RBUTTON) then
                local cam_x, cam_y, cam_z = getActiveCameraCoordinates()
                local width, heigth = convertGameScreenCoordsToWindowScreenCoords(339.1, 179.1)
                local aim_x, aim_y, aim_z = convertScreenCoordsToWorld3D(width, heigth, 100)
                local result, colPoint = processLineOfSight(cam_x, cam_y, cam_z, aim_x, aim_y, aim_z, false, false, true, false, false, false, false)
                if result then
                    if isLineOfSightClear(cam_x, cam_y, cam_z, colPoint.pos[1], colPoint.pos[2], colPoint.pos[3], true, true, false, true, true) then
                        if colPoint.entityType == 3 then
                            if getCharPointerHandle(colPoint.entity) ~= playerPed then
                                writeMemory(0xB7347A, 4, 255, 0)
                            end
                        end
                    end
                end
            end
        end
    end
end
 

Masayuki

Участник
81
32
Не робит либо код дебильный посмотри ты

1:
require 'lib.moonloader'

function main()
    while not isSampLoaded() do wait(100) end
    while true do wait(0)
        if isKeyDown(VK_XBUTTON1) then
            if isKeyDown(VK_RBUTTON) then
                local cam_x, cam_y, cam_z = getActiveCameraCoordinates()
                local width, heigth = convertGameScreenCoordsToWindowScreenCoords(339.1, 179.1)
                local aim_x, aim_y, aim_z = convertScreenCoordsToWorld3D(width, heigth, 100)
                local result, colPoint = processLineOfSight(cam_x, cam_y, cam_z, aim_x, aim_y, aim_z, false, false, true, false, false, false, false)
                if result then
                    if isLineOfSightClear(cam_x, cam_y, cam_z, colPoint.pos[1], colPoint.pos[2], colPoint.pos[3], true, true, false, true, true) then
                        if colPoint.entityType == 3 then
                            if getCharPointerHandle(colPoint.entity) ~= playerPed then
                                writeMemory(0xB7347A, 4, 255, 0)
                            end
                        end
                    end
                end
            end
        end
    end
end
В начало кода
local VK = require 'vkeys'