Search Scripts - Kizari/Flagrum GitHub Wiki
Sometimes you want to edit part of the game, but don't know where to start. It can really help you find a place to start if you are able to find a relevant keyword or path inside a specific script file. This guide will cover how to search all script files in the game at once for a specific search term.
This guide assumes:
- You have Final Fantasy XV Windows Edition installed
- You have Flagrum installed and your game files indexed
The first step in this process is to export every script in the game to human-readable XML so that they can be easily searched for certain words.
Inside Flagrum's Asset Explorer, make sure you are in Game View and in the data://
folder.
Click the “Export Folder” icon from the top of the folder explorer.
This will bring up the option to export all files of a certain type from the game. The interface looks a little daunting, but the quick presets can be used to ignore the large panel on the right.
- Click the “Scripts” quick preset, as only script files will be needed
- Ensure “Also export from subdirectories recursively” is checked so that scripts from all folders are exported
- Click the “Export” button to continue
Finally, select a folder where you would like to export all the scripts. Somewhere with a short path would be ideal to ensure the paths of scripts nested deep in the game files aren't too long.
For example, you could select a folder like C:\Modding\Scripts
This process could take anywhere from 30 seconds to many minutes depending on your system hardware. Just be patient and don't touch Flagrum again until it is complete.
When it is complete, you will have many folders inside the folder you exported to, and if you check through them, you will find many XML files.
There are many ways to approach this, but for the purpose of this guide, Visual Studio Code will be used.
The reason for this is that Visual Studio Code is free, lightweight, highly extensible, supports localisation, and supports XML and file searching out of the box. It will even show syntax errors in XML files when you edit game scripts, so it can be useful for catching bugs before they end up being put back into the game. You may use whatever tool you like here, but if you would like to use Visual Studio Code, you can find it here:
https://code.visualstudio.com/
First, open Visual Studio Code, then select “Open Folder” from the File menu.
Next, select the folder where you exported the scripts (e.g. C:\Modding\Scripts
).
You should see the following folders in the left panel:
Now to search all the scripts, simply follow the steps below.
- Click the Search tab on the far left
- Enter the text you wish to search for then hit enter
- From the results that appear, you can see which files contain the desired text. Click on any of the lines in the result to open the file at that point
- View the script to see if it gives you a place to start
And that's all there is to it! You can now search every script in the game whenever you like. Whether that's a path (or partial path) to an asset like the example above, a keyword that you think may be interesting to look into, the name of a character, or even a random guess as to a script construct that may or may not exist. Have fun exploring the scripts and finding a starting point for your next mod!