Jump to content

LonelyRoad

Members
  • Posts

    116
  • Joined

  • Last visited

Everything posted by LonelyRoad

  1. Depending on how indepth you want to be with your gamemode (do you want a website User Control Panel for example?) then you almost certainly want to use MySQL CE Server. SQLite and MySQL do not always use the same execution strings, but most of the time it can be the same. MySQL CE Server is free anyway, and depending on where you host it you may not need to pay for anything at all, for servers like MTA you probably want your own dedi of some form to administrate it all anyways.
  2. You need to learn LUA to make scripts for MTA, then learn the SQL functions to communicate with any kind of database. SQLite is easier to use but it has less functionality and makes it more difficult to use the data externally, for places such as on a website. You probably want to use MySQL, with the MySQL CE server (free version of the MySQL Server, available HERE). You will need a proper dedicated server to run any of this efficiently so good luck on the cost of that. P.s: MySQL Workbench is an admin tool for a MySQL Server.
  3. function validateEmail(email) local email = tostring(email) if (email:match("[A-Za-z0-9%.%%%+%-]+@[A-Za-z0-9%.%%%+%-]+%.%w%w%w?%w?")) then return true else return false end end This parses emails a lot better from my experience, and should resolve your issue.
  4. Now my issue just got weirder. I have a smaller resolution than the native one on my screen and I get a huge black border around the outside of the game window.
  5. I have today hooked up a second monitor to my computer and I now seem to get a problem where even though I have chose my native resolution on MTA when that 'Select Device' panel comes up, the game uses a smaller resolution but still appears as if it was full screen (no windowed mode features). EDIT: It should be noted however if I load the single player game I do not get any such issue.
  6. LonelyRoad

    Help!

    Ignore the error message, nothing is broken and there is nothing to worry about. I would guess however that yes, it will be fixed in a future update...but it may also require changes by the Game-Monitor team.
  7. LonelyRoad

    missionTimer

    What file and line?
  8. No longer an issue, seems to have fixed itself. Believe it may have been a packet flood attack, but we have Anti-DDoS now.
  9. The command, as seen here. Is it possible for me to force it to use the legacy args not the updated ones? I am using 1.3.3 server on Windows - if that information is relevant. (Is it as simple as not specifying enough arguments for it to get rgb for both colors?)
  10. Scratch the part about 30 players, that would not appear to be an accurate thing to base it on. It's intermittent and plain weird. On a side note, no errors are produced in the console - other than the "Player XX has disconnected [Timed Out]"
  11. Pretty much as the title says. IT started happening yesterday and we've not changed anything as far as I am aware that may cause the problem, but basically the server will reach about 30 players and then everyone Times Out and nobody can reconnect, imagine as if the MTA Server has lost its internet connection. The Remote Desktop still functions perfectly, but it might be worth noting that the Download on the bandwidth monitor spikes to at least 4Mbps down, but literally only for a couple seconds. As I said already, it only started yesterday afternoon and the very same server has been able to support 80+ players being online without any disconnections.
  12. I am trying to make a login system, but when the player first connects to the server and downloads all the resources - it seems to be the case that either this doesn't work at all, or goes too quickly and nothing happens on the client: function showLogin() triggerClientEvent(source, "showLoginWindow", source) end addEventHandler("onPlayerJoin", getRootElement(), showLogin) Here is the client of the event: showLoginWindow function playerConnect() showPlayerHudComponent("all", false) setAmbientSoundEnabled( "gunfire", false ) clearChat() setElementDimension(getLocalPlayer(), 9999) setElementInterior(getLocalPlayer(), 0) setCameraMatrix( 2149.0729980469, 1901.8781738281, 15, 1381.1181640625, 1904.9548339844, 200) fadeCamera(true) connect_openLoginWindow() end addEvent("showLoginWindow", true) addEventHandler("showLoginWindow", getRootElement(), playerConnect) And connect_openLoginWindow() is supposed to be the thing that actually draws the login GUI - I am not sure at what step it fails, but if the player reconnects everything functions as it should do (ie. all the functions get called and the GUI shows up as anticipated). Any ideas please?
  13. The :match() part I found on the Lua Docs, I was hoping a copy+paste with a little bit of tweaking would work.
  14. For what reason would the 'No Match!' output twice here now? If the email matches, it returns true and does the outputchatbox once, but if it's no match it does the outputchatbox twice (and presumably returns false twice, too).
  15. I am trying to validate an email address passed to a function (as shown in the code below) but no matter what I give the function it always returns no match (and the outputchatbox runs twice for some reason). function validateEmail(email) local email = tostring(email) if (email:match("[A-Za-z0-9%.%%%+%-]+@[A-Za-z0-9%.%%%+%-]+%.%w%w%w?%w?")) then outputChatBox("Match!") return true else outputChatBox("No Match!") return false end end addCommandHandler("testing", validateEmail)
  16. I've seen this done in a couple other servers, and I was wondering if anyone knew of how to do it or if it was a community resource?
  17. Neither of these functions are of any relevance, use Ctrl+F in all the files to search for: bindKey("p
  18. LonelyRoad

    Help?

    If a file is on your computer, it is inherently insecure, no matter what someone does to it. Moral of the story: Yes, it is possible. Outcome here? People won't help you.
  19. What it actually does is makes sure the script is never stopped, I don't believe you can use 'stop' on a resource that is protected. (Isn't that somewhere on the wiki, meta.xml page even?)
  20. Oh wait, ofcourse! It was clientside, my bad - I'm tired, completely oblivious to it (*waves arms and facedesks*)... Yeah, try using something like: local myATM = createObject(BLABLABLA)
  21. The first problem you have is on line 16, the outputChatBox() function, you don't tell it who to output to. "NOTE: When using optional arguments, you must supply all arguments before the one you wish to use. For more information on optional arguments..." EDIT: Second argument is who to output to, in your case it'd be: outputChatBox("DEBUGMSG::You clicked the atm.", localPlayer, 0,0,255) Considering the fact this is the only way you test if they click it, that may be what has deceived you. Furthermore, consider instead using the function: https://wiki.multitheftauto.com/wiki/CreateObject Instead of the map editor, the trouble with what you do now is all objects with name 'LS_Bank_ATM' will do this (probably not a big one, but all the same it's useful to have more granular control. This will allow you to permit certain functions on certain ATMs.
  22. For the benefit of players that want to bind this command, I want to accept it if it is typed in the console or done through a keybind. I don't however, want to accept if they type the /[COMMAND] in the chatbox. How?
  23. Comment/Remove the function that checks if the vehicle is underwater - boom, fixed.
  24. I'm quite...familiar with maps like this, I was a very good regular on the GMC servers, I like this map quite a lot - good work! PS: What song is that in the video? (I'm too lazy to search )
×
×
  • Create New...