basic controller input from JSL

may need compiles for linux and mac
This commit is contained in:
minenice55
2022-07-19 18:50:35 -04:00
parent 86a4f6efcd
commit 6699e7d98b
27 changed files with 1098 additions and 22 deletions

View File

@ -0,0 +1,23 @@
using UnityEngine;
using UnityEngine.UI;
using TMPro;
using HeavenStudio;
using static JSL;
namespace HeavenStudio.Editor
{
public class ControllerSettings : MonoBehaviour
{
[SerializeField] private TMP_Text numConnectedLabel;
[SerializeField] private TMP_Text currentControllerLabel;
public void SearchAndConnectControllers()
{
int connected = PlayerInput.InitJoyShocks();
numConnectedLabel.text = "Connected: " + connected;
//do this better
currentControllerLabel.text = "Current Controller: " + PlayerInput.GetJoyShockName(0);
}
}
}

View File

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 10d59ed8edc40a448a61794f93c74ccd
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant: