Element: Difference between revisions
Jump to navigation
Jump to search
m (Removed non-element classes from the listing) |
(Removed "client", added "console" and "admin"...) |
||
Line 1: | Line 1: | ||
An element is a generic class that can represent almost all in-game items. | |||
The element types representing in-game entities are: | |||
* [[Element/Player|Players]] | * [[Element/Player|Players]] | ||
* [[Element/Vehicle|Vehicles]] | * [[Element/Vehicle|Vehicles]] | ||
Line 11: | Line 11: | ||
* [[Element/Radar area|Radar areas]] | * [[Element/Radar area|Radar areas]] | ||
* [[Element/Team|Teams]] | * [[Element/Team|Teams]] | ||
* [[Element/Spawnpoint|Spawnpoints]] | * [[Element/Spawnpoint|Spawnpoints]] | ||
* [[Element/Console|Server console]] | |||
* [[Element/Admin|Remote admins]] | |||
Any other element type can be created as an abstract element, not referring to in-game entities. For example, ''resource'' and ''map'' elements are created to group entities they create as their children. | |||
Elements share common functions such as type and list retrieval, a destroy operation to remove both the element and the game entity it is linked to (except for client elements, which can't be destroyed)... | |||
All elements are stored internally in a [[Element tree|"tree" structure]], and as such every element has a parent element, be it the ''root'' element, a ''map'' or another element. This is purely for declaring the scope of function calls. | |||
==Related scripting functions== | |||
===Client=== | |||
{{Client element functions}} | |||
===Server=== | |||
{{Element functions}} |
Revision as of 12:04, 23 August 2007
An element is a generic class that can represent almost all in-game items. The element types representing in-game entities are:
- Players
- Vehicles
- Objects
- Pickups
- Markers
- Collision shapes
- Blips
- Radar areas
- Teams
- Spawnpoints
- Server console
- Remote admins
Any other element type can be created as an abstract element, not referring to in-game entities. For example, resource and map elements are created to group entities they create as their children.
Elements share common functions such as type and list retrieval, a destroy operation to remove both the element and the game entity it is linked to (except for client elements, which can't be destroyed)...
All elements are stored internally in a "tree" structure, and as such every element has a parent element, be it the root element, a map or another element. This is purely for declaring the scope of function calls.
Related scripting functions
Client
- getElementBoneMatrix
- getElementBonePosition
- getElementBoneRotation
- getElementBoundingBox
- getElementDistanceFromCentreOfMassToBaseOfModel
- getElementLighting
- getElementRadius
- isElementCollidableWith
- isElementLocal
- isElementOnScreen
- isElementStreamable
- isElementStreamedIn
- isElementSyncer
- isElementWaitingForGroundToLoad
- setElementBoneMatrix
- setElementBonePosition
- setElementBoneRotation
- setElementCollidableWith
- setElementStreamable
- updateElementRpHAnim
- Shared
- attachElements
- createElement
- destroyElement
- detachElements
- getAttachedElements
- getElementAlpha
- getElementAttachedOffsets
- getElementAttachedTo
- getElementByIndex
- getElementByID
- getElementChild
- getElementChildren
- getElementChildrenCount
- getElementCollisionsEnabled
- getElementColShape
- getElementData
- getAllElementData
- hasElementData
- getElementDimension
- getElementHealth
- getElementID
- getElementInterior
- getElementMatrix
- getElementModel
- getElementParent
- getElementPosition
- getElementRotation
- getElementsByType
- getElementsWithinColShape
- getElementsWithinRange
- getElementType
- getElementVelocity
- getLowLODElement
- getRootElement
- isElement
- isElementAttached
- isElementCallPropagationEnabled
- isElementDoubleSided
- isElementFrozen
- isElementInWater
- isElementLowLOD
- isElementWithinColShape
- isElementWithinMarker
- setElementAlpha
- setElementAngularVelocity
- getElementAngularVelocity
- setElementAttachedOffsets
- setElementCallPropagationEnabled
- setElementCollisionsEnabled
- setElementData
- setElementDimension
- setElementDoubleSided
- setElementFrozen
- setElementHealth
- setElementID
- setElementInterior
- setElementModel
- setElementParent
- setElementPosition
- setElementRotation
- setElementVelocity
- setLowLODElement
- getPedContactElement
- getResourceDynamicElementRoot
- getResourceRootElement
Server
- attachElements
- createElement
- destroyElement
- detachElements
- getAttachedElements
- getElementAlpha
- getElementAttachedOffsets
- getElementAttachedTo
- getElementByIndex
- getElementByID
- getElementChild
- getElementChildren
- getElementChildrenCount
- getElementCollisionsEnabled
- getElementColShape
- getElementData
- getAllElementData
- hasElementData
- getElementDimension
- getElementHealth
- getElementID
- getElementInterior
- getElementMatrix
- getElementModel
- getElementParent
- getElementPosition
- getElementRotation
- getElementsByType
- getElementsWithinColShape
- getElementsWithinRange
- getElementType
- getElementVelocity
- getLowLODElement
- getRootElement
- isElement
- isElementAttached
- isElementCallPropagationEnabled
- isElementDoubleSided
- isElementFrozen
- isElementInWater
- isElementLowLOD
- isElementWithinColShape
- isElementWithinMarker
- setElementAlpha
- setElementAngularVelocity
- getElementAngularVelocity
- setElementAttachedOffsets
- setElementCallPropagationEnabled
- setElementCollisionsEnabled
- setElementData
- setElementDimension
- setElementDoubleSided
- setElementFrozen
- setElementHealth
- setElementID
- setElementInterior
- setElementModel
- setElementParent
- setElementPosition
- setElementRotation
- setElementVelocity
- setLowLODElement
- getPedContactElement
- getResourceDynamicElementRoot
- getResourceRootElement