Supported Events
イベントシステムマネージャー

レイキャスター

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Sumbission failed

For some reason your suggested change could not be submitted. Please try again in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

EventSystemは,現在の入力イベントを送信する必要がある場合にこれを検出する手段が必要であり,これはRaycastersによって提供されます。これらはすべての潜在的なターゲットを収集する画面空間位置を与えられ,それが与えられた位置の下にあるかどうかを把握し,その後,スクリーンに最も近いオブジェクトを返します。提供されるRaycastersにはいくつかの種類があります:

  • GraphicRaycaster - UI要素で使用し,キャンバス上で生かされ,キャンバス内を検索する
  • Physics2DRaycaster - 2D物理要素に使用
  • PhysicsRaycaster - 3D物理要素に使用

Raycasterがシーンに存在し,有効になっている場合には,クエリがInputModuleから発行されるたびにEventSystemを使用します。

複数のRaycastersは,その後使用されている場合,すべてのキャスティングがそれらに対して行う必要があり,その結果は要素への距離に基づいてソートされます。

Supported Events
イベントシステムマネージャー