diff --git a/Source/DisplayClusterInput/Private/DisplayClusterInputDevice.cpp b/Source/DisplayClusterInput/Private/DisplayClusterInputDevice.cpp index 9eff51a9185bdb9f188478ad052338091b2a1136..8d1a3dba6f378ec5516079fff831b389eb27b2bb 100644 --- a/Source/DisplayClusterInput/Private/DisplayClusterInputDevice.cpp +++ b/Source/DisplayClusterInput/Private/DisplayClusterInputDevice.cpp @@ -70,9 +70,9 @@ void FDisplayClusterInputDevice::SendControllerEvents() { for (auto j = 0; j < AxisIndices.Num(); ++j) { - float Value; - InputManager->GetAxis(AxisDeviceIds[i], j, Value); - if (Value != 0.0f) MessageHandler->OnControllerAnalog(AxisIndices[j]->GetFName(), i, Value); + float Value = 0.0f; + InputManager ->GetAxis (AxisDeviceIds[i] , j, Value); + MessageHandler->OnControllerAnalog(AxisIndices [j]->GetFName(), i, Value); } } @@ -82,7 +82,7 @@ void FDisplayClusterInputDevice::SendControllerEvents() { for (auto j = 0; j < ButtonIndices.Num(); ++j) { - bool Pressed, Released; + bool Pressed = false, Released = false; InputManager->WasButtonPressed (ButtonDeviceIds[i], j, Pressed ); InputManager->WasButtonReleased(ButtonDeviceIds[i], j, Released); if (Pressed ) MessageHandler->OnControllerButtonPressed (ButtonIndices[j]->GetFName(), i, false); diff --git a/nDisplayInput.uplugin b/nDisplayInput.uplugin index cb78bd260c05f2a44dc92d133e5474171ca36715..15eca07e4a87c7e3fdfb1d84f9f13a741b38c123 100644 --- a/nDisplayInput.uplugin +++ b/nDisplayInput.uplugin @@ -17,7 +17,7 @@ "Modules": [ { "Name": "DisplayClusterInput", - "Type": "Developer", + "Type": "Runtime", "LoadingPhase": "Default" } ],