Guide: Translating your UMC without WesCamp

Discussion and development of scenarios and campaigns for the game.

Moderators: Forum Moderators, Developers

User avatar
octalot
Developer
Posts: 415
Joined: July 17th, 2010, 7:40 pm

Re: Guide: Translating your UMC without WesCamp

Post by octalot » May 17th, 2019, 4:29 pm

James_The_Invisible wrote:
June 8th, 2017, 9:55 am
  1. Make sure that you add-on can be translated. The wiki provides some instructions for this. You can stop reading at Getting your add-on into WesCamp as WesCamp is dead by now.
That part of the WesCamp page has now been moved to GettextForWesnothDevelopers, and a big update was done afterwards.

I'm thinking of doing (this weekend):
  • Done: Replace that part of the WesCamp page with just a link to the new location
  • Add female_message to the new location
  • Add Lua to the new location.

User avatar
EarthCake
Posts: 354
Joined: March 29th, 2019, 1:57 pm
Location: Braavosi

Re: Guide: Translating your UMC without WesCamp

Post by EarthCake » May 18th, 2019, 9:39 pm

The template (.pot) file contains all of the strings that need to be translated in the .po files, but without the translations.

The .pot is generated from WML and Lua files using is a tool called wmlxgettext. On Wesnoth 1.13 and later, it is shipped with Wesnoth itself and can be used from Maintenance tools GUI. Just go to data/tools, launch GUI.pyw and switch to the wmlxgettext tab.

Pre-1.13 instructions on how to get and use it are in Nobun's forum posting.
This really doesn't help how to create .pot files. After reading this, I only found wmlxgettext.

User avatar
octalot
Developer
Posts: 415
Joined: July 17th, 2010, 7:40 pm

Re: Guide: Translating your UMC without WesCamp

Post by octalot » May 19th, 2019, 1:41 am

Thanks for the feedback. Here's a new revision of the second paragraph:
The .pot is generated from WML and Lua files using a tool called wmlxgettext. With Wesnoth 1.14.5 and later, this is shipped with Wesnoth itself as part of the Maintenance_tools and can be used from the Maintenance Tools' GUI. At the moment it's not documented on that page, but if you follow the instructions to get GUI.pyw running then you'll see there's a wmlxgettext tab.
The Maintenance_tools page itself needs someone who uses Windows to check and update it.

User avatar
Adamant14
Posts: 897
Joined: April 24th, 2010, 1:14 pm

Re: Guide: Translating your UMC without WesCamp

Post by Adamant14 » May 19th, 2019, 4:18 pm

wiki.wesnoth.org/Maintenance_tools wrote: Note to Windows Users: This means you have to run it from the Command Line. The command line may be reached by hitting Start, then Run, then "cmd" or "command" depending on your version of Windows.
I works also without any use of the command line on Windows 10.
All I have done:
- I have installed Python 3.7.3
- then I opened Wesnoths folder where the tools are to find
- then I selected GUI.pyw
- then I clicked 'open'
Author of Antar, Son of Rheor ( SP Campaign) | Development Thread + Feedback Thread + Replays of ASoR

User avatar
EarthCake
Posts: 354
Joined: March 29th, 2019, 1:57 pm
Location: Braavosi

Re: Guide: Translating your UMC without WesCamp

Post by EarthCake » May 24th, 2019, 6:24 am

Are .pot files important for campaign translating?
I mean, I know you can translate campaign without .pot files (can you?), but is it much easier with .pot files or it is the same?

User avatar
Adamant14
Posts: 897
Joined: April 24th, 2010, 1:14 pm

Re: Guide: Translating your UMC without WesCamp

Post by Adamant14 » May 24th, 2019, 3:33 pm

EarthCake wrote:
May 24th, 2019, 6:24 am
Are .pot files important for campaign translating?
I mean, I know you can translate campaign without .pot files (can you?), but is it much easier with .pot files or it is the same?
Using Poedit, you can generate po.files/mo.files out of pot-files, and then translate them easily.
What is the name of the campaign you want to translate?
Author of Antar, Son of Rheor ( SP Campaign) | Development Thread + Feedback Thread + Replays of ASoR

User avatar
EarthCake
Posts: 354
Joined: March 29th, 2019, 1:57 pm
Location: Braavosi

Re: Guide: Translating your UMC without WesCamp

Post by EarthCake » May 24th, 2019, 5:42 pm

Adamant14 wrote:
May 24th, 2019, 3:33 pm
What is the name of the campaign you want to translate?
I am currently writing my own campaign, so I would like to translate it.

User avatar
Celtic_Minstrel
Developer
Posts: 1565
Joined: August 3rd, 2012, 11:26 pm
Location: Canada
Contact:

Re: Guide: Translating your UMC without WesCamp

Post by Celtic_Minstrel » May 29th, 2019, 2:57 am

octalot wrote:
May 17th, 2019, 4:29 pm
James_The_Invisible wrote:
June 8th, 2017, 9:55 am
  1. Make sure that you add-on can be translated. The wiki provides some instructions for this. You can stop reading at Getting your add-on into WesCamp as WesCamp is dead by now.
That part of the WesCamp page has now been moved to GettextForWesnothDevelopers, and a big update was done afterwards.

I'm thinking of doing (this weekend):
  • Done: Replace that part of the WesCamp page with just a link to the new location
  • Add female_message to the new location
  • Add Lua to the new location.
I added a few notes to the C++ section (and syntax highlighting!) and added a stub section about translations in Lua. Feel free to expand on the latter.
Author of The Black Cross of Aleron campaign and Default++ era.
Maintainer of Steelhive.

Post Reply