Open heroesiiifan opened 3 years ago
"Keyboard" is mostly handled through the .FNT files. Heroes3 doesn't generally change text casing, check the game assets.
Thanks for your answer.
Keyboard: When I open the savegame-dialog and I type "zzz" it displays "yyy" and will save it as "yyy" (file manager in windows). There should be any hard coded Layout. If I do this in the german RoE it will work correctly (uses same fonts).
Casing: My ResTypes.txt looks like following:
Holz Quecksilber Erz Schwefel Kristalle Edelsteine Gold Verlassen
I searched with Notepad++ in all files for an lowercase "holz". But nothing found. This is quite strange...
Edit: I've confirmed it: If I change "Holz" to "AAAHolz" in ResTypes.txt it will display "aAAHolz" in the Box on the right. Sadly there is an lowercasing (at least in the box after picking up e.g. wood; I've don't seen this anywhere else yet).
Learn something new every day looking at that exe... the first letter of resource names is transformed to lowercase before displaying. A localization plugin could take care of that.
I'm not familiar enough with heroes3's handling of keyboard styles and I don't have the German RoE version handy.
Your message contained copyrighted content, I deleted it.
I can think of two possible solutions: 1- use LoadKeyboardLayoutA to tell the application to use a specific locale. This is an intrusive call after Windows 8 so not a preferred option. 2- hack input manager and swap key presses
I'm not sure what kind of impact this would have overall to be honest.
EDIT 3- figure out where the input manager is switching between QWERTY and QWERTZ layout. Simple enough it could be done with a hex edit patch, but I think it's a worthwhile thing to be set via plugin.
Amazing results. Thank you. 3. looks very interesting.
With my Hex-Editor I don't find the values. Is the data encoded?
That's the memory layout of InputManager, you won't find it as is with a hex editor. I'll have a bit of free time this weekend, I can make a plugin for QWERTZ keyboard layout then.
I edited my memory with cheat engine. It seems to work. Very nice. Yes, a plugin would be the best way. :)
Thank you very much.
The only thing that won't work is uppercase at the "new" chars. E.g Shift+Y for a big Y or for example SHIFT+Ä for Ä
Was it working correctly in RoE?
Okay, really strange. The german RoE has the same behavior. It looks like the translator-team has worked improperly. :)
SHIFT+Z works -> uppercase SHIFT+ Y, Ä, Ö, Ü not -> it's lowercase
Probably just need to get the correct capitalized unicode characters, these 4 look like lowercase.
Give this one a try.
Essentially changed to this:
WordPatch(0x4ECA0E + 1, 0xFFDF); // ß unicode replacement
WordPatch(0x4ECA23 + 7, '@');
WordPatch(0x4ECA6B + 7, 'Z');
WordPatch(0x4ECA98 + 7, 0xFFDC); // Ü unicode replacement
WordPatch(0x4ECAA1 + 7, '+');
WordPatch(0x4ECB0D + 7, 0xFFD6); // Ö unicode replacement
WordPatch(0x4ECB16 + 7, 0xFFC4); // Ä unicode replacement
WordPatch(0x4ECB31 + 7, '#');
WordPatch(0x4ECB3A + 7, 'Y');
WordPatch(0x4ECB8B + 7, '-');
It looks ok in memory but I have no clue if it will work since it's not proper OBJECT REPLACEMENT CHARACTER
type.
X
and Y
works correct now.
But ÄÖÜ
are only uppercase now.
ß
is working. But if you type SHIFT+ß
it is still ß
but it should be ?
.
Okay, that's a good step forward. Now I can look in making the lowercase-uppercase conversion actually do its job instead of naively converting with +/- 0x20
which only works for ascii characters.
The issue I see with Shift+ß
is that this behaviour would lock the plugin in German version of QWERTZ. For now I suppose it can be a German-QWERTZ layout... if other people want to test their keyboard layout then the plugin can become customizable.
I've found the adresses for the other problem.
If I change the 20
to 0
the values stay uppercase.
How can I patch one byte with plugins?
That's to_lower()
you don't want to touch that. The correct procedure is to remove the call to to_lower()
for the controls that use resources, I have all the necessary info just not the time... I'll get around to it at some point.
Thank you.
Yes, that is correct. But I'm very happy that I managed to find the correct function. :)
Note: The Keyboard issue is completely fixed with HoMM3 HD 5.2 R54.
Hmm, I'll still do it at some point when I get time for it. Thanks for letting me know.
Hello,
I'm working currently on an complete german translation of H3 Complete. Normally only RoE exists in german.
But there are some things I can't fix.
Is it possible to modify the Keyboard-Layout of H3 Complete? The german RoE is the correct QWERTZ Layout. While the Complete is fixed to QWERTY.
Another problem to be perfect - Heroes III seems to automatically lowercase resources in the windows right. Is there a way to fix this?