Author Topic: [Done] Split "ExitGame?" string  (Read 2789 times)

GunChleoc

  • Horseman
  • ****
  • Posts: 202
    • View Profile
    • Fòram na Gàidhlig
[Done] Split "ExitGame?" string
« on: 13 June 2013, 12:19:14 »
The string ExitGame? is used in two places

  • The game menu
  • A feedback question (with the meaning of: are you sure... ?)
The question mark in the menu looks ugly in English, and it's creating problems for the translators. Could we have two separate strings for this please?

I suggest
  • Exit Game for the menu, and
  • Exit Game? or Are you sure you want to leave the game? for the feedback question.

Related: 3.7.0 beta1 translation + usability - Game menu - Exit game?
« Last Edit: 1 July 2016, 19:44:15 by filux »

softcoder

  • MegaGlest Team
  • Battle Machine
  • ********
  • Posts: 2,239
    • View Profile
Re: Split "ExitGame?" string
« Reply #1 on: 21 June 2013, 06:02:36 »
Updated as requested in svn rev#: 4481

ExitGame?=Would you like to close the game?
ExitGameMenu?=Exit current game?
ExitGameServer?=Exit current game? (this will end the game for all other connected players)

GunChleoc

  • Horseman
  • ****
  • Posts: 202
    • View Profile
    • Fòram na Gàidhlig
Re: Split "ExitGame?" string
« Reply #2 on: 21 June 2013, 08:22:53 »
Thanks! :D

GunChleoc

  • Horseman
  • ****
  • Posts: 202
    • View Profile
    • Fòram na Gàidhlig
Re: [done] Split "ExitGame?" string
« Reply #3 on: 15 July 2013, 13:54:58 »
I have just tested this with the latest beta from the automatic Windows builds, and it does not work. I am presented with ExitGameMenu? both for the menu entry and the question in the prompt dialog.

tomreyn

  • MegaGlest Team
  • Airship
  • ********
  • Posts: 2,764
    • View Profile
    • MegaGlest - the free and open source cross platform 3D real-time strategy game
Re: Split "ExitGame?" string
« Reply #4 on: 15 July 2013, 15:52:46 »
Hmm, let's see...

Current (r4510) English language file in the subversion repository.
(The latest revision is always available here.)

Current (r4510) Gaelic language file in the subversion repository.
(The latest revision is always available here.)

According to the CI subversion repository polling log the latest Windows build is based on r4518, was built 3 days ago, and the build succeeded.

In r4518, these keys are referenced in the following game engine files:
FileLine no.Code
source/glest_game/game/game.cpp1648menuItems.push_back(lang.get("ExitGameMenu?"));
source/glest_game/game/game.cpp3539showMessageBox(Lang::getInstance().get("ExitGameMenu?"), "", true);
source/glest_game/game/game.cpp5814showMessageBox(lang.get("YouLose")+" "+lang.get("ExitGameServer?"), lang.get("BattleOver"), false);
source/glest_game/game/game.cpp5817showMessageBox(lang.get("YouLose")+" "+lang.get("ExitGameMenu?"), lang.get("BattleOver"), false);
source/glest_game/game/game.cpp5825showMessageBox(lang.get("GameOver")+" "+lang.get("ExitGameMenu?"), lang.get("BattleOver"), false);
source/glest_game/game/game.cpp5828showMessageBox(lang.get("YouWin")+" "+lang.get("ExitGameMenu?"), lang.get("BattleOver"), false);
source/glest_game/menu/menu_state_root.cpp322showMessageBox(lang.get("ExitGame?"), "", true);
source/glest_game/main/battle_end.cpp770showMessageBox(lang.get("ExitGameMenu?"), "", true);

