αвυ-wαleed Posted June 24, 2015 Posted June 24, 2015 ابغى شرط اللي هو كل الاسلحة تقدر تدخل الماركر بس اذا كان معه سلاح رقم 5 يتم نقلة ابغى الشرط بس هذا اللي يهمني مثل كذا if getElementHealth(thePlayer) <= 10 then اذا كان دم اللاعب اقل من عشرة يمكنه دخول الماركر يعني ابغى التحقق يساوي ولا يساوي اذا كان السلاح لا يساوي 5 يدخل
Mr.R Posted June 24, 2015 Posted June 24, 2015 (edited) الي فهمته منك انك تبي الاعب يدخل الماركر بكل الاسلحه الا السلاح رقم 5 هذا الكود تفضل local Marker = createMarker ( ... ) addEventHandler ( "onClientMarkerHit", resourceRoot, function ( ) if ( getElementType ( localPlayer ) == "player" ) and ( source == Marker ) then if ( getPedWeapon ( localPlayer ) ~= 5 ) then return outputChatBox ( "لا يمكنك الانتقال , لانك تملك السلاح رقم 5", true ) end setElementPosition ( localPlayer, x, y, z ) -- x,y,z هنا حط الاحداثيات بدل end end ) Edited June 24, 2015 by Guest
TAPL Posted June 24, 2015 Posted June 24, 2015 ابغى شرط اللي هو كل الاسلحة تقدر تدخل الماركر بس اذا كان معه سلاح رقم 5 يتم نقلة اذا كان السلاح لا يساوي 5 يدخل الي فهمته منك انك تبي اذا الاعب معه سلاح رقم 5 ينقله وباقي الاسلحه ماينقله ويقدر يدخل عاديهذا الكود تفضل local Marker = createMarker ( ... ) addEventHandler ( "onClientMarkerHit", resourceRoot, function ( ) if ( getElementType ( localPlayer ) == "player" ) and ( source == Marker ) then if ( getPedWeapon ( localPlayer ) == 5 ) then return outputChatBox ( "لا يمكنك الانتقال , لا تملك السلاح رقم 5", true ) end setElementPosition ( localPlayer, x, y, z ) -- x,y,z هنا حط الاحداثيات بدل end end ) ! والشرط الي يجيب دم الاعب حقك صحيح معرفه thePlayer بس تأكد ان واذا تبغي العكس خل الشرط كذا if ( getPedWeapon ( localPlayer ) ~= 5 ) then return outputChatBox ( "يمكنك الدخول لانك , لا تملك السلاح رقم 5", true ) end في هذي الحاله بيصير العكس تدخل بكل الاسلحه الا سلاح رقم 5 اتوقع فهمت قصدي صراحه انلحس مخي
αвυ-wαleed Posted June 25, 2015 Author Posted June 25, 2015 تمت الافادة هذا اللي كنت احتاجة if ( getPedWeapon ( localPlayer ) ~= 5 )
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