addEvent "onPlayerHeadshot"
addEventHandler("onPlayerDamage", getRootElement(),
function (attacker, weapon, bodypart, loss)
if bodypart == 9 then
local result = triggerEvent("onPlayerHeadshot", source, attacker, weapon, loss)
if result == true then
killPed(source, attacker, weapon, bodypart)
end
end
end
)
local weapons = {20, 40}
function onClientPedDamage(_, weapon)
if(getElementType(source) == "player") then
if(weapons[weapon]) then
return killPed(source)
end
end
end
addEventHandler("onClientPedDamage", getRootElement(), onClientPedDamage)
for _, v in ipairs ( { "pro", "std", "poor" } ) do
setWeaponProperty ( "sniper", v, "damage", 9999 )
end
------------------------------------------------------------------------------------------------
ELE TA EXPLODINDO CARRO COM 1 TIRO TBM, COMO RESOLVO? QUERO Q MATE SO O PLAYER!