Wleed1998 Posted July 4, 2016 Share Posted July 4, 2016 آلسلام عليكم اريد مجموعة فانكشنات متطلبآت 1- فكرت المود المود عباره عن لوحتين لوحه فيه 6 شك بوكس 3 منه لحال و 3 لحال ال3 الاول نوع الشيء مثل يبي يشتري تاج -ساعات -املاك ال3 الثاني طريقة الشراء كاش يو - سواء -موبايل بعدين فيه 6 ايدت يحط فيه ارقام البطآيق و لما يمليه ويظغط زر ارسال المعلومات تروح ل لوحة الادآره لوحة آلآدره فيه جريد لست و 4 كولمن الكولمن الاول اسم الاعب الثاني نوع المشترى الثالث بنوع الباقه الرابع ارقام الي ارسله وفيه 1 بوتن واحد يحذف من الكولمن المحددد عليه ض1 طلبي شكله مزعج بس وش اسوي شرحت لكم ب التفصيل المود ض1 Link to comment
' A F . Posted July 4, 2016 Share Posted July 4, 2016 فيه اكثر من موضوع بنفس الفكرة ابحث Link to comment
Wleed1998 Posted July 4, 2016 Author Share Posted July 4, 2016 فيه اكثر من موضوع بنفس الفكرة ابحث ممكن رابطه Link to comment
Mhmd.z Posted July 4, 2016 Share Posted July 4, 2016 --client "onClientGUIClick" guiCheckBoxGetSelected guiGetText getPlayerName triggerServerEvent guiGridListAddRow guiGridListSetItemText guiGridListGetSelectedItem guiGridListGetItemText guiGridListRemoveRow --server getPlayerAccount isObjectInACLGroup triggerClientEvent Link to comment
Wleed1998 Posted July 4, 2016 Author Share Posted July 4, 2016 --client "onClientGUIClick" guiCheckBoxGetSelected guiGetText getPlayerName triggerServerEvent guiGridListAddRow guiGridListSetItemText guiGridListGetSelectedItem guiGridListGetItemText guiGridListRemoveRow --server getPlayerAccount isObjectInACLGroup triggerClientEvent مشكور اخي بس مو بي SQL يكون افضل طيب لوو العب حط معلومات و طلع وانا مني داخل السيرفر اذا دخلت القاء المعلومات ولا لا Link to comment
#STZ Posted July 4, 2016 Share Posted July 4, 2016 تلقا لاكن اذا سويت ريفرش للمود او رستارت للسيرفر ما بتلاقيه استخدم قواعد البيانات افضل لك Link to comment
Wleed1998 Posted July 5, 2016 Author Share Posted July 5, 2016 تلقا لاكن اذا سويت ريفرش للمود او رستارت للسيرفر ما بتلاقيه استخدم قواعد البيانات افضل لك كيف اربط معلومات الوحه الاول ب الثاني طيب Link to comment
MR.GRAND Posted July 5, 2016 Share Posted July 5, 2016 هذا الشيء الجميل مومشفر تقدر تستفيد منه ^ https://forum.multitheftauto.com/viewtopic.php?f=161&t=98962 Link to comment
Wleed1998 Posted July 5, 2016 Author Share Posted July 5, 2016 --client "onClientGUIClick" guiCheckBoxGetSelected guiGetText getPlayerName triggerServerEvent guiGridListAddRow guiGridListSetItemText guiGridListGetSelectedItem guiGridListGetItemText guiGridListRemoveRow --server getPlayerAccount isObjectInACLGroup triggerClientEvent سويت بس حاس اني جايب العيدد ض1 كلنت GUIEditor = { memo = {}, edit = {}, window = {}, checkbox = {}, label = {}, } GUIEditor.window[1] = guiCreateWindow(210, 66, 449, 493, "", false) guiWindowSetSizable(GUIEditor.window[1], false) guiSetAlpha(GUIEditor.window[1], 1.00) GUIEditor.memo[1] = guiCreateMemo(9, 25, 421, 184, "", false, GUIEditor.window[1]) GUIEditor.label[2] = guiCreateLabel(0, 209, 442, 20, "--------------------------------------------------------------", false, GUIEditor.window[1]) guiSetFont(GUIEditor.label[2], "sa-header") guiLabelSetColor(GUIEditor.label[2], 195, 0, 0) a1 = guiCreateCheckBox(29, 242, 110, 22, "سآعات", false, false, GUIEditor.window[1]) guiSetProperty(a1, "NormalTextColour", "FFC30000") b2 = guiCreateCheckBox(172, 243, 110, 22, "تاج", false, false, GUIEditor.window[1]) guiSetProperty(b2, "NormalTextColour", "FFB4A20A") c1 = guiCreateCheckBox(310, 243, 110, 22, "قريبآ", false, false, GUIEditor.window[1]) guiSetProperty(c1, "NormalTextColour", "FF05BB92") GUIEditor.label[3] = guiCreateLabel(44, 279, 390, 24, "يرجى تحديد طريقة الدفه", false, GUIEditor.window[1]) guiSetFont(GUIEditor.label[3], "default-bold-small") guiLabelSetColor(GUIEditor.label[3], 146, 157, 30) a2 = guiCreateCheckBox(36, 314, 98, 23, "سواء", false, false, GUIEditor.window[1]) guiSetProperty(GUIEditor.checkbox[4], "NormalTextColour", "FF873671") b2 = guiCreateCheckBox(174, 314, 98, 23, "كآش يو", false, false, GUIEditor.window[1]) guiSetProperty(GUIEditor.checkbox[5], "NormalTextColour", "FFA81456") c2 = guiCreateCheckBox(320, 314, 98, 23, "موبايل", false, false, GUIEditor.window[1]) guiSetProperty(GUIEditor.checkbox[6], "NormalTextColour", "FF2AC002") GUIEditor.label[4] = guiCreateLabel(30, 348, 411, 30, "يرجى عدم ترك الفراغات خآليه", false, GUIEditor.window[1]) guiSetFont(GUIEditor.label[4], "default-bold-small") guiLabelSetColor(GUIEditor.label[4], 193, 187, 0) a11 = guiCreateEdit(39, 380, 149, 27, "", false, GUIEditor.window[1]) b11 = guiCreateEdit(40, 417, 149, 27, "", false, GUIEditor.window[1]) c11 = guiCreateEdit(194, 380, 149, 27, "", false, GUIEditor.window[1]) a22 = guiCreateEdit(194, 417, 149, 27, "", false, GUIEditor.window[1]) b22 = guiCreateEdit(39, 456, 149, 27, "", false, GUIEditor.window[1]) c22 = guiCreateEdit(194, 456, 149, 27, "", false, GUIEditor.window[1]) GUIEditor.button[1] = guiCreateButton(344, 383, 96, 101, "آرسآل المعلومات", false, GUIEditor.window[1]) bindKey("F6","down", function () guiSetVisible(GUIEditor.window[1],not guiGetVisible(GUIEditor.window[1])) showCursor(guiGetVisible(GUIEditor.window[1])) end ) addEventHandler("onClientGUIClick",root) function (item,text) if source == GUIEditor.button[1] then if (guiCheckBoxGetSelected(a1) == false and guiCheckBoxGetSelected(b1) == false and guiCheckBoxGetSelected(c1) == false) then outputChatBox('* خطأ : #FFFFFF يجب ان تقوم بتحديد طريقة الدفع لأكمال عملية الشراء بنجاح !', 255, 0, 0, true) return end if (not getItemSelected or getItemSelected == "")then local aa = a1 or b1 or c1 if source == aa then item = guiCheckBoxGetSelected(aa) text = guiComboBoxGetItemText(aa, item) -------------------------------------------------------------------------- local bb = a2 or b2 or c2 if (guiCheckBoxGetSelected(a2) == false and guiCheckBoxGetSelected(b2) == false and guiCheckBoxGetSelected(c2) == false) then outputChatBox('* خطأ : #FFFFFF يجب ان تقوم بتحديد طريقة الدفع لأكمال عملية الشراء بنجاح !', 255, 0, 0, true) return end item1 = guiCheckBoxGetSelected(bb) text1 = guiComboBoxGetItemText(bb, item1) triggerServerEvent("box", localPlayer,item,text,item1,text1 ) ------------------------------------------------------------------------------- elseif (a11 and b11 and c11 and a22 and b22 and c22 ~= "" )then if (not tonumber(a11) and not tonumber(b11) and not tonumber(c11) and not tonumber(a22) and not tonumber(b22) and not tonumber(c22)) then outputChatBox('* خطأ : #FFFFFF يرجى كتابة رقم بطاقة صحيح لتتم عملية ارسال المعلومات بنجاح !', 255, 0, 0, true) return end if ((a11 ~= "") and not tonumber(a11) or (b11 ~= "") and not tonumber(b11) or (c11 ~= "") and not tonumber(c11) or (a22 ~= "") and not tonumber(a22) or (b22 ~= "") and not tonumber(b22) or (c22 ~= "") and not tonumber(c22)) then outputChatBox('* خطأ : #FFFFFF يرجى كتابة رقم بطاقة صحيح لتتم عملية ارسال المعلومات بنجاح !', 255, 0, 0, true) return end abc1 = guiGetText(GUIEditor.edit[1]) local a11 = guiGetText(a11) local b11 = guiGetText(b11) local c11 = guiGetText(c11) local a22 = guiGetText(a22) local b22 = guiGetText(b22) local c22 = guiGetText(c22) triggerServerEvent("box2", localPlayer,abc1,a11,b11,c11,a22,b22,c22 ) -------------------------------------------------------------------------------- end end end end end end end ----------------------- GUIEditor = { gridlist = {}, button = {}, window = {}, } addEventHandler("onClientResourceStart", resourceRoot, function() GUIEditor.window[2] = guiCreateWindow(198, 107, 468, 447, "", false) guiWindowSetSizable(GUIEditor.window[1], false) guiSetVisible ( GUIEditor.window[2],false ) GUIEditor.gridlist[1] = guiCreateGridList(9, 20, 450, 331, false, GUIEditor.window[2]) guiGridListAddColumn(GUIEditor.gridlist[1], "اسم الاعب", 0.2) guiGridListAddColumn(GUIEditor.gridlist[1], "نوع المشترى", 0.2) guiGridListAddColumn(GUIEditor.gridlist[1], "بآقة المشترى", 0.2) guiGridListAddColumn(GUIEditor.gridlist[1], "معلومات المشترى", 0.2) ss = guiCreateButton(153, 374, 147, 33, "حذف", false, GUIEditor.window[2]) end ) ------------------------------ addEvent( 'boxc', true ) addEventHandler( 'boxc', root, function (pla,item,text,item1,text1) local row = guiGridListAddRow (GUIEditor.gridlist[1]) guiGridListSetItemText (GUIEditor.gridlist[1],row,1,pla,false,false) guiGridListSetItemText (GUIEditor.gridlist[1],row,2,text,false,false) guiGridListSetItemText (GUIEditor.gridlist[1],row,3,text1,false,false) guiGridListSetItemText (GUIEditor.gridlist[1],row,4,text1,false,false) end ) addEvent( 'boxc1', true ) addEventHandler( 'boxc1', root, function (abc1,a11,b11,c11,a22,b22,c22) local row = guiGridListAddRow (GUIEditor.gridlist[1]) guiGridListSetItemText (GUIEditor.gridlist[1],row,4,text1,false,false) end ) addEventHandler("onClientGUIClick",root, function() if source == sss then local sw = guiGridListGetSelectedItem(GUIEditor.gridlist[1]) if (sw == -1) then outputChatBox( '* خطأ : #FFFFFF لم تقم بتحديد مشتري من القائمة !', 255, 0, 0, true) return end local sa = guiGridListGetItemData(GUIEditor.gridlist[1], sw, 1) local as = guiGridListGetItemData(GUIEditor.gridlist[1], sw, 2) triggerServerEvent( 'box1', localPlayer,sa,as) end end end ) addEvent( 'UPDATEGRIDLIST', true ) addEventHandler( 'UPDATEGRIDLIST', root, function() guiGridListClear(GUIEditor.gridlist[1]) end ) function Opens ( ) guiSetVisible ( GUIEditor.window[2],true ) showCursor ( true ) end addEvent ( "Open", true ) addEventHandler ( "Open", root, Opens ) سيرفر executeSQLQuery( ' CREATE TABLE IF NOT EXISTS `Boxs` (pla,item,text,item1,text1,abc,a11,b11,c11,a22,b22,c22) ' ) addEvent( 'box', true ) addEventHandler( 'box', root, function (item,text,item1,text1) pla = getPlayerName(source) triggerClientEvent(source"boxc",source,pla,item,text,item1,text1) end ) addEvent( 'box1', true ) addEventHandler( 'box1', root, function (as,sa) local checkPlayer = executeSQLQuery( ' SELECT * FROM `Boxs` WHERE pla=?', sa ) if (checkPlayer) then end executeSQLQuery( ' DELETE FROM `Boxs` WHERE pla=? ', as ) outputChatBox('* إدارة المشتريات : #FFFFFF تم حذف المشتري من القائمة بنجاح !', source, 0, 255, 0, true) triggerClientEvent( 'UPDATEGRIDLIST', source) end ) addEvent( 'box2', true ) addEventHandler( 'box2', root, function (abc1,a11,b11,c11,a22,b22,c22) triggerClientEvent(source"boxc1",source,abc1,a11,b11,c11,a22,b22,c22) end ) addCommandHandler ( "الكلمه اف 8", function ( p ) local acc = getPlayerAccount(p) if not isGuestAccount ( acc ) then if isObjectInACLGroup("user." .. getAccountName(acc), aclGetGroup("Admin")) then triggerClientEvent ( p, "Open", resourceRoot ) end end end ) Link to comment
Wleed1998 Posted July 5, 2016 Author Share Posted July 5, 2016 --client "onClientGUIClick" guiCheckBoxGetSelected guiGetText getPlayerName triggerServerEvent guiGridListAddRow guiGridListSetItemText guiGridListGetSelectedItem guiGridListGetItemText guiGridListRemoveRow --server getPlayerAccount isObjectInACLGroup triggerClientEvent سويت بس حاس اني جايب العيدد ض1 كلنت GUIEditor = { memo = {}, edit = {}, window = {}, checkbox = {}, label = {}, } GUIEditor.window[1] = guiCreateWindow(210, 66, 449, 493, "", false) guiWindowSetSizable(GUIEditor.window[1], false) guiSetAlpha(GUIEditor.window[1], 1.00) GUIEditor.memo[1] = guiCreateMemo(9, 25, 421, 184, "", false, GUIEditor.window[1]) GUIEditor.label[2] = guiCreateLabel(0, 209, 442, 20, "--------------------------------------------------------------", false, GUIEditor.window[1]) guiSetFont(GUIEditor.label[2], "sa-header") guiLabelSetColor(GUIEditor.label[2], 195, 0, 0) a1 = guiCreateCheckBox(29, 242, 110, 22, "سآعات", false, false, GUIEditor.window[1]) guiSetProperty(a1, "NormalTextColour", "FFC30000") b2 = guiCreateCheckBox(172, 243, 110, 22, "تاج", false, false, GUIEditor.window[1]) guiSetProperty(b2, "NormalTextColour", "FFB4A20A") c1 = guiCreateCheckBox(310, 243, 110, 22, "قريبآ", false, false, GUIEditor.window[1]) guiSetProperty(c1, "NormalTextColour", "FF05BB92") GUIEditor.label[3] = guiCreateLabel(44, 279, 390, 24, "يرجى تحديد طريقة الدفه", false, GUIEditor.window[1]) guiSetFont(GUIEditor.label[3], "default-bold-small") guiLabelSetColor(GUIEditor.label[3], 146, 157, 30) a2 = guiCreateCheckBox(36, 314, 98, 23, "سواء", false, false, GUIEditor.window[1]) guiSetProperty(GUIEditor.checkbox[4], "NormalTextColour", "FF873671") b2 = guiCreateCheckBox(174, 314, 98, 23, "كآش يو", false, false, GUIEditor.window[1]) guiSetProperty(GUIEditor.checkbox[5], "NormalTextColour", "FFA81456") c2 = guiCreateCheckBox(320, 314, 98, 23, "موبايل", false, false, GUIEditor.window[1]) guiSetProperty(GUIEditor.checkbox[6], "NormalTextColour", "FF2AC002") GUIEditor.label[4] = guiCreateLabel(30, 348, 411, 30, "يرجى عدم ترك الفراغات خآليه", false, GUIEditor.window[1]) guiSetFont(GUIEditor.label[4], "default-bold-small") guiLabelSetColor(GUIEditor.label[4], 193, 187, 0) a11 = guiCreateEdit(39, 380, 149, 27, "", false, GUIEditor.window[1]) b11 = guiCreateEdit(40, 417, 149, 27, "", false, GUIEditor.window[1]) c11 = guiCreateEdit(194, 380, 149, 27, "", false, GUIEditor.window[1]) a22 = guiCreateEdit(194, 417, 149, 27, "", false, GUIEditor.window[1]) b22 = guiCreateEdit(39, 456, 149, 27, "", false, GUIEditor.window[1]) c22 = guiCreateEdit(194, 456, 149, 27, "", false, GUIEditor.window[1]) GUIEditor.button[1] = guiCreateButton(344, 383, 96, 101, "آرسآل المعلومات", false, GUIEditor.window[1]) bindKey("F6","down", function () guiSetVisible(GUIEditor.window[1],not guiGetVisible(GUIEditor.window[1])) showCursor(guiGetVisible(GUIEditor.window[1])) end ) addEventHandler("onClientGUIClick",root) function (item,text) if source == GUIEditor.button[1] then if (guiCheckBoxGetSelected(a1) == false and guiCheckBoxGetSelected(b1) == false and guiCheckBoxGetSelected(c1) == false) then outputChatBox('* خطأ : #FFFFFF يجب ان تقوم بتحديد طريقة الدفع لأكمال عملية الشراء بنجاح !', 255, 0, 0, true) return end if (not getItemSelected or getItemSelected == "")then local aa = a1 or b1 or c1 if source == aa then item = guiCheckBoxGetSelected(aa) text = guiComboBoxGetItemText(aa, item) -------------------------------------------------------------------------- local bb = a2 or b2 or c2 if (guiCheckBoxGetSelected(a2) == false and guiCheckBoxGetSelected(b2) == false and guiCheckBoxGetSelected(c2) == false) then outputChatBox('* خطأ : #FFFFFF يجب ان تقوم بتحديد طريقة الدفع لأكمال عملية الشراء بنجاح !', 255, 0, 0, true) return end item1 = guiCheckBoxGetSelected(bb) text1 = guiComboBoxGetItemText(bb, item1) triggerServerEvent("box", localPlayer,item,text,item1,text1 ) ------------------------------------------------------------------------------- elseif (a11 and b11 and c11 and a22 and b22 and c22 ~= "" )then if (not tonumber(a11) and not tonumber(b11) and not tonumber(c11) and not tonumber(a22) and not tonumber(b22) and not tonumber(c22)) then outputChatBox('* خطأ : #FFFFFF يرجى كتابة رقم بطاقة صحيح لتتم عملية ارسال المعلومات بنجاح !', 255, 0, 0, true) return end if ((a11 ~= "") and not tonumber(a11) or (b11 ~= "") and not tonumber(b11) or (c11 ~= "") and not tonumber(c11) or (a22 ~= "") and not tonumber(a22) or (b22 ~= "") and not tonumber(b22) or (c22 ~= "") and not tonumber(c22)) then outputChatBox('* خطأ : #FFFFFF يرجى كتابة رقم بطاقة صحيح لتتم عملية ارسال المعلومات بنجاح !', 255, 0, 0, true) return end abc1 = guiGetText(GUIEditor.edit[1]) local a11 = guiGetText(a11) local b11 = guiGetText(b11) local c11 = guiGetText(c11) local a22 = guiGetText(a22) local b22 = guiGetText(b22) local c22 = guiGetText(c22) triggerServerEvent("box2", localPlayer,abc1,a11,b11,c11,a22,b22,c22 ) -------------------------------------------------------------------------------- end end end end end end end ----------------------- GUIEditor = { gridlist = {}, button = {}, window = {}, } addEventHandler("onClientResourceStart", resourceRoot, function() GUIEditor.window[2] = guiCreateWindow(198, 107, 468, 447, "", false) guiWindowSetSizable(GUIEditor.window[1], false) guiSetVisible ( GUIEditor.window[2],false ) GUIEditor.gridlist[1] = guiCreateGridList(9, 20, 450, 331, false, GUIEditor.window[2]) guiGridListAddColumn(GUIEditor.gridlist[1], "اسم الاعب", 0.2) guiGridListAddColumn(GUIEditor.gridlist[1], "نوع المشترى", 0.2) guiGridListAddColumn(GUIEditor.gridlist[1], "بآقة المشترى", 0.2) guiGridListAddColumn(GUIEditor.gridlist[1], "معلومات المشترى", 0.2) ss = guiCreateButton(153, 374, 147, 33, "حذف", false, GUIEditor.window[2]) end ) ------------------------------ addEvent( 'boxc', true ) addEventHandler( 'boxc', root, function (pla,item,text,item1,text1) local row = guiGridListAddRow (GUIEditor.gridlist[1]) guiGridListSetItemText (GUIEditor.gridlist[1],row,1,pla,false,false) guiGridListSetItemText (GUIEditor.gridlist[1],row,2,text,false,false) guiGridListSetItemText (GUIEditor.gridlist[1],row,3,text1,false,false) guiGridListSetItemText (GUIEditor.gridlist[1],row,4,text1,false,false) end ) addEvent( 'boxc1', true ) addEventHandler( 'boxc1', root, function (abc1,a11,b11,c11,a22,b22,c22) local row = guiGridListAddRow (GUIEditor.gridlist[1]) guiGridListSetItemText (GUIEditor.gridlist[1],row,4,text1,false,false) end ) addEventHandler("onClientGUIClick",root, function() if source == sss then local sw = guiGridListGetSelectedItem(GUIEditor.gridlist[1]) if (sw == -1) then outputChatBox( '* خطأ : #FFFFFF لم تقم بتحديد مشتري من القائمة !', 255, 0, 0, true) return end local sa = guiGridListGetItemData(GUIEditor.gridlist[1], sw, 1) local as = guiGridListGetItemData(GUIEditor.gridlist[1], sw, 2) triggerServerEvent( 'box1', localPlayer,sa,as) end end end ) addEvent( 'UPDATEGRIDLIST', true ) addEventHandler( 'UPDATEGRIDLIST', root, function() guiGridListClear(GUIEditor.gridlist[1]) end ) function Opens ( ) guiSetVisible ( GUIEditor.window[2],true ) showCursor ( true ) end addEvent ( "Open", true ) addEventHandler ( "Open", root, Opens ) سيرفر executeSQLQuery( ' CREATE TABLE IF NOT EXISTS `Boxs` (pla,item,text,item1,text1,abc,a11,b11,c11,a22,b22,c22) ' ) addEvent( 'box', true ) addEventHandler( 'box', root, function (item,text,item1,text1) pla = getPlayerName(source) triggerClientEvent(source"boxc",source,pla,item,text,item1,text1) end ) addEvent( 'box1', true ) addEventHandler( 'box1', root, function (as,sa) local checkPlayer = executeSQLQuery( ' SELECT * FROM `Boxs` WHERE pla=?', sa ) if (checkPlayer) then end executeSQLQuery( ' DELETE FROM `Boxs` WHERE pla=? ', as ) outputChatBox('* إدارة المشتريات : #FFFFFF تم حذف المشتري من القائمة بنجاح !', source, 0, 255, 0, true) triggerClientEvent( 'UPDATEGRIDLIST', source) end ) addEvent( 'box2', true ) addEventHandler( 'box2', root, function (abc1,a11,b11,c11,a22,b22,c22) triggerClientEvent(source"boxc1",source,abc1,a11,b11,c11,a22,b22,c22) end ) addCommandHandler ( "الكلمه اف 8", function ( p ) local acc = getPlayerAccount(p) if not isGuestAccount ( acc ) then if isObjectInACLGroup("user." .. getAccountName(acc), aclGetGroup("Admin")) then triggerClientEvent ( p, "Open", resourceRoot ) end end end ) الرجاء الرد ي شباب Link to comment
Wleed1998 Posted July 7, 2016 Author Share Posted July 7, 2016 يآجمآعه ردو يآجمآعه ردوووووووووووو تكفوووون 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