![[QB] Stop Violence Against PEDS main image](https://forum-cfx-re.akamaized.net/original/4X/c/a/6/ca6909c8287a7cab70d98d4df3c8dee0fb98ef18.jpeg)
Price
UnknownA script by krane_rcc
Price
Unknownhttps://i.imgur.com/xT9wmrW.png
This script will punish the user if he kills the PEDS from the street
for _, ped in pairs(QBCore.Functions.GetPeds({PlayerPedId()})) do
if not table_has_element(last_peds_killed, ped) then
if IsPedDeadOrDying(ped, 1) == 1 then
...
for _, ACTIVE_PLAYER in pairs(GetActivePlayers()) do
if GetPlayerPed(ACTIVE_PLAYER) == ped then
should_punish = false
end
end
if should_punish then
...
QBCore.Functions.Notify('You have been punished for killing a person.', 'error', 7500)
TriggerServerEvent("krane-punish-ped-killin")
TriggerEvent("krane-punish-ped-killin")
end
end
end
As you can see in the detection algorithm, it will bypass all the PLAYERS from your server from this check, so they can murder each other because they have equal chances at roleplay, but peds have no way to revolt against you, so this script will punish you
RegisterNetEvent("krane-punish-ped-killin")
to handle punishing from other scripts
Download the script for free: https://krane.tebex.io/package/5206423
Direct link: GitHub - kranercc/qb-stop-violence: This is a free fivem resource
Added integration for [QB] Skills ([QB] Skills - Modern Affordable)
No approved reviews found for this script yet.