LoginSignup
3
2

More than 5 years have passed since last update.

Unityでゲームパッドの接続台数を調べる

Last updated at Posted at 2015-01-18

What's this

Unityでゲームパッドの接続台数を調べる方法。(そのまま)
Input.GetJoystickNames()の戻り値配列の長さを調べれば分かるみたいです。

コード


var controllerNames = Input.GetJoystickNames();

Debug.Log(controllerNames.Length);

見当たらなかったため記事作成。

3
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
2