Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Debug message editor

I'm looking into a script to edit messages during test play. I know how you can make changes to the rxdata. I tested it out by erasing the character database in game. Of course you have to restart rpg maker to see that the character database is gone.
Now I just need to figure out how to target an event and message. Like while test playing if you see a typo you can just make a change to this.event or this.text block.

Are there any scripts like that already?
 
I spoke too soon.
Changing the rxdata for everything else seems to be easy because they're assigned to objects like "$data_actors" that I can change and save with the Rgss built-in save function.
But I don't know what the object name for maps would be. Like $data_map, $data_map001, or something.

I can target and change a message through scripts, I just can't save that change.
 
Sorry, I'm working off a phone, and short on internet time. I got to be quick to post.

Ok, proof of concept. I was able to change an event message via script and save the rxdata.
Next I need to work on an input window that the user can type in while playtesting.
 
At the moment Im using the "change character name" window for inputting new strings. I know there is a script for a keyboard input of that. When I get home I'll change it to that.
The next hurdle is formating the text. Basically each line of text is its own string. So if it goes over the character limit it needs to push to the next line. I'm also not sure how to handle the variables codes. Need to make a smarter text box that won't cutoff text.
 
This is the what I managed over the weekend away from home.
rmxp%20ingame%20text%20editor_zpsfkzd0jyq.jpg

It's limited to 1 line of text until I come up with a system that'll automatically push text to the next line.
It also only works on event page #1. I need to figure out how to identify the current event page to pass as a variable. For now it's hard coded as page 1.

I imagine this feature could save people time while playtesting. Normally, if you spot something you want to change you either have to close the game or keep playing and risk forgetting what you needed to change. And getting to that particular event might mean opening dozens of nested maps or scrolling across a large map - which of these blank graphic events was it in?

Now, I posted this in Game Making Discussion to talk about the possibilities of an in-game editing function.
I mean, it's one thing to edit a dialog box, but maybe it would be more useful if it could bring up a conversation log? I'm not even sure how I would visualize conditional branches. Or if I should just show an in-game version of the event command window.
That would be a lot of work.
 
I remember that the Pokemon Essentials starter kit had a text export function for localisation, which could also be used for spellchecking purposes.
From a quick google search this comes up. It doesn't have the ability to re-import dialogue, but I think it's definitely possible to implement if you're able to edit rxdata files properly.

I think this method would be more efficient in the long run, because it'd be better to export all text and search for the typos in a master document (notice the typo ingame, tab over to notepad, ctrl+f, fix, etc.) than to manually edit it requiring that part of the game to be open. You could also run a spellcheck on the entire dialogue file as well.

EDIT: Out of curiosity, how did you go about editing those rxdata files? I want to have a shot at this import/export idea. I need something to do :|
 
You still have to apply changes to the project file. And a text file won't show you the textbox overflow - people make last minute font changes and don't realize how much it can shift content.
You need to playtest. Imo, it's more time efficient to make changes at the same time.

Of course I always recommend typing your dialog in a work processor for the spellcheck advantage. But it could just be a case of rewording something to sound better. Fixing textbox widows and orphans (single word lines at the end or carried over to the start of another textbox. )
 
coyotecraft":1kwqgyz4 said:
And a text file won't show you the textbox overflow - people make last minute font changes and don't realize how much it can shift content.
I agree, but if you calculate the text widths as part of the text file importing, you can get it to automatically move content to the next line. This is pretty safe, because the editor supports 3 lines, but the textbox actually supports 4, giving you an entire line of error if it's needed.

Assuming only a single font is used, that is.
 
Something i need to test is the "show text" character limit. You have 3 lines for a normal textbox. 4 if you use batch text (but trying to edit it afterwards will just show 3).
But I don't know what happens if I push a string that's larger than what the event command line would normally hold, and save it. How will it appear in the command window when I reopen the project?
Technically each line in the event command list has an associated coded.
There's a code for the first line of "show text". And a different code for following lines of text.
>@show text: code 101
: : code 401
: : code 401
: : code 401
If i'm able to push the overflow onto new lines, I'm pretty sure I need to supply that code for following text.
I also need to make sure, if I create a new line, that I'm not writing over anything. 3 "show text" lines & a tint screen command becomes 4 "show text" lines & no tint screen. But it's an array with an index and everything so I should be able to splice in new lines.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top