Ищу скрипт

[w[w[

Новичок
Автор темы
13
0
Нарушение правил раздела
ищу скрипт показывающий ккол-во пт, как на срине, прошу помогите
Desktop Screenshot 2024.05.13 - 21.48.51.74.png
 

zakatov

zkt-team
Проверенный
1,724
549
Lua:
local font = renderCreateFont('Consolas', 13, 5)
local memory = require 'memory'
local state = false
function main()
    sampRegisterChatCommand('ptr', function()
        state = not state
        sampAddChatMessage(state and '{ff0000}On' or '{ffffff}Off', -1)
    end)
    while true do
        wait(0)
        if (isKeyDown(0x02) and state) then
            local AmmoInClip = getAmmoInClip()
            local weapon = getCurrentCharWeapon(1)
            local ammo = getAmmoInCharWeapon(1, weapon)
            local posX, posY = getCrosshairPositionOnScreen()
            local color = {0xFFFFFFFF, 0xFFFF0000}
            -- renderDrawBox(posX-27, posY-47, renderGetFontDrawTextLength(font, string.format("%d/%d", AmmoInClip, ammo-AmmoInClip))+4, renderGetFontDrawHeight(font)+4, 0xCA000000)
            renderFontDrawText(font, string.format("%d-%d", AmmoInClip, ammo-AmmoInClip), posX-25, posY-45, AmmoInClip>5 and color[1] or color[2])
        end
    end
end
function getAmmoInClip()
    local pointer = getCharPointer(playerPed)
    local weapon = getCurrentCharWeapon(playerPed)
    local slot = getWeapontypeSlot(weapon)
    local cweapon = pointer + 0x5A0
    local current_cweapon = cweapon + slot * 0x1C
    return memory.getuint32(current_cweapon + 0x8)
end
function getCrosshairPositionOnScreen()
    local resolutionX, resolutionY = getScreenResolution()
    local onScreenX = resolutionX * 0.5299999714
    local onScreenY = resolutionY * 0.4
    return onScreenX, onScreenY
end
/ptr активация
 
  • Влюблен
Реакции: Жопулик