local weapons = require('game.weapons')
local bool = false
local LastWeapon = 0
function main()
while not isSampAvailable() do wait(0) end
while true do
wait(0)
if bool then
if getCurrentCharWeapon(PLAYER_PED) ~= LastWeapon then
LastWeapon = getCurrentCharWeapon(PLAYER_PED)
sampSendChat('/me взял в руки '..weapons.get_name(LastWeapon))
end
end
end
end
-- в imgui.OnDrawFrame()
if imgui.ToggleButton(--[[что-то там]]) then bool = not bool end