This guide provides a comprehensive step-by-step approach to setting up the GTA-V environment for experimental purposes. Ensure you follow each step carefully for a successful setup.
- Get your copy of GTA-V from Rockstar. Visit Rockstar's website to download.
- Install Microsoft Visual Studio 2019 or a later version. You can download it from the official Visual Studio website.
- Download Script Hook V from Script Hook V's website. Save it in a folder named
ScriptHookV
.
- Obtain the Script Hook V SDK from the same website. Place it into a folder named
SHVsdk
.
- From the
ScriptHookV/bin
folder, copydinput8.dll
andScriptHookV.dll
. Paste these files into your GTA-V installation folder.
- In Microsoft Visual Studio, execute the command:
git clone https://github.com/Dorbmon/gtavTask.git
- From
SHVsdk
, copy theinc
,lib
, andsamples
folders. Paste them into thesdk
folder of thegtavTask
repository you just cloned.
- Open the solution in Visual Studio and build it. This will generate
ScriptHookVDotNet.asi
,ScriptHookVDotNet2.dll
, andScriptHookVDotNet3.dll
ingtavTask/bin/debug
. Copy these three files and paste them into your GTA-V folder.
- Under
gtavTask/Examples
, create a new script file, e.g.,mission_new_task.cs
.
- Adjust the configuration to match your GTA-V directory. For example, if your GTA-V is located in
D:\Game\GTAV
, modify the config as shown below. This ensures that the newly generated .dll file is copied directly to your game directory after the build process.
<Target Name="PostBuild" AfterTargets="PostBuildEvent">
<Exec Command="xcopy /Y $(SolutionDir)examples\bin\$(Configuration)\scripts\$(ProjectName).dll "D:\Game\GTAV\scripts\rx.3.dll*"" />
</Target>
- Finally, launch GTA-V to test if the script works as expected.
By following these steps, you should have a fully functional GTA-V environment set up for your experiments. Happy coding and gaming!
To test scripts conveniently, we provide a 100% save file, to load this save file:
- Copy the save file provided here to C:\Users\user_name\Documents\Rockstar Games\GTA V\Profiles\random_number
- Restart the game, go to SETTINGS\GAME\LOAD GAME, select the save point.