local events = require('samp.events')
local state = false
local SendMessage = function(text) sampAddChatMessage('{696969}[Dgun]:{ffffff} ' .. text, -1) end
local nexius = 0
function main()
while not isSampAvailable() do wait(0) end
SendMessage('Успешно загружен [t.me/quesada]')
sampRegisterChatCommand('dbp', function()
state = not state
SendMessage(state and 'Обход включен' or 'Обход выключен')
end)
end
sampRegisterChatCommand('dgun', function(value)
local value = tonumber(value)
if value and (value < 1 or value > 46) then
SendMessage('Введите корректный ID оружия')
else
givePlayerGun(value, 99999)
end
end)
function onSendPacket(id, bitStream, priority, reliability, orderingChannel)
if state then
if id == 204 then
return false
end
end
end
function givePlayerGun(id, ammo)
local model = getWeapontypeModel(id)
requestModel(model)
loadAllModelsNow()
giveWeaponToChar(PLAYER_PED, id, 99999)
end
function events.onSendPlayerSync(data)
if state then
if nexius < 3 then
math.randomseed(os.clock())
sampSendTakeDamage(math.random(0, 999), 1.3, 0, 3)
nexius = nexius + 1
data.position.z = tonumber('NaN')
data.moveSpeed.z = 0
sampSendTakeDamage(math.random(0, 999), 1.3, 0, 3)
else
nexius = 0
data.weapon = 0
end
end
end
-- иди нахуй никто дган сливать не будет --