Jump to content

Matar Jogador


Recommended Posts

  • Other Languages Moderators

Pesquise mais na Wiki antes de perguntar. Está tudo em onPlayerWasted.

addEventHandler ("onPlayerWasted", getRootElement(), function (ammo, attacker, weapon, bodypart)
    if (attacker) and getElementType (attacker) == "player" then
        local wanted = getPlayerWantedLevel (attacker)
        if wanted < 6 then
            setPlayerWantedLevel (attacker, wanted + 1)
        end
    elseif (attacker) and getElementType (attacker) == "vehicle" then
        local driver = getVehicleController (attacker)
        if driver and getElementType (driver) == "player" then
           local wanted = getPlayerWantedLevel (driver)
           if wanted < 6 then
               setPlayerWantedLevel (driver, wanted + 1)
           end 
        end
    end
end)

De nada.

Edited by Lord Henry
  • Thanks 1
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...