Here's an interesting problem I need to solve. As part of having worked with the Android Accelerometer I still have the following config:
JOY_X_1 = AccelX
JOY_Y_1 = AccelY
JOY_Z_1 = AccelZ
Running the same code on windows again, I don't have a joystick or accelerometer connected to the laptop, so the console log freaks out constantly giving:
[orxJoystick.c:orxJoystick_GLFW_GetAxisValue():264] Requested joystick ID <0> is not connected.
Which is fair enough. But I want to suppress this.
I did try removing the JOY_?_1 lines from the config and injecting them conditionally in with code when the game starts with:
But that doesn't work because the config has already loaded into memory.
orxConfig_ReloadHistory() does reload the config but still doesn't work.
Not sure what else to try at the moment. There is no way to have optional keys in the config. It would be great if I could set a boolean key in the config that causes a section to load or not.
Though, any way to work this out would be great.