Jump to content

Mr.R

Members
  • Posts

    775
  • Joined

  • Last visited

Everything posted by Mr.R

  1. شرحك ممتاز > بدون مجامله لاكن مايستاهل 27 دقيقه , كذا ملل بزياده المفروض تجهز كل شيء قبل التصوير وبعدين تشرح يعني ماتكتب كل شيء في التصوير ... عشان تختصر الوقت هذا اقتراحي ووجة نظري , وبالتوفيق
  2. تفضل هذي الاكواد بعد التصليح الكلي ض1 , بطعاً شغاله 100% بس لوحتك فيها اغلاط كثير لازم تصلحها وياليت تخليها لوحه عاديه يكون احسن ومافيه مشاكل local places = { { "النخيل", 2123.62622, 1397.25793, 10.81252 }, } GUIEditor = { gridlist = {}, staticimage = {}, button = {}, label = {} } addEventHandler ( "onClientResourceStart", resourceRoot, function ( ) wnd = guiCreateStaticImage(0.00, 0.21, 0.16, 0.56, "11.png", true) guiSetProperty(wnd, "ImageColours", "FF00FFFC") guiSetVisible(wnd,false) label = guiCreateLabel(32, 16, 137, 71, "places", false, wnd) guiSetFont(label, "sa-gothic") guiLabelSetColor(label, 0, 255, 252) grid = guiCreateGridList(6, 87, 195, 289, false, wnd) guiGridListAddColumn(grid, "places", 0.9 ) for k,v in ipairs ( places ) do local Row = guiGridListAddRow ( grid ) guiGridListSetItemText ( grid, Row, 1, v[1], false, false ) guiGridListSetItemData ( grid, Row, 1, { v[2], v[3], v[4] } ) end btn_warb = guiCreateButton(8, 380, 60, 32, "warp", false, wnd) guiSetFont(btn_warb, "default-bold-small") guiSetProperty(btn_warb, "NormalTextColour", "FF00FFFC") btn_close = guiCreateButton(155, 380, 40, 32, "✖", false, wnd) guiSetProperty(btn_close, "NormalTextColour", "FF00FFFC") label2 = guiCreateLabel(10, 418, 181, 16, "that mod made by :- 1XxCr[o]sS", false, wnd) guiSetFont(label2, "default-bold-small") guiLabelSetColor(label2, 0, 255, 252) end ) bindKey ( "F6", "down", function ( ) guiSetVisible ( wnd, not guiGetVisible ( wnd ) ) showCursor ( guiGetVisible ( wnd ) ) end ) addEventHandler ( "onClientGUIClick", resourceRoot, function ( ) if ( source == btn_warb ) then if ( guiGridListGetSelectedItem ( grid ) ~= -1 ) then setElementPosition ( localPlayer, unpack ( guiGridListGetItemData ( grid, guiGridListGetSelectedItem ( grid ), 1 ) ) ) outputChatBox ( "* تم الإنتقال بنجاح", 0, 255, 0, true ) else outputChatBox ( "* الرجاء اختيار مكان للإنتقال إليه", 255, 0, 0, true ) end end end ) addEventHandler ( "onClientGUIClick", resourceRoot, function ( ) if ( source == btn_close ) then guiSetVisible ( wnd, false ) showCursor ( false ) end end )
  3. triggerServerEvent ( "check", localPlayer )
  4. مافيه مشكله يتعلم من الاكواد واذا بينسخ ويمشي هو الخسران @taha20110 توني افهمك معليش تبيه يطلع كلام في الشات , حسبته نص شف كود جابر وتعلم منه
  5. X كذا انت تخليه يضغط شيء عشان تطلع الصوره وهو يبيه اذا ضغط الصوره يصير شيء @taha20110 طلبك الاول عطيتك اياهـ وبخصوص ذا الفنكشن guiCreateStaticImage ( ... ) هذا حق الصورهـ , حط بداله الصوره حقتك وهذا طلبك الثاني استلمه photo = guiCreateStaticImage ( ... ) -- هنا استبدله بفنكشن الصورهـ حقتك , حطيته بس للتوضيح عشان المثال addEventHandler ( "onClientMouseEnter", resourceRoot, function ( ) if ( source == photo ) then -- هنا اختار فنكشن الكلام الي يطلع وحطه هنا عشان يطلع النص -- dxDrawText or guiCreateLabel end end ) هنا اختار نوع الكلام الي تبيه يطلع عن طريق الفنكشنين ذول < اضغط عليها عشان تشوف الامثله dxDrawText او guiCreateLabel
  6. هذا طلبك photo = guiCreateStaticImage ( ... ) addEventHandler ( "onClientGUIClick", resourceRoot, function ( ) if ( source == photo ) then -- الأمر الي تبيه يصير بعد الضغط على الصوره end end )
  7. خلاص مشكورين حليت الممشكله : )...
  8. بالنسبه للأفك الولد قصدهـ كذا function AFK ( ) if ( source == اسم الزر ) then setElementInterior ( localPlayer, 0, x, y, z ) -- بالاحداثيات فالمكان الي يعجبك داخل الانترو x, y, z بدل 0 بالانترو الي تبيه ينتقل له وبدل setElementFrozen ( localPlayer, true ) outputChatBox ( "* تم نقلكـ لعالم الافك", 255, 255, 255, true ) else setElementInterior ( localPlayer, 0, x, y, z ) --بالاحداثيات الي تبيه يرجع لها للعالم الحقيقي x, y, z بدل setElementFrozen ( localPlayer, false ) outputChatBox ( "* تم الرجوع للعالم الحقيقي", 255, 255, 255, true ) end end addEventHandler ( "onClientGUIClick", getRootElement ( ), AFK )
  9. لو تبحث شوي بس بالقسم .
  10. مثال سريع على طريقتي + هي شغاله 100% لاكن تسوي زحمه في ملف سيرفر وكذا Client local Weapons = { [ 1 ] = { "Minigun", 38, 4000 }, -- اسم السلاح والايدي والسعر [ 2 ] = { "Armor", "ArmorIteam", 1300 }, -- نلاحظ هنا الدرع ماله ايدي } addEventHandler ( "onClientGUIClick", resourceRoot, function ( ) if ( source == Button1 ) then if ( guiGridListGetSelectedItem ( GridList ) ~= -1 ) then local Money = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 2 ) local iD = guiGridListGetItemData ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) if ( Money ~= '' and iD ~= '' ) then triggerServerEvent( "Weapon", localPlayer, iD, Money ) end else outputChatBox ( "* Please Select Weapon", 255, 0, 0, true ) end end end ) Server addEvent( "Weapon", true ) addEventHandler( "Weapon", root, function ( iD, Money ) if not ( iD == "ArmorIteam" ) then if ( getPlayerMoney ( client ) >= tonumber ( Money ) ) then if ( giveWeapon ( client, tonumber ( iD ), 2000 ) ) then takePlayerMoney ( client, tonumber ( Money ) ) outputChatBox ( "* You Bought "..getWeaponNameFromID ( iD ).." With "..tonumber ( Money ).."", client, 0, 255, 0, true ) end else outputChatBox ( "* You Don't Have engouf money", client, 255, 0, 0, true ) end else if ( getPlayerMoney ( client ) >= tonumber ( Money ) ) then setPedArmor ( client, 100 ) takePlayerMoney ( client, tonumber ( Money ) ) outputChatBox ( "* You Bought Armor With "..tonumber ( Money ).."", client ) else outputChatBox ( "* You Don't Have engouf money", client ) end end end ) يعني هذي طريقتي الحاليه زي ما انتو شايفين , اي شيء بأضيفه ماله ايدي لازم اتحقق من سعره اكبر من او يساوي واسويه الي عندهـ طريقه مختصره او حركه يطرحها .
  11. السلام عليكم انا عندي متجر اسلحه كامل عموما جيت بأضيف دم + درع طبعاً معروف لكل سلاح أيدي , وهنا المشكله مالقيت للدم والدرع ايدي > ادري من زمان مالهم أيدي لاكن يوم جيت اطبق لقيت هالمشكله حطيت ايدي بالسترنق وهمي وضبط وفعلاً ضبط "ArmorIteam" مثلا جدول >> tableملاحظه : مسوي الاسلحه والدم والدرع إلخ... بـ والطريقه الي استخدمها غبيه شوي ومسويه زحمه وياليت اي واحد عنده طريقه مختصرهـ وحلوه يطرحها لاني بأضيف كذا شيء ماله أيدي لحد يجيب طريقه كلها كلنت لاني ما ابي الدرع وهمي , انا مسويها بالترايقر للسيرفر وجزاكم الله خير ^^
  12. مثال على طلبك addEventHandler ( "onClientGUIClick", resourceRoot, function ( ) if ( source == اسم الزر ) then if ( isTimer ( Timer ) ) then return end Timer = setTimer ( function ( ) end, 4000, 1 ) -- بدّل 4000 بالمده الي تبيها end end )
  13. هو طرحه يقول وش الخطأ يمكن ما أضاف حدث ووظيفه او ملف مليتا + مشكور عالمعلومه ^
  14. addEventHandler ( "onClientResourceStart", resourceRoot, function ( ) local x = 5 local y = 3 local w = x + y outputChatBox ( tostring ( w ) ) end )
  15. اهنيك مبببدع صراحه <3 لا توقف
  16. 2011 سيرفر حمودي هجوله ثم بيس مود تابل , احسن سيرفر لعبت فيه : ( ايام ايام الله يسقيها
  17. addCommandHandler("VIP", function (Player) if isObjectInACLGroup("user."..getAccountName(getPlayerAccount(Player)), aclGetGroup("VIP")) then triggerClientEvent(Player, "Open_VIP", Player) end end ) + addEvent ( "Open_VIP", true ) addEventHandler ( "Open_VIP", root, function ( ) guiSetVisible ( اسم النافذهـ, true ) showCursor ( true ) end )
  18. كودكـ صحيح بس بكذا الدم وهمي , يعني مايشوفه الا الاعب نفسه @DTC12 شف كود صحيح 100% بس مدري ليه حاط الدم 200 اتوقع ماتضبط لازم فنكشن setPedStat
  19. addEventHandler ( "onClientGUIClick", resourceRoot, function ( ) if ( source == اسم الزر ) then exports [ "guimessages" ] : outputClient ( root, "Hi All", 255, 255, 255, true ) end end ) بكذا بيطلع الكلام للكل الي في السيرفر بناء على طلبك + حطه من جانب كلينت وتأكد من ملف الميتا انه مضبوط يكون شغال عشان يطلع الكلام guimessgaes وضروري مود
  20. local marker = createMarker ( ... ) addEventHandler ( "onClientMarkerHit", resourceRoot, function ( player ) if ( player == localPlayer ) and ( source == marker ) then guiSetVisible ( اسم النافذهـ, true ) showCursor ( true ) end end )
  21. local marker = createMarker ( 3724.6000976563, -385.5, 1.6000000238419, "cylinder", 4, 255, 255, 255, 255 ) setElementData ( marker, "OpenOrClose", false ) function ( ) if ( isTimer ( OpenMarker ) ) then killTimer ( OpenMarker ) end OpenMarker = setTimer ( function ( ) setElementData ( Marker, "OpenOrClose", true ) outputChatBox ( "* بدأت المهمه", source, 255, 255, 255, true ) end end, 50000, 0 ) كود التايمر .. لم تتم التجربه
  22. ^ luac مو شرط يكون تأكد من صيغته زين وجرب تحط ترميز الملف UTF-8 -- يمكن تنفع ما أدري بالتوفيق
  23. استبدل كودك الي بكلنت بـ هذا function MarkerHit ( hitPlayer ) if getElementType ( hitPlayer ) == "player" then triggerServerEvent ( "GiveWeaponGift", hitPlayer ) destroyElement ( GiftBlip ) destroyElement ( GiftObject ) destroyElement ( GiftMarker ) end end addEventHandler ( "onClientMarkerHit", GiftMarker, MarkerHit )
×
×
  • Create New...