engineSetObjectGroupPhysicalProperty | Multi Theft Auto: Wiki Skip to content

engineSetObjectGroupPhysicalProperty

Client-side
Server-side
Shared
Needs checking

This function was partially migrated from the old wiki. Please review manually:

  • Missing section: Properties
  • Missing section: Physical properties
  • Missing section: Damage effect
  • Missing section: Collision Response
  • Missing section: Fx Type
  • Missing section: Break Mode
  • Missing section: Fx Effect

Manual Review Required

Please finish this page using the corresponding Old Wiki article. Go to Contribution guidelines for more information.


This function sets physical property of given properties group.

Syntax

bool engineSetObjectGroupPhysicalProperty ( int groupID, objectgroup-modifiable property, var newValue )
Required Arguments
  • groupID: the id of physical properties group which you wish to set a property of.
  • property: MISSING_PARAM_DESC
  • newValue: new value of the property, with proper type as specified in table below

Returns

  • bool: value

Returns true if everything went well, error is raised otherwise.

Code Examples

shared
function lamppostCollision()
engineSetObjectGroupPhysicalProperty(111, "cause_explosion", true)
end
addEventHandler("onClientResourceStart", resourceRoot, lamppostCollision)
--Every time you hit a lamppost, an explosion will be created

See Also

Engine Functions
Engine Elements