Rotate Object
Rotate Object¶
Sets a rotational value on a model or rendered sprite over a specified duration.
Properties¶
System¶
| Name | Explanation | Type |
|---|---|---|
| Duration | The duration to rotate the object over in milliseconds. | Variable or Value |
| Run Asynchronously | Whether the rotation runs asynchronously, allowing subsequent commands to execute without waiting. | Toggle |
| Target | The rendered physics object to rotate. | Physics Object Reference |
| Use As Delta Values | Whether the rotation values are relative to the current rotation instead of absolute. | Toggle |
| X | The rotation value for the X (pitch) axis in degrees. | Variable or Value |
| X (Pitch) | Whether the X (pitch) rotation axis is enabled. | Toggle |
| Y | The rotation value for the Y (yaw) axis in degrees. | Variable or Value |
| Y (Yaw) | Whether the Y (yaw) rotation axis is enabled. | Toggle |
| Z | The rotation value for the Z (roll) axis in degrees. | Variable or Value |
| Z (Roll) | Whether the Z (roll) rotation axis is enabled. | Toggle |
Examples¶
Rotate an Entity on X and Y Axes Over One Second¶
Rotates entity 0 to 45 degrees on the X axis and 90 degrees on the Y axis over 1000 milliseconds.
{"Data":{"Duration":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"1000","VariableIndex":0,"Metadata":null},"IsAsynchronousOperation":false,"IsRelative":false,"IsXEnabled":true,"IsYEnabled":true,"IsZEnabled":false,"Target":{"IsSelf":false,"IsPartyMember":false,"IsEntity":true,"IsUniqueID":false,"IsDoodad":false,"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null}},"X":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"45","VariableIndex":0,"Metadata":null},"Y":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"90","VariableIndex":0,"Metadata":null},"Z":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Animation.RotateObjectCommand"}
Rotate a Doodad Relative to Current Rotation Asynchronously¶
Rotates doodad 0 by 45 degrees on the X axis relative to its current rotation without blocking subsequent commands.
{"Data":{"Duration":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"1000","VariableIndex":0,"Metadata":null},"IsAsynchronousOperation":true,"IsRelative":true,"IsXEnabled":true,"IsYEnabled":false,"IsZEnabled":false,"Target":{"IsSelf":false,"IsPartyMember":false,"IsEntity":false,"IsUniqueID":false,"IsDoodad":true,"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null}},"X":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"45","VariableIndex":0,"Metadata":null},"Y":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"Z":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Animation.RotateObjectCommand"}