GetMass (Function): Difference between revisions

From Legacy Roblox Wiki
Jump to navigationJump to search
>Mindraker
mNo edit summary
>Mr Doom Bringer
No edit summary
Line 1: Line 1:
{{CatUp|Functions}}
The GetMass function returns a [[Number]] value of the object's mass. Currently, all objects in Roblox have a density of 1, which means the GetMass returns the same value as the Volume of the object (size x * size y * size x*). This can be useful to determine more than just the mass of an object, but also the size.
{{Function|
{{Function|
name = GetMass
name = GetMass
|arguments =  
|arguments =  
|returns = [[Float]] ''object mass''
|returns = [[Number]] ''object mass''
|description = Returns a float of the object's mass.
|description = Returns a Number of the object's mass.
|object = [[RBX.lua.FlagStand (Object)|Flagstand]], [[RBX.lua.Part (Object)|Part]], [[RBX.lua.Seat (Object)|Seat]], [[RBX.lua.SpawnLocation (Object)|SpawnLocation]]
|object = [[RBX.lua.FlagStand (Object)|Flagstand]], [[RBX.lua.Part (Object)|Part]], [[RBX.lua.Seat (Object)|Seat]], [[RBX.lua.SpawnLocation (Object)|SpawnLocation]]
|}}
|}}

Revision as of 21:18, 23 March 2010

The GetMass function returns a Number value of the object's mass. Currently, all objects in Roblox have a density of 1, which means the GetMass returns the same value as the Volume of the object (size x * size y * size x*). This can be useful to determine more than just the mass of an object, but also the size.

GetMass( )
Returns Number object mass
Description: Returns a Number of the object's mass.