Scripting

Search The Documentation:

  1. Home
  2. Docs
  3. Scripting
  4. Collision
  5. enableCollider

enableCollider

Platform Compatibility

PC Mac OSX Oculus Quest
X X X

Parameters:

  • _tf
    • A boolean if the collider is enabled or not

Example:

1
2
--Enable the collider
obj.enableCollider(true)

More about Triggers and Colliders

Artspark supports two forms of collider shapes: Colliders and Triggers.

Colliders

Colliders are solid and any object obeying the physics engine will automatically be pushed away by them. These are best used for real objects in the play space.

Triggers

Triggers are not solid and can freely pass through all objects. They are best used for detecting objects entering a “zone” or if two objects are about to make contact.

Tags
Was this article helpful to you? Yes No

How can we help?