Skip to content

Instantly share code, notes, and snippets.

@takashicompany
Last active August 29, 2015 14:02
Show Gist options
  • Save takashicompany/5e95cc66447b5c10a650 to your computer and use it in GitHub Desktop.
Save takashicompany/5e95cc66447b5c10a650 to your computer and use it in GitHub Desktop.
int layerMask = 1 << 8;
// PlayerレイヤーにあるオブジェクトとRayが相互作用するか判定します。
if (Physics.Raycast(transform.position,Vector3.down,Mathf.Infinity,layerMask))
{
Debug.Log("RayがGroundに当たりました");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment