addEventHandler( "onPlayerWasted", root,
function ( _,killer )
if ( killer and killer ~= source and getElementType( killer ) == "player" ) then
if ( getPlayerTeam( killer ) and getPlayerTeam( killer ) == getTeamFromName ( "Swat" ) ) then
if ( getPlayerWantedLevel ( source ) > 0 ) then
givePlayerMoney ( killer, 7000 )
exports["guimessages"]:outputClient("*" .. getPlayerName(killer) .. "Jailed" .. getPlayerName(source) .. "",root,0,0,255,true)
setTimer ( setElementPosition, 100, 1,source , 263.53342, 77.61669, 1001.03906 )
setTimer ( setElementPosition, 100, 1,killer , 2289.52686, 579.96320, 7.78125 )
end
end
end
end
)