Dialogue Extractor and injector by Hoboayoyo

hoboayoyo

Regular
Regular
Joined
Oct 29, 2016
Messages
103
Reaction score
21
Primarily Uses
***Make sure you do not use the original map files or you can risk losing data. Run this script in a different location that's not your game folder.***

Have you ever wanted to extract all the dialogue from your game to give it a once over?
Did you ever want to bulk edit existing dialogue in your project?
Well now you can, thanks to a handy program I whipped up while working on my game Banbard(check it out on steam).
This is not a plugin for MV but rather a stand alone program in C++ (I couldn't find a good topic to post this on.)
Library Required: JsonCpp
The program is pretty straight forward where you can select your file(s) and then tell it to either generate a txt file, or have the dialogue from a txt file overwrite json file. This works by looking at the json file and pulling anything that has the parameter code of 401.
Limitation: when editing multiple files at a time you cannot skip files(i.e do map files 1-5 and 7-10 at the same time).
You also must not edit the total number of lines of the text file since the script is expecting the total amount of dialogue to match up. (i.e if the json file has 100 lines of a dialogue and the txt file has 101 lines the script will generate an error.).
Finally some errors might cause your json or txt file to save as empty. But as long as you don't divert from instructions you'll be fine.

Instructions.
1. Set up your folder that has the Dialogue Extractor and injector script with the jsonCPP library as stated above.
2. Copy and paste any map files you want to use for this script into the same folder.
3. Run the file, select the starting and ending numbers of the files you want to work with (ascending order). The numbers you give must be three digits long (nothing over 999 maps and set any digits lower than 100 with the appropriate 0's. Such as 005 or 050).
4. When asked if you want to generate a text file or inject txt file dialogue into a json enter '1'.
5. Wait for the program to finish and check that your txt file was generated correctly.
6. Make any dialogue changes needed without changing the total amount of lines in the txt file.
7. Once you are ready run the program again, and when it asks you if you want to generate a text file or inject txt file dialogue into a json enter '2' this time.
8. Done! Your json file has been updated with new Dialogue.
9. To test this out BACKUP YOUR ORIGINAL JSON MAPS and insert your new one's into your game folder and run your project.

Download
 

Attachments

  • JsonSkitReader.zip
    3.4 KB · Views: 10
Last edited:

Ms Littlefish

Time Traveling Victorian Vampire
Global Mod
Joined
Jan 15, 2014
Messages
8,902
Reaction score
14,204
First Language
English
Primarily Uses
RMMV
I have moved this thread to Useful Development Tools.
 

kyonides

Reforged is laughable
Regular
Joined
Nov 17, 2019
Messages
1,894
Reaction score
967
First Language
English
Primarily Uses
RMXP
The idea is fine, but the execution is lacking. The very same warning you included in your post should deter people from using it till it can be used even without copies of map files. Json files are not supposed to be terribly hard to read and write on the fly if you have enough experience handling them. This tool is only supposed to process primitives the whole time so it's weird to read here it's still that unreliable as of yet.
 

hoboayoyo

Regular
Regular
Joined
Oct 29, 2016
Messages
103
Reaction score
21
Primarily Uses
The idea is fine, but the execution is lacking. The very same warning you included in your post should deter people from using it till it can be used even without copies of map files. Json files are not supposed to be terribly hard to read and write on the fly if you have enough experience handling them. This tool is only supposed to process primitives the whole time so it's weird to read here it's still that unreliable as of yet.
Have you tried using it yet?
I've used this on over 100 maps and have had no issues yet. However, I'm the only person that has used this so far. I don't know if there is something you could put in your text file that would mess up the json map file. That's why that warning is there, I'm being cautious because I wouldn't want to delete someone's master map file by accident. Backing up your files while running a program that can alter it is just good practice.
 

Latest Threads

Latest Posts

Latest Profile Posts

1701524304115.png
Part of growing up is finding out that love hurts.
"I signed up for this heartbreak."
Oh man. Updating my PC backup because I'd like to start 2024 with a reformat. At some point in time I turned into a "folders in my folders" type of girl. :kaoslp:
Lesson of the day: Trying to arrive in time is sometimes more difficult than any boss fight.
Day #2: Today we have some teddybears... and a brave dad to fend them off!1701517253009.png
Driving to Florida today to spend a week like we did last year. Looks like it will just be me and the Mrs. But she sleeps a lot longer than me so I will still have time to work on my Game Jam project. :stickytongue:

Forum statistics

Threads
136,681
Messages
1,268,710
Members
180,388
Latest member
vddvdyv
Top