=xx=Ali=xx= Posted April 10, 2014 Share Posted April 10, 2014 السلام عليكم ورحمة الله وبركاته اخباركم شباب انشاء الله طيبين المهم اليوم واجهتني مشكله المشكله هيا بل ظبط معي قيم مود حق مستر سعد بس ياخي المشكله لمن اخرج وادخل الاقي الاسلحه الي شريتها اختفت مدري وش الححل الي يعرف يفيدني Link to comment
1REDBULL Posted April 10, 2014 Share Posted April 10, 2014 حمل مود save الي يحفظ الاسلحه و الفلوس راح تلقاه في الكومنتي وهذا واحد جبته لك https://community.multitheftauto.com/in ... ls&id=3940 Link to comment
=xx=Ali=xx= Posted April 10, 2014 Author Share Posted April 10, 2014 حمل مود save الي يحفظ الاسلحه و الفلوس راح تلقاه في الكومنتي وهذا واحد جبته لك https://community.multitheftauto.com/in ... ls&id=3940 اخوي كمأن نفس المشكله + ممكن سكايبكك لاهنت Link to comment
Jey Posted April 11, 2014 Share Posted April 11, 2014 المشكلة من السباون تبع الشخصيات Link to comment
shwaeki Posted April 11, 2014 Share Posted April 11, 2014 يب احسن شي كلم مستر سعد يحللك اياها Link to comment
=xx=Ali=xx= Posted April 11, 2014 Author Share Posted April 11, 2014 يب احسن شي كلم مستر سعد يحللك اياها معكك سكايبه ؟ او اعطيك الكود تحله لي Link to comment
ΞĪŚŚÀ Posted April 11, 2014 Share Posted April 11, 2014 قصدك مشكلة مود الحفظ مع اختيار الشخصيات ؟ Link to comment
=xx=Ali=xx= Posted April 11, 2014 Author Share Posted April 11, 2014 قصدك مشكلة مود الحفظ مع اختيار الشخصيات ؟ يب يب اخوي تكفى ساعدني ابي افتح سيرفري باقي له 20 يوم ويقفل مرت 10 ايام وهو مقفل ساعدني Link to comment
shwaeki Posted April 11, 2014 Share Posted April 11, 2014 ما دخل مود الحفظ المشكلة انة الجيم مود بشيل الاسلحة ولا بعرفش اشي لانو برضو انا جربت في اكتر من طريقة Link to comment
=xx=Ali=xx= Posted April 11, 2014 Author Share Posted April 11, 2014 ذا كود مستر سعد GUIEditor_Button1 = {}GUIEditor_Label2 = {}GUIEditor_Edit2 = {}GUIEditor_Image2 = {}GUIEditor_TabPanel = {}GUIEditor_Tab = {}local timee = {}local timeee = {}------------------------------Function to create windows----------------------------function show()destoy() --- this function to destroy all open window--------------------Center Window------------------local screenWidth, screenHeight = guiGetScreenSize()local windowWidth, windowHeight = 646, 505local left = (screenWidth-windowWidth)/2local top = (screenHeight-windowHeight)/2GUIEditor_Image2[1] = guiCreateStaticImage(left,top,windowWidth,windowHeight,"images/11.png",false) guiSetAlpha(GUIEditor_Image2[1],0.80000001192093) GUIEditor_TabPanel[1] = guiCreateTabPanel(10,19,628,397,false,GUIEditor_Image2[1]) guiSetAlpha(GUIEditor_TabPanel[1],0.90000001192093)--------------------Weapon-1------------------GUIEditor_Tab[1] = guiCreateTab("Weapon-1",GUIEditor_TabPanel[1]) GUIEditor_Image2[2] = guiCreateStaticImage(45,41,107,99,"images/22.png",false,GUIEditor_Tab[1])GUIEditor_Label2[1] = guiCreateLabel(27,140,141,31,"Colt 45 \n 5 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[1],150,150,150) guiLabelSetVerticalAlign(GUIEditor_Label2[1],"center") guiLabelSetHorizontalAlign(GUIEditor_Label2[1],"center",false) guiSetFont(GUIEditor_Label2[1],"default-bold-small")GUIEditor_Edit2[1] = guiCreateEdit(39,174,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[1],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[1],5)GUIEditor_Image2[3] = guiCreateStaticImage(200,41,111,100,"images/23.png",false,GUIEditor_Tab[1])GUIEditor_Label2[2] = guiCreateLabel(182,142,141,31,"Silenced \n 8 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[2],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[2],"center",false) guiSetFont(GUIEditor_Label2[2],"default-bold-small")GUIEditor_Edit2[2] = guiCreateEdit(191,173,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[2],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[2],5)GUIEditor_Image2[4] = guiCreateStaticImage(353,44,101,100,"images/24.png",false,GUIEditor_Tab[1])GUIEditor_Label2[3] = guiCreateLabel(336,142,141,31,"Deagle \n 10 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[3],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[3],"center",false) guiSetFont(GUIEditor_Label2[3],"default-bold-small")GUIEditor_Edit2[3] = guiCreateEdit(350,172,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[3],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[3],5)GUIEditor_Image2[5] = guiCreateStaticImage(503,42,107,98,"images/25.png",false,GUIEditor_Tab[1])GUIEditor_Label2[4] = guiCreateLabel(489,140,141,31,"Shotgun \n 14 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[4],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[4],"center",false) guiSetFont(GUIEditor_Label2[4],"default-bold-small")GUIEditor_Edit2[4] = guiCreateEdit(503,170,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[4],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[4],5)GUIEditor_Image2[6] = guiCreateStaticImage(41,214,110,94,"images/26.png",false,GUIEditor_Tab[1])GUIEditor_Label2[5] = guiCreateLabel(28,310,141,31,"Shotgun \n 12 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[5],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[5],"center",false) guiSetFont(GUIEditor_Label2[5],"default-bold-small")GUIEditor_Edit2[5] = guiCreateEdit(41,343,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[5],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[5],5)GUIEditor_Image2[7] = guiCreateStaticImage(198,215,113,94,"images/27.png",false,GUIEditor_Tab[1])GUIEditor_Label2[6] = guiCreateLabel(182,309,141,31,"Combat Shotgun \n 18 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[6],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[6],"center",false) guiSetFont(GUIEditor_Label2[6],"default-bold-small")GUIEditor_Edit2[6] = guiCreateEdit(196,341,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[6],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[6],5)GUIEditor_Image2[8] = guiCreateStaticImage(354,217,111,94,"images/28.png",false,GUIEditor_Tab[1])GUIEditor_Label2[7] = guiCreateLabel(344,310,141,31,"Tec-9 \n 20 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[7],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[7],"center",false) guiSetFont(GUIEditor_Label2[7],"default-bold-small")GUIEditor_Edit2[7] = guiCreateEdit(355,339,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[7],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[7],5)GUIEditor_Image2[9] = guiCreateStaticImage(508,218,107,94,"images/29.png",false,GUIEditor_Tab[1])GUIEditor_Label2[8] = guiCreateLabel(492,309,141,31,"MP5 \n 25 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[8],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[8],"center",false) guiSetFont(GUIEditor_Label2[8],"default-bold-small")GUIEditor_Edit2[8] = guiCreateEdit(506,338,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[8],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[8],6)--------------------Weapon-2------------------ GUIEditor_Tab[2] = guiCreateTab("Weapon-2",GUIEditor_TabPanel[1]) GUIEditor_Image2[10] = guiCreateStaticImage(45,41,107,99,"images/30.png",false,GUIEditor_Tab[2])GUIEditor_Label2[9] = guiCreateLabel(27,140,141,31,"AK-47 \n 30 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[9],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[9],"center",false) guiSetFont(GUIEditor_Label2[9],"default-bold-small")GUIEditor_Edit2[9] = guiCreateEdit(39,174,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[9],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[9],5)GUIEditor_Image2[11] = guiCreateStaticImage(200,41,111,100,"images/31.png",false,GUIEditor_Tab[2])GUIEditor_Label2[10] = guiCreateLabel(182,142,141,31,"M4 \n 35 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[10],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[10],"center",false) guiSetFont(GUIEditor_Label2[10],"default-bold-small")GUIEditor_Edit2[10] = guiCreateEdit(191,173,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[10],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[10],5)GUIEditor_Image2[12] = guiCreateStaticImage(353,44,101,100,"images/32.png",false,GUIEditor_Tab[2])GUIEditor_Label2[11] = guiCreateLabel(336,142,141,31,"Uzi \n 17 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[11],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[11],"center",false) guiSetFont(GUIEditor_Label2[11],"default-bold-small")GUIEditor_Edit2[11] = guiCreateEdit(350,172,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[11],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[11],5)GUIEditor_Image2[13] = guiCreateStaticImage(503,42,107,98,"images/33.png",false,GUIEditor_Tab[2])GUIEditor_Label2[12] = guiCreateLabel(489,140,141,31,"Rifle \n 21 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[12],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[12],"center",false) guiSetFont(GUIEditor_Label2[12],"default-bold-small")GUIEditor_Edit2[12] = guiCreateEdit(503,170,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[12],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[12],5)GUIEditor_Image2[14] = guiCreateStaticImage(41,214,110,94,"images/34.png",false,GUIEditor_Tab[2])GUIEditor_Label2[13] = guiCreateLabel(28,310,141,31,"Sniper \n 40 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[13],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[13],"center",false) guiSetFont(GUIEditor_Label2[13],"default-bold-small")GUIEditor_Edit2[13] = guiCreateEdit(41,343,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[13],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[13],5)GUIEditor_Image2[15] = guiCreateStaticImage(198,215,113,94,"images/16.png",false,GUIEditor_Tab[2])GUIEditor_Label2[14] = guiCreateLabel(182,309,141,31,"Grenade \n 100 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[14],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[14],"center",false) guiSetFont(GUIEditor_Label2[14],"default-bold-small")GUIEditor_Edit2[14] = guiCreateEdit(196,341,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[14],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[14],5)GUIEditor_Label2[15] = guiCreateLabel(156,430,156,17,"Total : 0 $",false,GUIEditor_Image2[1]) guiSetFont(GUIEditor_Label2[15],"default-bold-small")GUIEditor_Button1[1] = guiCreateButton(186,457,113,28,"Exit",false,GUIEditor_Image2[1]) guiSetFont(GUIEditor_Button1[1],"default-bold-small")GUIEditor_Button1[2] = guiCreateButton(57,457,113,28,"Buy",false,GUIEditor_Image2[1]) guiSetFont(GUIEditor_Button1[2],"default-bold-small")GUIEditor_Label2[16] = guiCreateLabel(65,428,92,21,"Price Weapon:",false,GUIEditor_Image2[1]) guiLabelSetColor(GUIEditor_Label2[16],150,255,0) ---------------------------------End Window------------------------------------------- --------------------timer Edit------------------timee[localPlayer] = setTimer(function ()local gWA22 = guiGetText (GUIEditor_Edit2[1]) if gWA22 ~= '' then local tPMt22 = tonumber(gWA22) * 5 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt22 .." $") endlocal gWA23 = guiGetText (GUIEditor_Edit2[2]) if gWA23 ~= '' then local tPMt23 = tonumber(gWA23) * 8 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt23 .." $") endlocal gWA24 = guiGetText (GUIEditor_Edit2[3]) if gWA24 ~= '' then local tPMt24 = tonumber(gWA24) * 10 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt24 .." $") endlocal gWA25 = guiGetText (GUIEditor_Edit2[4]) if gWA25 ~= '' then local tPMt25 = tonumber(gWA25) * 14 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt25 .." $") endlocal gWA26 = guiGetText (GUIEditor_Edit2[5]) if gWA26 ~= '' then local tPMt26 = tonumber(gWA26) * 12 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt26 .." $") endlocal gWA27 = guiGetText (GUIEditor_Edit2[6]) if gWA27 ~= '' then local tPMt27 = tonumber(gWA27) * 18 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt27 .." $") endlocal gWA28 = guiGetText (GUIEditor_Edit2[7]) if gWA28 ~= '' then local tPMt28 = tonumber(gWA28) * 20 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt28 .." $") endlocal gWA29 = guiGetText (GUIEditor_Edit2[8]) if gWA29 ~= '' then local tPMt29 = tonumber(gWA29) * 25 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt29 .." $") end local gWA30 = guiGetText (GUIEditor_Edit2[9]) if gWA30 ~= '' then local tPMt30 = tonumber(gWA30) * 30 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt30 .." $") endlocal gWA31 = guiGetText (GUIEditor_Edit2[10]) if gWA31 ~= '' then local tPMt31 = tonumber(gWA31) * 35 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt31 .." $") end local gWA32 = guiGetText (GUIEditor_Edit2[11]) if gWA32 ~= '' then local tPMt32 = tonumber(gWA32) * 17 or tonumber(gWA32) * 17 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt32 .." $") endlocal gWA33 = guiGetText (GUIEditor_Edit2[12]) if gWA33 ~= '' then local tPMt33 = tonumber(gWA33) * 21 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt33 .." $") end local gWA34 = guiGetText (GUIEditor_Edit2[13]) if gWA34 ~= '' then local tPMt34 = tonumber(gWA34) * 40 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt34 .." $") end local gWA16 = guiGetText (GUIEditor_Edit2[14]) if gWA16 ~= '' then local tPMt16 = tonumber(gWA16) * 100 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt16 .." $") end end, 50, 0 )timeee[localPlayer] = setTimer(function ()local gWA22 = guiGetText (GUIEditor_Edit2[1]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[1],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[2]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[2],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[3]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[3],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[4]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[4],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[5]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[5],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[6]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[6],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[7]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[7],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[8]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[8],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[9]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[9],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[10]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[10],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[11]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[11],"") end local gWA22 = guiGetText (GUIEditor_Edit2[12]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[12],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[13]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[13],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[14]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[14],"") endend, 50, 0 )end----------------------Destroy all window--------------------function destoy() for i,v in ipairs(GUIEditor_Button1) do ---destroy all buton if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Label2) do --destro all label if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Edit2) do ---destroy all edit if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Image2) do --destroy all image if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_TabPanel) do --destroy all tap-panel if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Tab) do --destroy all tap if isElement(v) then destroyElement(v) end end if isTimer(timee[localPlayer]) then killTimer(timee[localPlayer]) end --kill timee if isTimer(timeee[localPlayer]) then killTimer(timeee[localPlayer]) end --kill timeeeend-------------------- clear all edit when click------------------function onGuiClick (button, state, absoluteX, absoluteY) if (source == GUIEditor_Edit2[1]) then guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[2]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[3]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[4]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[5]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[6]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[7]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[8]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[9]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[10]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[11]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[12]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[13]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[14]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") endendaddEventHandler ("onClientGUIClick", getRootElement(), onGuiClick)------------------------Buy Weapon----------------------function onGuiClick (button, state, absoluteX, absoluteY) if (source == GUIEditor_Button1[2]) then local gWA = guiGetText (GUIEditor_Edit2[1]) string.format ("-", gWA) if gWA ~= '' then local tPM = tonumber(gWA) * 5 local wID = 22 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[2]) if gWA ~= '' then local tPM = tonumber(gWA) * 8 local wID = 23 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[3]) if gWA ~= '' then local tPM = tonumber(gWA) * 10 local wID = 24 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[4]) if gWA ~= '' then local tPM = tonumber(gWA) * 14 local wID = 25 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[5]) if gWA ~= '' then local tPM = tonumber(gWA) * 12 local wID = 26 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[6]) if gWA ~= '' then local tPM = tonumber(gWA) * 18 local wID = 27 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[7]) if gWA ~= '' then local tPM = tonumber(gWA) * 20 local wID = 32 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[8]) if gWA ~= '' then local tPM = tonumber(gWA) * 25 local wID = 29 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[9]) if gWA ~= '' then local tPM = tonumber(gWA) * 30 local wID = 30 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[10]) if gWA ~= '' then local tPM = tonumber(gWA) * 35 local wID = 31 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[11]) if gWA ~= '' then local tPM = tonumber(gWA) * 17 local wID = 28 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[12]) if gWA ~= '' then local tPM = tonumber(gWA) * 21 local wID = 33 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[13]) if gWA ~= '' then local tPM = tonumber(gWA) * 40 local wID = 34 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[14]) if gWA ~= '' then local tPM = tonumber(gWA) * 100 local wID = 16 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end elseif (source == GUIEditor_Button1[1]) then destoy() showCursor( false ) endendaddEventHandler ("onClientGUIClick", getRootElement(), onGuiClick)------------------------Create Marker & bilp----------------------local Marker = createMarker ( 296, -37, 999.5, "cylinder", 2, 255, 255, 0, 150 )setElementInterior( Marker, 1, 296, -37, 999.5 )addEventHandler('onClientMarkerHit', Marker,function ( hitPlayer ) if ( hitPlayer == localPlayer ) then show() showCursor( true ) endend )createBlip ( 1367, -1279, 13 , 6 ) Link to comment
ΞĪŚŚÀ Posted April 11, 2014 Share Posted April 11, 2014 ذا كود مستر سعد GUIEditor_Button1 = {}GUIEditor_Label2 = {}GUIEditor_Edit2 = {}GUIEditor_Image2 = {}GUIEditor_TabPanel = {}GUIEditor_Tab = {}local timee = {}local timeee = {}------------------------------Function to create windows----------------------------function show()destoy() --- this function to destroy all open window--------------------Center Window------------------local screenWidth, screenHeight = guiGetScreenSize()local windowWidth, windowHeight = 646, 505local left = (screenWidth-windowWidth)/2local top = (screenHeight-windowHeight)/2GUIEditor_Image2[1] = guiCreateStaticImage(left,top,windowWidth,windowHeight,"images/11.png",false) guiSetAlpha(GUIEditor_Image2[1],0.80000001192093) GUIEditor_TabPanel[1] = guiCreateTabPanel(10,19,628,397,false,GUIEditor_Image2[1]) guiSetAlpha(GUIEditor_TabPanel[1],0.90000001192093)--------------------Weapon-1------------------GUIEditor_Tab[1] = guiCreateTab("Weapon-1",GUIEditor_TabPanel[1]) GUIEditor_Image2[2] = guiCreateStaticImage(45,41,107,99,"images/22.png",false,GUIEditor_Tab[1])GUIEditor_Label2[1] = guiCreateLabel(27,140,141,31,"Colt 45 \n 5 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[1],150,150,150) guiLabelSetVerticalAlign(GUIEditor_Label2[1],"center") guiLabelSetHorizontalAlign(GUIEditor_Label2[1],"center",false) guiSetFont(GUIEditor_Label2[1],"default-bold-small")GUIEditor_Edit2[1] = guiCreateEdit(39,174,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[1],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[1],5)GUIEditor_Image2[3] = guiCreateStaticImage(200,41,111,100,"images/23.png",false,GUIEditor_Tab[1])GUIEditor_Label2[2] = guiCreateLabel(182,142,141,31,"Silenced \n 8 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[2],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[2],"center",false) guiSetFont(GUIEditor_Label2[2],"default-bold-small")GUIEditor_Edit2[2] = guiCreateEdit(191,173,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[2],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[2],5)GUIEditor_Image2[4] = guiCreateStaticImage(353,44,101,100,"images/24.png",false,GUIEditor_Tab[1])GUIEditor_Label2[3] = guiCreateLabel(336,142,141,31,"Deagle \n 10 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[3],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[3],"center",false) guiSetFont(GUIEditor_Label2[3],"default-bold-small")GUIEditor_Edit2[3] = guiCreateEdit(350,172,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[3],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[3],5)GUIEditor_Image2[5] = guiCreateStaticImage(503,42,107,98,"images/25.png",false,GUIEditor_Tab[1])GUIEditor_Label2[4] = guiCreateLabel(489,140,141,31,"Shotgun \n 14 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[4],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[4],"center",false) guiSetFont(GUIEditor_Label2[4],"default-bold-small")GUIEditor_Edit2[4] = guiCreateEdit(503,170,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[4],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[4],5)GUIEditor_Image2[6] = guiCreateStaticImage(41,214,110,94,"images/26.png",false,GUIEditor_Tab[1])GUIEditor_Label2[5] = guiCreateLabel(28,310,141,31,"Shotgun \n 12 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[5],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[5],"center",false) guiSetFont(GUIEditor_Label2[5],"default-bold-small")GUIEditor_Edit2[5] = guiCreateEdit(41,343,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[5],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[5],5)GUIEditor_Image2[7] = guiCreateStaticImage(198,215,113,94,"images/27.png",false,GUIEditor_Tab[1])GUIEditor_Label2[6] = guiCreateLabel(182,309,141,31,"Combat Shotgun \n 18 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[6],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[6],"center",false) guiSetFont(GUIEditor_Label2[6],"default-bold-small")GUIEditor_Edit2[6] = guiCreateEdit(196,341,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[6],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[6],5)GUIEditor_Image2[8] = guiCreateStaticImage(354,217,111,94,"images/28.png",false,GUIEditor_Tab[1])GUIEditor_Label2[7] = guiCreateLabel(344,310,141,31,"Tec-9 \n 20 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[7],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[7],"center",false) guiSetFont(GUIEditor_Label2[7],"default-bold-small")GUIEditor_Edit2[7] = guiCreateEdit(355,339,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[7],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[7],5)GUIEditor_Image2[9] = guiCreateStaticImage(508,218,107,94,"images/29.png",false,GUIEditor_Tab[1])GUIEditor_Label2[8] = guiCreateLabel(492,309,141,31,"MP5 \n 25 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[8],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[8],"center",false) guiSetFont(GUIEditor_Label2[8],"default-bold-small")GUIEditor_Edit2[8] = guiCreateEdit(506,338,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[8],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[8],6)--------------------Weapon-2------------------ GUIEditor_Tab[2] = guiCreateTab("Weapon-2",GUIEditor_TabPanel[1]) GUIEditor_Image2[10] = guiCreateStaticImage(45,41,107,99,"images/30.png",false,GUIEditor_Tab[2])GUIEditor_Label2[9] = guiCreateLabel(27,140,141,31,"AK-47 \n 30 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[9],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[9],"center",false) guiSetFont(GUIEditor_Label2[9],"default-bold-small")GUIEditor_Edit2[9] = guiCreateEdit(39,174,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[9],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[9],5)GUIEditor_Image2[11] = guiCreateStaticImage(200,41,111,100,"images/31.png",false,GUIEditor_Tab[2])GUIEditor_Label2[10] = guiCreateLabel(182,142,141,31,"M4 \n 35 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[10],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[10],"center",false) guiSetFont(GUIEditor_Label2[10],"default-bold-small")GUIEditor_Edit2[10] = guiCreateEdit(191,173,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[10],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[10],5)GUIEditor_Image2[12] = guiCreateStaticImage(353,44,101,100,"images/32.png",false,GUIEditor_Tab[2])GUIEditor_Label2[11] = guiCreateLabel(336,142,141,31,"Uzi \n 17 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[11],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[11],"center",false) guiSetFont(GUIEditor_Label2[11],"default-bold-small")GUIEditor_Edit2[11] = guiCreateEdit(350,172,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[11],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[11],5)GUIEditor_Image2[13] = guiCreateStaticImage(503,42,107,98,"images/33.png",false,GUIEditor_Tab[2])GUIEditor_Label2[12] = guiCreateLabel(489,140,141,31,"Rifle \n 21 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[12],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[12],"center",false) guiSetFont(GUIEditor_Label2[12],"default-bold-small")GUIEditor_Edit2[12] = guiCreateEdit(503,170,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[12],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[12],5)GUIEditor_Image2[14] = guiCreateStaticImage(41,214,110,94,"images/34.png",false,GUIEditor_Tab[2])GUIEditor_Label2[13] = guiCreateLabel(28,310,141,31,"Sniper \n 40 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[13],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[13],"center",false) guiSetFont(GUIEditor_Label2[13],"default-bold-small")GUIEditor_Edit2[13] = guiCreateEdit(41,343,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[13],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[13],5)GUIEditor_Image2[15] = guiCreateStaticImage(198,215,113,94,"images/16.png",false,GUIEditor_Tab[2])GUIEditor_Label2[14] = guiCreateLabel(182,309,141,31,"Grenade \n 100 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[14],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[14],"center",false) guiSetFont(GUIEditor_Label2[14],"default-bold-small")GUIEditor_Edit2[14] = guiCreateEdit(196,341,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[14],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[14],5)GUIEditor_Label2[15] = guiCreateLabel(156,430,156,17,"Total : 0 $",false,GUIEditor_Image2[1]) guiSetFont(GUIEditor_Label2[15],"default-bold-small")GUIEditor_Button1[1] = guiCreateButton(186,457,113,28,"Exit",false,GUIEditor_Image2[1]) guiSetFont(GUIEditor_Button1[1],"default-bold-small")GUIEditor_Button1[2] = guiCreateButton(57,457,113,28,"Buy",false,GUIEditor_Image2[1]) guiSetFont(GUIEditor_Button1[2],"default-bold-small")GUIEditor_Label2[16] = guiCreateLabel(65,428,92,21,"Price Weapon:",false,GUIEditor_Image2[1]) guiLabelSetColor(GUIEditor_Label2[16],150,255,0) ---------------------------------End Window------------------------------------------- --------------------timer Edit------------------timee[localPlayer] = setTimer(function ()local gWA22 = guiGetText (GUIEditor_Edit2[1]) if gWA22 ~= '' then local tPMt22 = tonumber(gWA22) * 5 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt22 .." $") endlocal gWA23 = guiGetText (GUIEditor_Edit2[2]) if gWA23 ~= '' then local tPMt23 = tonumber(gWA23) * 8 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt23 .." $") endlocal gWA24 = guiGetText (GUIEditor_Edit2[3]) if gWA24 ~= '' then local tPMt24 = tonumber(gWA24) * 10 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt24 .." $") endlocal gWA25 = guiGetText (GUIEditor_Edit2[4]) if gWA25 ~= '' then local tPMt25 = tonumber(gWA25) * 14 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt25 .." $") endlocal gWA26 = guiGetText (GUIEditor_Edit2[5]) if gWA26 ~= '' then local tPMt26 = tonumber(gWA26) * 12 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt26 .." $") endlocal gWA27 = guiGetText (GUIEditor_Edit2[6]) if gWA27 ~= '' then local tPMt27 = tonumber(gWA27) * 18 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt27 .." $") endlocal gWA28 = guiGetText (GUIEditor_Edit2[7]) if gWA28 ~= '' then local tPMt28 = tonumber(gWA28) * 20 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt28 .." $") endlocal gWA29 = guiGetText (GUIEditor_Edit2[8]) if gWA29 ~= '' then local tPMt29 = tonumber(gWA29) * 25 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt29 .." $") end local gWA30 = guiGetText (GUIEditor_Edit2[9]) if gWA30 ~= '' then local tPMt30 = tonumber(gWA30) * 30 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt30 .." $") endlocal gWA31 = guiGetText (GUIEditor_Edit2[10]) if gWA31 ~= '' then local tPMt31 = tonumber(gWA31) * 35 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt31 .." $") end local gWA32 = guiGetText (GUIEditor_Edit2[11]) if gWA32 ~= '' then local tPMt32 = tonumber(gWA32) * 17 or tonumber(gWA32) * 17 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt32 .." $") endlocal gWA33 = guiGetText (GUIEditor_Edit2[12]) if gWA33 ~= '' then local tPMt33 = tonumber(gWA33) * 21 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt33 .." $") end local gWA34 = guiGetText (GUIEditor_Edit2[13]) if gWA34 ~= '' then local tPMt34 = tonumber(gWA34) * 40 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt34 .." $") end local gWA16 = guiGetText (GUIEditor_Edit2[14]) if gWA16 ~= '' then local tPMt16 = tonumber(gWA16) * 100 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt16 .." $") end end, 50, 0 )timeee[localPlayer] = setTimer(function ()local gWA22 = guiGetText (GUIEditor_Edit2[1]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[1],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[2]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[2],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[3]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[3],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[4]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[4],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[5]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[5],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[6]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[6],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[7]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[7],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[8]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[8],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[9]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[9],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[10]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[10],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[11]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[11],"") end local gWA22 = guiGetText (GUIEditor_Edit2[12]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[12],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[13]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[13],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[14]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[14],"") endend, 50, 0 )end----------------------Destroy all window--------------------function destoy() for i,v in ipairs(GUIEditor_Button1) do ---destroy all buton if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Label2) do --destro all label if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Edit2) do ---destroy all edit if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Image2) do --destroy all image if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_TabPanel) do --destroy all tap-panel if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Tab) do --destroy all tap if isElement(v) then destroyElement(v) end end if isTimer(timee[localPlayer]) then killTimer(timee[localPlayer]) end --kill timee if isTimer(timeee[localPlayer]) then killTimer(timeee[localPlayer]) end --kill timeeeend-------------------- clear all edit when click------------------function onGuiClick (button, state, absoluteX, absoluteY) if (source == GUIEditor_Edit2[1]) then guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[2]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[3]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[4]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[5]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[6]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[7]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[8]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[9]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[10]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[11]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[12]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[13]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[14]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") endendaddEventHandler ("onClientGUIClick", getRootElement(), onGuiClick)------------------------Buy Weapon----------------------function onGuiClick (button, state, absoluteX, absoluteY) if (source == GUIEditor_Button1[2]) then local gWA = guiGetText (GUIEditor_Edit2[1]) string.format ("-", gWA) if gWA ~= '' then local tPM = tonumber(gWA) * 5 local wID = 22 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[2]) if gWA ~= '' then local tPM = tonumber(gWA) * 8 local wID = 23 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[3]) if gWA ~= '' then local tPM = tonumber(gWA) * 10 local wID = 24 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[4]) if gWA ~= '' then local tPM = tonumber(gWA) * 14 local wID = 25 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[5]) if gWA ~= '' then local tPM = tonumber(gWA) * 12 local wID = 26 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[6]) if gWA ~= '' then local tPM = tonumber(gWA) * 18 local wID = 27 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[7]) if gWA ~= '' then local tPM = tonumber(gWA) * 20 local wID = 32 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[8]) if gWA ~= '' then local tPM = tonumber(gWA) * 25 local wID = 29 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[9]) if gWA ~= '' then local tPM = tonumber(gWA) * 30 local wID = 30 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[10]) if gWA ~= '' then local tPM = tonumber(gWA) * 35 local wID = 31 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[11]) if gWA ~= '' then local tPM = tonumber(gWA) * 17 local wID = 28 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[12]) if gWA ~= '' then local tPM = tonumber(gWA) * 21 local wID = 33 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[13]) if gWA ~= '' then local tPM = tonumber(gWA) * 40 local wID = 34 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[14]) if gWA ~= '' then local tPM = tonumber(gWA) * 100 local wID = 16 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end elseif (source == GUIEditor_Button1[1]) then destoy() showCursor( false ) endendaddEventHandler ("onClientGUIClick", getRootElement(), onGuiClick)------------------------Create Marker & bilp----------------------local Marker = createMarker ( 296, -37, 999.5, "cylinder", 2, 255, 255, 0, 150 )setElementInterior( Marker, 1, 296, -37, 999.5 )addEventHandler('onClientMarkerHit', Marker,function ( hitPlayer ) if ( hitPlayer == localPlayer ) then show() showCursor( true ) endend )createBlip ( 1367, -1279, 13 , 6 ) ذا ككود الششوب . على العموم . امسح كود الي يعطي سلاح اول مايدخل الاعب السيرفر Link to comment
Jey Posted April 11, 2014 Share Posted April 11, 2014 ذا كود مستر سعد GUIEditor_Button1 = {}GUIEditor_Label2 = {}GUIEditor_Edit2 = {}GUIEditor_Image2 = {}GUIEditor_TabPanel = {}GUIEditor_Tab = {}local timee = {}local timeee = {}------------------------------Function to create windows----------------------------function show()destoy() --- this function to destroy all open window--------------------Center Window------------------local screenWidth, screenHeight = guiGetScreenSize()local windowWidth, windowHeight = 646, 505local left = (screenWidth-windowWidth)/2local top = (screenHeight-windowHeight)/2GUIEditor_Image2[1] = guiCreateStaticImage(left,top,windowWidth,windowHeight,"images/11.png",false) guiSetAlpha(GUIEditor_Image2[1],0.80000001192093) GUIEditor_TabPanel[1] = guiCreateTabPanel(10,19,628,397,false,GUIEditor_Image2[1]) guiSetAlpha(GUIEditor_TabPanel[1],0.90000001192093)--------------------Weapon-1------------------GUIEditor_Tab[1] = guiCreateTab("Weapon-1",GUIEditor_TabPanel[1]) GUIEditor_Image2[2] = guiCreateStaticImage(45,41,107,99,"images/22.png",false,GUIEditor_Tab[1])GUIEditor_Label2[1] = guiCreateLabel(27,140,141,31,"Colt 45 \n 5 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[1],150,150,150) guiLabelSetVerticalAlign(GUIEditor_Label2[1],"center") guiLabelSetHorizontalAlign(GUIEditor_Label2[1],"center",false) guiSetFont(GUIEditor_Label2[1],"default-bold-small")GUIEditor_Edit2[1] = guiCreateEdit(39,174,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[1],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[1],5)GUIEditor_Image2[3] = guiCreateStaticImage(200,41,111,100,"images/23.png",false,GUIEditor_Tab[1])GUIEditor_Label2[2] = guiCreateLabel(182,142,141,31,"Silenced \n 8 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[2],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[2],"center",false) guiSetFont(GUIEditor_Label2[2],"default-bold-small")GUIEditor_Edit2[2] = guiCreateEdit(191,173,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[2],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[2],5)GUIEditor_Image2[4] = guiCreateStaticImage(353,44,101,100,"images/24.png",false,GUIEditor_Tab[1])GUIEditor_Label2[3] = guiCreateLabel(336,142,141,31,"Deagle \n 10 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[3],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[3],"center",false) guiSetFont(GUIEditor_Label2[3],"default-bold-small")GUIEditor_Edit2[3] = guiCreateEdit(350,172,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[3],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[3],5)GUIEditor_Image2[5] = guiCreateStaticImage(503,42,107,98,"images/25.png",false,GUIEditor_Tab[1])GUIEditor_Label2[4] = guiCreateLabel(489,140,141,31,"Shotgun \n 14 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[4],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[4],"center",false) guiSetFont(GUIEditor_Label2[4],"default-bold-small")GUIEditor_Edit2[4] = guiCreateEdit(503,170,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[4],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[4],5)GUIEditor_Image2[6] = guiCreateStaticImage(41,214,110,94,"images/26.png",false,GUIEditor_Tab[1])GUIEditor_Label2[5] = guiCreateLabel(28,310,141,31,"Shotgun \n 12 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[5],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[5],"center",false) guiSetFont(GUIEditor_Label2[5],"default-bold-small")GUIEditor_Edit2[5] = guiCreateEdit(41,343,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[5],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[5],5)GUIEditor_Image2[7] = guiCreateStaticImage(198,215,113,94,"images/27.png",false,GUIEditor_Tab[1])GUIEditor_Label2[6] = guiCreateLabel(182,309,141,31,"Combat Shotgun \n 18 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[6],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[6],"center",false) guiSetFont(GUIEditor_Label2[6],"default-bold-small")GUIEditor_Edit2[6] = guiCreateEdit(196,341,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[6],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[6],5)GUIEditor_Image2[8] = guiCreateStaticImage(354,217,111,94,"images/28.png",false,GUIEditor_Tab[1])GUIEditor_Label2[7] = guiCreateLabel(344,310,141,31,"Tec-9 \n 20 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[7],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[7],"center",false) guiSetFont(GUIEditor_Label2[7],"default-bold-small")GUIEditor_Edit2[7] = guiCreateEdit(355,339,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[7],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[7],5)GUIEditor_Image2[9] = guiCreateStaticImage(508,218,107,94,"images/29.png",false,GUIEditor_Tab[1])GUIEditor_Label2[8] = guiCreateLabel(492,309,141,31,"MP5 \n 25 $",false,GUIEditor_Tab[1]) guiLabelSetColor(GUIEditor_Label2[8],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[8],"center",false) guiSetFont(GUIEditor_Label2[8],"default-bold-small")GUIEditor_Edit2[8] = guiCreateEdit(506,338,113,24,"",false,GUIEditor_Tab[1]) guiSetAlpha(GUIEditor_Edit2[8],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[8],6)--------------------Weapon-2------------------ GUIEditor_Tab[2] = guiCreateTab("Weapon-2",GUIEditor_TabPanel[1]) GUIEditor_Image2[10] = guiCreateStaticImage(45,41,107,99,"images/30.png",false,GUIEditor_Tab[2])GUIEditor_Label2[9] = guiCreateLabel(27,140,141,31,"AK-47 \n 30 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[9],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[9],"center",false) guiSetFont(GUIEditor_Label2[9],"default-bold-small")GUIEditor_Edit2[9] = guiCreateEdit(39,174,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[9],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[9],5)GUIEditor_Image2[11] = guiCreateStaticImage(200,41,111,100,"images/31.png",false,GUIEditor_Tab[2])GUIEditor_Label2[10] = guiCreateLabel(182,142,141,31,"M4 \n 35 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[10],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[10],"center",false) guiSetFont(GUIEditor_Label2[10],"default-bold-small")GUIEditor_Edit2[10] = guiCreateEdit(191,173,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[10],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[10],5)GUIEditor_Image2[12] = guiCreateStaticImage(353,44,101,100,"images/32.png",false,GUIEditor_Tab[2])GUIEditor_Label2[11] = guiCreateLabel(336,142,141,31,"Uzi \n 17 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[11],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[11],"center",false) guiSetFont(GUIEditor_Label2[11],"default-bold-small")GUIEditor_Edit2[11] = guiCreateEdit(350,172,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[11],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[11],5)GUIEditor_Image2[13] = guiCreateStaticImage(503,42,107,98,"images/33.png",false,GUIEditor_Tab[2])GUIEditor_Label2[12] = guiCreateLabel(489,140,141,31,"Rifle \n 21 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[12],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[12],"center",false) guiSetFont(GUIEditor_Label2[12],"default-bold-small")GUIEditor_Edit2[12] = guiCreateEdit(503,170,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[12],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[12],5)GUIEditor_Image2[14] = guiCreateStaticImage(41,214,110,94,"images/34.png",false,GUIEditor_Tab[2])GUIEditor_Label2[13] = guiCreateLabel(28,310,141,31,"Sniper \n 40 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[13],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[13],"center",false) guiSetFont(GUIEditor_Label2[13],"default-bold-small")GUIEditor_Edit2[13] = guiCreateEdit(41,343,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[13],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[13],5)GUIEditor_Image2[15] = guiCreateStaticImage(198,215,113,94,"images/16.png",false,GUIEditor_Tab[2])GUIEditor_Label2[14] = guiCreateLabel(182,309,141,31,"Grenade \n 100 $",false,GUIEditor_Tab[2]) guiLabelSetColor(GUIEditor_Label2[14],150,150,150) guiLabelSetHorizontalAlign(GUIEditor_Label2[14],"center",false) guiSetFont(GUIEditor_Label2[14],"default-bold-small")GUIEditor_Edit2[14] = guiCreateEdit(196,341,113,24,"",false,GUIEditor_Tab[2]) guiSetAlpha(GUIEditor_Edit2[14],0.80000001192093) guiEditSetMaxLength(GUIEditor_Edit2[14],5)GUIEditor_Label2[15] = guiCreateLabel(156,430,156,17,"Total : 0 $",false,GUIEditor_Image2[1]) guiSetFont(GUIEditor_Label2[15],"default-bold-small")GUIEditor_Button1[1] = guiCreateButton(186,457,113,28,"Exit",false,GUIEditor_Image2[1]) guiSetFont(GUIEditor_Button1[1],"default-bold-small")GUIEditor_Button1[2] = guiCreateButton(57,457,113,28,"Buy",false,GUIEditor_Image2[1]) guiSetFont(GUIEditor_Button1[2],"default-bold-small")GUIEditor_Label2[16] = guiCreateLabel(65,428,92,21,"Price Weapon:",false,GUIEditor_Image2[1]) guiLabelSetColor(GUIEditor_Label2[16],150,255,0) ---------------------------------End Window------------------------------------------- --------------------timer Edit------------------timee[localPlayer] = setTimer(function ()local gWA22 = guiGetText (GUIEditor_Edit2[1]) if gWA22 ~= '' then local tPMt22 = tonumber(gWA22) * 5 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt22 .." $") endlocal gWA23 = guiGetText (GUIEditor_Edit2[2]) if gWA23 ~= '' then local tPMt23 = tonumber(gWA23) * 8 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt23 .." $") endlocal gWA24 = guiGetText (GUIEditor_Edit2[3]) if gWA24 ~= '' then local tPMt24 = tonumber(gWA24) * 10 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt24 .." $") endlocal gWA25 = guiGetText (GUIEditor_Edit2[4]) if gWA25 ~= '' then local tPMt25 = tonumber(gWA25) * 14 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt25 .." $") endlocal gWA26 = guiGetText (GUIEditor_Edit2[5]) if gWA26 ~= '' then local tPMt26 = tonumber(gWA26) * 12 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt26 .." $") endlocal gWA27 = guiGetText (GUIEditor_Edit2[6]) if gWA27 ~= '' then local tPMt27 = tonumber(gWA27) * 18 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt27 .." $") endlocal gWA28 = guiGetText (GUIEditor_Edit2[7]) if gWA28 ~= '' then local tPMt28 = tonumber(gWA28) * 20 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt28 .." $") endlocal gWA29 = guiGetText (GUIEditor_Edit2[8]) if gWA29 ~= '' then local tPMt29 = tonumber(gWA29) * 25 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt29 .." $") end local gWA30 = guiGetText (GUIEditor_Edit2[9]) if gWA30 ~= '' then local tPMt30 = tonumber(gWA30) * 30 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt30 .." $") endlocal gWA31 = guiGetText (GUIEditor_Edit2[10]) if gWA31 ~= '' then local tPMt31 = tonumber(gWA31) * 35 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt31 .." $") end local gWA32 = guiGetText (GUIEditor_Edit2[11]) if gWA32 ~= '' then local tPMt32 = tonumber(gWA32) * 17 or tonumber(gWA32) * 17 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt32 .." $") endlocal gWA33 = guiGetText (GUIEditor_Edit2[12]) if gWA33 ~= '' then local tPMt33 = tonumber(gWA33) * 21 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt33 .." $") end local gWA34 = guiGetText (GUIEditor_Edit2[13]) if gWA34 ~= '' then local tPMt34 = tonumber(gWA34) * 40 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt34 .." $") end local gWA16 = guiGetText (GUIEditor_Edit2[14]) if gWA16 ~= '' then local tPMt16 = tonumber(gWA16) * 100 guiSetText (GUIEditor_Label2[15],"Total : ".. tPMt16 .." $") end end, 50, 0 )timeee[localPlayer] = setTimer(function ()local gWA22 = guiGetText (GUIEditor_Edit2[1]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[1],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[2]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[2],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[3]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[3],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[4]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[4],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[5]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[5],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[6]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[6],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[7]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[7],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[8]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[8],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[9]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[9],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[10]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[10],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[11]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[11],"") end local gWA22 = guiGetText (GUIEditor_Edit2[12]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[12],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[13]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[13],"") endlocal gWA22 = guiGetText (GUIEditor_Edit2[14]) if gWA22 == '-' then guiSetText (GUIEditor_Edit2[14],"") endend, 50, 0 )end----------------------Destroy all window--------------------function destoy() for i,v in ipairs(GUIEditor_Button1) do ---destroy all buton if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Label2) do --destro all label if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Edit2) do ---destroy all edit if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Image2) do --destroy all image if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_TabPanel) do --destroy all tap-panel if isElement(v) then destroyElement(v) end end for i,v in ipairs(GUIEditor_Tab) do --destroy all tap if isElement(v) then destroyElement(v) end end if isTimer(timee[localPlayer]) then killTimer(timee[localPlayer]) end --kill timee if isTimer(timeee[localPlayer]) then killTimer(timeee[localPlayer]) end --kill timeeeend-------------------- clear all edit when click------------------function onGuiClick (button, state, absoluteX, absoluteY) if (source == GUIEditor_Edit2[1]) then guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[2]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[3]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[4]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[5]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[6]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[7]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[8]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[9]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[10]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[11]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[12]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[13]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[14],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") elseif (source == GUIEditor_Edit2[14]) then guiSetText (GUIEditor_Edit2[1],"") guiSetText (GUIEditor_Edit2[2],"") guiSetText (GUIEditor_Edit2[3],"") guiSetText (GUIEditor_Edit2[4],"") guiSetText (GUIEditor_Edit2[5],"") guiSetText (GUIEditor_Edit2[6],"") guiSetText (GUIEditor_Edit2[7],"") guiSetText (GUIEditor_Edit2[8],"") guiSetText (GUIEditor_Edit2[9],"") guiSetText (GUIEditor_Edit2[10],"") guiSetText (GUIEditor_Edit2[11],"") guiSetText (GUIEditor_Edit2[12],"") guiSetText (GUIEditor_Edit2[13],"") guiSetText (GUIEditor_Label2[15],"Total : 0 $") endendaddEventHandler ("onClientGUIClick", getRootElement(), onGuiClick)------------------------Buy Weapon----------------------function onGuiClick (button, state, absoluteX, absoluteY) if (source == GUIEditor_Button1[2]) then local gWA = guiGetText (GUIEditor_Edit2[1]) string.format ("-", gWA) if gWA ~= '' then local tPM = tonumber(gWA) * 5 local wID = 22 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[2]) if gWA ~= '' then local tPM = tonumber(gWA) * 8 local wID = 23 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[3]) if gWA ~= '' then local tPM = tonumber(gWA) * 10 local wID = 24 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[4]) if gWA ~= '' then local tPM = tonumber(gWA) * 14 local wID = 25 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[5]) if gWA ~= '' then local tPM = tonumber(gWA) * 12 local wID = 26 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[6]) if gWA ~= '' then local tPM = tonumber(gWA) * 18 local wID = 27 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[7]) if gWA ~= '' then local tPM = tonumber(gWA) * 20 local wID = 32 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[8]) if gWA ~= '' then local tPM = tonumber(gWA) * 25 local wID = 29 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[9]) if gWA ~= '' then local tPM = tonumber(gWA) * 30 local wID = 30 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[10]) if gWA ~= '' then local tPM = tonumber(gWA) * 35 local wID = 31 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[11]) if gWA ~= '' then local tPM = tonumber(gWA) * 17 local wID = 28 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[12]) if gWA ~= '' then local tPM = tonumber(gWA) * 21 local wID = 33 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[13]) if gWA ~= '' then local tPM = tonumber(gWA) * 40 local wID = 34 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end local gWA = guiGetText (GUIEditor_Edit2[14]) if gWA ~= '' then local tPM = tonumber(gWA) * 100 local wID = 16 triggerServerEvent ("BuyW", getLocalPlayer(), tPM , gWA, wID ) end elseif (source == GUIEditor_Button1[1]) then destoy() showCursor( false ) endendaddEventHandler ("onClientGUIClick", getRootElement(), onGuiClick)------------------------Create Marker & bilp----------------------local Marker = createMarker ( 296, -37, 999.5, "cylinder", 2, 255, 255, 0, 150 )setElementInterior( Marker, 1, 296, -37, 999.5 )addEventHandler('onClientMarkerHit', Marker,function ( hitPlayer ) if ( hitPlayer == localPlayer ) then show() showCursor( true ) endend )createBlip ( 1367, -1279, 13 , 6 ) ذا ككود الششوب . على العموم . امسح كود الي يعطي سلاح اول مايدخل الاعب السيرفر رومند يا حبي المشكلة من سباون الشخصيات مو من اعطاء سلاح Link to comment
=xx=Ali=xx= Posted April 12, 2014 Author Share Posted April 12, 2014 يعني مافي ححل منتدى برمجه كبير مافيهه حل واحد ؟ Link to comment
1REDBULL Posted April 12, 2014 Share Posted April 12, 2014 يعني مافي ححل منتدى برمجه كبير مافيهه حل واحد ؟ الى في حلول بس انت تعلم و اكتب الاكواد مره ثانيه بس خلها بين . Link to comment
ΞĪŚŚÀ Posted April 12, 2014 Share Posted April 12, 2014 اشرح المششكلة حبة حبة وآبشر بـ الحل |: Link to comment
=xx=Ali=xx= Posted April 13, 2014 Author Share Posted April 13, 2014 شباب كلمت رومأند ونفس المشكلة يقول مايعرف وسعد معرف وين الاقيه من زمأن ماشوفهه Link to comment
ΞĪŚŚÀ Posted April 13, 2014 Share Posted April 13, 2014 جرب -- -- -- File : Main / server ver = "v3.4" rRoot = getResourceRootElement(getThisResource()) local root = getRootElement() local Key = "F4" Teams = { -- here all team name {"Grove", 0, 255, 0}, {"Aztecas", 0, 150, 255}, {"Police", 0, 50, 255}, {"Ballas", 255, 0, 150}, {"No Team", 255, 255, 255}, {"Medic", 6, 183, 248} } local function set(plr, data, bole) if not isElement(plr) then return end return setElementData(plr, data, bole) end local function get(plr, data) if not isElement(plr) then return end return getElementData(plr, data) end addEventHandler("onResourceStart", resourceRoot, function() setGameType("GangWars v3.4") for _,theTeam in ipairs(Teams) do createTeam(theTeam[1], theTeam[2], theTeam[3], theTeam[4]) end for _,AllTeams in ipairs(getElementsByType("team")) do if getTeamFriendlyFire(AllTeams) == true then setTeamFriendlyFire(AllTeams, false) end end setTeamFriendlyFire(getTeamFromName("No Team"), true) for i,v in ipairs(getElementsByType("player")) do bindKey(v, Key, "down", "changeTeame") setElementData(v, "OnJoinFirstSpawn", false) end setElementData(rRoot,"maxPlayer",getMaxPlayers()) end ) addEventHandler("onResourceStop", resourceRoot, function() local players = getElementsByType("player") for k,v in ipairs(players) do set(v, "hjwalah", false) set(v, "Grove", false) set(v, "Aztecs", false) set(v, "Police", false) set(v, "Ballas", false) set(v, "noTeam", false) set(v, "Medic", false) set(v, "GameModeActive", false) end end ) addEvent("onLoadedClient", true) addEventHandler("onLoadedClient", root, function(player) versionDisplay = textCreateDisplay() local versionText = textCreateTextItem("Gang wars " .. ver .. "", 1, 0.975, "clear-normal", 175, 175, 175, 255, 1.1, "right","bottom") textDisplayAddText(versionDisplay, versionText) textDisplayAddObserver(versionDisplay, player) setElementData(player, "CancleFirstSpawn", true) playSoundFrontEnd(player, 16) OutPut("The Download has finnished Succesfully", player, 255, 255, 0) setElementData(player, "OnJoinFirstSpawn", false) end ) addEventHandler("onPlayerJoin", root, function() showTextForPlayer ( source, 6000, 255, 0, 0, 1.5, "Welcome To Gang War Server") showTextForPlayer1 ( source, 6000, 255, 0, 0, 1.5, "Please Wait until the Download Finnished .....!") setCameraMatrix(source,512.2, -1263.57, 32.53,542.16, -1287.07, 17.24) end ) addEventHandler("onPlayerSpawn", root, function() checkWeapon(source) end ) function checkWeapon(player) setTimer(function(player) if isElement(player) then if getElementData(player, "Police") == true then giveWeapon(player, 3) end else takeWeapon(player, 3) end end, 800, 1, player) end addEvent("onClientWantsToSpawn", true) addEventHandler("onClientWantsToSpawn", getRootElement(), function(player, ID, TeamName) if TeamName == "Grove" then setElementData(player, "ID", ID) GroveTeam(player) elseif TeamName == "Aztecas" then setElementData(player, "ID", ID) AztecsTeam(player) elseif TeamName == "Police" then setElementData(player, "ID", ID) PoliceTeam(player) elseif TeamName == "Ballas" then setElementData(player, "ID", ID) Ballas(player) elseif TeamName == "No Team" then setElementData(player, "ID", ID) NoTeam(player) elseif TeamName == "Medic" then setElementData(player, "ID", ID) MedicTeam(player) elseif TeamName == "Drift" then setElementData(player, "ID", ID) hjwalah(player) end end ) function checkWeapon(player) setTimer(function(player) if isElement(player) then if getElementData(player, "Police") == true then giveWeapon(player, 3) end else takeWeapon(player, 3) end end, 800, 2, player) end function onSelectTeam(player) if not isElement(player) then return end local playerTeam = getPlayerTeam(player) showTextForPlayer(player, 5000, 255, 0, 0, 1.5, "You have been assigned to team [" .. tostring(getTeamName(playerTeam)) .. "]") OutPut("To return to spawn press["..Key.."]", player, 255, 255, 255) local playeraccount = getPlayerAccount(player) if playeraccount and not isGuestAccount(getPlayerAccount(player)) then if getElementData(player, "hjwalah") == true then return false end if getElementData(player, "wasgied") == true then return false end setElementData(player, "wasgied", true) local weap0 = getAccountData(playeraccount, "s.weap0") local weap1 = getAccountData(playeraccount, "s.weap1") local weap2 = getAccountData(playeraccount, "s.weap2") local ammo2 = getAccountData(playeraccount, "s.ammo2") local weap3 = getAccountData(playeraccount, "s.weap3") local ammo3 = getAccountData(playeraccount, "s.ammo3") local weap4 = getAccountData(playeraccount, "s.weap4") local ammo4 = getAccountData(playeraccount, "s.ammo4") local weap5 = getAccountData(playeraccount, "s.weap5") local ammo5 = getAccountData(playeraccount, "s.ammo5") local weap6 = getAccountData(playeraccount, "s.weap6") local ammo6 = getAccountData(playeraccount, "s.ammo6") local weap7 = getAccountData(playeraccount, "s.weap7") local ammo7 = getAccountData(playeraccount, "s.ammo7") local weap8 = getAccountData(playeraccount, "s.weap8") local ammo8 = getAccountData(playeraccount, "s.ammo8") local weap9 = getAccountData(playeraccount, "s.weap9") local ammo9 = getAccountData(playeraccount, "s.ammo9") local weap10 = getAccountData(playeraccount, "s.weap10") local weap11 = getAccountData(playeraccount, "s.weap11") local weap12 = getAccountData(playeraccount, "s.weap12") local wanted = getAccountData(playeraccount, "WantedLevel") if tonumber(wanted) then setPlayerWantedLevel(player, wanted) elseif tonumber(weap0) then giveWeapon(player, weap0, 1) elseif tonumber(weap1) then giveWeapon(player, weap1, 1) elseif tonumber(weap2) and tonumber(ammo2) then giveWeapon(player, weap2, ammo2) elseif tonumber(weap3) and tonumber(ammo3) then giveWeapon(player, weap3, ammo3) elseif tonumber(weap4) and tonumber(ammo4) then giveWeapon(player, weap4, ammo4) elseif tonumber(weap6) and tonumber(ammo5) then giveWeapon(player, weap5, ammo5) elseif tonumber(weap6) and tonumber(ammo6) then giveWeapon(player, weap6, ammo6) elseif tonumber(weap7) and tonumber(ammo7) then giveWeapon(player, weap7, ammo7) elseif tonumber(weap8) and tonumber(ammo8) then giveWeapon(player, weap8, ammo8) elseif tonumber(weap9) and tonumber(ammo9) then giveWeapon(player, weap9, ammo9) elseif tonumber(weap10) then giveWeapon(player, weap10, 30) elseif tonumber(weap11) then giveWeapon(player, weap11, 30) elseif tonumber(weap12) then giveWeapon(player, weap12, 10) end end end function camera(plr) if not isElement(plr) then return end setTimer(fadeCamera, 50, 1, plr, false, 1) setTimer(fadeCamera, 100, 1, plr, true, 3) setCameraTarget(plr, plr) showChat(plr, true) end addEventHandler("onPlayerSpawn", root, function() setElementData(source, "FristTimeSpawn", false) bindKey(source, Key, "down", "changeTeame") setElementData(source, "WasChangeTeam", false) end ) Change = false addCommandHandler("changeTeame", function(plr) if getElementData(plr, "WasChangeTeam") == false then setElementData(plr, "ChangeTeam", true) OutPut("The team will change after you die", plr, 255, 0, 255) setTimer(cancleTeam, 1700, 1, plr) setElementData(plr, "WasChangeTeam", true) else OutPut("Change the team has been canceled", plr, 255, 255, 0) setElementData(plr, "ChangeTeam", false) setElementData(plr, "WasChangeTeam", false) end Change = not Change end ) function cancleTeam(plr) if Change == false then return false end OutPut("To cancel the change team press again", plr, 255, 255, 0) 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