Of course, to get the latest translations you also need to use the latest game data archive (to get what's in the subversion repository) or use the games' option menu to pull the latest translations from Transifex.

Now what do you think should be changed?

Update: I just submitted a minimal change (r4519, which is only comprised of two changes to the french main language file) which will trigger the data package to be rebuild, but you can safely ignore this.
« Last Edit: 15 July 2013, 16:14:48 by tomreyn »
atibox: Ryzen 1800X (8 cores @3.6GHz), 32 GB RAM, MSI Radeon RX 580 Gaming X 8G, PCI subsystem ID [1462:3417], (Radeon RX 580 chipset, POLARIS10) @3440x1440; latest stable Ubuntu release, (open source) radeon (amdgpu) / mesa video driver
atibox (old): Core2Quad Q9400 (4 cores @2.66GHz), 8 GB RAM, XFX HD-467X-DDF2, PCI subsystem ID [1682:2931], (Radeon HD 4670, RV730 XT) @1680x1050; latest stable Ubuntu release, (open source) radeon / mesa video driver
notebook: HP envy13d020ng
internet access: VDSL2+

· · · How YOU can contribute to MG · Latest development snapshot · How to build yourself · Megapack techtree · Currently hosted MG games · · ·

GunChleoc

  • Horseman
  • ****
  • Posts: 202
    • View Profile
    • Fòram na Gàidhlig
Re: Split "ExitGame?" string
« Reply #5 on: 16 July 2013, 08:39:35 »
I did pull the latest translation from Transifex.  It loaded fine, because the new "Show next hint" button is there. I then changed the ExitGameMenu? string in Transifex, reloaded the translation and it promptly changed in both locations. So, it's definitely the same variable.

I thik the culprit is this one:
FileLine no.Code
source/glest_game/game/game.cpp1648menuItems.push_back(lang.get("ExitGameMenu?"));
which should be ExitGame? to separate the strings correctly.

We then still have reversed semantics. i.e. replace all ExitGame? (a question) with ExitGameMenu? (a button text) and all ExitGameMenu? with ExitGame?

ExitGameMenu? where it sould be a menu entry


ExitGameMenu? where it should be a question. It also appears in the "You Won. Exit Game?" question.

tomreyn

  • MegaGlest Team
  • Airship
  • ********
  • Posts: 2,764
    • View Profile
    • MegaGlest - the free and open source cross platform 3D real-time strategy game
Re: Split "ExitGame?" string
« Reply #6 on: 16 July 2013, 12:01:37 »
With the change you suggest it would look like this:



(while the follow-up screen is unmodified).

Hmm, I don't think that's an improvement. Maybe that's not what you wanted to do?

I don't speak Gaelic, so it's difficult to understand what your goal is. If what you are discussing is not primarily an issue with Gaelic translations but one which also affects the source language (English), then it would be best to refer to this.
« Last Edit: 16 July 2013, 12:07:33 by tomreyn »
atibox: Ryzen 1800X (8 cores @3.6GHz), 32 GB RAM, MSI Radeon RX 580 Gaming X 8G, PCI subsystem ID [1462:3417], (Radeon RX 580 chipset, POLARIS10) @3440x1440; latest stable Ubuntu release, (open source) radeon (amdgpu) / mesa video driver
atibox (old): Core2Quad Q9400 (4 cores @2.66GHz), 8 GB RAM, XFX HD-467X-DDF2, PCI subsystem ID [1682:2931], (Radeon HD 4670, RV730 XT) @1680x1050; latest stable Ubuntu release, (open source) radeon / mesa video driver
notebook: HP envy13d020ng
internet access: VDSL2+

· · · How YOU can contribute to MG · Latest development snapshot · How to build yourself · Megapack techtree · Currently hosted MG games · · ·

GunChleoc

  • Horseman
  • ****
  • Posts: 202
    • View Profile
    • Fòram na Gàidhlig
Re: Split "ExitGame?" string
« Reply #7 on: 16 July 2013, 14:17:48 »
After changing this, they then are all the wrong way around, in all languages.

We then still have reversed semantics. i.e. replace all ExitGame? (a question) with ExitGameMenu? (a button text) and all ExitGameMenu? with ExitGame?

So, we have 2 problems:

1. Two variables that share the same string and that shouldn't.

2. Two translations being generally assigned the wrong way around.

Will do the table in the next post

GunChleoc

  • Horseman
  • ****
  • Posts: 202
    • View Profile
    • Fòram na Gàidhlig
Re: Split "ExitGame?" string
« Reply #8 on: 16 July 2013, 14:26:00 »
 
FileLine no.Code
source/glest_game/game/game.cpp1648menuItems.push_back(lang.get("ExitGameMenu?"));
source/glest_game/game/game.cpp3539showMessageBox(Lang::getInstance().get("ExitGame?"), "", true);
source/glest_game/game/game.cpp5814showMessageBox(lang.get("YouLose")+" "+lang.get("ExitGameServer?"), lang.get("BattleOver"), false);
source/glest_game/game/game.cpp5817showMessageBox(lang.get("YouLose")+" "+lang.get("ExitGame?"), lang.get("BattleOver"), false);
source/glest_game/game/game.cpp5825showMessageBox(lang.get("GameOver")+" "+lang.get("ExitGame?"), lang.get("BattleOver"), false);
source/glest_game/game/game.cpp5828showMessageBox(lang.get("YouWin")+" "+lang.get("ExitGame?"), lang.get("BattleOver"), false);
source/glest_game/menu/menu_state_root.cpp322showMessageBox(lang.get("ExitGameMenu?"), "", true);
source/glest_game/main/battle_end.cpp770showMessageBox(lang.get("ExitGame?"), "", true);

 

anything