Transform Component: Difference between revisions

From Pummel Party Mod Documentation
Jump to navigation Jump to search
m (Added to components category)
(Added gif and more information)
Line 1: Line 1:
The Transform Component is the base component of all GameObjects in a mod.  
[[File:TransformComponentExample.gif|thumb|right|600px|Notice how the transform values change when the object is moved, rotated and scaled.]]
The Transform Component is the base component of every [[Gameobject]] in a mod. It defines the position, orientation and scale of the gameobject. These values are relative to the parent gameobject in the hierarchy, or from the world origin if the gameobject doesn't have a parent.
 
== Component Settings ==
== Component Settings ==
[[File:Transform component box.png|frame|none]]
{| class="wikitable"
{| class="wikitable"
|-
|-
! Property !! Description
! Property !! Description
|-
|-
|'''Position''' || The position of the GameObject in the world. From left to right, alters position along the x-axis, y-axis and z-axis.
|'''Position''' || The position of the GameObject relative to its parent. The three values from left to right represent a position on the x-axis, y-axis and z-axis respectively.
|-
|-
| '''Rotation''' || The position of the GameObject in the world. From left to right, rotates around the x-axis, y-axis and z-axis.
| '''Rotation''' || The rotation of the GameObject relative to its parent. The three values from left to right represent a rotation around the x-axis, y-axis and z-axis respectively. These values are in degrees.
|-
|-
| '''Scale''' || The relative scale of the GameObject. From left to right, scales along the GameObject's x-axis, y-axis and z-axis.
| '''Scale''' || The relative scale of the GameObject. The three values from left to right represent relative scaling along the GameObject's x-axis, y-axis and z-axis respectively.
|}
|}


[[Category:Components]]
[[Category:Components]]

Revision as of 22:02, 6 December 2022

Notice how the transform values change when the object is moved, rotated and scaled.

The Transform Component is the base component of every Gameobject in a mod. It defines the position, orientation and scale of the gameobject. These values are relative to the parent gameobject in the hierarchy, or from the world origin if the gameobject doesn't have a parent.

Component Settings

Property Description
Position The position of the GameObject relative to its parent. The three values from left to right represent a position on the x-axis, y-axis and z-axis respectively.
Rotation The rotation of the GameObject relative to its parent. The three values from left to right represent a rotation around the x-axis, y-axis and z-axis respectively. These values are in degrees.
Scale The relative scale of the GameObject. The three values from left to right represent relative scaling along the GameObject's x-axis, y-axis and z-axis respectively.