Skip to main content

BoxCollider

info

BoxCollider inherits from Collider

A box-shaped primitive collider. Unity BoxCollider

Members

Properties

NameDescription
BoxCollider.centerThe center of the box, measured in the object's local space.
BoxCollider.sizeThe size of the box, measured in the object's local space.

Inherited Members

Inherited Properties

NameDescription
BoxCollider.attachedRigidbodyThe rigidbody the collider is attached to.
BoxCollider.boundsThe world space bounding volume of the collider (Read Only).
BoxCollider.contactOffsetContact offset value of this collider.
BoxCollider.enabledEnabled Colliders will collide with other Colliders, disabled Colliders won't.
BoxCollider.isTriggerIs the collider a trigger?
BoxCollider.materialThe material used by the collider.
BoxCollider.sharedMaterialThe shared physic material of this collider.
BoxCollider.gameObjectThe game object this component is attached to. A component is always attached to a game object.
BoxCollider.tagThe tag of this game object.
BoxCollider.transformThe Transform attached to this GameObject.
BoxCollider.hideFlagsShould the object be hidden, saved with the Scene or modifiable by the user?
BoxCollider.nameThe name of the object.

Inherited Methods

NameDescription
BoxCollider.ClosestPoint(position)Returns a point on the collider that is closest to a given location.
BoxCollider.ClosestPointOnBounds(position)The closest point to the bounding box of the attached collider.
BoxCollider.Raycast(ray, maxDistance)Casts a Ray that ignores all Colliders except this one.
BoxCollider.BroadcastMessage(methodName, parameter=nil)Calls the method named methodName on every Lua Script in this game object or any of its children.
BoxCollider.CompareTag(tag)Is this game object tagged with tag ?
BoxCollider.GetAllLuaScripts()Returns an array of all Lua scripts that attached to the game object.
BoxCollider.GetComponent(type)Returns the component of Type type if the game object has one attached, nil if it doesn't.
BoxCollider.GetComponentInChildren(t)Returns the component of Type type in the GameObject or any of its children using depth first search.
BoxCollider.GetComponentInParent(t)Returns the component of Type type in the GameObject or any of its parents.
BoxCollider.GetComponents(type)Returns all components of Type type in the GameObject.
BoxCollider.GetComponentsInChildren(t)Returns all components of Type type in the GameObject or any of its children.
BoxCollider.GetComponentsInParent(t)Returns all components of Type type in the GameObject or any of its parents.
BoxCollider.SendMessage(methodName, value=nil)Calls the method named methodName on every Lua Script in this game object.
BoxCollider.SendMessageUpwards(methodName, value=nil)Calls the method named methodName on every LuaScript in this game object and on every ancestor of the behaviour.
BoxCollider.TryGetComponent(type)Gets the component of the specified type, if it exists.
BoxCollider.GetInstanceID()Returns the instance id of the object.