Vector3 WorldScale { get; set; }

robot_2Generated
code_blocksInput

Description

The WorldScale property represents the scale of the game object in world coordinates. It is a Vector3 value that defines how much the object is scaled along the X, Y, and Z axes in the world space.

Usage

Use the WorldScale property to get or set the scale of a game object in the world space. This property is useful when you need to adjust the size of an object relative to the world, rather than its local space.

Example

// Example of setting the WorldScale of a component
Component myComponent = new Component();
myComponent.WorldScale = new Vector3(2.0f, 2.0f, 2.0f); // Doubles the size of the object in all directions

// Example of getting the WorldScale of a component
Vector3 currentScale = myComponent.WorldScale;
// Use currentScale for further calculations or logic