Valna 0 Posted April 14, 2016 Can't open any Translate....GPLed program Error. I have Windows 10, any Problem with this? "Please contact the application support team..." Quote Share this post Link to post Share on other sites
Darknessfmy 2 Posted May 10, 2016 (edited) - Po can be save ASCI to UTF-8 ? - Client can use langtype default to UTF-8 ? - you have a simple file .po UTF-8 ? Sry, I'm bad English. simple, generate the file .po of emu. open the file .po in notepad++ and convert to ANSI CONVERT TO UNIX FORMAT the file .po and save. Open Podit and use iso-8859-1 character Work very fine, tested in poedit and the game, best rewards from ultimate localization system of rAthena Edited May 10, 2016 by Darknessfmy Quote Share this post Link to post Share on other sites
evilpuncker 503 Posted May 10, 2016 - Po can be save ASCI to UTF-8 ? - Client can use langtype default to UTF-8 ? - you have a simple file .po UTF-8 ? Sry, I'm bad English. simple, generate the file .po of emu. open the file .po in notepad++ and convert to ANSI CONVERT TO UNIX FORMAT the file .po and save. Open Podit and use iso-8859-1 character Work very fine, tested in poedit and the game, best rewards from ultimate localization system of rAthena rA? Quote Share this post Link to post Share on other sites
zenghanbiao 0 Posted August 21, 2016 But what's the difference if I translate it in files and update every time? Quote Share this post Link to post Share on other sites
ZelosAvalon 14 Posted September 1, 2016 Hercules Ultimate Localization Design Hello~! - What?! [*]Servers are now able to run under any number of languages, without having any of the default files modified[*]Designed by Haruna and Ind Translating NPCs without editing them [*]By launching map server with the --generate-translations param a .pot (.po template) file will be created with all of the servers translate-able strings (including all npc dialogue), this file can be edited in text mode or by utilising any .po editor (there are many out there; for a high range of OSes)[*]A .po file does not need to be fully translated to be used, map server will know when loading the file, and will fallback to the hardcoded string in the npc files as necessary [*]Users are able to change their language with the new @lang command, @lang controls what language users see in @commands (msg_txt stuff) as well as over npc dialogues [*]map-server.conf has a new setting called default_language where server owners may specify which language should be used as a base [*]When you have a new .po file you want map server to use, add it to db/translations.conf Easy to Maintain [*]Since .po is a widely used format there are many tools that can help with merging for example Poedit, which easily consolidates a translated .po file with a newly generated .pot. For example when you have a translated .po and since it was created npc dialogs were added or modified all you have to do is launch map server to generate a new .pot, open your old .po in Poedit, go "Catalog -> Update from POT file" and it will insert the new translatable strings without touching your existing translations, it will also notify you of any "obsolete" strings that are in your .po file but that are no longer in use Script Command Macro [*]Besides messages.conf, all the dialogue utilised by 'mes' and 'select' is included in the .pot automatically, this patch also introduces a mechanism for utilising strings outside of these commands, the script macro _() which can be employed just as if it were a script function, for example set .@status$,_("Available"); tells map server to export "Available" as a translate-able string when it is run with --generate-translations (when running map server normally the macro has no overhead during runtime) Special Thanks to [*]Raizen and Roberto from Cronus, we would not have worked on this if it weren't for them Links~! [*]Commit Editing Example TranslationSample1.png still working in the new revision on Hercules ? cuz i try to modify my map-server and add --generate-translations and nothing happened! @ECHO OFF CALL serv.bat map-server.exe map-server --generate-translations is that correct? Quote Share this post Link to post Share on other sites
chao93 2 Posted September 14, 2016 (edited) http://imgur.com/gallery/xwuXB I get the error message, unknow option '--generate-translations'Windows Edited September 14, 2016 by chao93 Quote Share this post Link to post Share on other sites
Ragno 57 Posted September 24, 2016 (edited) I'm having problems with translations plugin. This is the npc: prontera,50,50,0 script NPC_TEST PORING,{ mes "A little " + (Sex == SEX_MALE ? "boy" : "girl") + ". Who are you?"; mes "Oh! you are " + strcharinfo(PC_NAME) + ", nice to meet you."; close; } In the example, all the text is included on generated translations file, but the line ", nice to meet you." is not. It seems like if the strcharinfo command ends the line (even when the conditional boy/girl is all included and reanudates the line). #: npc/test.txt # mes "A little " + (Sex == SEX_MALE ? "boy" : "girl") + ". Who are you?"; msgctxt "NPC_TEST" msgid "A little " msgstr "" #: npc/test.txt # mes "A little " + (Sex == SEX_MALE ? "boy" : "girl") + ". Who are you?"; msgctxt "NPC_TEST" msgid "boy" msgstr "" #: npc/test.txt # mes "A little " + (Sex == SEX_MALE ? "boy" : "girl") + ". Who are you?"; msgctxt "NPC_TEST" msgid "girl" msgstr "" #: npc/test.txt # mes "A little " + (Sex == SEX_MALE ? "boy" : "girl") + ". Who are you?"; msgctxt "NPC_TEST" msgid ". Who are you?" msgstr "" #: npc/test.txt # mes "Oh! you are " + strcharinfo(PC_NAME) + ", nice to meet you."; msgctxt "NPC_TEST" msgid "Oh! you are " msgstr "" http://imgur.com/gallery/xwuXB I get the error message, unknow option '--generate-translations'Windows That is because since commits on Jun 25, 2016 it was moved translations template generator to a plugin and it is now needed to build the plugin to use it. You can build the plugin following this instructions (based on wiki) : 1. Open folder \vcproj-14\ 2. Copy and paste plugin-sample.vcxproj to duplicate it. 3. Rename file "plugin-sample.vcxproj" to "generate-translations.vcxproj" 4. Open generate-translations.vcxproj in Notepad++ 5. Find this line: <ProjectName>plugin-sample</ProjectName> 6. Rename 'plugin-sample' to 'generate-translations' 7. Find this line: <TargetName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">generate-translations</TargetName> 8. Rename sample to generate-translations 9. Find this line: <ClCompile Include="..\src\plugins\sample.c" /> 10. Renae sample to generate-translations 11. Save changes and close 12. Open MSVC. Do right-clic on Solution 'Hercules-14'. Select Add -> Existing Project... 13. Select generate-translations.vcxproj in folder \vcproj-14\ 14. Right-click Hercules-14, Select Build-Solution 15. Add it to /conf/plugins.conf plugins_list: [ /* Enable HPMHooking when plugins in use rely on Hooking */ "HPMHooking", // <-- Uncomment this //"db2sql", //"sample", //"other", "generate-translations", // loads generate-translations plugin ] Edited September 24, 2016 by Ragno Quote Share this post Link to post Share on other sites
chao93 2 Posted September 25, 2016 I'm having problems with translations plugin. This is the npc: prontera,50,50,0 script NPC_TEST PORING,{ mes "A little " + (Sex == SEX_MALE ? "boy" : "girl") + ". Who are you?"; mes "Oh! you are " + strcharinfo(PC_NAME) + ", nice to meet you."; close; } In the example, all the text is included on generated translations file, but the line ", nice to meet you." is not. It seems like if the strcharinfo command ends the line (even when the conditional boy/girl is all included and reanudates the line). #: npc/test.txt # mes "A little " + (Sex == SEX_MALE ? "boy" : "girl") + ". Who are you?"; msgctxt "NPC_TEST" msgid "A little " msgstr "" #: npc/test.txt # mes "A little " + (Sex == SEX_MALE ? "boy" : "girl") + ". Who are you?"; msgctxt "NPC_TEST" msgid "boy" msgstr "" #: npc/test.txt # mes "A little " + (Sex == SEX_MALE ? "boy" : "girl") + ". Who are you?"; msgctxt "NPC_TEST" msgid "girl" msgstr "" #: npc/test.txt # mes "A little " + (Sex == SEX_MALE ? "boy" : "girl") + ". Who are you?"; msgctxt "NPC_TEST" msgid ". Who are you?" msgstr "" #: npc/test.txt # mes "Oh! you are " + strcharinfo(PC_NAME) + ", nice to meet you."; msgctxt "NPC_TEST" msgid "Oh! you are " msgstr "" http://imgur.com/gallery/xwuXB I get the error message, unknow option '--generate-translations' Windows That is because since commits on Jun 25, 2016 it was moved translations template generator to a plugin and it is now needed to build the plugin to use it. You can build the plugin following this instructions (based on wiki) : 1. Open folder \vcproj-14\ 2. Copy and paste plugin-sample.vcxproj to duplicate it. 3. Rename file "plugin-sample.vcxproj" to "generate-translations.vcxproj" 4. Open generate-translations.vcxproj in Notepad++ 5. Find this line: <ProjectName>plugin-sample</ProjectName> 6. Rename 'plugin-sample' to 'generate-translations' 7. Find this line: <TargetName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">generate-translations</TargetName> 8. Rename sample to generate-translations 9. Find this line: <ClCompile Include="..\src\plugins\sample.c" /> 10. Renae sample to generate-translations 11. Save changes and close 12. Open MSVC. Do right-clic on Solution 'Hercules-14'. Select Add -> Existing Project... 13. Select generate-translations.vcxproj in folder \vcproj-14\ 14. Right-click Hercules-14, Select Build-Solution 15. Add it to /conf/plugins.conf plugins_list: [ /* Enable HPMHooking when plugins in use rely on Hooking */ "HPMHooking", // <-- Uncomment this //"db2sql", //"sample", //"other", "generate-translations", // loads generate-translations plugin ] Thank you! i get sucked this error in week. http://imgur.com/4O73d0m Poedit not allowed new scripting format? "\r" Quote Share this post Link to post Share on other sites
Ridley 295 Posted September 25, 2016 I'm having problems with translations plugin. This is the npc: prontera,50,50,0 script NPC_TEST PORING,{ mes "A little " + (Sex == SEX_MALE ? "boy" : "girl") + ". Who are you?"; mes "Oh! you are " + strcharinfo(PC_NAME) + ", nice to meet you."; close; } mesf("A little %s. Who are you?", Sex == SEX_MALE ? "boy" : "girl"); mesf("Oh! you are %s, nice to meet you.", strcharinfo(PC_NAME)); to include functions, variables, strings or whatever you need to use mesf (mes+sprintf) you can find some examples in my recent commits reference sprintf 2 Mystery and Ragno reacted to this Quote Share this post Link to post Share on other sites
ZelosAvalon 14 Posted October 6, 2016 (edited) That is because since commits on Jun 25, 2016 it was moved translations template generator to a plugin and it is now needed to build the plugin to use it. You can build the plugin following this instructions (based on wiki) : 1. Open folder \vcproj-14\ 2. Copy and paste plugin-sample.vcxproj to duplicate it. 3. Rename file "plugin-sample.vcxproj" to "generate-translations.vcxproj" 4. Open generate-translations.vcxproj in Notepad++ 5. Find this line: <ProjectName>plugin-sample</ProjectName> 6. Rename 'plugin-sample' to 'generate-translations' 7. Find this line: <TargetName Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">generate-translations</TargetName> 8. Rename sample to generate-translations 9. Find this line: <ClCompile Include="..\src\plugins\sample.c" /> 10. Renae sample to generate-translations 11. Save changes and close 12. Open MSVC. Do right-clic on Solution 'Hercules-14'. Select Add -> Existing Project... 13. Select generate-translations.vcxproj in folder \vcproj-14\ 14. Right-click Hercules-14, Select Build-Solution 15. Add it to /conf/plugins.conf plugins_list: [ /* Enable HPMHooking when plugins in use rely on Hooking */ "HPMHooking", // <-- Uncomment this //"db2sql", //"sample", //"other", "generate-translations", // loads generate-translations plugin ] Thank you! i get sucked this error in week. http://imgur.com/4O73d0m Poedit not allowed new scripting format? "\r" how it work now ? I tried to do what you said, but it didn't work! can you help me ? i need to know how generate-translations work now, how can i generate a new translate with this new plugin ? and how can i configure this plugin? Edited October 6, 2016 by ZelosAvalon Quote Share this post Link to post Share on other sites
4144 364 Posted October 8, 2016 mesf("A little %s. Who are you?", Sex == SEX_MALE ? "boy" : "girl"); This line better replace to: if (Sex == SEX_MALE) mes("A little boy. Who are you?"); else mes("A little girl. Who are you?"); Because in some languages can be issue because sentence can be different depend on gender. 2 Ragno and Nuck reacted to this Quote Share this post Link to post Share on other sites
Ragno 57 Posted December 20, 2016 (edited) Huld doesn't support \r in mes command (tested on Hercules-68947c86d5fe3eb2686c9b3393e3db0df083bb11 version). Example: Script: mes("It seems those limbs belong to that ugly octopus. That monster should be taken care of,\r" "but it's hard for ourselves only to make it happen, hehe."); Generated translation: #: npc/re/instances/octopus_cave.txt # mes("It seems those limbs belong to that ugly octopus. That monster should be taken care of,\r" msgctxt "Starfish" msgid "It seems those limbs belong to that ugly octopus. That monster should be taken care of,\rbut it's hard for ourselves only to make it happen, hehe." msgstr "Parece que esas extremidades pertenecen a ese horrible pulpo. Alguien debería encargarse de ese monstruo,\rpero el hacerlo es muy difícil para nosotros solos, hehe." Even when there is a translation, huld always shows English text. Edited December 20, 2016 by Ragno Quote Share this post Link to post Share on other sites
java 3 Posted March 6, 2018 (edited) generate-translations is not working, please fix it, it's work now , ty Edited March 21, 2018 by java Quote Share this post Link to post Share on other sites
Duzanjos 0 Posted March 30, 2018 How do I add "announce", "map announce" so that --generate_translations draws from NPCs? I did not understand it! Quote Script Command Macro Besides messages.conf, all the dialogue utilised by 'mes' and 'select' is included in the .pot automatically, this patch also introduces a mechanism for utilising strings outside of these commands, the script macro _() which can be employed just as if it were a script function, for example set .@status$,_("Available"); tells map server to export "Available" as a translate-able string when it is run with --generate-translations (when running map server normally the macro has no overhead during runtime) Quote Share this post Link to post Share on other sites
Fou-lu 7 Posted April 1, 2020 Sorry, i am noob. I dont understand how generate the .po file. I'm execute map-server with --generate-translations param and nothing .po file is created. Someone can help? Thanks. Quote Share this post Link to post Share on other sites
java 3 Posted June 8, 2023 On 4/1/2020 at 11:16 AM, Fou-lu said: Sorry, i am noob. I dont understand how generate the .po file. I'm execute map-server with --generate-translations param and nothing .po file is created. Someone can help? Thanks. it's work a charm bro Quote Share this post Link to post Share on other sites
botka4aet 5 Posted April 11 Any idea why map-server restarts with generate-translations plugin? [Status]: Event 'OnInit' executed with '2405' NPCs. [Info]: Hercules, Copyright (C) 2012-2024, Hercules Dev Team and others. [Info]: Licensed under the GNU General Public License, version 3 or later. [Status]: Server is 'ready' and listening on port '5121'. [Status]: Terminating... [Status]: Cleaned up 1156 maps. [Status]: Close Map DB Connection.... [Status]: Close Log DB Connection.... [Status]: Finished. [Info]: Memory manager: No memory leaks found. Map-Server has shutdown successfully. Restarting in 15 seconds, press Ctrl+C to cancel. Quote Share this post Link to post Share on other sites
KirieZ 88 Posted April 11 9 hours ago, botka4aet said: Any idea why map-server restarts with generate-translations plugin? [Status]: Event 'OnInit' executed with '2405' NPCs. [Info]: Hercules, Copyright (C) 2012-2024, Hercules Dev Team and others. [Info]: Licensed under the GNU General Public License, version 3 or later. [Status]: Server is 'ready' and listening on port '5121'. [Status]: Terminating... [Status]: Cleaned up 1156 maps. [Status]: Close Map DB Connection.... [Status]: Close Log DB Connection.... [Status]: Finished. [Info]: Memory manager: No memory leaks found. Map-Server has shutdown successfully. Restarting in 15 seconds, press Ctrl+C to cancel. [Status]: Event 'OnInit' executed with '2405' NPCs. [Info]: Hercules, Copyright (C) 2012-2024, Hercules Dev Team and others. [Info]: Licensed under the GNU General Public License, version 3 or later. [Status]: Server is 'ready' and listening on port '5121'. [Status]: Terminating... [Status]: Cleaned up 1156 maps. [Status]: Close Map DB Connection.... [Status]: Close Log DB Connection.... [Status]: Finished. [Info]: Memory manager: No memory leaks found. Map-Server has shutdown successfully. Restarting in 15 seconds, press Ctrl+C to cancel. You are not supposed to keep the server online with generate-translations plugin. This plugin is only meant for you to use when generating the PO files. e.g.: ./map-server --load-plugin generate-translations --generate-translations After you run it, it will generate the translation files and shut down. After that you don't need the plugin anymore, unless you have new NPCs that you want to generate new translation files. Quote Share this post Link to post Share on other sites