Leaderboard
Popular Content
Showing content with the highest reputation on 31/01/19 in all areas
-
-: اعضاء فريق مجتمع العرب @justboy @#CroSs @NX_CI @ibrahim# @Rakan#3 points
-
I use https://www.phpmyadmin.net/ https://wiki.multitheftauto.com/wiki/DbQuery1 point
-
1 point
-
Aé, acabei me esquecendo, quando coloca "and" automaticamente o valor vira o ultimo, ou seja dessa forma não mudou nada o problema local plants = {} local plants1 = {} local indexPl = {} function iniciarFarm8 ( client, x, y, z ) if not indexPl[client] then indexPl[client] = 1 else indexPl[client] = indexPl[client] + 1 end newIndex = getPlayerName(client) .."".. indexPl[client] plants[newIndex] = createObject ( 862, x , y , z - 1 , 0, 0, 0 ) setElementData( client, "Trabalho8", true, false ) animation = setPedAnimation(source, "medic", "CPR", -1, false, false, false, false) end addEvent ("iniciaJob8", true) addEventHandler ("iniciaJob8", getRootElement(), iniciarFarm8) function plantDestroy ( thePlayer ) newIndex = getPlayerName(thePlayer) .."".. indexPl[thePlayer] if plants[newIndex] and isElement(plants[newIndex] ) and getElementModel(plants[newIndex] ) == 862 then local numero = tonumber(indexPl[thePlayer]) for i=1,numero do destroyElement ( plants[newIndex] ) indexPl[thePlayer] = indexPl[thePlayer] -1 newIndex = getPlayerName(thePlayer) .."".. indexPl[thePlayer] end end end addEvent ("onDestroyElement", true) addEventHandler ("onDestroyElement", getRootElement(), plantDestroy) Tente dessa forma, o ruim mesmo, é que eu não tenho como testar, ai tenho que ficar mandando sempre kk1 point
-
لول طيب الداتا تقدر تجيب حتى لو بملف سيرفر و في مود ثاني عادي ترا مثال عندك ملف في سكربت محدد داخل الملف هذا انت معطي اللاعب او اي شي ثاني معطيه داتا تقدر تخش سكربت ثاني و تجيب الداتا من السكربت الثاني ما يحتاج لك اكسبورت فقط جيب الداتا ويعطيك القيمة اللي داخلها1 point
-
1 point
-
Alright, Go to this page: https://wiki.multitheftauto.com/wiki/Resource:Performancebrowser Next to high CPU usage, your code can also be creating a memory leak. This means that your code is not able to clean itself. Just like buy stuff your entire life, but you never throw it away. At the end it gets piled in your basement... https://wiki.multitheftauto.com/wiki/Resource:Performancebrowser#Category_-_Lua_memory To check this: -1. Go to this page: https://wiki.multitheftauto.com/wiki/Resource:Performancebrowser#Category_-_Lua_memory 0. Start your resourcebrowser. 1. Set category: lua memory 2. Start all your resources you would normally need. 3. Wait a minute or two for the memory values to be normalised. 4. Make a screenshot of the values, this is your first sample. 5. repeat step 4 multiple, with a delay of your choice. 6. Now compare the samples. The column current should always get down at a given point. If it keeps increasing forever, then you have a memory leak in your code. Check also column timers, it is not recommended to have here a leak. This can/will crash your server after a while.1 point
-
--ACCEPTED-- Hello Dear.Thanks for the request The server information was sent to your email / private message --------- ARTAGAMEING COMPANY --------- --ACCEPTED-- Hello Dear.Thanks for the request The server information was sent to your email / private message --------- ARTAGAMEING COMPANY --------- --ACCEPTED-- Hello Dear.Thanks for the request The server information was sent to your email / private message --------- ARTAGAMEING COMPANY ---------1 point
-
I am not a professional at hardware performance, so the information below might not be 100% correct. You have per CPU core an amount of processing power available. If you have a duo core then your pc have 2 cores. And for a quad-core you have 4 of those. (virtual cores excluded) Your system will assign application processes to those cores. (MTA is an application) MTA can only use one of those cores. So that is your limit. If you have a lot of cores it doesn't usually mean you have more performance in MTA. But it can it can relieve pressure by being able to keep other applications at different cores. If my interpretation is correct, then 100% is the available amount of (1 CPU core) power assigned for your resources. This is most likely not 100% of this single CPU core. yes I know, it is complicated stuff. Crossing that value should result in high frame dropping. Please correct me if I am wrong.1 point
-
Sim, vai precisar da função de conta pra salvar quando o servidor desligar ou quando o resource for parado. Você pode optar só pelo addAccount + setAccountData se preferir.1 point
-
I don't know your language, but I can understand your problem. Here you have a script of mine that could help: GOOGLE TRANSLATOR Não conheço sua língua, mas posso entender seu problema. Aqui você tem um script meu que poderia ajudar: https://community.multitheftauto.com/index.php?p=resources&s=details&id=158541 point
-
Solução rápida: Crie uma tabela Ao entrar na área verificar se o carro está blindado, adiciona argumento na tabela Ao sair verifica o argumento que está na tabela Execução: dataVehicle = {} -- A tabela citada. local hillArea = createColRectangle(-2171.0678710938, 678.17950439453, 15, 15) local hillRadar = createRadarArea(-2183.5678710938, 705.67950439453, 40, -40, 0, 255, 0, 175) function hill_Enter(thePlayer, matchingDimension) if (getElementType(thePlayer) == "player") then -- Verifica se o elemento que "entrou" é um player. local gVeh = getPedOccupiedVehicle(thePlayer) -- Pega o veículo que o player está. if gVeh then -- Verifica se o player está em um veículo. if isVehicleDamageProof(gVeh) then -- Verifica se o veículo já está blindado. dataVehicle[gVeh] = true -- Se o veículo já estiver blindado ele seta um argumento na tabela. else setVehicleDamageProof(gVeh, true) -- Se o veículo não estiver blindado ele blinda. end end end end addEventHandler("onColShapeHit", hillArea, hill_Enter) function hill_Exit(thePlayer, matchingDimension) if (getElementType(thePlayer) == "player") then -- Verifica se o elemento que "saiu" é um player. local gVeh = getPedOccupiedVehicle(thePlayer) -- Pega o veículo que o player está. if gVeh then -- Verifica se o player está em um veículo. if dataVehicle[gVeh] then -- Verifica se quando o veículo entrou na área já estava blindado. dataVehicle[gVeh] = nil -- Se já estava blindado ele deleta o argumento do veículo da tabela e não tira a blindagem. else setVehicleDamageProof(gVeh, false) -- Se quando entrou não estava blindado então ele tira a blindagem quando sai. end end end end addEventHandler("onColShapeLeave", hillArea, hill_Exit) EDIT: Não testei. @Lord Henry @DNL291 se eu falei besteira ou fiz algo viajado me corrigem pf1 point
-
Você tá salvando a profissão na conta e usando getElementData no client, sendo que element-data é um valor armazenado diretamente para um elemento. Use: setElementData( source, "Profissão", "Mecânico" ) no lado server.1 point
-
الاصدار الرابع , حاولت كثير اني اخليه يتصل عن طريقة اللعبة لكن للاسف كل المحاولات باتت بالفشل ips السلام عليكم , معي منتدى وكان فيه مواضيع هنا بالمنتدى للنفس السكربت المستخدم ولكن لاصدارت قديمة اتمنى من لدية الخبرة الكافية مساعدتي في كيفية ان نقوم بالاتصال بالمنتدى واللعبه رجاء عدم سؤالي على الاكواد المستعملة , لانها اكواد خاصة وحساسة قليلا , من لدية الخبرة الكافية يساعدني هنا او في الرسائل الخاصة او عن طريق الديسكورد حسابي بالديسكور : @SuperX#0660 @N3xT1 point
-
يا مرحبا , تشرفت بالإنضمام لمجتمع العرب و أتمنى أن أفيد و أستفيد معكم1 point
-
1 point
-
التشهير والاتهامات مكانها ليس بالمنتدى, اي رد خارج عن سياق الموضوع بعد ذلك سوف يؤدي الى عقابات قاسية1 point
-
طلب الانضمام للمصميين مفتوح :Cوين المصممين المحترفين1 point
-
الوظيفتين سهله مب صعبه ركز معي شوف المثال ذا وقول لي اذا مو فاهمه؟ tic = getTickCount () -- الوقت اللي اشتغل فيه نظامك على السيرفر, طبعاً بيجيب رقم ثابت مايتحدث addCommandHandler ( 'tics', function() newtic = getTickCount() -- هنا نجيب الوقت الجديد مع التحديث local seconds = math.floor ( ( newtic - tic ) / 1000 ) --[[ - math.floor عشان نقرب الرقم لأقرب عدد عشري - newtic - tic ننقص الوقت الاول من الثاني كذا بيطلع لنا الوقت بالمليسيكوند - ( newtic - tic ) / 1000 نقسم الوقت اللي نقصناه على الف عشان نجيب الثواني ]] local minutes = math.floor ( ( newtic - tic ) / 60000 ) -- : طريقة التحويل من مليسيكوند الى ثانيه او دقيقه او ساعه نقسم على -- to sec : / 1000 -- to min : / 60000 -- to hour : / 3600000 local hour = math.floor ( ( newtic - tic ) / 3600000 ) outputChatBox ( seconds .. ' Second(s) > '.. minutes .. ' minuet(s) > '.. hour .. ' Hour(s).' ) end) interpolateBetween وذا مثال ثاني عن الوظيفه ذي تقدر تسوي منها تأثيرات على اي شي تبيه ماركر, كلام, نافذه واشياء كثير... ^ 3D+2D يعني اللي نفهمه اننا نقدر نستخدمها شوف هالمثال, window = guiCreateWindow ( 300, 260, 240, 290, 'Test', false ) guiSetVisible ( window, false ) start = getTickCount () -- نجيب الوقت اللي اشتغل فيه نظامك داخل السيرفر end_ = getTickCount () + 3500 -- نسوي وقت انتهاء من خلال تزويد مليسيكوند على وقت البدأ draw = function ( ) elapsedTime = getTickCount () - start -- ننقص الوقت الحالي من وقت التشغيل عشان نجيب الوقت اللي انقضى بينهم duration = end_ - start -- نجيب المدة مابين البدء والإنتهاء progress = elapsedTime / duration -- نقسمهم على بعض outputChatBox ( progress ) -- راح تلاحظ الرقم يبدأ من صفر ويزيد لين يوصل 1 local width, height = interpolateBetween ( 0, 0, 0, 240, 290, 0, progress, "InQuad" ) -- ^ x,y,z اول ثلاث ارقومنتات هي حق البداية, يعني بداية التأثير -- اذا كنت ما تحتاجه وتحطه صفر z تقدر تستغني عن الاحداثي -- ^ x,y,z الارقومنت الرابع والخامس والسادس هي حق النهاية, يعني نهاية التأثير -- ^ الارقومنت السابع هو حق حركة التأثير ويكون عدد عشري مابين صفر وواحد -- ^ الارقومنت الثامن هو حق طريقة التأثير او الطريقه اللي تشوف فيها التأثير وتلقى انواع التأثيرات بصفحة الويكي -- [url=https://wiki.multitheftauto.com/wiki/Easing]https://wiki.multitheftauto.com/wiki/Easing[/url] --[[ سؤال : ليه حطيت اول ثلاث ارقومنتات صفر؟ عشان انا ابيها تبدأ من صفر وتنتهي عند القيمه اللي انا حطيتها وهي الارقومنت الرابع والخامس والسادس سؤال: ليه الارقومنت الثالث والسادس ما احتاجهم؟ عشان انا مسوي التأثير على لوحة, واللوحه ثنائية الأبعاد سؤال: متى احتاج الارقومنت الثالث والسادس؟ .تحتاجهم اذا تبي تسوي تأثير لشيء ثلاثي الأبعاد مثل اوبجكت ماركر الخ سؤال: ليه استخدمنا العمليات الحسابيه فوق؟ عشان نخلي حركة التأثير تبدأ من اصغر قيمة لأعلى قيمه, اصغر قيمه صفر, أعلى قيمه واحد ]] guiSetVisible ( window, true ) guiSetSize(window, width, height, false) end bindKey ( 'n', 'down', function ( ) if guiGetVisible ( window ) == false then addEventHandler ( 'onClientRender', root, draw ) setTimer ( function() removeEventHandler ( 'onClientRender', root, draw ) end,3000,1 ) -- التايمر تقديري يمكن ما انتهى التأثير زود او نقص التايمر end end) . ذا شرح مختصر, مو متأكد من احداثيات النافذه اللعبه مب عندي حطيتها من راسي,اذا مافهمت شي تفضل اسأل1 point
-
I want to show a little video: Already realized finding the shortest path and drawing it on the radar. Wait a detailed video.1 point