ドキュメント

Unity Engine

Unity Engine

GetLayerMask(params string[])

Get a PhysicsMask for the specified layer name(s).
読み終わるまでの所要時間 1 分最終更新 1ヶ月前

Definition

  • Type: Method
  • Namespace: Unity.U2D.Physics
  • Assembly: UnityEngine.PhysicsCore2DModule

GetLayerMask(string[])

public static PhysicsMask GetLayerMask(params string[] layerNames)

Parameters

layerNames

The layer names (case sensitive) to find a combined physics mask for.

Returns

Type

Description

PhysicsMaskThe combined physics mask associated with the specified layer names or, if not found, PhysicsMask.None will be returned in which case a console warning will also be produced.