nurver9 Posted October 19, 2022 Share Posted October 19, 2022 (edited) Introduction Please do not use this thread to submit requests. They will be ignored. Strings house all of the game's text, from story dialog to UI elements. There are two locations where you can find strings at: PokeMMO\data\strings - this is the directory where the base-game strings are located / loaded from. PokeMMO\dump\strings - create this directory from the in-game Settings menu -> Utilities -> Run both string dump utilities Use the Find in Files function to search these directories for the dialog you are looking for. While editing game files, it's recommended you use a text editor which is capable of highlighting syntax. https://notepad-plus-plus.org/ https://www.sublimetext.com/ What is an XML? It is important that you avoid modifying or replacing any of the existing XML files. Instead, we can define our own that side-load with the chosen client language. Why? Files are modified during official updates and the majority of these changes are not logged in the patch notes. Anything developed on a previous revision more than likely will not be forwards compatible. Use outdated content at your own risk. Formatting and file types Whatever content is at the bottom of the file takes priority over whatever is at the top. That means you can have multiples of the same string in one file, but whatever is last will end up loading into the game. There are two types of strings; regular strings and archive strings. Regular strings contain basic string ids: (found in default directory and in dumps) <string id="0">example</string> To get your documents ready for your translations, create a new XML file in PokeMMO\data\strings titled z_strings_xx_edits, where xx = your language short-code, e.g., "en" or "es". <?xml version="1.0" encoding="UTF-8" standalone="no"?> <strings is_primary="0" lang="default lang shortcode" lang_full="default full language name"> <!-- comment example; ignored by game --> <!-- modified strings go inside this code block --> <!-- use tab to indent text --> </strings> As long as the lang and the lang_full flags match the language which your client is loading, any string you place inside this file will gracefully side-load into the game. This is relevant for both regular and archive strings. Advantages of utilizing this format include: ensures you always have the latest game files on your system not having to define a custom language in-game (causes issues.) not having to maintain your files as the defaults are overwritten during each update the "is_primary=0" flag allows Gilan's Encounter Counter to function properly Archive strings contain block ids, entry ids, and table ids: (found only in dumps) <string block_id="0" entry_id="0" table_id="0">example</string> There are two types of archive strings; Sinnoh and Unova. To get your documents ready for your translations, create a new XML file in PokeMMO\data\strings titled z_strings_x_edits, where x = the region which you're modifying. Sinnoh: (region_id="3") <?xml version="1.0" encoding="UTF-8" standalone="no"?> <ds_strings_archive archive_type="0" is_primary="0" lang="default lang shortcode" region_id="3"> <!-- comment example; ignored by game --> <!-- modified strings go inside this code block --> <!-- use tab to indent text --> </ds_strings_archive> Before continuing it is extremely important to understand that when you re-import Unova strings while using English or a custom client language, you will encounter an "issue" where the game will revert to using the internal dump version of files. That means if you have any string that edits region_id="2" on your system- all MMO specific dialog is not being displayed. Correct dialog with "proper" string files: Updated Smoke Ball description / breeding item text Incorrect dialog from "bad" string files: Old Smoke Ball description / missing breeding item text These are single examples of dialog displaying improperly / straight from the ROMs. There's approximately 48 thousand lines of dialog in the Unova region alone, that is essentially the entire game's worth of monster, item and ability descriptions, conversations etc- anything the developers made specifically for the MMO is not being displayed. To circumvent this, use this placeholder file @realmadrid1809 and I created. Create a new XML file in PokeMMO\data\strings titled a_placeholder_for_enabling_unova_edits: <?xml version="1.0" encoding="UTF-8" standalone="no"?> <strings lang="en" lang_full="English" is_primary="1"> <string id="0987654321234567890"> </string> <!-- If you remove this file, you will load over 48,000 lines of incorrect dialog. The game will revert to using the internal dump version of files when reimporting Unova strings. That means if you have any string that edits region_id="2" on your system- all MMO specific dialog is not being displayed. You may repurpose this file for your own use if you wish, however- please credit nurver, realmadrid1809 and AnonymousPoke. --> </strings> Without a file similar to this, your game is displaying dialog from the ROMs, not the MMO. In other words, your game is outdated. Unova: (region_id="2") <?xml version="1.0" encoding="UTF-8" standalone="no"?> <ds_strings_archive archive_type="0" is_primary="0" lang="default lang shortcode" region_id="2"> <!-- comment example; ignored by game --> <!-- modified strings go inside this code block --> <!-- use tab to indent text --> </ds_strings_archive> There are two types of Unova strings; archive_type="0" and archive_type="1". Amend the archive_type flag to match the dialog being modified. Final thoughts List of additions / changes to the game files: https://forums.pokemmo.com/index.php?/topic/150659-docs-psa-to-themers-and-modders Conversations can source dialog from multiple string entries, even from other regions whilst in a totally different one You can only shorten string load time by removing existing line breaks "\n" and turning multiple sentences into a single short one Every area of each region is handled differently. Dialog that is tied to animation or background scripts behaves differently than others Files can technically be titled anything- as long as they load after your main files, but the Unova placeholder must remain the first file that loads Check the console.log in PokeMMO\log to confirm what order your game is loading your files Do not store extra copies or other unused loose files in the strings directory Please ensure you have repaired your client and cleaned your game directories before reporting bugs. It wastes the time of everyone involved. If you have further questions or require assistance, feel free to reach out. Edited November 9, 2022 by nurver9 Enzemos, realmadrid1809, pokemonmaster69 and 5 others 5 2 1 Link to comment
Enzemos Posted October 19, 2022 Share Posted October 19, 2022 Whilst I still dont fully understand how to do this, I appreciate the documentation. Maybe one day I'll tackle making custom strings.. nurver9 1 Link to comment
Thekingofglory Posted October 22, 2022 Share Posted October 22, 2022 hi,nurver,i wrote a tutorial in chinese forums 2 months ago,but i think yours is really useful nurver9 and ClaudyTzy 1 1 Link to comment
Thekingofglory Posted October 24, 2022 Share Posted October 24, 2022 oh,so this is only for your archetype theme? ClaudyTzy 1 Link to comment
nurver9 Posted October 24, 2022 Author Share Posted October 24, 2022 4 hours ago, Thekingofglory said: oh,so this is only for your archetype theme? This has nothing to do with themes at all. Link to comment
Thekingofglory Posted October 24, 2022 Share Posted October 24, 2022 5 hours ago, Thekingofglory said: oh,so this is only for your archetype theme? so what's this docs mean? Link to comment
realmadrid1809 Posted October 24, 2022 Share Posted October 24, 2022 5 hours ago, Thekingofglory said: so what's this docs mean? It's a tutorial on how to create string mods for all regions, that don't need to be updated everytime Pokemmo gets a new revision. nurver9 1 Link to comment
ShaoYuWeiZZ Posted October 26, 2022 Share Posted October 26, 2022 Nice informative post. I didn't know about the dump directory at all, even though it's listed in the game's utilities. realmadrid1809 and nurver9 2 Link to comment
ShaoYuWeiZZ Posted October 29, 2022 Share Posted October 29, 2022 On 10/19/2022 at 8:31 PM, nurver9 said: Create a new XML file in PokeMMO\data\strings titled a_placeholder_for_enabling_unova_edits: <?xml version="1.0" encoding="UTF-8" standalone="no"?> <strings lang="en" lang_full="English" is_primary="1"> <string id="0987654321234567890"> </string> </strings> Without a file similar to this, your game is displaying dialog from the ROMs, not the MMO. In other words, your game is outdated. @nurver9Thanks for this information, I have something to clarify though since the topic is load order. `a_placeholder_for_enabling_unova_edits.xml` Am I correct in saying the game will only load this file as a primary string container if it is ahead of the other possible string containers in alphabetical order? Link to comment
realmadrid1809 Posted October 29, 2022 Share Posted October 29, 2022 2 hours ago, ShaoYuWeiZZ said: @nurver9Thanks for this information, I have something to clarify though since the topic is load order. `a_placeholder_for_enabling_unova_edits.xml` Am I correct in saying the game will only load this file as a primary string container if it is ahead of the other possible string containers in alphabetical order? Yes, out of all string files with the is_primary="1" flag it will choose the first one in alphabetical order ShaoYuWeiZZ 1 Link to comment
ClosedBox Posted November 7, 2022 Share Posted November 7, 2022 On 10/19/2022 at 12:31 PM, nurver9 said: <?xml version="1.0" encoding="UTF-8" standalone="no"?> <ds_strings_archive archive_type="0" is_primary="0" lang="default lang shortcode" region_id="3"> <!-- comment example; ignored by game --> <!-- modified strings go inside this code block --> <!-- use tab to indent text --> </strings> Noticed here it doesn't load anything since it mismatches <ds_strings_archive> with </strings>. Changing </strings> to </ds_strings_archive> solves the issue. nurver9 1 Link to comment
nurver9 Posted November 7, 2022 Author Share Posted November 7, 2022 Just now, ClosedBox said: Noticed here it doesn't load anything since it mismatches <ds_strings_archive> with </strings>. Changing </strings> to </ds_strings_archive> solves the issue. thanks for the heads up, just closed out my block incorrectly ClosedBox 1 Link to comment
R34ct1on Posted February 7 Share Posted February 7 The amount of help and knowledge i got in this post to do my own strings is wholesome, tysm Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now