Editor Map and all related files stored in 1 map folder (or file)
#1
I noticed that to show text I made for map and my game language is set to English I need to wrote all that text in Localizations/English/English.xml file. It means I need to place custom text for map along with all other texts made in English for all game elements. It may cause some troubles if I want to have many maps imported from other map authors that includes custom text messages for their map in scripts, especially if it comes to make text in specific language or more language than one - I couldn't just simply replace someone's English.xml to English.xml placed in game Localizations directory - I could lose text made for other maps this way - I would need to copy text from someone's English.xml to English.xml placed in Localizations directory.

To solve that problem what if if each map could have it's own folder in which all related to map files could be stored there and each localization could be stored in it's separate file?
So for my map named "asdf" (in which I made texts in English and Polish language) after saving the map game would generate folder named ../Media/Maps/asdf and it would contain files like:
  • ../Media/Maps/asdf/asdf.data;
  • ../Media/Maps/asdf/asdf.xml;
  • ../Media/Maps/asdf/asdf_localizations.xml (here is the list of languages for that map) - however maybe it could be included in asdf.xml instead?;
  • ../Media/Maps/asdf/English/asdf_EN_text.xml (stores texts wrote in English language, only players with English language chosen in launcher settings can see texts from there, however if someone plays Dwelvers in i.e. Chinese language than game should make English as default (because there's no .xml wrote in Chinese like asdf_CN_text.xml), so for map that haven't texts in Chinese localization will load texts from default English localization so in case of "asdf" map from asdf_EN_text.xml);
  • ../Media/Maps/asdf/Polish/asdf_PL_text.xml (stores texts wrote in Polish, which can be shown for this map in game only for those who have Polish language set in their game settings);
  • ../Media/Maps/asdf/Polish/asdf_scene1speech1_PL.ogg (custom sound/music), asdf_scene1speech2_PL.ogg, etc.

In the asdf.xml texts could be loaded for English language from asdf_EN_text.xml and for Polish language from asdf_PL_text.xml so in asdf.xml you would just need to write a text like:
Code:
<localization option="English" action type="subs_scene_1" message="map:asdf:subs_scene_1:something_1" duration="x.y"/>
<localization option="Polish" action type="subs_scene_1" message="map:asdf:subs_scene_1:something_1" duration="x.y"/>
That means that game will search for a file that have localization option="English" (so asdf_EN_text.xml file) and localization option="Polish" (asdf_PL_text.xml file), so map will only show text in English or Polish language for that particular scene, but only if files for both languages are stored in Media/Maps/asdf/English and Media/Maps/asdf/Polish consecutively. This way it would be far more easier to download and play maps uploaded in Steam Workshop - all files in one folder.
Spec: Win 10, ATI 7800 HD, res: 1280x1024x75. I support The Venus Project & Resource-Based Economy
Reply
#2
That makes sense as long as the editor continues to save maps this way. Any editors I've used in the past just compiled all the customizations to a single file, and if that's what ultimately happens here, then there would need to be a way in the editor to add multiple translations into your map.
Reply
#3
Yeah, 1 file contains everything, in the same way maps were saved in Warcraft III or HoM&M III. Only in Dungeon Keeper 1 all texts were stored in one .txt file.
If it comes to Steam Workshop if someone would like to use custom sounds or textures these could be uploaded as external pack on SW containing all needed files. Sounds for example could actually be placed in Media/Sounds folder instead in map folder, so having all texts + scripts + map data etc. in one file with unique extension for Dwelvers like asdf.dvl would be the best option.

I presented format for text files above as temporary, because now it's impossible or at least I don't know the scripts which could allow me to play map in my language except writing texts in my language in English.xls which, well... does not feel well organized, does it? Big Grin At the moment if we look at campaign map .xls there no single link to English or any other localization file whatsoever, that means for me that game assumes it needs to search for a text in default localization file which is English.xls. Maybe Rasmus just didn't took when making campaign possibility of translating it into other languages yet. Wink.
Spec: Win 10, ATI 7800 HD, res: 1280x1024x75. I support The Venus Project & Resource-Based Economy
Reply
#4
Yeah, I have't played with the editor enough so I'd need some time before I could really speak intelligently on it. It's a shame too since this feature is one I've been looking forward to since I first played. I should fix that right Tongue
Reply
#5
That is a good idea. But I want to avoid spreading out the localization xml files. Perhaps I could have the translations directly in the map.xml file as you said.
Reply
#6
If .data and .xml file couldn't be merged together (at least until writing text messages cannot be implemented in Editor), than yeah, that would be great.
In WC3 World Editor any text message can be placed between different triggers in the same action, than having the possibility to place text messages and for different localizations within lines of code for scripted events would solve the problem.
Spec: Win 10, ATI 7800 HD, res: 1280x1024x75. I support The Venus Project & Resource-Based Economy
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)