#pick up item system
1 messages · Page 1 of 1 (latest)
1 messages · Page 1 of 1 (latest)
im trying to make it so when a player presses e it checks if they are colliding with a holdable object but i dont know how to check if the player is colliding with a obj with a certain Layer
Check the gameobject api docs page.
if ((layerMask.value & (1 << other.transform.gameObject.layer)) > 0)
Use layer index