Tarek1 Posted February 16, 2017 Share Posted February 16, 2017 theTeam = "Police" local allTeams = getElementsByType ( "team" ) for index, theTeam in ipairs(allTeams) do if ( getTeamFriendlyFire ( theTeam ) == false ) then setTeamFriendlyFire ( theTeam, true ) end end فكره السكربت : الاعبون اللي في تيم بوليس لا يستطيعوا قتل بعضهم Link to comment
Tarek1 Posted February 16, 2017 Author Share Posted February 16, 2017 1 minute ago, #_iMr.[E]coo said: و المطلوب ؟ المطلوب ان فين الخطا Link to comment
^iiEcoo'x_) Posted February 16, 2017 Share Posted February 16, 2017 (edited) addEventHandler ( "onResourceStart", getRootElement(), function ( ) local team = getTeamFromName("Police") if ( getTeamFriendlyFire ( team ) == false ) then setTeamFriendlyFire ( team, true ) end end ) نسخ لصق ؟ Edited February 16, 2017 by #_iMr.[E]coo Link to comment
Tarek1 Posted February 16, 2017 Author Share Posted February 16, 2017 1 minute ago, #_iMr.[E]coo said: addEventHandler ( "onResourceStart", getRootElement(), function ( ) local team = getTeamFromName("Police") if ( getTeamFriendlyFire ( team ) == false ) then setTeamFriendlyFire ( team, true ) end end ) نسخ لصق ؟ مش فاهم ؟ Link to comment
Adham Posted February 16, 2017 Share Posted February 16, 2017 انت اخد الكود من الويكي -- get a table with all teams local allTeams = getElementsByType ( "team" ) -- for every team, for index, theTeam in ipairs(allTeams) do -- if friendly fire is off, if ( getTeamFriendlyFire ( theTeam ) == false ) then -- switch it on setTeamFriendlyFire ( theTeam, true ) end end https://wiki.multitheftauto.com/wiki/SetTeamFriendlyFire 1 Link to comment
Tarek1 Posted February 16, 2017 Author Share Posted February 16, 2017 Just now, Deativated said: انت اخد الكود من الويكي -- get a table with all teams local allTeams = getElementsByType ( "team" ) -- for every team, for index, theTeam in ipairs(allTeams) do -- if friendly fire is off, if ( getTeamFriendlyFire ( theTeam ) == false ) then -- switch it on setTeamFriendlyFire ( theTeam, true ) end end https://wiki.multitheftauto.com/wiki/SetTeamFriendlyFire اها امال الويكي معمول ليه علشان نتامله :D? Link to comment
^iiEcoo'x_) Posted February 16, 2017 Share Posted February 16, 2017 ولآ شي الكود الي فوق سيرفر Link to comment
iPrestege Posted February 16, 2017 Share Posted February 16, 2017 -- Server Side setTeamFriendlyFire ( getTeamFromName ( 'Police' ),true ); 1 Link to comment
#Soking Posted February 16, 2017 Share Posted February 16, 2017 (edited) 4 minutes ago, #_iMr.[E]coo said: ولآ شي الكود الي فوق سيرفر كودك غلط و تقدرون تسونها ب سطر واحد setTeamFriendlyFire ( getTeamFromName ( 'Police' ) , false ) 2 minutes ago, iPrestege said: -- Server Side setTeamFriendlyFire ( getTeamFromName ( 'Police' ),true ); جيت ارد حصلتك رديت ض Edited February 16, 2017 by #Soking 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