I am creating a game in which if at any point an object is touching another object then it needs to stop. Rather than a specific if coll.gameObject.tag == “Enemy” for example is it possible to create a boolean value upon the condition that the player’s object is touching any other object. Just to stipulate it is a 2D game, Thank You.
You search to do it in another way than "coll.gameObject.tag " ?
You can use the IsTouching & IsTouchingLayers calls.
http://docs.unity3d.com/ScriptReference/30_search.html?q=istouching