Jump to content

طلب كود بسيط


[DONE]*

Recommended Posts

السلام عليكم و رحمة الله و بركاته 8)

____________________________________________________________________________________________________________

كيف الحال شباب انشاء الله بخير :)

____________________________________________________________________________________________________________

كنت طالب كود بسيط لما واحد يكون بتيم معين مايقدر يقتل اي احد :roll:

____________________________________________________________________________________________________________

وشكرا لكم :wink:

----------------------------------------------------------------------------------------------------------------------------------------------------------

Link to comment
جـرب ,

  
addEventHandler ("onClientPlayerDamage", root, 
function() 
 if getPlayerTeam ( source ) and getPlayerTeam ( source ) == getTeamFromName ( "TeamName" ) then 
  cancelEvent () 
 end 
end 
) 
getPlayerTeam ( source ) and getPlayerTeam ( source ) 

??????????

Link to comment
local TeamName = "" -- اسم الفريق 
addEventHandler('onClientPlayerDamage',localPlayer, 
function () 
    if ( getPlayerTeam ( localPlayer ) ) then 
        if ( getPlayerTeam ( localPlayer ) == getTeamFromName( TeamName ) ) then 
        cancelEvent() 
        end  
    end 
end ) 

اذا ما خاب ظني :lol:

+

يآ ريت الي يدققو في اكواد الناس ويقولو ؟؟؟؟؟؟؟

يآ ريت بدال ما تسوي لي المدرك واانا الي يكشف اخطاء الناس حاول تصلحها يكون ابرك لك

او لا تكتب رد ترى مو لازم :/

Edit: تم التعديل :mrgreen:

Edited by Guest
Link to comment
local TeamName = "" -- اسم الفريق 
addEventHandler('onClientPlayerDamage',root, 
function () 
    if ( getPlayerTeam ( localPlayer ) ) then 
        if ( getPlayerTeam ( localPlayer ) == getTeamFromName( TeamName ) ) then 
        cancelEvent() 
        end  
    end 
end ) 

اذا ما خاب ظني

+

يآ ريت الي يدققو في اكواد الناس ويقولو ؟؟؟؟؟؟؟

يآ ريت بدال ما تسوي لي المدرك واانا الي يكشف اخطاء الناس حاول تصلحها يكون ابرك لك

او لا تكتب رد ترى مو لازم :/

local TeamName = "" -- اسم الفريق 
addEventHandler('onClientPlayerDamage',localPlayer, 
function () 
    if ( getPlayerTeam ( localPlayer ) ) then 
        if ( getPlayerTeam ( localPlayer ) == getTeamFromName( "TeamName" ) ) then 
        cancelEvent() 
        end  
    end 
end ) 

:mrgreen:

Link to comment

شباب الكود حطيته ما ظبت شوفوه في شي غلط

local TeamName = "Example" 
addEventHandler('onClientPlayerDamage',localPlayer, 
function () 
    if ( getPlayerTeam ( localPlayer ) ) then 
        if ( getPlayerTeam ( localPlayer ) == getTeamFromName( "Example" ) ) then 
        cancelEvent() 
        end 
    end 
end ) 

Link to comment

بالنسبة لصاحب الموضوع جرب :

addEventHandler ( "onClientPlayerDamage", localPlayer, function ( attacker ) 
  if ( attacker and attacker ~= source and getElementType( attacker ) == "player" ) then   
    if ( getPlayerTeam ( attacker ) and getPlayerTeam ( attacker ) == getTeamFromName( "Example" ) ) then 
        cancelEvent (  ) 
    end 
  end 
end ) 
Link to comment
بالنسبة لصاحب الموضوع جرب :

addEventHandler ( "onClientPlayerDamage", localPlayer, function ( attacker ) 
  if ( attacker and attacker ~= source and getElementType( attacker ) == "player" ) then   
    if ( getPlayerTeam ( attacker ) and getPlayerTeam ( attacker ) == getTeamFromName( "Example" ) ) then 
        cancelEvent (  ) 
    end 
  end 
end ) 

مشكؤؤؤؤؤؤر, جزاك الله خير :wink:

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