onElementColShapeHit
Client-side
 Server-side
 Shared
 This event is triggered when an player or vehicle element collides with a colshape.
Parameters
colshape theColShape, bool matchingDimension- theColShape: the colshape that this element collided with.
- matchingDimension: a boolean representing if the element and the colshape are in the same dimension.
Source
element: The source of this event is the player or vehicle that collided with the colshape.
Code Examples
 server   
 This example prints type of the element which entered the created colshape to chatbox.
colArea = createColCircle( 1400.0, -700.0, 5.0 ) -- create the colshape
function elementColShapeHit( colShapeHit )    if colShapeHit == colArea then -- if element entered the created colshape        outputChatBox( getElementType( source ) .. " entered the colCircle!" ) -- print the type of the element to chatbox    endendaddEventHandler( "onElementColShapeHit", root, elementColShapeHit ) -- add a handler function for the eventSee Also
Element Events
- onClientElementColShapeHit
- onClientElementColShapeLeave
- onClientElementDataChange
- onClientElementDestroy
- onClientElementDimensionChange
- onClientElementModelChange
- onClientElementInteriorChange
- onClientElementStreamIn
- onClientElementStreamOut
- onElementClicked
- onElementColShapeHit
- onElementColShapeLeave
- onElementDestroy
- onElementDataChange
- onElementModelChange
- onElementStopSync
- onElementDimensionChange
- onElementStartSync
- onElementInteriorChange
Element Functions
- attachElements
- createElement
- destroyElement
- detachElements
- getAllElementData
- getAttachedElements
- getElementAlpha
- getElementAngularVelocity
- getElementAttachedOffsets
- getElementAttachedTo
- getElementByID
- getElementByIndex
- getElementChild
- getElementChildren
- getElementChildrenCount
- getElementCollisionsEnabled
- getElementDimension
- getElementData
- getElementHealth
- getElementID
- getElementInterior
- getElementMatrix
- getElementModel
- getElementPosition
- getElementRotation
- getElementParent
- getElementType
- getElementVelocity
- getElementsByType
- getElementsWithinRange
- getResourceRootElement
- getRootElement
- hasElementData
- getResourceDynamicElementRoot
- getLowLODElement
- getPedContactElement
- isElement
- isElementAttached
- isElementCallPropagationEnabled
- isElementDoubleSided
- isElementFrozen
- isElementInWater
- isElementLowLOD
- isElementOnFire
- isElementWithinMarker
- setElementAlpha
- setElementAngularVelocity
- setElementAttachedOffsets
- setElementCallPropagationEnabled
- setElementCollisionsEnabled
- setElementData
- setElementDimension
- setElementDoubleSided
- setElementFrozen
- setElementHealth
- setElementInterior
- setElementModel
- setElementOnFire
- setElementID
- setElementParent
- setElementPosition
- setElementRotation
- setElementVelocity
- setLowLODElement
- getElementBoneMatrix
- getElementBonePosition
- getElementBoneQuaternion
- getElementBoneRotation
- getElementBoundingBox
- getElementDistanceFromCentreOfMassToBaseOfModel
- getElementLighting
- getElementRadius
- isElementCollidableWith
- isElementLocal
- isElementOnScreen
- isElementStreamable
- isElementStreamedIn
- isElementSyncer
- isElementWaitingForGroundToLoad
- setElementBoneMatrix
- setElementBonePosition
- setElementBoneQuaternion
- setElementBoneRotation
- setElementCollidableWith
- setElementLighting
- setElementStreamable
- updateElementRpHAnim
- addElementDataSubscriber
- clearElementVisibleTo
- cloneElement
- getElementSyncer
- getElementZoneName
- hasElementDataSubscriber
- isElementVisibleTo
- removeElementData
- removeElementDataSubscriber
- setElementSyncer
- setElementVisibleTo
 
 