αвυ-wαleed Posted May 26, 2014 Posted May 26, 2014 السلام عليكم ورحمة الله وبركاته طلبي 1- اذا اللاعب ضربوة ووصل دمة 20 يسوي حركة 2- ابغى اللاعب ماينقص دمة عن 20% لو يرموة باي سلاح 3- بعد مايسوي الحركة يجي له وقت 5 دقايق ان مازاد دمة يموت اكيد فهمتوا اش ابغى اسوي بانتظار ردودكم ..
max-mohammed Posted May 26, 2014 Posted May 26, 2014 event : "onPlayerDamage" getElementHealth setElementHealth setPedAnimation
shwaeki Posted May 26, 2014 Posted May 26, 2014 'onPlayerDamage' getElementHealth setPedAnimation cancelEvent setElementData getElementData killPed setTimer
</Mr.Tn6eL> Posted May 26, 2014 Posted May 26, 2014 مراح يكنسل الافنت ماتقرون الويكي صفحة الويكي حقت onPlayerDamage مافي كنسل افنت https://wiki.multitheftauto.com/wiki/On ... ayerDamage or https://wiki.multitheftauto.com/wiki/OnClientPedDamage بس كلنت اقتباس من الويكي Cancel effect If this event is canceled, then any damaging effects to the local player will cease.
Quited Posted May 26, 2014 Posted May 26, 2014 احداث الدمج للكلنت والسيرفر كلها تتكنسل لكن انت فهمت الاقتباس من الويكي فهمته غلط
</Mr.Tn6eL> Posted May 27, 2014 Posted May 27, 2014 جرب حدث الكلنت مو السيرفر شوف ردي فوق تلقا مثال بالرابط
αвυ-wαleed Posted May 27, 2014 Author Posted May 27, 2014 addEventHandler( "onPlayerDamage", root, function( ) if ( getElementHealth( source ) < 20 ) then setPedAnimation ( source, "BEACH", "bather") cancelEvent() end end ) الحين سويت حاجة وحده اذا وصل 20 دمة يسوي الحركة باقي ابغاه اذا وصل 20 ماينزل عن 20 مايموت واذا زاد دمة فوق 20 يوقف الحركة
#DRAGON!FIRE Posted May 27, 2014 Posted May 27, 2014 لحستني ترأ .. تقول ما ينقص دمه عن 20 وتقول لو صار دمه 20 او اقل يسوي حركة وبعد 5 دقائق لو نقص دمه عن 20 كيف ذي ؟ ..
3tibe511 Posted May 27, 2014 Posted May 27, 2014 هو يقول ابيه يوقف دمه على 20% ويعطيه مدة معينة لمن يخلص يصير يتحرك دمه
The Killer Posted May 27, 2014 Posted May 27, 2014 Client side: addEventHandler ("onClientPlayerDamage", root, function () if getElementHealth (localPlayer) <= 20 then addEventHandler ("onClientPlayerDamage", getLocalPlayer (), cancelEvent) setElementHealth (localPlayer, 20) setPedAnimation (localPlayer, "BEACH", "bather") else removeEventHandler ("onClientPlayerDamage", getLocalPlayer (), cancelEvent) end end)
#DRAGON!FIRE Posted May 28, 2014 Posted May 28, 2014 جججرب .. : addEventHandler( "onClientPlayerDamage", localPlayer, function( attacker ) if ( attacker and attacker ~= source ) then if ( getElementHealth( source ) <= 20 ) then cancelEvent( ) setPedAnimation ( source, "BEACH", "bather" ) setTimer ( function( ) if ( isElement( source ) ) then if ( getElementHealth( source ) == 20 ) then setElementHealth( source, 0 ) else setPedAnimation( source, false ) end end end, 300000, 1 ) end end end )
Simba Posted May 28, 2014 Posted May 28, 2014 Client side: addEventHandler ("onClientPlayerDamage", root, function () if getElementHealth (localPlayer) <= 20 then addEventHandler ("onClientPlayerDamage", getLocalPlayer (), cancelEvent) setElementHealth (localPlayer, 20) setPedAnimation (localPlayer, "BEACH", "bather") else removeEventHandler ("onClientPlayerDamage", getLocalPlayer (), cancelEvent) end end) الحدث OnClientPlayerDamage والحدث كلنت وانت حاط بعد الحدث كاتب root المفروض localPlayer صح ولا انا غلطاان.؟
iMr.Dawix~# Posted May 28, 2014 Posted May 28, 2014 Client side: addEventHandler ("onClientPlayerDamage", root, function () if getElementHealth (localPlayer) <= 20 then addEventHandler ("onClientPlayerDamage", getLocalPlayer (), cancelEvent) setElementHealth (localPlayer, 20) setPedAnimation (localPlayer, "BEACH", "bather") else removeEventHandler ("onClientPlayerDamage", getLocalPlayer (), cancelEvent) end end) الحدث OnClientPlayerDamage والحدث كلنت وانت حاط بعد الحدث كاتب root المفروض localPlayer صح ولا انا غلطاان.؟ صح كلامك + ما يتكنسل onPlayerDamage للي ردو فوق حدث onClientPlayerDamage بس
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