Hard Light Productions Forums
Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Cross-Platform Development => Topic started by: heathen on January 28, 2009, 03:14:46 pm
-
Hi!
I have a problem with running FSO. I tried some mods (mediavp, WC Saga, BtRL) with different engine's builds, but have one problem. Game starting, I can see preview (cool graphic, by the way!), and on Create new pilot screen all is over for me. I can't enter pilot name: keyboard did not working except service keys (like Enter, Esc and so on). None of keys is working: letters or digits, none of this. I can only exit the game via Esc.
My system:
MacOS X 10.5.5 on PC
Intel C2Q6600, 4Gb RAM, nVidia GF6600, USB keyboard\mouse (wireless Logitech keyboard; work fine in every application I tried before), Logitech USB wireless joystick.
I have two keyboard maps enabled (Eng and Russian) but even work with US-only keyboard map nothing changes.
Hope you can help me remember my past: I began from Wing Commander and Wing Commander 2 at my school on 386SX at 1993. ;-)
P.S. Sorry for a bad English. ;)
-
I tried some mods (mediavp, WC Saga, BtRL)
Just to clarify on thing: you do know that Wing Commander Saga and Beyond the Red Line are standalones? You must install them separate from your FreeSpace2 installation.
-
I tried some mods (mediavp, WC Saga, BtRL)
Just to clarify on thing: you do know that Wing Commander Saga and Beyond the Red Line are standalones? You must install them separate from your FreeSpace2 installation.
Thanks for your reply.
Of course I know. I mean I tried different builds - and it was on different directories. And everything works fine at start - except keyboard input. :(
Add:
BtRL was installed by it's own installer - for the first try.
WCS on original dmg dist - for the second.
FSO with mediavp - for the third.
WCS with new wcs-specific build (wcs_prologe_5028) - and for the last.
-
I still need your help, guys.
I tried to look into the code and change some old commented debug code. That's what I found:
game_poll() does not get key codes except for the numeric (both main and keypad) and function keys (Ctrl, Shift, Fx, Esc, Enter and so on). None of keys in main keys area produce key press event, so game_poll() did not receive key code. The error is around key_inkey() I think, but I can't understand all logic at this step after this quick code review.
What can I do at this point? (Well, in addition to simply forget about the game and to do something else :-D )
-
I'm not sure that this is someone interested in (we got a conversation with himself), but I found the problem. Not sure of the differences, but in my case, code keys - in the international part of the SDLK code table.
If someone needs a patch - it as an attachment.
And, of course, patched build 5055_k (http://depositfiles.com/files/15mns4dga).
[attachment deleted by admin]
-
It's interesting, I kind of want to know more about what exactly the cause of the problem is.
-
I'm not sure that this is someone interested in (we got a conversation with himself), but I found the problem. Not sure of the differences, but in my case, code keys - in the international part of the SDLK code table.
I thought that this might be the problem. However, in that case it's key map related, and you mentioned in the initial post that you had already tried a standard US map. So my guess is that you actually weren't using the proper key map, or you changed it after you had already started the game (in which case SDL didn't know about it).
Your patch isn't really a general fix though, so it can't go into SVN. That key layout would really only be valid for the keyboard map/setup that you are using. And unfortunately proper support for a non en-US key map requires a nice sized rewrite to work properly.
-
I held a small experiment:
1. Put the US keymap only, leaving only the English language in regional settings. Reboot. The original build without my patch is working properly.
2. Set key maps to US and Russian-PC. Language: English. Reboot. The original build without the patch is working properly.
3. Key maps: US + Russian-PC. Language: English, but sort order - Russian. Reboot. The original build without the patch works well again.
4. And now, interesting. Key map: US only. Language: Russian first, English at the second position. Reboot. The original build without the patch does NOT work as needed.
So I tried to install languages instead Russian. Discovered that the original version works in all cases, except for the languages on the basis of the Cyrillic alphabet. Ie Turkish, Greek, Japanese, Farsi, etc - everything works well. If, however, put the Russian, Ukrainian, Bulgarian, Serbian - there is a problem. Test system does not include any layout, except the US.
Thus (absolutely incomprehensible to me) the problem arises only when the main interface on the basis of the Cyrillic alphabet.
Now about the patch. Actually, I do not see the options under which he can do much harm. If you use this option, the primary FS2 scan codes table does not change in any way, only the additional SDLtoFS2 array elements are initialized.
And I see about it problem at least once when dig at Google - but it was under Linux.
But, of course, include it in the main tree or not - this is your case as a team of developers. I was curious to figure out why it does not work - I understand it now, and I can play now. :-)
Incidentally, there is a description of how to build for the WC Saga and Beyond the Red Line? I would like to see these modes too.
-
And I forgot to clean up some debug code from the patch. :nervous:
-
I wondered what that printf() was doing there. :)
-
Incidentally, there is a description of how to build for the WC Saga and Beyond the Red Line? I would like to see these modes too.
the difference for WCSaga is that the preferences are stored in <your home folder>"/Library/WCS Prologue" on MacOS X
the define is in code/osapi/osregistry_unix.cpp
HTH