Jump to content

[V|REL|HOOK] LUA Plugin for Script Hook V


Recommended Posts

Current Version: 9,10.0

Description:

Write any LUA Script for GTA5

you are able to use all Natives from NativeDB

 

 

 

Changelog

 

Requirements:

Installation Instructions:

  1. Extract LUA.zip
  2. Move the LUA.asi in the GTA5 Folder where the ScriptHookV.dll is located
  3. Place the scripts folder in the GTA 5 Folder
  4. Add any Scripts you want into the scripts/addins folder
  5. Run GTA 5 over Steam or Rockstar Launcher

Extra Note:

I can convert your Lua Scripts to fully Independent .asi files for safety/speed just write me a PM

Example:

local basemodule = {}basemodule.GUI = Libs["GUI"]function basemodule.unload()endfunction basemodule.giveWeapon(weapon)    WEAPON.GIVE_DELAYED_WEAPON_TO_PED(PLAYER.PLAYER_PED_ID(), GAMEPLAY.GET_HASH_KEY(weapon), 1000, true)endfunction basemodule.init()    bodyguard.GUI.addButton("Give Me RAILGUN",basemodule.giveWeapon,"WEAPON_RAILGUN",0,0.2,0.05,0.05)endfunction basemodule.tick()    basemodule.GUI.tick()endreturn basemodule 

Download:

LUA Plugin Download

 

Found a Bug?

Report them here: https://github.com/gallexme/LuaPlugin-GTAV/issues

 

Thanks for your Love and Support: martysama0134 (i owe you something)

Edited by headscript
Link to comment
https://gtaforums.com/topic/789139-vrelhook-lua-plugin-for-script-hook-v/
Share on other sites

 

dosen't work it crashes..

 

He did mention it could crash since it's very alpha or new, but this is good news to the modding community, the way I see this is that it's taking a new step towards amazing mods.

 

I know but it doesn't work...

Updated works now :)

have you updated the download links files as i have just launched the game and it still seams to crash the game

 

Thanks

 

EDIT : Nevermind works bro just reloaded game

Edited by burnsyboo

 

Updated works now :)

have you updated the download links files as i have just launched the game and it still seams to crash the game

 

Thanks

 

make sure u got vc 2013 redist x64 installed

https://www.microsoft.com/de-de/download/details.aspx?id=40784

 

 

Updated works now :)

have you updated the download links files as i have just launched the game and it still seams to crash the game

 

Thanks

 

make sure u got vc 2013 redist x64 installed

https://www.microsoft.com/de-de/download/details.aspx?id=40784

 

it is working fine now thank you i just reloaded GTA V a second time. :lol:

Edited by burnsyboo

Hey there, awesome stuff! I'm sort of a noob and I'm just curious where I would find the functions like VEHICLE.SET_VEHICLE_FORWARD_SPEED, etc. Is there a list somewhere or are you loooking through GTA itself?

 

Thanks. :]

 

Edit: Never mind I found it! http://www.dev-c.com/nativedb/

Edited by Swarm96
Marty McFly

Is there an actual native for that? I would've just read the current vehicle speed and multiplied it with some factor. Interesting what's available already :blink:

Edited by Marty McFly

Would it be possible for you to add a Lua console to this mod, so you don't need to restart the game and wait for it to load every time you want to try something new?

dont u see a console when u join a game?

you cant type anything in but if error occurs u see them there and u can reload your own lua files easily with lua builtin functions

 

Would it be possible for you to add a Lua console to this mod, so you don't need to restart the game and wait for it to load every time you want to try something new?

dont u see a console when u join a game?

you cant type anything in but if error occurs u see them there and u can reload your own lua files easily with lua builtin functions

 

