TAPL Posted December 11, 2012 Share Posted December 11, 2012 local pick = createPickup(0,0,3,3,1550) addEventHandler("onPickupHit", pick, function(hitPlayer) if (getTeamName(getPlayerTeam(hitPlayer)) == "M") then destroyElement(pick) givePlayerMoney(hitPlayer, 2000) else cancelEvent() end end) Link to comment
Bo7meeeD Posted December 11, 2012 Author Share Posted December 11, 2012 local pick = createPickup(0,0,3,3,1550) addEventHandler("onPickupHit", pick, function(hitPlayer) if (getTeamName(getPlayerTeam(hitPlayer)) == "M") then destroyElement(pick) givePlayerMoney(hitPlayer, 2000) else cancelEvent() end end) ياااخي والله مجربها ولا ضبطت كبف الحين تضبط مشكؤؤر تم Link to comment
3NAD Posted December 11, 2012 Share Posted December 11, 2012 -- Server Side thePickup = createPickup ( 0, 0, 3, 3, 1550 ) addEventHandler ( "onPickupHit", root, function ( hitPlayer ) --hitPlayer not thePlayer if source == thePickup then if getTeamName ( getPlayerTeam ( hitPlayer ) ) == "M" then ----hitPlayer not thePlayer destroyElement ( thePickup ) givePlayerMoney ( hitPlayer, 2000 ) ----hitPlayer not thePlayer end end end ) يعني سويت شيء جديد ؟؟ thePlayer ههههه انت مغير Link to comment
KinG_DrifT Posted December 11, 2012 Share Posted December 11, 2012 local pick = createPickup(0,0,3,3,1550) addEventHandler("onPickupHit", pick, function(hitPlayer) if (getTeamName(getPlayerTeam(hitPlayer)) == "M") then destroyElement(pick) givePlayerMoney(hitPlayer, 2000) else cancelEvent() end end) ياااخي والله مجربها ولا ضبطت كبف الحين تضبط مشكؤؤر تم الكود صحح الله يحفظكك ^_ جربتهه Link to comment
KinG_DrifT Posted December 11, 2012 Share Posted December 11, 2012 (edited) -- Server Side thePickup = createPickup ( 0, 0, 3, 3, 1550 ) addEventHandler ( "onPickupHit", root, function ( hitPlayer ) --hitPlayer not thePlayer if source == thePickup then if getTeamName ( getPlayerTeam ( hitPlayer ) ) == "M" then ----hitPlayer not thePlayer destroyElement ( thePickup ) givePlayerMoney ( hitPlayer, 2000 ) ----hitPlayer not thePlayer end end end ) يعني سويت شيء جديد ؟؟ thePlayer ههههه انت مغير اقرا الكلام صحح Edited December 11, 2012 by Guest Link to comment
Bo7meeeD Posted December 11, 2012 Author Share Posted December 11, 2012 local pick = createPickup(0,0,3,3,1550) addEventHandler("onPickupHit", pick, function(hitPlayer) if (getTeamName(getPlayerTeam(hitPlayer)) == "M") then destroyElement(pick) givePlayerMoney(hitPlayer, 2000) else cancelEvent() end end) ياااخي والله مجربها ولا ضبطت كبف الحين تضبط مشكؤؤر تم الكود صحح الله يحفظكك ^_ جربتهه ادري انه صح وانا قلت غلط ؟ Link to comment
3NAD Posted December 11, 2012 Share Posted December 11, 2012 تركييز ششوي اقصد هنا . . function ( hitPlayer ) --hitPlayer not thePlayer مسوي يعني رآح تتغير النتيجة ؟ Link to comment
KinG_DrifT Posted December 11, 2012 Share Posted December 11, 2012 تركييز ششوي اقصد هنا . . function ( hitPlayer ) --hitPlayer not thePlayer مسوي يعني رآح تتغير النتيجة ؟ مابي اطول كلام لان الرجـآآل آستفاد وخلصص Link to comment
abu5lf Posted December 11, 2012 Share Posted December 11, 2012 -- Server Side thePickup = createPickup ( 0, 0, 3, 3, 1550 ) addEventHandler ( "onPickupHit", root, function ( hitPlayer ) --hitPlayer not thePlayer if source == thePickup then if getTeamName ( getPlayerTeam ( hitPlayer ) ) == "M" then ----hitPlayer not thePlayer destroyElement ( thePickup ) givePlayerMoney ( hitPlayer, 2000 ) ----hitPlayer not thePlayer end end end ) كود عنـآآد عدل بس في اضافات لازم تكون منكك ههههههههههههههع hitPlayer not thePlayer -- ماتفرق شيء Link to comment
KinG_DrifT Posted December 11, 2012 Share Posted December 11, 2012 -- Server Side thePickup = createPickup ( 0, 0, 3, 3, 1550 ) addEventHandler ( "onPickupHit", root, function ( hitPlayer ) --hitPlayer not thePlayer if source == thePickup then if getTeamName ( getPlayerTeam ( hitPlayer ) ) == "M" then ----hitPlayer not thePlayer destroyElement ( thePickup ) givePlayerMoney ( hitPlayer, 2000 ) ----hitPlayer not thePlayer end end end ) كود عنـآآد عدل بس في اضافات لازم تكون منكك ههههههههههههههع hitPlayer not thePlayer -- ماتفرق شيء -- Server Side thePickup = createPickup ( 0, 0, 3, 3, 1550 ) addEventHandler ( "onPickupHit", root, function ( hitPlayer ) --hitPlayer not thePlayer if source == thePickup then if getTeamName ( getPlayerTeam ( hitPlayer ) ) == "M" then ----hitPlayer not thePlayer destroyElement ( thePickup ) givePlayerMoney ( hitPlayer, 2000 ) ----hitPlayer not thePlayer end end end ) هنـآآ مـآآتفرق؟ if getTeamName ( getPlayerTeam ( hitPlayer ) ) == "M" then Link to comment
abu5lf Posted December 11, 2012 Share Posted December 11, 2012 ماتفرق هي كلمة تقدر تحط اي كلمة Link to comment
Tete omar Posted December 11, 2012 Share Posted December 11, 2012 math.random(3,5) هذي تجيب لك ارقام عشوائية ما بين ال 3 وال 5 ممكن تصير كذا math.random(5) راح يعطيك ارقام عشوائية تصل إلى 5 math.random( v1, v2 ) v2 لازم تكون اصغر من v1 ولا مايصلح ولها استخدامات كثيرة مهب بس في الارقام العشوائية مع اني استخدمت رقم عشوائي في المثال لكن عطاني نص عشوائي e.g: aText = { 'السلام عليكم'; 'كيف الحال'; 'بخير الحمدلله'; } outputChatBox( aText[ math.random( #aText ) ] ) وانت الحين اقتبست تعليقي على اساس انو فيه خطاء في اللي كاتبه مثلاً ؟ 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