Jump to content

تخصيص سلاح لتيم معين


aL.Kfo

Recommended Posts

معي مود بوليس الشرطي لا مات م ترجع معه العصا لزم يتوطف ثاني

ب اختصار ابي يكون لا مات الشرطي يرجع معه العصا

اسم التيم

Police

Edited by Guest
Link to comment
Event "onPlayerWasted"

getPlayerTeam 
getTeamName 
getTeamFromName 
giveWeapon 

أسستخدم كـل ذأ عشأن عصاء بس :?

كثيرهـ

# لأنك ما تحأول ولأ تحب تحاول وتبي الكود جاهز بس

# حأول وبسسأعدكـ

# كله 4 او5 اسسطر , وتقول صعب

لو انها فنكشن واحد حاولت بس ذي كثير مدرري من كل رابط وش اخذ

:(

Edited by Guest
Link to comment
addEventHandler("onPlayerWasted", root, 
function (player) 
if getPlayerTeam ( player ) and getPlayerTeam ( player ) == getTeamFromName ( "Police" ) then 
setTimer (giveWeapon, 2500, 1, player, 3) 
end 
end 
) 

# الحين انت ليه تعطيه ؟

# نحنا نبيه يحأول شوية بـ كم سطر مو عارف يسويه وأنت تجي تعطيه , ياخي خله يحأول

Link to comment
addEventHandler("onPlayerWasted", root, 
function (player) 
if getPlayerTeam( player ) and getTeamName( getPlayerTeam( player ) ) == "Police" then 
setTimer (giveWeapon, 2500, 1, player, 3) 
end 
end 
) 

# الحين انت ليه تعطيه ؟

# نحنا نبيه يحأول شوية بـ كم سطر مو عارف يسويه وأنت تجي تعطيه , ياخي خله يحأول

الكود ساهل

Edited by Guest
Link to comment
addEventHandler("onPlayerWasted", root, 
function (player) 
if getPlayerTeam ( player ) and getPlayerTeam ( player ) == getTeamFromName ( "Police" ) then 
setTimer (giveWeapon, 2500, 1, player, 3) 
end 
end 
) 

ثانكسس مانستر :wink:

2tq4F.jpg

فيسبوك نتعلم حبة حبة

حياككك

Link to comment
addEventHandler("onPlayerWasted", root, 
function (player) 
if getPlayerTeam( player ) and getTeamName( getPlayerTeam( player ) ) == "Police" then 
setTimer (giveWeapon, 2500, 1, player, 3) 
end 
end 
) 

ثانكسس مانستر :wink:

2tq4F.jpg

فيسبوك نتعلم حبة حبة

حياككك

حياك الله ^_^

Edited by Guest
Link to comment
addEventHandler("onPlayerWasted", root, 
function (player) 
if getPlayerTeam ( player ) and getPlayerTeam ( player ) == getTeamFromName ( "Police" ) then 
setTimer (giveWeapon, 2500, 1, player, 3) 
end 
end 
) 

# الحين انت ليه تعطيه ؟

# نحنا نبيه يحأول شوية بـ كم سطر مو عارف يسويه وأنت تجي تعطيه , ياخي خله يحأول

الكود ساهل

# لأنه سهل مو لأزم تعطيه , كود زي كذا مو عارف يسسويهه وش تتوقع لو جاه كود اصعب من ذا

# خله يحأول على الأقل بـ نص الكود ونكملهه له

Link to comment

# لأنه سهل مو لأزم تعطيه , كود زي كذا مو عارف يسسويهه وش تتوقع لو جاه كود اصعب من ذا

# خله يحأول على الأقل بـ نص الكود ونكملهه له

انا شفت انه ماراح يقدر يسويه #_# و عطيته

Link to comment
addEventHandler("onPlayerWasted", root, 
function (player) 
if getPlayerTeam ( player ) and getPlayerTeam ( player ) == getTeamFromName ( "Police" ) then 
setTimer (giveWeapon, 2500, 1, player, 3) 
end 
end 
) 

player = ?

أقرا الـ Parameters عدل !

اول بارتمنت انت حاطه player , لكن تشوفه بالويكي راح تلاحظ

int totalAmmo, element killer, int killerWeapon, int bodypart [, bool stealth ] 

totalAmmo: an integer representing the total ammo the victim had when he died.

killer: an element representing the player or vehicle who was the killer. If there was no killer this is false.

killerWeapon: an integer representing the killer weapon or the death reason.

bodypart: an integer representing the bodypart ID the victim was hit on when he died.

3: Torso

4: Ass

5: Left Arm

6: Right Arm

7: Left Leg

8: Right leg

9: Head

stealth: boolean value representing whether or not this was a stealth kill

Source

The source of this event is the player that died or got killed.

فالكود يصير كذا :

 Timer = {  }; 
  
addEventHandler ( "onPlayerWasted", root, function  (  ) 
    if getPlayerTeam ( source ) == getTeamFromName ( "Police" ) then 
      if isTimer ( Timer [ source ] ) then killTimer ( Timer [ source ] ) Timer [ source ] = nil end 
          Timer [ source ] = setTimer ( giveWeapon, 1000, 1, source, 3 ) 
    end 
end 
) 

Link to comment
addEventHandler("onPlayerWasted", root, 
function (player) 
if getPlayerTeam ( player ) and getPlayerTeam ( player ) == getTeamFromName ( "Police" ) then 
setTimer (giveWeapon, 2500, 1, player, 3) 
end 
end 
) 

player = ?

أقرا الـ Parameters عدل !

اول بارتمنت انت حاطه player , لكن تشوفه بالويكي راح تلاحظ

int totalAmmo, element killer, int killerWeapon, int bodypart [, bool stealth ] 

totalAmmo: an integer representing the total ammo the victim had when he died.

killer: an element representing the player or vehicle who was the killer. If there was no killer this is false.

killerWeapon: an integer representing the killer weapon or the death reason.

bodypart: an integer representing the bodypart ID the victim was hit on when he died.

3: Torso

4: Ass

5: Left Arm

6: Right Arm

7: Left Leg

8: Right leg

9: Head

stealth: boolean value representing whether or not this was a stealth kill

Source

The source of this event is the player that died or got killed.

فالكود يصير كذا :

 Timer = {  }; 
  
addEventHandler ( "onPlayerWasted", root, function  (  ) 
    if getPlayerTeam ( source ) == getTeamFromName ( "Police" ) then 
      if isTimer ( Timer [ source ] ) then killTimer ( Timer [ source ] ) Timer [ source ] = nil end 
          Timer [ source ] = setTimer ( giveWeapon, 1000, 1, source, 3 ) 
    end 
end 
) 

كل كود أكوسس من ألثاني

ثأنكس

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