Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 09/12/18 in Posts

  1. Hello friends! We want to introduce you to the new gamemode in MTA. Would you like to visit Mars? Subscribe to the topic to get the latest news! Twitter: https://twitter.com/MTAMarsX VK: https://vk.com/mtamarsx
    1 point
  2. This is a little project I've been working on for a while now. I'm a huge Ace Combat fan, and I always wanted to bring the frantic, high altitude battles to MTA. That being said, I unfortunately don't have a lot of free time to work on this gamemode, which is why I want to assemble a small team to help me with that. What exactly is SKIES HIGH? SKIES HIGH is a "arcade flight simulator", if you will. Battle against other players around the globe for air superiority, purchase aircraft, climb their respective skilltrees, become what pilots refer to as an "Ace", and eventually, the "Ace of Aces". What does SKIES HIGH offer? Here are a few things that will be included in the gamemode: Dogfight: Small-scale skirmishes with up to 8 players - either against each other, or in teams The Round Table: Large-scale, all-out war with up to 32 players. Last man standing, only the best survive the airspace commonly referred to as "The Round Table". Missions: Experience the story of SKIES HIGH with 3 other players Other than that, the following features will also be available: Hangar: Buy/sell your aircraft, upgrade them by climbing the skilltree, add and change skins/tags/squadron logo "Weapons of Mass Destruction": Specialized, highly dangerous superweapons capable of easily destroying entire squadrons Events: Special events which allow players to unlock skins/aircraft/story which might never be available again This sounds really cool. Is the gamemode available for download? No. The whole gamemode is a work in progress, pre-alpha state, in a manner of speaking. I'm currently more interested in assembling a team to help me code this gamemode, anyway. The gamemode itself won't be released to the public, either. It'll be closed source, running on 2-3 servers at most, all hosted and managed by the team. This sucks. And let me guess, there'll be lootboxes or something like that to pay for the server costs. No. There won't be any lootboxes. In order to pay for server costs, we'll allow players to purchase cosmetics for their aircraft. And no, you won't be able to bribe your way to victory by buying a F-22A Raptor. I'm interested in joining your team. That's awesome. However, interest alone won't allow you to just join, there's a few requirements you must fullfill: Must have experience with Lua (ideally, you should have already scripted your own gamemode) Willing to not disclose/leak/share any parts of the code, however insignificant you may deem that action Working knowledge of the english language - I'm absolutely fine with grammatical errors, as long as you know the difference between its and it's You think you'd pass these requirements with flying colors? Good, then send me a private message, and we'll talk! Is there a lot left to script? Yes, unfortunately. As I've said, I don't have enough free time to dedicate myself to scripting everything, hence the assembly of a team. I've started scripting a few things, like the HUD, the lobby, "start menu", but there's still a lot left to do. What about modellers? Do you need one, too? Yes. I've found a lot of aircraft skins online, but for some reasons, they are broken. A modeller could certainly fix them, though. Final question: what's in for me if I join your team? Err, if you expect monetary compensation or something, I'm afraid I'll have to disappoint you. SKIES HIGH is a project of passion. Any money earned with it will be used to pay server/website costs, and PERHAPS commission the creation of special aircraft skins. I'm really sorry I can't provide you with screenshots or videos right now, but rest assured, I'll post some once I have proper, working internet (which is another reason I want and need a team). Still, I hope I sparked your interest in this gamemode. See you up in the skies, fellow pilots!
    1 point
  3. عندك غلطات في مثالك سطر 11 =حدث عند دخول اللاعب ما فيه باراميتارز سطر 13 = ما حطيت الألمنت الي تبي الرساله تظهر له سطر 15 = المفروض تبدل بلاير بـ سورس
    1 point
  4. "Google translating gone sexual"
    1 point
  5. You can edit the building .DFF in zModeler2 Add me on Skype if you need help
    1 point
  6. Hi @Krex ! I don't know 100% working method. But I give you a little support regarding this. Server Side :- addEventHandler("onPlayerDamage",root, function (_,type) if type == 19 then local x,y,z = getElementPosition(source) createExplosion(x,y,z,10) createExplosion(x,y,z,10) createExplosion(x,y,z,10) end end ) This is my little effort results. When a player hit a missile, x3 explosion create. But if missile explode near the player. Our custom explosions done on the player . examine the code and build your own. Good Luck !
    1 point
  7. Hello @Tony Brand ! I'm not well known on databases of MTA server. I'm here to answer your last question. According to my knowledge, I thought it can be happen. I can give you a suggestion regarding this. That is; you should use 'setTimer' function on some of player's data changed. Meanwhile, as you say, if player change his money continuously, server had a many load to do. So, you should use a timer. When player change his money, timer run and about 6/7 seconds after, server executes the database function to save player's money. Since database save function run on 6/7 seconds interval, player can continuously change his data on that time period. Then server will save current money one time on database. So I think this way is efficient.
    1 point
  8. Hello ! I have a probblem. Everytime when I creating a ped in the server using 'createPed' function, the ped that creating can't be killed [ immortal ]. I don't like that way. The ped should be able to killed. Did you know to fix this ? createPed(0, 0, 0, 5)
    1 point
  9. One way is using 'setAccountData' function to save.
    1 point
  10. Well, I don't know what happened, I didn't change anything, and it just randomly started working..?
    1 point
  11. @Quenix It's my practice. Always think about your script. Every time try yourself to solve your LUA problem. Then you'll also become a god automatically !
    1 point
  12. I test a png image file with spaces in it's name. That png file is finding by the resource and work perfectly. And if you want to remove the image when player close the window, simply use; bindKey ( "f4", "down", function ( ) if getElementData(localPlayer, "logedin") then local state = ( not guiGetVisible (SHOP.window[1]) ) if not getElementData(localPlayer,"shop.viewing") then setElementData(localPlayer,"shop.viewing",1) end guiSetVisible ( SHOP.window[1], state ) showCursor ( state ) if guiGetVisible(SHOP.window[1]) == false then removeEventHandler ( "onClientGUIClick", root, onSwitch ) if isElement(itemImage) then destroyElement(itemImage) end else addEventHandler ( "onClientGUIClick", root, onSwitch ) end end end )
    1 point
  13. Test this; function click () if source == SHOP.panel[1] or source == SHOP.panel[2] or source == SHOP.panel[3] or source == SHOP.panel[4] or source == SHOP.panel[5] then local selectedItem = guiGridListGetItemText ( source, guiGridListGetSelectedItem ( source ), 1 ) local price = guiGridListGetItemText ( source, guiGridListGetSelectedItem ( source ), 2 ) guiSetText( SHOP.label[1],"To buy "..selectedItem.." for "..price.." K.B.K Points press button below") guiLabelSetColor( SHOP.label[1],255,255,255) if isElement(itemImage) then destroyElement(itemImage) itemImage = guiCreateStaticImage( 500, 500, 400, 400, selectedItem..".png", false ) else itemImage = guiCreateStaticImage( 500, 500, 400, 400, selectedItem..".png", false ) end end end
    1 point
  14. Quick Hint :- If you want to draw a DX image with the item click, you can use this trick. Rename the images how it appears in the gridlist's first column. Then, when customer click on one of our 3 gridlists, take the selected text of gridlist as a variable and draw image according to it.
    1 point
  15. EDIT: I have realized I am an idiot, and discovered the "setTrafficLightsLocked" function. Problem solved. END EDIT Hey all, so I was attempting to make it so the lights updated at an almost realistic time. After 20 seconds of being green, I want them to turn yellow, after 6 seconds yellow, turn red, 1 second of red, turn back to green but for the other direction, and so on and so forth. Unfortunately this has just resulted in chaos, the lights are not updating even within the 20 seconds and after about 30 seconds or so they just start flashing like crazy. greenTime = 20000 yellowTime = 6000 redTime = 1000 gTimer = nil yTimer = nil rTimer = nil lState = nil function startTrafficLights() setTrafficLightState(0) lState = 0 gTimer = setTimer(updateLights,greenTime,1) end addEventHandler("onResourceStart",getRootElement(getThisResource()),startTrafficLights) function updateLights() if(lState == 0)then setTrafficLightState(1) killTimer(gTimer) lState = 1 yTimer = setTimer(updateLights,yellowTime,1) elseif(lState == 1)then setTrafficLightState(2) killTimer(yTimer) lState = 2 rTimer = setTimer(updateLights,redTime,1) elseif(lState == 2)then setTrafficLightState(3) killTimer(rTimer) lState = 3 gTimer = setTimer(updateLights,greenTime,1) elseif(lState == 3)then setTrafficLightState(4) killTimer(gTimer) lState = 4 yTimer = setTimer(updateLights,yellowTime,1) elseif(lState == 4)then setTrafficLightState(2) killTimer(yTimer) lState = 5 rTimer = setTimer(updateLights,redTime,1) elseif(lState == 5)then setTrafficLightState(0) killTimer(rTimer) lState = 0 gTimer = setTimer(updateLights,greenTime,1) end end I'm unsure what could be causing this, or even if I'm approaching this correctly. Any help is always appreciated! EDIT: I added in debugstrings to each timer section, and it is calling the debugstring accordingly, but the traffic light states are not holding.
    1 point
  16. First of all sorry for late ! I just edit some of code in client side. The item table also divided into 3 parts. I just divided them to show you the method. They are not divided correctly. You should fix them. You can understand below code. Examine it well. Server code remains same. local items = { --items,cena(K.B.K Points) porsion1List = { {"M1911",50}, {"PDW",150}, {"Winchester 1866",150}, {"AK-107",300}, {"Lee Enfield",400}, {"M4A1 Holo",300}, {"MK 48 Mod 0",450}, {"CZ550",300}, {"DMR",400} }, porsion2List = { {"M1911 Mag",50}, {"PDW Mag",100}, {"1866 Slug",125}, {"AK-107 Mag",100}, {"M4A1 Holo Mag",50}, {"MK 48 Mod 0 Mag",200}, {"Lee Enfield Mag",70}, {"CZ550 Mag",50}, {"DMR Mag",25}, {"Medic Kit",50}, {"Painkiller",10}, {"Morphine",10}, {"Bandage",5}, {"Water Bottle",15}, {"Burger",15} }, porsion3List = { {"Tire",75}, {"Engine",125}, {"Tank Parts",50}, {"Camouflage Clothing",100}, {"Army Clothing",150}, {"Ghost Clothing",200}, {"K.B.K Backpack",150}, {"Ghillie Suit",200}, {"Civilian Clothing",30}, {"GPS",15}, {"Map",15}, {"Toolbox",25} } } SHOP = { button = {}, window = {}, label = {}, tabpanel = {}, tab = {}, panel = {} } addEventHandler("onClientResourceStart", resourceRoot, function() SHOP.window[1] = guiCreateWindow(0.16, 0.26, 0.65, 0.55, "Kill Or Be Killed Shop", true) guiWindowSetMovable(SHOP.window[1], false) guiWindowSetSizable(SHOP.window[1], false) guiSetProperty(SHOP.window[1], "CaptionColour", "FFFF0000") SHOP.label[1] = guiCreateLabel(0.02, 0.69, 0.97, 0.08, "Select item which you want to buy! \nThe shop value is K.B.K Points", true, SHOP.window[1]) guiSetFont(SHOP.label[1], "default-bold-small") guiLabelSetHorizontalAlign(SHOP.label[1], "center", true) guiLabelSetVerticalAlign(SHOP.label[1], "center") SHOP.button[1] = guiCreateButton(0.35, 0.79, 0.30, 0.12, "BUY", true, SHOP.window[1]) guiSetFont(SHOP.button[1], "default-bold-small") SHOP.tabpanel[1] = guiCreateTabPanel(40, 33, 587, 240, false, SHOP.window[1]) SHOP.tab[1] = guiCreateTab("Porsion 1", SHOP.tabpanel[1]) SHOP.panel[1] = guiCreateGridList(0.01, 0.03, 0.98, 0.92, true, SHOP.tab[1]) guiGridListAddColumn(SHOP.panel[1], "Item", 0.5) guiGridListAddColumn(SHOP.panel[1], "Price", 0.5) for i,v in pairs ( items.porsion1List ) do local row = guiGridListAddRow ( SHOP.panel[1] ) guiGridListSetItemText ( SHOP.panel[1], row, 1, v[1], false, false ) guiGridListSetItemText ( SHOP.panel[1], row, 2, v[2].."", false, false ) end SHOP.tab[2] = guiCreateTab("Porsion 2", SHOP.tabpanel[1]) SHOP.panel[2] = guiCreateGridList(0.01, 0.03, 0.97, 0.92, true, SHOP.tab[2]) guiGridListAddColumn(SHOP.panel[2], "Item", 0.5) guiGridListAddColumn(SHOP.panel[2], "Price", 0.5) for i,v in pairs ( items.porsion2List ) do local row = guiGridListAddRow ( SHOP.panel[2] ) guiGridListSetItemText ( SHOP.panel[2], row, 1, v[1], false, false ) guiGridListSetItemText ( SHOP.panel[2], row, 2, v[2].."", false, false ) end SHOP.tab[3] = guiCreateTab("Porsion 3", SHOP.tabpanel[1]) SHOP.panel[3] = guiCreateGridList(0.01, 0.03, 0.97, 0.92, true, SHOP.tab[3]) guiGridListAddColumn(SHOP.panel[3], "Item", 0.5) guiGridListAddColumn(SHOP.panel[3], "Price", 0.5) for i,v in pairs ( items.porsion3List ) do local row = guiGridListAddRow ( SHOP.panel[3] ) guiGridListSetItemText ( SHOP.panel[3], row, 1, v[1], false, false ) guiGridListSetItemText ( SHOP.panel[3], row, 2, v[2].."", false, false ) end guiSetVisible(SHOP.window[1],false) addEventHandler ( "onClientGUIClick", SHOP.panel[1], click ) addEventHandler ( "onClientGUIClick", SHOP.panel[2], click ) addEventHandler ( "onClientGUIClick", SHOP.panel[3], click ) addEventHandler ( "onClientGUIClick", SHOP.button[1], buttonClick ) end ) bindKey ( "f4", "down", function ( ) if getElementData(localPlayer, "logedin") then -- if getElementData (getLocalPlayer(),"playerlevel") >= 3 then local state = ( not guiGetVisible (SHOP.window[1]) ) if not getElementData(localPlayer,"shop.viewing") then setElementData(localPlayer,"shop.viewing",1) end guiSetVisible ( SHOP.window[1], state ) showCursor ( state ) if guiGetVisible(SHOP.window[1]) == false then removeEventHandler ( "onClientGUIClick", root, onSwitch ) else addEventHandler ( "onClientGUIClick", root, onSwitch ) end -- else -- outputChatBox (" 3!") -- end end end ) function buttonClick(button,state) if getElementData(localPlayer, "logedin") then if button == "left" and state == "up" then if getElementData(localPlayer,"shop.viewing") then o = getElementData(localPlayer,"shop.viewing") local nRow, nColumn = guiGridListGetSelectedItem( SHOP.panel[o] ) if nRow ~= -1 and nColumn ~= - 1 then local selectedItem = guiGridListGetItemText ( SHOP.panel[o], guiGridListGetSelectedItem ( SHOP.panel[o] ), 1 ) local price = guiGridListGetItemText ( SHOP.panel[o], guiGridListGetSelectedItem ( SHOP.panel[o] ), 2 ) local money = getPlayerMoney(thePlayer) if (money) >= tonumber(price) then guiLabelSetColor( SHOP.label[1],255,255,255) -- guiSetText( SHOP.label[1],"pietiek nauda") setPlayerMoney(money -tonumber(price)) if selectedItem == "MK 48 Mod 0 Mag" then setElementData(getLocalPlayer(),selectedItem,getElementData(getLocalPlayer(),selectedItem)+100) elseif selectedItem == "M4A1 Holo Mag" then setElementData(getLocalPlayer(),selectedItem,getElementData(getLocalPlayer(),selectedItem)+20) elseif selectedItem == "AK-107 Mag" then setElementData(getLocalPlayer(),selectedItem,getElementData(getLocalPlayer(),selectedItem)+30) elseif selectedItem == "DMR Mag" then setElementData(getLocalPlayer(),selectedItem,getElementData(getLocalPlayer(),selectedItem)+5) elseif selectedItem == "CZ550 Mag" then setElementData(getLocalPlayer(),selectedItem,getElementData(getLocalPlayer(),selectedItem)+10) elseif selectedItem == "PDW Mag" then setElementData(getLocalPlayer(),selectedItem,getElementData(getLocalPlayer(),selectedItem)+30) elseif selectedItem == "M1911 Mag" then setElementData(getLocalPlayer(),selectedItem,getElementData(getLocalPlayer(),selectedItem)+10) elseif selectedItem == "1866 slug" then setElementData(getLocalPlayer(),selectedItem,getElementData(getLocalPlayer(),selectedItem)+7) elseif selectedItem == "Lee Enfield Mag" then setElementData(getLocalPlayer(),selectedItem,getElementData(getLocalPlayer(),selectedItem)+10) else setElementData(getLocalPlayer(),selectedItem,getElementData(getLocalPlayer(),selectedItem)+1) end guiLabelSetColor( SHOP.label[1],10,255,10) guiSetText( SHOP.label[1],"You succesfully bought "..selectedItem.." and you still have "..(money -tonumber(price)).." K.B.K Points") else outputChatBox("no enough money !",255,0,0) end end else guiLabelSetColor( SHOP.label[1],255,10,10) guiSetText( SHOP.label[1],"You are missing "..(price -tonumber(money)).." K.B.K Points") end else guiSetText( SHOP.label[1],"Select something first") guiLabelSetColor( SHOP.label[1],255,255,255) end end end function onSwitch() if source == SHOP.panel[1] then setElementData(localPlayer,"shop.viewing",1) elseif source == SHOP.panel[2] then setElementData(localPlayer,"shop.viewing",2) elseif source == SHOP.panel[3] then setElementData(localPlayer,"shop.viewing",3) end end function click () if source == SHOP.panel[1] or source == SHOP.panel[2] or source == SHOP.panel[3] then local selectedItem = guiGridListGetItemText ( source, guiGridListGetSelectedItem ( source ), 1 ) local price = guiGridListGetItemText ( source, guiGridListGetSelectedItem ( source ), 2 ) guiSetText( SHOP.label[1],"To buy "..selectedItem.." for "..price.." K.B.K Points press button below") guiLabelSetColor( SHOP.label[1],255,255,255) end end
    1 point
  17. السلام عليكم ورحمة الله وبركاته في بداية دخولك للغة البرمجة إل يو اي عليك معرفة الأساسيات مثل الدوال و المتغيرات والشرط و نهاية الدالة و متى يتحقق الشرط و متى يصبح خاطئاً (ترو , فولس ) أي المنطق كل هذه اشياء اساسية عليك معرفتها من خلال الدروس في قسم الشروحات , إذا لم تفهمها جيداً فنصيحتي لك أن تسأل عنها و تحاول أن تفهمها قبل أن تنتقل لخطوات متقدمه و أيضاً عليك التأني في تعلم لغة البرمجة لأنها تحتاج وقت و تركيز و رغبه , فلم يكن قبلك أحد أجاد لغة برمجية خلال اسبوع او اسبوعين أو حتى خلال شهر . .وهذا من واقع تجربة وخبره# أما بالنسبة لأزرار اللوحة وكيف تتعامل معها فتوجد شروحات كثيره جداً ومبسطه من الإخوان في المنتدى بقسم الشروحات و قد نجح الكثير في إجتياز هذه المصاعب الابتدائية بفضل تلك الدروس فراجعها . الآن سأضع لك بعض الأمثلة على لوحة تجريبية لنفترض أننا أنشأنا لوحةً تحمل 3 أزرار لكل زر وظيفة محدده وهي كالتالي : الزر الأول : يكتب إسم اللاعب الذي ضغط على الزر الأول الزر الثاني : يكتب عدد اللاعبين في الخادم الزر الثالث : يقوم بإغلاق اللوحة .ملاحظة هامة : جميع الأكواد التالية تُوضَع في ملف العميل أو( الكلينت ) فقط ولا توضَع في ملف الخادم أو السيرفر الكود التالية هو كود بناء اللوحة تم نسخه من سكربت الجي يو أي إديتور * GUIEditor = { button = {}, window = {} } addEventHandler("onClientResourceStart", resourceRoot, function() GUIEditor.window[1] = guiCreateWindow(609, 376, 661, 423, "لوحة تجريبية", false) guiWindowSetSizable(GUIEditor.window[1], false) guiSetAlpha(GUIEditor.window[1], 0.98) guiSetVisible( GUIEditor.window[1],false ) -- دالة تقوم بإغلاق اللوحة فور تشغيلها لأنه إفتراضياً سوف تظهر اللوحة على شاشتك عند تشغيل السكربت أو المود GUIEditor.button[1] = guiCreateButton(22, 57, 249, 41, "الزر الأول", false, GUIEditor.window[1]) guiSetFont(GUIEditor.button[1], "default-bold-small") guiSetProperty(GUIEditor.button[1], "NormalTextColour", "FFAAAAAA") GUIEditor.button[2] = guiCreateButton(376, 57, 249, 41, "الزر الثاني", false, GUIEditor.window[1]) guiSetFont(GUIEditor.button[2], "default-bold-small") guiSetProperty(GUIEditor.button[2], "NormalTextColour", "FFAAAAAA") GUIEditor.button[3] = guiCreateButton(209, 220, 226, 55, "الزر الثالث", false, GUIEditor.window[1]) guiSetProperty(GUIEditor.button[3], "NormalTextColour", "FFAAAAAA") end ) إضغط هنا يفتح معك موقع في داخله صورة اللوحة الآن نريد توظيف الأزرار , نبدأ بالزر الأول أردنا أن نجعل الزر الأول يحضر إسم اللاعب و يكتبه في الشات العام داخل اللعبه إذن من خلال كود إنشاء اللوحة في الأعلى نقول أن المتغير التالي يمثل الزر الأول : GUIEditor.button[1] سيكون عملنا على المتغير وليس إسم الزر بالعربي ** الدوال التي نحتاجها لبرمجة الزر الأول كالتالي : دالة جلب إسم اللاعب getPlayerName دالة إخراج النص للشات outputChatBox أما الحـدث الموجود لدينا هنا هو حدث الضغط على زر : onClientGUIClick نبدأ على بركة الله , ننشئ دالةً جديده و لنجعل أسمها كالتالي : function firstButtonWork() نقوم الآن بإغلاق الدالة كي تصبح جاهزه لأداء المهام المدرجة بداخلها : function firstButtonWork() -- بداية الدالة end -- نهاية الدالة الآن نقوم بإستخراج إسم اللاعب و نضعه في متغير داخل الدالة function firstButtonWork() -- بداية الدالة -- منطقة عمل الدالة إذا كان فارغاً فلن تعمل ولكن لن تعطيك أخطاء -- local playerName = getPlayerName( localPlayer ) -- ووضعنا له وظيفة الحصول على اسم اللاعب إذن المتغير هو إسم اللاعب نفسه playerName انشئنا متغير باسم end -- نهاية الدالة الآن نقوم بكتابة الخطوة الأخيره للزر الأول وهي إخراج أي نص في الشات و النَّصُ هنا هو إسم اللاعب : function firstButtonWork() -- بداية الدالة -- منطقة عمل الدالة إذا كان فارغاً فلن تعمل ولكن لن تعطيك أخطاء -- local playerName = getPlayerName( localPlayer ) -- ووضعنا له وظيفة الحصول على اسم اللاعب إذن المتغير هو إسم اللاعب نفسه playerName انشئنا متغير باسم outputChatBox( playerName,localPlayer, 255, 0, 200 ) -- هو إسم اللاعب الذي حصلنا عليه من الدالة السابقة في الأعلى playerName دالة إخراج النص حيث end -- نهاية الدالة إنتهينا الآن من الدالة الموكلة بالوظائف التي تلي الضغط على الزر الأول متبقي لدينا أن نربط الزر الأول بالحدث function firstButtonWork() -- بداية الدالة if source == GUIEditor.button[1] then -- بداية شرط التحقق من ان الزر المضغوط هو الزر الاول -- منطقة عمل الدالة إذا كان فارغاً فلن تعمل ولكن لن تعطيك أخطاء -- local playerName = getPlayerName( localPlayer ) -- ووضعنا له وظيفة الحصول على اسم اللاعب إذن المتغير هو إسم اللاعب نفسه playerName انشئنا متغير باسم outputChatBox( playerName,localPlayer, 255, 0, 200 ) -- هو إسم اللاعب الذي حصلنا عليه من الدالة السابقة في الأعلى playerName دالة إخراج النص حيث end -- نهاية الشرط end -- نهاية الدالة addEventHandler('onClientGUIClick', root, firstButtonWork) الآن نقوم بإنشاء دالة خاصة بالزر الثاني و هو زر إظهار عدد اللاعبين في الشات : function secondButtonWork() -- بداية الدالة if source == GUIEditor.button[2] then -- شرط التحقق من أن الزر المضغوط هو الزر الثاني local players = getElementsByType("player") -- دالة تمثل كل اللاعبين في السيرفر local playersCount = #players -- متغير يمثل عدد اللاعبين في السيرفر local text = tostring(playersCount) -- تحويل عدد اللاعبين من أرقام إلى نص outputChatBox(text, localPlayer, 000, 094, 166) -- إخراج الرقم في الشات end -- نهاية الشرط end -- نهاية الدالة addEventHandler('onClientGUIClick', root, secondButtonWork) -- حدث عند الضغط على الزر نقوم الآن بتعيين دالة جديده تخص إغلاق اللوحة للزر الثالث والأخير: function thirdButtonWork() -- بداية الدالة if source == GUIEditor.button[3] then -- شرط التحقق من أن الزر المضغوط هو الزر الثالث guiSetVisible(GUIEditor.window[1], false) -- دالة إغلاق اللوحة showCursor(false) -- دالة عرض المؤشر أو إخفاؤه end -- نهاية الشرط end -- نهاية الدالة addEventHandler('onClientGUIClick', root, thirdButtonWork) -- حدث عند الضغط على الزر F5 لم يتبقى لنا إلا تعيين أحد أزرار الكيبورد لفتح اللوحة التجريبية و لنفترض أن الزر هو: function openWindow() -- بداية الدالة guiSetVisible(GUIEditor.window[1], not guiGetVisible(GUIEditor.window[1])) -- تعيين حالة اللوحة ( مفتوحة أو مغلقة ) عكس حالتها حين تضغط على زر اف 5 showCursor(not isCursorShowing()) end -- نهاية الدالة bindKey("F5", 'down', openWindow) -- تعيين زر إف 5 كفتح و إغلاق للوحة التجريبية في النهاية أتمنى منك تحاول و تتعلم وتبحث , كلنا كان نحتاج مساعده في البداية و حصلنا مساعده و تجاوب من الاخوان في المنتدى الله يجزاهم خير و لكن لم نعتمد على أكواد جاهزه فقط بالتوفيق .
    1 point
  18. Maybe you should ask your friend?
    1 point
  19. That's sympatic that your friend gave you a cool login panel but he didn't gave us So we can not guess the code
    1 point
  20. عندك انا كاتب في اكواد تتحط في ملف الكلينت واكواد في ملف السيرفر لغا تحط كلة في ملف علشان بيخرب -- Server Group = "Console" -- قروب addEvent("SHOW_s",true) addEventHandler("SHOW_s",getRootElement(), function() if isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)), aclGetGroup( Group )) then triggerClientEvent ( source, "SHOW", source) else outputChatBox ( "مخصص لـ الكونسل", source, 255, 255, 255, true ) end end) دي في ملف السيرفر -- Client guiSetVisible (wnd, false ) function OpenWin() if guiGetVisible (wnd) then guiSetVisible (wnd, false ) showCursor(false) guiSetInputEnabled(false) else triggerServerEvent("SHOW_s",localPlayer) end end bindKey("/", "down", OpenWin) addEvent('SHOW',true) addEventHandler('SHOW',root, function () guiSetVisible (wnd, true ) showCursor(true) guiSetInputEnabled(true) end ) ودي في الكلينت
    1 point
  21. This script has been stolen from a server by taking the uncompiled client.lua from the client resources directory while playing there. As this happens to be my server, I took this opportunity to publish the script on community rather than having someone else show off with work that isn't theirs. Said server has been running this script for a couple of years already. You can download the resource at https://community.multitheftauto.com/index.php?p=resources&s=details&id=15749 now (open source). Topic locked because this practice isn't allowed on the forums Arabic translation (not by me): هذا السكربت تمت سرقته من السيرفر الخاص بي عن طريق سرقة ملف الكلاينت الغير مشفر من مجلد المودات أثناء اللعب هناك, وبالصدفة هذا السكربت خاص بسيرفري لذلك استغليت الفرصة وقمت بنشر السكربت في الكوميونيتي بدلاً من تظاهر شخص بعمل ليس له, هذا السكربت يعمل بالسيرفر لعدة سنين حالياً https://community.multitheftauto.com/index.php?p=resources&s=details&id=15749 : ( تحميل السكربت ( مفتوح المصدر .هذا الموضوع مغلق لأن هذا التصرف ممنوع في المنتدى
    1 point
  22. شرح كيف اسوي شرح
    1 point
  23. Go in the directory of the map you've made. Edit the map file and that line of code: removeWorldModel (4215, 10000, 0, 0, 0)
    1 point
  24. I want someone my server programming in Exchange for money but to have a professional with the evidence and images of exclusively lesbian
    0 points
  25. تحتاج تسوي دوال جديده ويبيلها شغل تحتاج حدث : onClientWeaponFire راح يصير السورس عندك هو السلاح اللي يطلق النار ,لازم تجرب هل تحتاج تسوي كانسل ايفنت او لا طبعا تستخدم هذي الدالة = setWeaponFiringRate عشان تحط معدل إطلاق النار .
    0 points
×
×
  • Create New...