0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

【Unity】PlayerInput(InputSystem)でマウスからGamePad操作に切り替わらない問題

Posted at

環境
Unity2021.3.6
Windows
GamepadはXboxコン
 
問題
・New InputSystemでマウスキーボード、ゲームパッドを切り替えるためにAutoSwitchを使っている
・ゲームパッド用にバーチャルマウスを使用している
・この時ゲームパッドにSchemeを切り替えた後(バーチャルマウス等で)エディタ外にカーソルがでると、マウスだけではCurrentSchemeのオートスイッチができない
 
結論
おそらくバグではなく仕様だから諦める
エディタをゲームウインドウと別のソフトと考えるならゲームウインドウ外に出た時点で、エディタ全体がUnityというソフトになっているので、ウインドウ上で入力してもゲームへの入力として識別されない
結果、Schemeが切り替わらない
 
対処
キーボード等で入力すれば切り替え可能(Actionの登録は不要)
使用しているMapのActionにマウスのActionを登録しても変わらない
たぶん実機上では起こらないので、あまり気にしなくてもいい

0
0
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
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?