GetObjectModelGroup: Difference between revisions

From Onset Developer Wiki
No edit summary
No edit summary
 
(4 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Info|Function|Client|1.0}}
{{Info|Function|Client|1.0}}


{{FuncDescription|__EDIT_ME__}}
{{FuncDescription|Returns the group name of an object model.}}


{{FuncSyntax|GetObjectModelGroup(model)}}
{{FuncSyntax|GetObjectModelGroup(model)}}


{{FuncParameters}}
{{FuncParameters}}
{{FuncParam|model|__EDIT_ME__}}
{{FuncParam|model|The model identifier from [[Objects]].}}


{{FuncReturnValue|Returns the objects model category as string.}}
{{FuncReturnValue|Returns the objects model category as string.}}
<pre>
General, Buildings, Building Parts, Industrial, Other Parts, Small Items, Walls, Ramps Tubes, Roads, Props, Signs, Nature, Food, Interior, Clothing, Weapons, Specials, Misc
</pre>


== Example ==
== Example ==
__EDIT_ME__
<syntaxhighlight lang="Lua>
local modelId = 455
print("The object model "..modelId.." is part of group "..GetObjectModelGroup(modelId).." objects.")
</syntaxhighlight>


{{RelatedFunctions}}
{{RelatedFunctions}}
__EDIT_ME__
* [[GetObjectCount]]
* [[GetObjectModelCount]]
* [[GetObjectModelName]]
* [[GetStreamedObjects]]
* [[GetObjectModel]]
* [[GetObjectLocation]]
* [[GetObjectRotation]]
* [[GetObjectScale]]
* [[GetObjectBoundingBox]]
* [[GetObjectSize]]
* [[EnableObjectHitEvents]]
* [[GetObjectMass]]
* [[SetObjectEditorSpeed]]
* [[SetObjectEditable]]
* [[SetObjectOutline]]
* [[SetObjectCastShadow]]
* [[SetObjectColor]]
* [[SetObjectEmissiveColor]]
* [[SetObjectTexture]]
* [[SetObjectAnimatedTexture]]

Latest revision as of 16:57, 13 December 2019

GetObjectModelGroup

Type: Function
Context: Client
Introduced: v1.0

Description

Returns the group name of an object model.

Syntax

GetObjectModelGroup(model)

Parameters

  • model
    The model identifier from Objects.

Return Value

  • Returns the objects model category as string.
General, Buildings, Building Parts, Industrial, Other Parts, Small Items, Walls, Ramps Tubes, Roads, Props, Signs, Nature, Food, Interior, Clothing, Weapons, Specials, Misc

Example

local modelId = 455
print("The object model "..modelId.." is part of group "..GetObjectModelGroup(modelId).." objects.")

See also