コガネブログ

平日更新を目標に Unity や C#、Visual Studio、ReSharper などのゲーム開発アレコレを書いていきます

【Unity】Multiple targets with name 'Unity Editor' running.

概要

f:id:baba_s:20211009203834p:plain

Multiple targets with name 'Unity Editor' running.
Unable to connenct.
Use "Unity Attach Debugger" from the command palette
(View > Command Palette...) to specify which process to attach to.

VSCode で Unity のデバッグを開始しようとしたら上記のエラーが出た

f:id:baba_s:20211009203859p:plain

タスクマネージャーの「詳細」タブを開いてみたら
Unity を 1 つしか起動していないのに「Unity.exe」か 2 つ存在した

Unity を再起動したら「Unity.exe」が 1 つになり、前述のエラーが出なくなった