Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 22/12/16 in all areas

  1. value: The value you wish to store. Set to false to remove the data.
    2 points
  2. When you are a wannabe spiderman.
    1 point
  3. I have a little tip, I use a Toshiba Satellite and it was murder with FPS, instead of installing modified operating systems, check CPU, on windows 7 it is a common problem for low end laptops to have up to 100% CPU usage from "svchost" or "Trusted Installer" you can however stop these, click the services using a lot of memory in task manager (services tab), go to "services...", click exteneded tab and READ DESCRIPTION CAREFULLY. If it sounds like it won't effect your computer and isn't vital (so just looks for updates) then right click it and click disable, you also want to disable aero glass bar, windows is made to check every window at all times making sure they have the bar, so disabling it should (in theory) boost gameplay by a small fraction. And if you're really struggling with FPS you can probably buy parts that are compatible from your manufacturer online, so bigger RAM, better CPU etc.... further more you play on a laptop, you will have lags no doubt, so ensure your laptop gets a good vacum at the fan or if you are taking the case off use compressed air to remove dust, this should keep your laptop cool and reduce lags. P.S. Sorry for taking this off topic, but lag is something I feel strongly about, I have learned to play with it and don't think others should suffer, also congrats on fixing it!!!
    1 point
  4. You are 100% right. It was a tweaked Windows 7 which worked kinda better than the unaltered one, i mean it did perform a lot better on my low-end laptop, which helped even with fps in games such as GTA, but yeah. Could not run MTA using it. I went back to the original one i had and it actually works, but my GTA performance is noticeably worse, which is a bit annoying, but at least it is working now. I will make sure to use the original *.iso images next time, and i think i we have found an issue to that problem and it might be the reason why other people could not fix the same problem. Hopefully this topic helps and brings some new solutions to that network error.
    1 point
  5. كود رائع صراحة يعطييك العافيه
    1 point
  6. I suspect you used a Windows installation ISO/DVD from unreliable source that had third-party specific tweaks applied to TCP/IP and/or registry. This is why you should never recklessly download & install any pirated or OEM Windows, because you can't know what they changed before packaging it. Always confirm if it's unaltered OS. If that wasnt the case, one of the programs you installed later on made changes to TCP/IP. However the .bat file I provided should undo those, so if your Windows installation was altered by a third party, those set values are the new defaults and the .bat file will just reset all TCP/IP and network stack to default. So that's maybe why the .bat file didnt work and that program did, because the program sets something completely different from what the thirdparty changed (something more close to the original tcp/ip configuration or atleast missing corruptions your disk's OS installation had) Let that be a lesson: always use official Windows installation media/ISO/DVD and be sure of its integrity (if you know the source was reliable one of the apps later installed is at fault for overriding, but many times such an installation DVD becomes your standard disk to install while it brings problems so in that case I recommend you to throw the disk away)
    1 point
  7. 1. This board is for suggestions, you should have posted in the support board. 2. How much RAM does it say is available? 3. As long as the answer to question 2 is above 500 MB then definitely yes, unless you had some resources that consume a lot of RAM which you can see how much they consume in performancebrowser.
    1 point
  8. resource-cache folder is only for client side files. Without this seperate folder, MTA would be ruined because anyone could download any single file from the resources folder if they knew the name of the file, such as server side scripts, sqlite files, etc. Also what loki2143 said, if a client side file was edited and not immediately restarted, players who then joined would be downloading and running a different script to other players.
    1 point
  9. ليه مسوي زرين إضافة, الأفضل زر واحد للإضافة
    1 point
  10. شفت الصوره, أكوادك مكررة كيف تبيني أعرف الكود اللي فيه الخطأ ؟
    1 point
  11. Depends on the operating system, your gamemode and the other services that are running on the VPS. It might be enough, if you: use a lightweight Linux distribution (Debian should be fine for the most part, but you could try running MTA on something like Alpine Linux) have a gamemode that doesn't use serverside scripts to a very large extent don't run other services e.g. a webserver, control panel, ... But since most VPS hosters support 1-click upgrading, it's perfectly fine to buy the small server, see what happens and upgrade if necessary.
    1 point
  12. Line 27 : executeSQLQuery( 'INSERT INTO aSokingX22DXD (xRow) VALUES ( ? )' , aTextX ) xRow = عمود غير معرف لديك في السكل تيبل بدلها بـ Row @Abu-Solo أو انشئ عمود جديد باسمة
    1 point
  13. I'm not sure also but guessing for safety measures? This is how i think the cache "works". Lets say its downloads directly from the resource folder, if a resource was to be modified and new players join they will download the newest version of the resource while the other players who were there before the resource was edited will still have that version. If someone were to find a way to edit scripts on a server without permission he wouldn't need to restart the script for the changed to happen, then as new players join he can do whatever he wants to the server. So i think the resource-cache are for resources that are ready to be downloaded by clients. Just my theory lol.
    1 point
  14. @Misha_Konsta, а они и добавили, в шапке группы: Perl,PHP,ASP,ASP NET,NodeJS,Lua,Python.Ruby,Pawn,Java,Squirrel,сисадмины вин и лин(отдельно), веб-дизайнер, "кинооператор, знающий все популярные программы для монтажа видео и умеющий грамотно разговаривать. ", модератор, журналист. А в статусе админа спонсор ещё вакантен. В общем я думаю, если бы инвайт им кто на хабр дал, уже бы пол рунета работало на них.
    1 point
  15. @ShadowHumannn, наоборот, если ты хочешь Lua не для МТА, то возможно тебе понадобиться что-то ещё. Для серверов МТА, может понадобиться ещё работа с шейдерами. И если ты захочешь как-то поучавствовать в разработке МТА, то С/С++. Если же тебе хочется C# в МТА, то тебе все равно понадобится все то что написал раньше. Но если целиться только на МТА, то можно даже не прикасаться к чему-то ещё, пока не будет опыта на Lua.
    1 point
  16. @ShadowHumannn, есть и просто без нетворка, и длительность зависит от мощности сервера и нагруженности другими вещами. Конкретно с отдельными точками, уже немало серверов, и даже публично наверно можно найти это решение. Такое решение также будет иметь недостатки. Но делиться вариантами нормального решения, я конечно же не буду. Стандартная "система" релута, в целом обладает очень существенными недостатками. Ну а переписать под таймеры на каждую точку, как это сделали многие, в принципе рутинно даже.
    1 point
  17. ¿Se supone que "conteo" son los kills del gang clanwd? setElementData(root, "team1", 0) addEventHandler("onPlayerWasted", root, function(_, killer, _, _) if (killer) then if (getElementType(killer) == "player") then if getElementData(killer, "gang") == "clanwd" then local conteo = getElementData(root,"team1") setElementData(root,"team1",getElementData(root,"team1") + 1) outputChatBox("[server] clanwd tiene" ..conteo.. " Kills",root,255,255,0,true) end end end end) Eso suma las kills si estás en el gang "clanwd", no sé si es lo que quieras.
    1 point
  18. السلام عليكم ورحمة الله وبركاته * Server Side removeAccountData وظيفة مسح الداتا من الحساب ------------------------------------------------------------------ Syntax bool removeAccountData ( element theElement, string key ) Required Arguments theElement: The element you wish to remove the data from. key: The key string you wish to remove. Code :- function removeAccountData ( playerAccount, data ) if ( playerAccount ~= "" ) and ( data ~= "" ) then if getAccount ( playerAccount ) then local dataName = getAccountData(playerAccount, data) if ( dataName ~= nil ) or ( dataName ~= "" ) then setAccountData(playerAccount, data, false) end end end end Example :- function reCheck( ) for i,player in ipairs ( getElementsByType('player') ) do if ( not isGuestAccount ( getPlayerAccount ( player ) ) ) then local acc = getPlayerAccount(player) if ( isObjectInACLGroup('user.'..getAccountName(getPlayerAccount(player)),aclGetGroup('Admin') ) ) then setAccountData ( acc , 'Admin' , true ) else removeAccountData(acc, 'Admin') end end end addEventHandler('onResourceStart',resourceRoot,reCheck) addEventHandler('onPlayerLogin',root,reCheck) addEventHandler('onPlayerLogout',root,reCheck) Thx To @N3xT والسلام خير الختام
    1 point
  19. فيه فكرة حلوة بدل ماتيشل الاكاونت داتا سو في الوظيفة اللي تبغى تشيل منه الداتا اعطه داتا ثانية على الاكاونت تفرض اسمها abu وسو في الوظيفة الأولى تحقق اذا عنده الداتا abu مايكمل الوظيفة أتمنى فهمتني ذذ
    1 point
  20. But you can store stringified JSON if really needed.
    1 point
  21. Достаточно одной Lua. C# тут не к месту.
    1 point
  22. oh yeah source is the marker, my bad
    1 point
  23. This is not an link you should have or a page you could use (backend systems not for public use), because it's done at the discretion of MTA team and only for highly popular servers with top player counts that have a risk for servername cloners. It's judged on case by case basis and not requested but offered by MTA team, you got low chance to aquire it. What's your server name? (I doubt it's a topranked MTA server) And what is the source of that URL (how you got it)
    1 point
  24. in dbQuery, you have to put 2 argument, first the connection handler, second is mysql query. Example: conn = dbConnect("blabla") query = dbQuery(conn, "Your MySQL Query.")
    1 point
  25. -- كلينت addEventHandler ( "onClientGUIClick", root, function ( ) if source == GUIEditor.button[1] then triggerServerEvent ( "onSave", localPlayer, guiGetText ( GUIEditor.edit[1] ) ) guiSetText ( GUIEditor.label[1], guiGetText ( GUIEditor.edit[1] ) ) end end ) addEvent( "addText", true ) addEventHandler ( "addText", root, function ( Text ) guiSetText ( GUIEditor.label[1], Text ) end ) -- سيرفر addEvent ( "onSave", true ) addEventHandler ( "onSave", root, function ( Text ) exports [ "sqldata" ] : setPlayerSerialData ( source , "SaveText" , Text ) end ) addEventHandler ( "onPlayerJoin", root, function ( ) local Text = exports [ "sqldata" ] : getPlayerSerialData ( source , "SaveText" ) if Text then triggerClientEvent ( source, "addText", source, Text ) end end )
    1 point
  26. Good News! I have fixed it! Try right click on the shortcut and then go to properties, then go to compatibility, finally run this program in compatibility mode for windows XP (Service Pack 3) ... if that does not work then go to reg edit (quick way is open task manager> Click "services..." or right click computer in the start menu and then manage) and ensure the following services are started. Application Information Applicaton Layer Gateway Service TCP/IP NetBIOS Helper If this doesn't work then uninstall MTA, making sure you do full uninstall and install it again, if all else fails you may need to go back to the store you bought your PC from and explain the issue. Hope this helps. NOTE: THIS IS FOR WINDOWS 7 ULTIMATE (32 BIT) OTHER VERSIONS OF WINDOWS WILL VARY WITH COMPATIBILITY MODE etc.
    1 point
  27. local player = guiGridListGetItemText(table.gridlist[1], guiGridListGetSelectedItem(table.gridlist[1]), 1); if player and getPlayerFromName(player) then -- so let's say you already got the "targetPlayer" in variable "player" setElementData(player, "lastChatMessage", { getPlayerName(localPlayer), "The New Message To Send" }) end -- then... local playerMessages = {} addEventHandler ( "onClientElementDataChange", getRootElement(), function ( dataName ) if getElementType ( source ) == "player" and dataName == "lastChatMessage" and source == localPlayer then local newValue = getElementData(localPlayer, "lastChatMessage") if not newValue then return end if playerMessages[newValue[1]] then table.insert(playerMessages[newValue[1]], newValue[2]) else playerMessages[newValue[1]] = { newValue[2] } end setElementData(localPlayer, "lastChatMessage", false) end end ) --[[ so this way the table should look like this: local playerMessages = { ["playerName1"] = { "Hello", "How's things?"}, ["playerName2"] = { "Hi", "Not so bad.."} } and you can just easily loop through the table to find a specific player's message by name ]]
    1 point
  28. Did you even install the Wifi adapter driver I linked you to earlier? https://www.atheros-drivers.com/qualcomm-atheros-download-drivers-nr-306-with-code-4613.html But that most likely wont solve it because its a clear OS issue now, do you know if you set any device-specific settings for your local PC in the router configuration? For example: DHCP binding, forwarding, etc. Also I noticed it wasnt asked yet; please list all Firewall and Antivirus/security software you got installed. Disable them all completely before trying to connect.
    1 point
  29. I haven't asked you to use the DISM command at all after noticing you had to use that Windows update package, it replaces DISM and does the same as dism for win8/10. You misunderstood, just run the sfc /scannow command after that update finished installing (and it did as you said).. again, don't forget to restart your PC inbetween the update finishing and sfc /scannow, so only thing left on your mind now is sfc /scannow, after which you can run the .bat file again.
    1 point
  30. You forgot the spaces between each / command EDIT: Actually for Windows 7 use this tool as replacement for DISM: https://www.microsoft.com/en-us/download/details.aspx?id=20858 I advise you due to its size to first try run sfc /scannow step i detailed in earlier post and if that gives ''windows resource protection found corrupt files but was unable to fix some of them'', only then run the Readiness tool download. It it doesnt give that message but only that errors were fixed or no integrity violations were found, consider the step taken and try the netsh .bat file again.
    1 point
  31. That already means something in your Windows networking stack is corrupt (you were right its an OS problem) as the netsh commands should always work on an integer Windows installation, that helper DLL is part of networking stack. So this is likely the root problem, you can first try recovering from that networking stack damage by; Open commandprompt (Run as administrator), first enter ''dism /online /cleanup-image /restorehealth'' and let it complete, then restart Windows. (the DISM command will ensure the next step - sfc /scannow - will recover everything to its max and not say ''windows resource protection found corrupt files but was unable to fix some of them'' - it might take a while though) Once restarted, open commandprompt again and now enter this: ''sfc /scannow'' After that finished, restart your PC again, and THEN take and run the netfix.bat file I gave you. If the DISM and SFC commands don't work properly, ensure you got both the Windows Firewall and Windows Update services enabled and in started state (check through Run > services.msc) EDIT: Despite the helper DLL error the commands on netsh (bat file) were executed with ''Ok'' as result (most likely means nothing if helper DLL error is present - false hope - but ok..), try restarting your PC first to see whether it did anything. Restart your PC anyways before taking any other steps such as SFC or DISM commands, as they might fail otherwise
    1 point
  32. Take these steps: 1: download this file: https://www.dropbox.com/s/8kyfbievryrmyz1/netfix.bat?dl=1 Rightclick it and select ''Run as Administrator'' (this will revise your Windows network stack and hopefully remove corruptions in networking) Restart your PC after this and try if MTA works fine now. 2: Go to start > run > services.msc, navigate to ''Windows Firewall'', rightclick it, select Disabled state and ''stop'' the service (undo it if problem doesnt end up fixed, its a probe) EDIT: after that, download this Wifi driver, https://www.atheros-drivers.com/qualcomm-atheros-download-drivers-nr-306-with-code-4613.html and extract the .zip file, then open Device manager and rightclick you Wifi adapter under ''Network adapters'', and click ''Update drivers'' in the dropdown menu of that device. Now walk through the wizard to install drivers off a custom location, (''search on my PC'') and then ''Choose from a list'' then point it to the folder you extracted the driver files to, and force driver update on the first result from the list it displays afterwards. (If it says it cannot verify, just choose to install regardless, if it displays nothing in the list, just untick the box ''show only compatible drivers'' and scan the given folder again
    1 point
  33. It will take quite a bit of work. You'll need an ARM version of premake5, and then 10,000 hours fixing all the compile errors. And after all that, you'll need an ARM version of the net module from us (which we don't currently have).
    1 point
  34. Hello guys, I am creating this thread so that members of the community can share useful tips and tricks they have learned during their time of scripting. I don't know if it's already created before or not but i think it's something useful to help beginners to learn Lua language plus i think Tutorials board is the best place. to begin with, here a few tricks I have picked up: You can do this: local variable = "no" if Condition then variable = "yes" end But it's faster if you do it like this: local variable = (Condition and "yes") or "no" Reversing bools: bool = true -- if you want to reverse it you can either do bool = false -- or bool = not bool When assigning a variable you don't want to be nil you could do this: local variable = otherVariable if variable == nil then variable = 10 end But it can be done a lot faster: local variable = otherVariable or 10 Commenting multiple lines : -- line1 -- line2 -- line3 You can just use this: --[[line1 line2 lin3]] There are a lot more cool things you can do with lua, if you have something you wish to share feel free to post below.
    1 point
×
×
  • Create New...