Loading...
18 files liked
10 comments
1 video
1 upload
2 followers
1,620 downloads
  • 3b5316 6281870

    @Success No problem; you and I are both in the same boat pretty much. I wish I could fully replicate the entire FiveM environment while also expanding upon it quite a bit, maybe one day I/we will get there if this picks up and people join the cause, but for now at least this makes it easier to port over FiveM scripts to normal/regular singleplayer and introduces FiveM style game native function calls for us.

    May 02, 2021
  • 3b5316 6281870
  • 3b5316 6281870

    @Rambosmother yes that appears to be a C language and are game native functions; with Lua Plugin, you would call them in a similar way, replacing the "::" with a "." instead for the "legacy" style of game native function calls. For the "GTA.Native.Function.Call" and "GTA.Native.Hash" and whatnot, you will need to sub those out in LuaPlugin as they don't exist in that fashion; the hashes you can search around for like on the FiveM Native Reference and the DEV-C/AB Native Database. For example, searching the FiveM Native Reference for "setblipname" or "SET_BLIP_NAME" explains some info about/regarding it as well as some examples to go along with it (you of course however will not be able to use the FiveM style or copy-paste examples if you are still using the other/older Lua Plugin instead of mine/this)

    Also it's fine as I don't really mind, I left FB several years ago otherwise I'd check it out (they require login for everything)

    April 25, 2021
  • 3b5316 6281870

    @Rambosmother yeah in most of my Discord guilds by default you'll only have access to a handful of read-only channels and will need to "react" in one of those channels to receive a role that will grant you access to more/main channels which are read-write.
    As for me helping, I can answer some questions and provide some guidance, maybe even work on some chunks of code or functions (from time to time/occasionally); for the most part though, as far as I've both designed and tested, every Lua script that was created for or uses the other/older variant of Lua Plugin here will pretty much just work perfectly fine as it should or was intended to (if not work even better), and people have a lot more things that they can take advantage of with my variant (should they choose to use it of course), plus my plans to continue to add more to it based upon some things that I see from others' Lua script releases that utilize Lua Plugin in general.
    And as for the commas, yeah when used in a function they are arguments or parameters that will typically be used to control how the function works; `print()` for example, will print everything you pass to it, separated by commas, so `print("Hello World!")` will print "Hello World!" while `print("Hello", "World", "!")` will print "Hello" then "World" then "!".
    But yeah, I can (and would be willing to) help you learn, though I'm also not the greatest teacher lol.

    April 20, 2021
  • 3b5316 6281870

    Also, create better documentation and examples for this of course.

    April 19, 2021
  • 3b5316 6281870

    @Ilikeeditingpolice01 yeah, most Lua scripts that I see on here are from several years ago, back in 2015 or 2016, not many beyond that; most left the scripting scene altogether or moved to a C language primarily due to the abandonment of the original Lua Plugin project (and having no one pick it up again), and/or due to the introduction of FiveM which proved to be a much better place/experience overall for Lua scripting in GTA. I picked it up because I recently left FiveM (after 3+ years of experience) and started to port some of my scripts over and thought/felt that it could be so much better and would be nice to potentially (be able to) revive Lua scripting in normal GTA and make it into something compelling again, especially since working with C for me is an arm and a leg; really, I just need to get this out there a bit more for it to catch on and grow, and it's not helping that the old/outdated version is the one that shows up by default first before this one, so I might start commenting more in other Lua script mod pages and/or re-release some of the other Lua script mods updated for starters and maybe try to make some videos and do some other things, I'll also be taking in some ideas from other Lua script mods for features to add built in, such as pre-defined functions that can read/write config files and do things in game like draw text.

    April 19, 2021
  • 3b5316 6281870

    @Rambosmother using my version of LuaPlugin you could do something along the lines of the following:
    ```
    local config = {}
    for line in io.lines(Scripts_Path.."configFile.ini") do
    --1: String gsub out certain characters such as "\n" and "\r" (and maybe even spaces) to avoid potential issues
    line = string.gsub(line, "\n", "") line = string.gsub(line, "\r", "")
    --2: String split the contents of the line into "arguments" or "key and value" pairs for your config
    line = string.split(line, 'separation character (like "=" for example)')
    --3: Optionally process things a bit further (mainly the values), converting strings to booleans or just basic checks
    --4: Add/Insert the final results into your config table, config[key] = config[value]
    config[line[1]] = config[line[2]]
    end
    ```
    Thank you for the idea of adding/implementing a built in config file reader into my variant of LuaPlugin @JustSomeAussie , I will likely add something similar to the above into my next release as a global function that you can call from your scripts to read files with a simple and specific layout.

    April 19, 2021
  • 3b5316 6281870

    @Ilikeeditingpolice01 I mean you _can_ `os.exit()` if your objective is to close the game, otherwise if you simply wish to end your script's execution, use the included examples/templates and/or be creative with it; I may be able to provide some help or guidance for whatever it is you're trying to do (assuming it's to stop your script's execution without closing the game).

    April 19, 2021
  • 3b5316 6281870

    If anyone wants a better, more up to date and performant version of this, I've created my own version that you can download from https://www.gta5-mods.com/tools/jm36-lua-plugin-for-script-hook-v-reloaded or https://github.com/JayMontana36/LuaPlugin-GTAV/releases which I will be updating constantly over time with tons of new optimization features implemented; it maintains compatibility with older/existing scripts designed for this version of Lua Plugin too.

    April 12, 2021
  • 3b5316 6281870

    Is there a way that we could convert this to CitizenFX to get it working in FiveM? I'd attempt to do this myself (and probably more than likely fail at doing so) however there's no source code or anything for it.

    June 23, 2019