Jump to content

[HD Problem]


Tando

Recommended Posts

addEvent("onPlayerHeadshot")
addEventHandler("onPlayerDamage", getRootElement(),
    function (attacker, weapon, bodypart, loss)
        if bodypart == 9 and weapon == 34 then
            local result = triggerEvent("onPlayerHeadshot", source, attacker, weapon, loss)
            if result == true then
				setElementHealth ( source, getElementHealth(source) - 100 ) 
				if isPlayerDead ( source ) == true then 					
					killPed(source, attacker, weapon, bodypart)
					setPedHeadless( source, true )
					setTimer( BackUp, 900, 1, source )
				end
            end
        end
    end
)
function BackUp( source )   
    if getElementType ( source ) == "player" then
        setPedHeadless ( source, false )
    end
end 

it's working fine but need to add img on it

like when player kill someone headshot give img in killmessages

Link to comment
6 hours ago, (SAUG)Tando said:

addEvent("onPlayerHeadshot")
addEventHandler("onPlayerDamage", getRootElement(),
    function (attacker, weapon, bodypart, loss)
        if bodypart == 9 and weapon == 34 then
            local result = triggerEvent("onPlayerHeadshot", source, attacker, weapon, loss)
            if result == true then
				setElementHealth ( source, getElementHealth(source) - 100 ) 
				if isPlayerDead ( source ) == true then 					
					killPed(source, attacker, weapon, bodypart)
					setPedHeadless( source, true )
					setTimer( BackUp, 900, 1, source )
				end
            end
        end
    end
)
function BackUp( source )   
    if getElementType ( source ) == "player" then
        setPedHeadless ( source, false )
    end
end 

it's working fine but need to add img on it

like when player kill someone headshot give img in killmessages

22.jpg

Same as the image?

 
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...