mouse controls, fixed texture loading
This commit is contained in:
@@ -31,6 +31,11 @@ static void CallKeyEvent( EInputDeviceType eDevice, EInputButton eButton, bool b
|
||||
g_pHumanDeviceManager->SetButtonUnpressed(eButton);
|
||||
}
|
||||
|
||||
static void CallAxisEvent( EInputDeviceType eDevice, EInputAxis eAxis, float fValue )
|
||||
{
|
||||
g_pHumanDeviceManager->AxisEventRelative(eDevice, eAxis, fValue );
|
||||
}
|
||||
|
||||
extern "C" void __cdecl SteamAPIDebug( ESteamNetworkingSocketsDebugOutputType nType, const char *pszMsg )
|
||||
{
|
||||
V_printf("STEAM: %s\n", pszMsg);
|
||||
@@ -88,6 +93,7 @@ extern "C" void FunnyMain( int argc, char **argv )
|
||||
pWindow = g_pWindowManager->CreateWindow();
|
||||
pWindow->Init();
|
||||
pWindow->SetKeyCallback(CallKeyEvent);
|
||||
pWindow->SetAxisCallback(CallAxisEvent);
|
||||
|
||||
g_pRenderContext = (IRenderContext*)pRenderSystemFactory(RENDER_CONTEXT_INTERFACE_VERSION, NULL);
|
||||
g_pRenderContext->SetMainWindowManager(g_pWindowManager);
|
||||
|
||||
@@ -14,6 +14,7 @@ public:
|
||||
|
||||
virtual void SetButtonPressed( EInputButton eButton ) override;
|
||||
virtual void SetButtonUnpressed( EInputButton eButton ) override;
|
||||
virtual void AxisEventRelative( EInputDeviceType eDevice, EInputAxis eAxis, float fValue ) override;
|
||||
|
||||
virtual void WriteUTF8( uint32_t uCode ) override;
|
||||
|
||||
@@ -83,6 +84,13 @@ void CHumanDeviceManager::SetButtonUnpressed( EInputButton eButton )
|
||||
pInput->OnButton(k_EInputDevice_Keyboard, eButton, false);
|
||||
}
|
||||
|
||||
void CHumanDeviceManager::AxisEventRelative( EInputDeviceType eDevice, EInputAxis eAxis, float fValue )
|
||||
{
|
||||
IHumanDeviceInput *pInput = GetCurrentInput();
|
||||
if (pInput)
|
||||
pInput->OnGameAxisDiff(eDevice, eAxis, fValue);
|
||||
}
|
||||
|
||||
void CHumanDeviceManager::WriteUTF8( uint32_t uCode )
|
||||
{
|
||||
|
||||
|
||||
Reference in New Issue
Block a user