Jump to content

Mr.R

Members
  • Posts

    775
  • Joined

  • Last visited

Everything posted by Mr.R

  1. ع البر ولا ع الجو عالجو ولا عالطاير عالطاير ولا عالنازل
  2. Client local button = guiCreateButton(...) -- هنا زرك ياقدع addEventHandler("onClientGUIClick", resourceRoot, function( ) if source == button then triggerServerEvent("changeLocalPlayerVehicleColor", localPlayer, 255, 0, 0) end end) Server addEvent("changeLocalPlayerVehicleColor", true) addEventHandler("changeLocalPlayerVehicleColor", root, function(r, g, b) local vehicle = getPedOccupiedVehicle(source) if vehicle then setVehicleColor(vehicle, r, g, b) else outputChatBox("اركب العربية ياقدع", source, 255, 0, 0) end end) ليه ارسلت اللون مع الترايقر وماحطيته مباشره في الفنكشن ؟؟؟
  3. اهنيك تسلم يديك , مود مثل صاحبه يصلح حق مسابقات ض1 لاتحرمنا من ابداعاتك بالتوفيق
  4. يعني مثلاً أنا عطيت نفسي دم من جانب كلنت واللاعب الي قدامي يشوف دمي القديم؟ ماهيب أي وظيفة تحطها بجانب كلنت تصير وهمية انا قلت اغلبها + هذا الي تعلمته من الكلام الي جاني والله اعلم
  5. كنت حاط بدل لوكال بلاير سورس ناسي ض1 لاكن يبقى وهمي الدم لانه من كلنت هذا الي اعرفه , والي قالوه لي هل الخبره ادخل سيرفر مجاني من جهازك هذا واذا عندك جهاز ثاني ادخل فيه بعد يعني خلكم في خادم واحد وعط لاعبك دم وشف الاعب الثاني يشوفه ولالا
  6. رح جرب انا جربتها من زمان ماضبطت وسألت كذا مبرمج كبير وجربتها قبل شوي بعد م ضبطت
  7. جرب الحين , الكود شغال تمام وزي ماتبي جربته @Me[Z]oO المفروض تعطيه دم من جانب سيرفر لانه حاليا من جانب كلنت في كودك وهذا غلط لان الدم يكون وهمي ممكن دليل انه وهمي ؟ + ليش تتحقق ان دمه 100 وتسوي ريتيورن يمكن الرجال معطي الاعب دم 200 ولو ضغط الزر يجيه 100 وكذا >< الدليل جرب تعطيه دم من جانب كلنت , مايقبل اصلا لازم سيرفر + معروف ان الكلنت وهمي لا تسألني انا اسأله هو لانه هو الي حاطها , انا صححت له الكود لا اقل ولا اكثر اذا حاط الدم 200 بسيطه يشيل التحقق وخلاص مع اني متأكد غالبا انه حاطه 100 واذا الدم 100 يكون احسن يخلي التحقق عشان اذا جاء الاعب ياخذ دم مره ثانيه ودمه 100 مايعطيه الا اذا نقص عشان م يكرر كلام في الشات + ماله داعي اصلا ياخذ دم 100 ودمه اصلا 100
  8. جرب الحين , الكود شغال تمام وزي ماتبي جربته @Me[Z]oO المفروض تعطيه دم من جانب سيرفر لانه حاليا من جانب كلنت في كودك وهذا غلط لان الدم يكون وهمي
  9. تفضل شغال 100% تمت التجربه -- Client Side GUIEditor = { window = { } } addEventHandler ( "onClientResourceStart", resourceRoot, function ( ) GUIEditor.window[1] = guiCreateWindow(420, 190, 361, 182, "::Panel x6lbat::", false) guiWindowSetSizable(GUIEditor.window[1], false) guiSetVisible ( GUIEditor.window[1], false ) give = guiCreateButton(21, 47, 93, 33, "Give Car", false, GUIEditor.window[1]) take = guiCreateButton(134, 47, 93, 33, "Destroy Car", false, GUIEditor.window[1]) kill = guiCreateButton(247, 47, 93, 33, "Slap", false, GUIEditor.window[1]) health = guiCreateButton(21, 123, 93, 33, "100 Health", false, GUIEditor.window[1]) armor = guiCreateButton(134, 123, 93, 33, "100 Armor", false, GUIEditor.window[1]) fly = guiCreateButton(247, 123, 93, 33, "Fly Car", false, GUIEditor.window[1]) end ) bindKey ( "x", "down", function ( ) guiSetVisible ( GUIEditor.window[1], not guiGetVisible ( GUIEditor.window[1] ) ) showCursor ( guiGetVisible ( GUIEditor.window[1] ) ) end ) addEventHandler ( "onClientGUIClick", resourceRoot, function ( ) if ( source == health ) then triggerServerEvent ( "Give_He", localPlayer ) elseif ( source == armor ) then triggerServerEvent ( "Give_Ar", localPlayer ) elseif ( source == kill ) then triggerServerEvent ( "playerkill", localPlayer ) elseif ( source == fly ) then setWorldSpecialPropertyEnabled ( "aircars", true ) outputChatBox ( "You Can Fly know !!", 255, 255, 255, true ) elseif ( source == take ) then triggerServerEvent( "DestroyMyCar",localPlayer ) elseif ( source == give ) then triggerServerEvent ( "GiveVehicle", localPlayer ) end end ) -- Server Side local table = { }; addEvent ( "Give_Ar", true ) addEventHandler ( "Give_Ar", root, function ( ) if ( getPedArmor ( source ) == 100 ) then return end setPedArmor ( source, 100 ) outputChatBox ( "Done Armor", source, 255, 255, 255, true ) end ); addEvent ( "Give_He", true ) addEventHandler ( "Give_He", root, function ( ) if ( getElementHealth ( source ) == 100 ) then return end setElementHealth ( source, 100 ) outputChatBox ( "Done Health", source, 255, 255, 255, true ) end ); addEvent ( "playerkill", true ) addEventHandler ( "playerkill", root, function ( ) killPed ( source, source ) outputChatBox ( "Done Kill", source, 255, 255, 255, true ) end ); addEvent ( "GiveVehicle", true ) addEventHandler ( "GiveVehicle", root, function ( ) if isElement ( table[source] ) then destroyElement ( table[source] ) end local PosX, PosY, PosZ = getElementPosition ( source ) table[source] = createVehicle ( 411, PosX, PosY, PosZ ) warpPedIntoVehicle ( source , table[source] ) end ); addEvent ( "DestroyMyCar", true ) addEventHandler ( "DestroyMyCar", root, function ( ) if ( table[source] ) and isElement ( table[source] ) then destroyElement ( table[source] ) end end ); addEventHandler ( "onPlayerQuit", root, function ( ) if ( table[source] ) and isElement ( table[source] ) then destroyElement ( table[source] ) table[source] = nil end end ); @Me[Z]oO بالله وش غيرت بكودهـ ض1
  10. Client local Cars = { { "Ferrari", 250, 100000 }, { "Nissan", 130, 2000000 }, } for _,v in ipairs ( Cars ) do local row = guiGridListAddRow ( grid ) guiGridListSetItemText ( grid, row, 1, v[1], false, false ) guiGridListSetItemText ( grid, row, 2, v[3], false, false ) guiGridListSetItemData ( grid, row, 1, v[2] ) end addEventHandler ( "onClientGUIClick", resourceRoot, function ( ) if ( source == buy ) then if ( guiGridListGetSelectedItem ( grid ) ~= -1 ) then local Money = guiGridListGetItemText ( grid, guiGridListGetSelectedItem ( grid ), 2 ) local CarName = guiGridListGetItemText ( grid, guiGridListGetSelectedItem ( grid ), 1 ) local iD = guiGridListGetItemData ( grid, guiGridListGetSelectedItem ( grid ), 1 ) if ( Money ~= "" and iD ~= "" and CarName ~= "" ) then triggerServerEvent ( "GiveCar", localPlayer, iD, Money, CarName ) end else outputChatBox ( "* الرجاء اختيار سيارهـ اولاً", 255, 0, 0, true ) end end ) Server local Vehicle = { }; addEvent ( "GiveCar", true ) addEventHandler ( "GiveCar", root, function ( iD, Money, CarName ) if ( Vehicle[source] ) and isElement ( Vehicle[source] ) then destroyElement ( Vehicle[source] ) end if ( getPlayerMoney ( source ) >= tonumber ( Money ) ) then takePlayerMoney ( source, tonumber ( Money ) ) outputChatBox ( "* $".. tonumber ( Money ) .." بـ ".. CarName .." تم شراء السيارهـ", source, 255, 255, 255, true ) else outputChatBox ( "* ".. CarName .." لا تملك المال الكافي لـ شراء", source, 255, 255, 255, true ) end local x, y, z = getElementPosition ( source ) Vehicle[source] = createVehicle ( iD, x, y, z ) warpPedIntoVehicle ( source, Vehicle[source] ) end ) لم تتم التجربه
  11. شف ردي هنا بيفيدك
  12. addEventHandler ( "onClientGUIClick", resourceRoot, function ( ) if ( source == GUIEditor.button[2] )then triggerServerEvent ( "pizza", localPlayer ) guiSetEnabled ( GUIEditor.button[2], false ) setTimer ( function ( ) guiSetEnabled ( GUIEditor.button[2], true ) end, 10000, 1 ) end end )
  13. triggerServerEvent ("pizza",localPlayer) guiSetEnabled (button , true) setTimer ( function ( ) guiSetEnabled ( button , false ) end ,20000,1) انسخ كود ااتايمر وحطه بعد التريقر بمللف الكلنت !!! يصير كذا يالحبيب guiSetEnabled ( button , false ) setTimer ( function ( ) guiSetEnabled ( button , true ) end, 20000, 1 ) انت عاكس الترو والفولس دقق الحين وشف الفرق
  14. هنا تلقى الحركات كلها من إلى Animations
  15. جرب addEventHandler ( "onClientRender", resourceRoot, function ( ) for k,v in ipairs ( getElementsByType ( "player" ) ) do if ( getElementHealth ( v ) >= 1 ) then local width, height = guiGetScreenSize ( ) local lx, ly, lz = getWorldFromScreenPosition ( width / 2, height / 2, 10 ) setPedLookAt ( v, lx, ly, lz ) end end end )
  16. جرب CheckBox = guiCreateCheckBox ( ... ) addEventHandler ( "onClientGUIClick", Soking, function ( ) if ( guiCheckBoxGetSelected ( CheckBox ) == true ) then executeCommandHandler ( "Soking" ) end end,false )
  17. ^ تم ماانتبهت لها هههه , مشكور عالتنبيه
  18. local marker = createMarker ( ... ) -- استبدله بفنكشن الماركر حقك addEventHandler ( "onMarkerHit", root, function ( player ) if ( source == marker ) and ( getElementType ( player ) == "player" ) then setPedAnimation ( player, "IDLE_chat", "IDLE_chat" ) outputChatBox ( "* انت الان ترقص ض1", player, 0, 255, 0, true ) end end ) ! لم تتم التجربه
  19. الحين وضح انت تبي الاعب يركب السياره اذا ضغط زر ولا اذا لمس ماركر ولا ايش بالضبط ؟؟؟
  20. ^ تم التعديل مشكور عالتنبيه
  21. تفضل هذا طلبك كامل , لاتنسخه وتمشي افهم كيف صارت الاكواد واذا منت فاهم شيء تفضل , اسأل عنه .. #Client local Skins = { { "ARMY", 287 }, { "SWAT", 285 }, -- { "Skin Name", iD }, -- ضيف كل السكنات الي تبيها لو مليون سكن } addEventHandler ( "onClientResourceStart", resourceRoot, function ( ) Window1 = guiCreateWindow ( 247, 143, 639, 510, "Skin Window", false ) guiWindowSetSizable ( Window1, false ) guiSetVisible ( Window1, false ) GridList = guiCreateGridList ( 9, 21, 154, 452, false, Window1 ) guiGridListAddColumn ( GridList, "Skins...", 0.9 ) for _,v in ipairs ( Skins ) do local Row = guiGridListAddRow ( GridList ) guiGridListSetItemText ( GridList, Row, 1, tostring ( v[1] ), false, false ) guiGridListSetItemData ( GridList, Row, 1, tonumber ( v[2] ) ) end Button1 = guiCreateButton ( 191, 350, 200, 49, "Change Skin", false, Window1 ) end ) bindKey ( "F5", "down", function ( ) guiSetVisible ( Window1, not guiGetVisible ( Window1 ) ) showCursor ( guiGetVisible ( Window1 ) ) end ) addEventHandler ( "onClientGUIClick", resourceRoot, function ( ) if ( source == Button1 ) then if ( guiGridListGetSelectedItem ( GridList ) ~= -1 ) then local SkinName = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) local SkiniD = guiGridListGetItemData( GridList, guiGridListGetSelectedItem( GridList ), 1 ) if ( SkinName ~= '' and SkiniD ~= '' ) then triggerServerEvent ( "Skin", localPlayer, SkiniD ) end else outputChatBox ( "* Please Select Skin", 0, 255, 0, true ) end end end ) #Server addEvent ( "Skin", true ) addEventHandler ( "Skin", root, function ( SkiniD ) setElementModel ( source, tonumber ( SkiniD ) ) outputChatBox ( "* Changed Skin", source, 255, 0, 0, true ) end )
  22. ^ ايه صحيح , استخدمه اول لاكن ماجاء على بالي a وهو اخر ارقمنت اسمه marker createMarker ( float x, float y, float z [, string theType = "checkpoint", float size = 4.0, int r = 0, int g = 0, int b = 255, int a = 255 ] ) استبدله من 255 إلى 0 عشان ينخفي واذا حاب تستخدم هذا الفنشكن setElementAlpha .. مافيه مشكله
  23. عشان تعطله استخدم الداتا setElementData getElementData وعشان تخفيه setElementAlpha اذا بتسخدم هذا destroyElement مراح يكون موجود نهائياً لاكن الفنكشن الي فوقه يكون موجود بلفعل لاكن مخفي
  24. جرب كذا MD = { {"1-الجبل",-2242.18115,-1726.20325,480.39978}, {"2-الصحراء",214.83893,1863.85681,13.14063}, {"3-حارة سي جي",2384.80933,-1669.25671,13.73438}, }
×
×
  • Create New...