From 3239fc16aee8fea9138e815b005c416d631ad213 Mon Sep 17 00:00:00 2001 From: n00btube3D <54535183+n00btube3D@users.noreply.github.com> Date: Thu, 30 Mar 2023 20:50:17 +0800 Subject: [PATCH] Fix Linux Playback/Keyboard Bug (#373) --- Assets/Scripts/InputSystem/PlayerInput.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Assets/Scripts/InputSystem/PlayerInput.cs b/Assets/Scripts/InputSystem/PlayerInput.cs index 265c112a..27c15a22 100644 --- a/Assets/Scripts/InputSystem/PlayerInput.cs +++ b/Assets/Scripts/InputSystem/PlayerInput.cs @@ -87,8 +87,8 @@ namespace HeavenStudio public static InputController GetInputController(int player) { - // Needed so Keyboard works on MacOS - #if UNITY_STANDALONE_OSX || UNITY_EDITOR_OSX + // Needed so Keyboard works on MacOS and Linux + #if UNITY_STANDALONE_OSX || UNITY_EDITOR_OSX || UNITY_EDITOR_LINUX || UNITY_STANDALONE_LINUX inputDevices = new List(); if(inputDevices.Count < 1) { @@ -119,8 +119,8 @@ namespace HeavenStudio //controller IDs are determined by connection order (the Keyboard is always first) - // Needed so Keyboard works on MacOS - #if UNITY_STANDALONE_OSX || UNITY_EDITOR_OSX + // Needed so Keyboard works on MacOS and Linux + #if UNITY_STANDALONE_OSX || UNITY_EDITOR_OSX || UNITY_EDITOR_LINUX || UNITY_STANDALONE_LINUX inputDevices = new List(); if(inputDevices.Count < 1) { @@ -142,8 +142,8 @@ namespace HeavenStudio public static void UpdateInputControllers() { - // Needed so Keyboard works on MacOS - #if UNITY_STANDALONE_OSX || UNITY_EDITOR_OSX + // Needed so Keyboard works on MacOS and Linux + #if UNITY_STANDALONE_OSX || UNITY_EDITOR_OSX || UNITY_EDITOR_LINUX || UNITY_STANDALONE_LINUX inputDevices = new List(); if(inputDevices.Count < 1) {