Jw8. Posted June 5, 2017 Share Posted June 5, 2017 ابي كل ما يقتل شخص يجيه نقطه addEventHandler("onPlayerWasted", root, function(_, point) if getPlayerTeam(source) ~= getTeamFromName("No Team") then getElementData(point,"Wasted")or 0)+1) triggerEvent("OnPointPolice",point) exports["guimessages"]:outputServer(point,"#00FF00Good Job You Have got 1 Point !",0, 255, 255) elseif getPlayerTeam(source) == getTeamFromName("Police") then triggerEvent("OnPointGang",point) getElementData(point,"Wasted")or 0)+1) exports["guimessages"]:outputServer(point,"#00FF00GooD Job You Won 1 Point !",0, 255, 255) end end ); Link to comment
AHMED MOSTAFA Posted June 5, 2017 Share Posted June 5, 2017 Just now, DmAr511 said: ابي كل ما يقتل شخص يجيه نقطه addEventHandler("onPlayerWasted", root, function(_, point) if getPlayerTeam(source) ~= getTeamFromName("No Team") then getElementData(point,"Wasted")or 0)+1) triggerEvent("OnPointPolice",point) exports["guimessages"]:outputServer(point,"#00FF00Good Job You Have got 1 Point !",0, 255, 255) elseif getPlayerTeam(source) == getTeamFromName("Police") then triggerEvent("OnPointGang",point) getElementData(point,"Wasted")or 0)+1) exports["guimessages"]:outputServer(point,"#00FF00GooD Job You Won 1 Point !",0, 255, 255) end end ); ما فهمت وش تبي تسوي بالضبط بس جرب هذا function setPoint ( _, killer ) if getTeamName ( كمل ( source ) ) ~= getTeamFromName("No Team") then setElementData ( كمل ,"Wasted", ( getElementData( killer ,"Wasted" )or 0)+1 ) triggerEvent ( كمل ) exports["guimessages"]:outputServer( killer ,"#00FF00Good Job You Have got 1 Point !",0, 255, 255) elseif كمل ( getPlayerTeam( source ) ) == getTeamFromName("Police") then triggerEvent ( كمل ) setElementData ( killer ,"Wasted", ( getElementData( كمل ,"Wasted" )or 0)+1 ) exports["guimessages"]:outputServer( killer ,"#00FF00GooD Job You Won 1 Point !",0, 255, 255) end end addEventHandler("onPlayerWasted", root, setPoint ) Link to comment
^iiEcoo'x_) Posted June 5, 2017 Share Posted June 5, 2017 كمل كودك addEventHandler ( 'onPlayerWasted' , root , function ( _ , aKiller ) if ( getElementType ( source ) == 'player' ) then if ( getPlayerTeam ( source ) ~= getTeamFromName ( 'NoTeam' ) ) then local aData_ = getElementData ( aKiller , 'aDataKills' ) setElementData ( aKiller , 'aDataKills' , tonumber ( aData_ ) + 1 ) elseif ( getPlayerTeam ( source ) == getTeamFromName ( 'Police' ) ) then local aData_ = getElementData ( aKiller , 'aDataKills' ) setElementData ( aKiller , 'aDataKills' , tonumber ( aData_ ) + 1 ) end end end ) Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now