C# Class LayerExtensions, GameStartUP

Usefull methods for Layermask
Datei anzeigen Open project: badawe/GameStartUP Class Usage Examples

Public Methods

Method Description
AddToMask ( this original ) : LayerMask

Add the specific layers to the layer mask

IsInLayerMask ( this targetGameObject, LayerMask targetMask ) : bool

Check if the game object fit the layer targetMask

LayerNumbersToMask ( ) : LayerMask

Generate one layermask based on the layers number

NamesToMask ( ) : LayerMask

Method Details

AddToMask() public static method

Add the specific layers to the layer mask
public static AddToMask ( this original ) : LayerMask
original this
return LayerMask

IsInLayerMask() public static method

Check if the game object fit the layer targetMask
public static IsInLayerMask ( this targetGameObject, LayerMask targetMask ) : bool
targetGameObject this
targetMask LayerMask
return bool

LayerNumbersToMask() public static method

Generate one layermask based on the layers number
public static LayerNumbersToMask ( ) : LayerMask
return LayerMask

NamesToMask() public static method

public static NamesToMask ( ) : LayerMask
return LayerMask