Jump to content

Lpsd

Discord Moderators
  • Content Count

    301
  • Joined

  • Last visited

  • Days Won

    2

Lpsd last won the day on June 9 2019

Lpsd had the most liked content!

Community Reputation

89 Popular

3 Followers

About Lpsd

  • Rank
    Discord Moderator

Details

  • Gang
    EPG
  • Location
    UK

Recent Profile Visitors

2,946 profile views
  1. Lpsd

    Banned by mta

    Temporary bans cannot be appealed. Please wait for your ban to expire and don't repeat your actions (you know what you did).
  2. ConGuard Network/connection helper for MTA:SA This resource provides measures to deal with lagswitch / connection abuse in MTA (commonly seen in Destruction Derby servers, although you can use this resource in any environment/mode you wish). When a player loses connection to the server, the player (and their vehicle, if it exists) will be frozen for all remote players and a "lost connection" icon will be placed above the player. Upon re-connection, the player will be unfrozen and (by default) set back to their original position before they lost connection, to avoid the teleporting
  3. @ilnaz You haven't posted any examples of how you're using dxDrawImage in your script, so it's really hard to advise you. Please post code examples.
  4. You are not providing a callback to your `UPDATE` query - which means dbPoll is not being called on the query handler, resulting in the query not being freed. You should instead use dbExec, instead of dbQuery, for your `UPDATE` query - providing you don't need to do anything once the query has completed. Otherwise, see the wiki page for dbQuery on providing a callback function with dbPoll. Regarding your problem with auto increment. You cannot set a text/string type column to auto increment. Auto increment is limited to INT type columns. You should have an additional column (at the s
  5. Try this addEvent("onSettingChange", true) addEventHandler("onSettingChange", localPlayer, function(variable, value) if variable == "draw_distance" then local state = not (value == "Off") draw.setVisible(state, true) end end) function draw.setVisible(visible, notifyDisplay) draw.visible = visible and true or false draw.changeDistance(draw.visible) if notifyDisplay then triggerEvent("notification:create", localPlayer, "Draw distance", "is now "..(draw.visible and "ON" or "OFF")) end end function draw.changeDistance(max) for i,object in pairs(getElementsByType("object"))
  6. Just so you know, the actual max value for engineSetModelLODDistance is 325
  7. Can you explain in more detail what you mean by object vs array? Are you referring to JSON data format? If you're referring to element (object) data storage, versus standard storage in Lua tables, then Lua tables are always going to perform better. However, some more understanding of what you mean / what you're trying to do would help explain it
  8. @salh You are storing the password in plain text. This is NOT recommended in any circumstances! (you are breaking European law) I would advise you to remove this code from your server immediately and replace it with a secure login system. Please see the tutorial topic that I sent above.
  9. No, copying that code would not work because you have 2 undefined functions. Furthermore, as stated, this is a bad way to create a remember me functionality because you appear to be storing the password in plaintext (which is illegal if you're accepting European traffic by the way - and just bad practice in general). Instead, you should be using a token system as explained in the linked tutorial
  10. @salh This code doesn't do anything. You haven't defined the `getUserAndPass` function. Furthermore, you wouldn't be saving the actual password, you'd be using a token based system. @Master_11 Please see this tutorial which includes a "remember me" functionality
  11. The "getPedTargetStart" function will retrieve the starting point of the target range. This target range is probably linked to the camera position (I'm not entirely sure though), which would explain why your camera is "always moving forward" Let's say the target start range is always 1 unit in front of the camera. Your camera position is set to 0. Then you set the camera position to the start range (1), and the start range then subsequently changes to 2. This will happen forever whilst you are zoomed in. You should store the initial target start position, instead of getting it on eac
  12. You want to listen to YouTube audio? You'll need to install these on your server https://github.com/ytdl-org/youtube-dl https://www.ffmpeg.org youtube-dl comes with a tutorial. You need to make a PHP script which is triggered by callRemote to initiate the download
  13. Alternatively, you can create your own file / download manager using PHP. Currently this is the only way.
  14. Lpsd

    xml vs json

    Currently, JSON is better for something like that. You can store that information in a database (which is way more efficient than reading/writing XML files) I would give an example, but there really isn't much to show.
  15. Yeah, your arguments are all messed up. unix_socket should be part of the second argument, the string is also formatted incorrectly. dbConnect("mysql", "dbname="..databaseName..";host="..databaseHost..";unix_socket=/var/run/mysqld/mysqld.sock", databaseUsername, databasePassword, "autoreconnect=1")
×
×
  • Create New...