How would I do this? Googled around a bit on reloading but nothing explained it well. Could you point me in the right direction? It is a pain to restart GTA :(

 

Why is the ASI file so large ?

3mb is a lot

because of wrapper code from the natives and lua engine itself

 

 

Right, because compiled code is very large.

That's why you should never comment your code, compiled comments take a lot of disk space.

 

 

Why is the ASI file so large ?

3mb is a lot

because of wrapper code from the natives and lua engine itself

 

 

Right, because compiled code is very large.

That's why you should never comment your code, compiled comments take a lot of disk space.

 

its over 150 000 lines of code what do you think -.-

all like

 lua_module(lua_S,"DLC2",0); lua_beginmodule(lua_S,"DLC2"); lua_function(lua_S,"IS_DLC_PRESENT",lua_natives_DLC2_IS_DLC_PRESENT00); lua_function(lua_S,"_0xF2E07819EF1A5289",lua_natives_DLC2__0xF2E07819EF1A528900); lua_function(lua_S,"_0x9489659372A81585",lua_natives_DLC2__0x9489659372A8158500); lua_function(lua_S,"_0xA213B11DFF526300",lua_natives_DLC2__0xA213B11DFF52630000); lua_function(lua_S,"_0x8D30F648014A92B5",lua_natives_DLC2__0x8D30F648014A92B500); lua_function(lua_S,"_0x10D0A8F259E93EC9",lua_natives_DLC2__0x10D0A8F259E93EC900); lua_function(lua_S,"_0x46E2B844905BC5F0",lua_natives_DLC2__0x46E2B844905BC5F000); lua_function(lua_S,"_0xD7C10C4A637992C9",lua_natives_DLC2__0xD7C10C4A637992C900); lua_function(lua_S,"_0x0888C3502DBBEEF5",lua_natives_DLC2__0x0888C3502DBBEEF500); lua_endmodule(lua_S);

and the wrapped function definitions and type conversions and error checking

 

 

 

Why is the ASI file so large ?

3mb is a lot

because of wrapper code from the natives and lua engine itself

 

 

Right, because compiled code is very large.

That's why you should never comment your code, compiled comments take a lot of disk space.

 

its over 150 000 lines of code what do you think -.-

all like

 lua_module(lua_S,"DLC2",0); lua_beginmodule(lua_S,"DLC2"); lua_function(lua_S,"IS_DLC_PRESENT",lua_natives_DLC2_IS_DLC_PRESENT00); lua_function(lua_S,"_0xF2E07819EF1A5289",lua_natives_DLC2__0xF2E07819EF1A528900); lua_function(lua_S,"_0x9489659372A81585",lua_natives_DLC2__0x9489659372A8158500); lua_function(lua_S,"_0xA213B11DFF526300",lua_natives_DLC2__0xA213B11DFF52630000); lua_function(lua_S,"_0x8D30F648014A92B5",lua_natives_DLC2__0x8D30F648014A92B500); lua_function(lua_S,"_0x10D0A8F259E93EC9",lua_natives_DLC2__0x10D0A8F259E93EC900); lua_function(lua_S,"_0x46E2B844905BC5F0",lua_natives_DLC2__0x46E2B844905BC5F000); lua_function(lua_S,"_0xD7C10C4A637992C9",lua_natives_DLC2__0xD7C10C4A637992C900); lua_function(lua_S,"_0x0888C3502DBBEEF5",lua_natives_DLC2__0x0888C3502DBBEEF500); lua_endmodule(lua_S);

and the wrapped function definitions and type conversions and error checking

 

 

You do know that you could just put it all into 1 function and do the checking there, right?

That would decrease file size a lot.

 

 

 

 

Why is the ASI file so large ?

3mb is a lot

because of wrapper code from the natives and lua engine itself

 

 

Right, because compiled code is very large.

That's why you should never comment your code, compiled comments take a lot of disk space.

 

its over 150 000 lines of code what do you think -.-

all like

 lua_module(lua_S,"DLC2",0); lua_beginmodule(lua_S,"DLC2"); lua_function(lua_S,"IS_DLC_PRESENT",lua_natives_DLC2_IS_DLC_PRESENT00); lua_function(lua_S,"_0xF2E07819EF1A5289",lua_natives_DLC2__0xF2E07819EF1A528900); lua_function(lua_S,"_0x9489659372A81585",lua_natives_DLC2__0x9489659372A8158500); lua_function(lua_S,"_0xA213B11DFF526300",lua_natives_DLC2__0xA213B11DFF52630000); lua_function(lua_S,"_0x8D30F648014A92B5",lua_natives_DLC2__0x8D30F648014A92B500); lua_function(lua_S,"_0x10D0A8F259E93EC9",lua_natives_DLC2__0x10D0A8F259E93EC900); lua_function(lua_S,"_0x46E2B844905BC5F0",lua_natives_DLC2__0x46E2B844905BC5F000); lua_function(lua_S,"_0xD7C10C4A637992C9",lua_natives_DLC2__0xD7C10C4A637992C900); lua_function(lua_S,"_0x0888C3502DBBEEF5",lua_natives_DLC2__0x0888C3502DBBEEF500); lua_endmodule(lua_S);

and the wrapped function definitions and type conversions and error checking

 

 

You do know that you could just put it all into 1 function and do the checking there, right?

That would decrease file size a lot.

 

doesnt work in this particular case but if you want to try contact me on skype: fabs1996

 

 

 

Right, because compiled code is very large.

That's why you should never comment your code, compiled comments take a lot of disk space.

 

This is the dumbest thing i've ever heard someone say.

 

 

lol, that was just sarcasm

I was making fun of the large disk space the plugin requires ^^

 

 

 

 

 

 

 

 

 

 

 

 

Why is the ASI file so large ?

3mb is a lot

because of wrapper code from the natives and lua engine itself

 

 

Right, because compiled code is very large.

That's why you should never comment your code, compiled comments take a lot of disk space.

 

its over 150 000 lines of code what do you think -.-

all like

 lua_module(lua_S,"DLC2",0); lua_beginmodule(lua_S,"DLC2"); lua_function(lua_S,"IS_DLC_PRESENT",lua_natives_DLC2_IS_DLC_PRESENT00); lua_function(lua_S,"_0xF2E07819EF1A5289",lua_natives_DLC2__0xF2E07819EF1A528900); lua_function(lua_S,"_0x9489659372A81585",lua_natives_DLC2__0x9489659372A8158500); lua_function(lua_S,"_0xA213B11DFF526300",lua_natives_DLC2__0xA213B11DFF52630000); lua_function(lua_S,"_0x8D30F648014A92B5",lua_natives_DLC2__0x8D30F648014A92B500); lua_function(lua_S,"_0x10D0A8F259E93EC9",lua_natives_DLC2__0x10D0A8F259E93EC900); lua_function(lua_S,"_0x46E2B844905BC5F0",lua_natives_DLC2__0x46E2B844905BC5F000); lua_function(lua_S,"_0xD7C10C4A637992C9",lua_natives_DLC2__0xD7C10C4A637992C900); lua_function(lua_S,"_0x0888C3502DBBEEF5",lua_natives_DLC2__0x0888C3502DBBEEF500); lua_endmodule(lua_S);

 

and the wrapped function definitions and type conversions and error checking

 

 

You do know that you could just put it all into 1 function and do the checking there, right?

That would decrease file size a lot.

 

doesnt work in this particular case but if you want to try contact me on skype: fabs1996

 

 

Why wouldn't it? It takes some work, yes. But it's definetly possible.

For inspiration you could take a look at my repo.

Edited by TJGM

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • 0 User Currently Viewing
    0 members, 0 Anonymous, 0 Guests

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.