momar5700 Posted September 1, 2015 Share Posted September 1, 2015 سلام عليكم ورحمة الله وبركاته لوحة فيها زر تفتح لوحة بمود تانبه بس مستر جراند سوي شرح بس مشكلة انه بنفس المود انا ابي اسوي بمود اخري يعني لوحة الاول بي مود ولوحة تانيه بمود 2 ولوحة الاول بها زر دوس عليها تفتح لك لوحة تانيه ممكن شرح هاد لوحة الاول -- Window 1 local screenW, screenH = guiGetScreenSize() Window1 = guiCreateWindow((screenW - 394) / 2, (screenH - 310) / 2, 394, 310, "لوحة f5", false) guiWindowSetSizable(Window1, false) guiSetAlpha(Window1, 1.00) guiSetVisible(Window1,false) BTN2-OPEN = guiCreateButton((394 - 156) / 2, (310 - 36) / 2, 156, 36, "لوحة قوانين", false, Window1) BTN1_open = guiCreateButton((394 - 156) / 2, (310 - 36) / 2, 156, 36, "لوحة معلومات", false, Window1) BTN2_Close1 = guiCreateButton(280, 264, 104, 32, "إغلاق اللوحة", false, Window1) -- Window 2 local screenW, screenH = guiGetScreenSize() Window2 = guiCreateWindow((screenW - 275) / 2, (screenH - 362) / 2, 275, 362, "لوحة المعلومات", false) guiWindowSetSizable(Window2, false) guiSetAlpha(Window2, 1.00) guiSetVisible(Window2,false) BTN3_close2 = guiCreateButton(175, 312, 90, 34, "إغلاق", false, Window2) -- Functions local KEY = "F5" function OPEN() guiSetVisible(Window1,true) showCursor(true) end bindKey(KEY,"down",OPEN) addEventHandler("onClientGUIClick",root, function() if source == BTN2_Close1 then -- هنا يتحققق بأن الشيء اللي نبيه يشتغل عليه الحدث هو الزر حق الاغلاق guiSetVisible(Window1,false) showCursor(false) -- هنا يغلق اللوحة ويشيل المؤشر بعد مايتحقق من الشرط end -- نهاية end -- .. ) -- اقفال الحدث addEventHandler('onClientGUIClick',root, function() if source == BTN1_open then -- هنا يتحقق بأن الشيء اللي نبي الحدث يتطبق عليه هو الزر حق فتح لوحة رقم 2 guiSetVisible(Window2,true) showCursor(true) -- هنا يفتح لنا اللوحة guiSetVisible(Window1,false) -- إغلاق نافذة 1 end -- نهاية end -- .. ) -- إقفال addEventHandler('onClientGUIClick',root, function() if source == BTN3_close2 then guiSetVisible(Window2,false) showCursor(false) end end ) addEventHandler('onClientGUIClick',root, function() if source == BTN2-OPEN then -- هنا يتحقق بأن الشيء اللي نبي الحدث يتطبق عليه هو الزر حق فتح لوحة رقم 2 guiSetVisible(Window2,true) showCursor(true) -- هنا يفتح لنا اللوحة guiSetVisible(Window1,false) -- إغلاق نافذة 1 end -- نهاية end -- .. ) الحين وش اكتب يلوحة القونين علشان المود ده يفتحها او وش اكتب هنا علشان تفتح لوحة القوانين Link to comment
iMr.SFA7 Posted September 1, 2015 Share Posted September 1, 2015 عندي لك فكرة خل لوحتك الثآنية تفتح بأمر من اف8 addCommandHandler guiSetVisible showCursor وخل الزر الي تبيه يفتح اللوحة لما يضغطه كأنه كتب الأمر تمآم ؟ "onClientGUIClick" executeCommandHandler Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 طيب ممكن كامل لو سمحت وممكن ترد علي موضوعي حق القيم مود ولا انت خلاص سحبت علي Link to comment
iMr.SFA7 Posted September 1, 2015 Share Posted September 1, 2015 طيب ممكن كامل لو سمحت لا Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 لاني بصراحا ماعرف طريقة صنع الاكواد ليه كدا Link to comment
iMr.SFA7 Posted September 1, 2015 Share Posted September 1, 2015 لاني بصراحا ماعرف طريقة صنع الاكواد أنا لا أعتقد أن في شيء غاصبك أنك ما تتعلم حآول حآول حآول Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 طيب انا الحين سويت لوحة قوانين تفتح بي باف8 addCommandHandler('QWANEN', function() local vis = not guiGetVisible(GUIEditor.window[1]) guiSetVisible(GUIEditor.window[1],vis) showCursor(vis) end ) الحين كيف اسوي زر Link to comment
iMr.SFA7 Posted September 1, 2015 Share Posted September 1, 2015 كودك فيه أخطاء ^ صححته لكك addCommandHandler('QWANEN', function() guiSetVisible(GUIEditor.window[1],true) showCursor( true ) end ) بالنسبة للزر حآول "onClientGUIClick" executeCommandHandler Link to comment
The Killer Posted September 1, 2015 Share Posted September 1, 2015 تقدر تستعمل exports وهذي طريقه ثانيه بعد .. # Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 هادا فيه خطا function open () showCursor ( false ) executeCommandHandler ( "الكلمة الي تفتح بأف 8 في السكربت الاول" ) end Link to comment
iMr.SFA7 Posted September 1, 2015 Share Posted September 1, 2015 هادا فيه خطا function open () showCursor ( false ) executeCommandHandler ( "الكلمة الي تفتح بأف 8 في السكربت الاول" ) end وين الحدث؟ وأنت تبي تظهر الوحة ليه تخفي المآوس؟ Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 addEventHandler('onClientGUIClick',root, function() if source == GUIEditor.button[5] then showCursor ( false ) executeCommandHandler ( "QWANEN" ) end انا سويته كدا بس مود مايبي يشتغل Link to comment
MoDeR2014 Posted September 1, 2015 Share Posted September 1, 2015 تفضل مثال للكلينت MainWindow = guiCreateWindow(10, (screenH - 325) / 2, 240, 325, "[ Skin Shop ]", false) guiSetVisible(MainWindow, false); function showSkinShopPanel( bool ) if guiGetVisible(MainWindow) ~= bool then guiSetVisible(MainWindow ,bool); showCursor(bool); end end طبعاً سويت الفنكشن الي يفتح النافذه اسمه showSkinShopPanel نسويله اكسبورت من الميتا function="showSkinShopPanel" type="client"/> الحين لما نبي نفتح هذي النافذه من مود ثاني نسويله اكسبورت من المود الثاني exports["اسم المود الي تبي تتصل بيه"]:showSkinShopPanel( true ) ان شاء الله تكون فهمت https://forum.multitheftauto.com/viewtopic.php?f=160&t=91209 Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 الوو مافهمت ولا شيء منك ولا حتي حرف واحد Link to comment
iMr.SFA7 Posted September 1, 2015 Share Posted September 1, 2015 addEventHandler('onClientGUIClick',root, function() if source == GUIEditor.button[5] then showCursor ( true ) executeCommandHandler ( "QWANEN" ) end end ) Link to comment
MoDeR2014 Posted September 1, 2015 Share Posted September 1, 2015 الوو مافهمت ولا شيء منكولا حتي حرف واحد اقرأ براحه وتفهم Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 ايه نجح سويته كدا addEventHandler('onClientGUIClick',root, function() if source == GUIEditor.button[5] then showCursor ( false ) executeCommandHandler ( "QWANEN" ) end end ) بس لوحة الاول تفطل موجودة ليه Link to comment
iMr.SFA7 Posted September 1, 2015 Share Posted September 1, 2015 addEventHandler('onClientGUIClick',root, function() if source == GUIEditor.button[5] then showCursor ( false ) executeCommandHandler ( "QWANEN" ) guiSetVisible (اسم اللوحة القديمة ,false) end end ) Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 bindKey("F6", "down", function ( ) if guiGetVisible (GUIEditor.window[1] ) then guiSetVisible (GUIEditor.window[1] , false ) showCursor(false) guiSetInputEnabled(false) else guiSetVisible (GUIEditor.window[1] , true ) showCursor(true) guiSetInputEnabled(true) end end ) بس انا لما اختار القوانين تروح لوحة بس ادمن ماتشتغل لازم اضغط زر اف6 واضغط تاني علشان تروح ليش هادا هو زر فوق وش الخطا Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 والفارة لما تروح لوحة تفضل موجودة Link to comment
iMr.SFA7 Posted September 1, 2015 Share Posted September 1, 2015 عدل كود فتح النافذة بكومماند وحطه كذآ = )) addCommandHandler('QWANEN', function() if ( guiGetVisible (GUIEditor.window[1]) == false ) then guiSetVisible(GUIEditor.window[1],true) showCursor( true ) else guiSetVisible (GUIEditor.window[1],false) showCursor ( false ) end end ) Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 (edited) طيب بس لما انا اضغط قوانين تروح لوحة بس اضغط ادمن ماتبي تشتغل ليش علشان تشتغل لازم ادوز اف6 علشان افتح وادوس مره تانيه عليه علشان اقفله ويشتغل ادمن طيب ليه bindKey("F6", "down", function ( ) if guiGetVisible (GUIEditor.window[1] ) then guiSetVisible (GUIEditor.window[1] , false ) showCursor(false) guiSetInputEnabled(false) else guiSetVisible (GUIEditor.window[1] , true ) showCursor(true) guiSetInputEnabled(true) end end ) Edited September 1, 2015 by Guest Link to comment
iMr.SFA7 Posted September 1, 2015 Share Posted September 1, 2015 طيب بس لما انا اضغط قوانين تروح لوحة بس اضغط ادمن ماتبي تشتغل ليش علشان تشتغل لازم ادوز اف6 علشان افتح وادوس مره تانيه عليه علشان اقفله ويشتغل ادمن طيب ليه وضح لآهنت آيش دخل الادمن؟ Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 الحين ابي افتح قوانين لما افتحها تروحه الوحة ولوحة القوانين تشتغل بس ادوس علي حرف ح مايبي يظهر لوحة الادمن ادوس علي اف6 مرتين علشان تفتح لوحة وتسكر تشتغل ليش Link to comment
momar5700 Posted September 1, 2015 Author Share Posted September 1, 2015 هو الحين في خطا في ده bindKey("F6", "down", function ( ) if guiGetVisible (GUIEditor.window[1] ) then guiSetVisible (GUIEditor.window[1] , false ) showCursor(false) guiSetInputEnabled(false) else guiSetVisible (GUIEditor.window[1] , true ) showCursor(true) guiSetInputEnabled(true) end end ) 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