M MY Multiplayer: Wiki
Side
Kind

setObjectScale

Shared

Changes an object's size, evenly or along each axis.

bool setObjectScale(object object, float scale [, float scaleY = scale, float scaleZ = scale, bool scaleCollision = true])

Parameters

NameTypeDescription
objectobjectThe object.
scalefloatThe scale along x, or along every axis if it is the only number. A vector with all three also works.
scaleYfloatThe scale along y.default scale
scaleZfloatThe scale along z.default scale
scaleCollisionboolWhether the object's collision follows the scale.default true

Returns

true once the scale is set.

On the server, the scale reaches every client.

Example

setObjectScale(ramp, 2) -- twice as big
setObjectScale(sign, 1, 1, 3, false) -- only taller, same collision

See also