Openrct2: Add Hungarian currency

Created on 27 Sep 2018  路  14Comments  路  Source: OpenRCT2/OpenRCT2

Hungarian forint (Ft)

feature

Most helpful comment

I already spoke to him on Discord. Considering the effort that goes into the translation, I said I would be willing to add Forint as a built-in currency.

All 14 comments

You can add an extra currency using the 'Custom currency' function, at the bottom of the currency dropdown.

I already spoke to him on Discord. Considering the effort that goes into the translation, I said I would be willing to add Forint as a built-in currency.

Aren't amounts of currency in Hungarian more commonly referred to as HUF instead of Ft?

Aren't amounts of currency in Hungarian more commonly referred to as HUF instead of Ft?

Only among non-Hungarians. HUF is the international currency code, Ft is the equivalent of 拢 or $.

My group and I are wanting to implement this feature, just to make sure there is no PR for this yet?
Edit: we know how to add HUF to the program, however that would require us to add the string id for it in every language packet in their languages respectively. Should we add it to all of them in their languages respectively, or just english in all of them? We could use google translate to change that one word.

Also, in Currency.cpp on line 19,

currency_descriptor CurrencyDescriptors[CURRENCY_END] = {
    {   "GBP",  10,     CURRENCY_PREFIX,    "\xC2\xA3",     CURRENCY_SUFFIX,    "GBP",  STR_POUNDS          },  // British Pound
    {   "USD",  10,     CURRENCY_PREFIX,    "$",            CURRENCY_PREFIX,    "$",    STR_DOLLARS         },  // US Dollar
    {   "FRF",  10,     CURRENCY_SUFFIX,    "F",            CURRENCY_SUFFIX,    "F",    STR_FRANC           },  // French Franc
    {   "DEM",  10,     CURRENCY_PREFIX,    "DM",           CURRENCY_PREFIX,    "DM",   STR_DEUTSCHE_MARK   },  // Deutsche Mark
    {   "JPY",  1000,   CURRENCY_PREFIX,    "\xC2\xA5",     CURRENCY_SUFFIX,    "YEN",  STR_YEN             },  // Japanese Yen

I know what the first section is, which in our case would be "HUF", however I don't understand what the next section would be such as for the US dollar is 10, however the Japanese yen is 1000. And may someone explain what the "\xC2\xA5" is? is it for formatting everything?

Because YEN has no equivalent to pence or cent etc. it needs to be scaled. You can think of it as an exchange rate which is rounded to the nearest 10/100.

The \xC2\xA5 are code points to represent the full unicode character in UTF-8. It isn't necessary anymore as we can write UTF-8 strings directly in the source code by using the u8 string literal prefix.

@IntelOrca i will do this feature today and make a pull request as soon as possible. Since i will add it to the string ids, would you like me to add them into each language.txt file as well as in their respective languages?

Only touch en-GB.txt, all the other languages are edited in our separate localisation repository.

Ok, will do that

I found 2 variations of en-GB.txt. One in G9\data\language and one in G9\bin\data\language. Which one should I alter? or just both?

Bin/data isn't part of the repo that's created as part of the build steps.

so just data\language. will make a pull request now.

Has been implemented.

Was this page helpful?
0 / 5 - 0 ratings