Alter Collider
Alter Collider¶
Changes the collider shape and dimensions of a physics object.
Properties¶
System¶
| Name | Explanation | Type |
|---|---|---|
| Depth | The depth of the collider along the Z axis. | Variable or Value |
| Height | The height of the collider along the Y axis. | Variable or Value |
| Points | The vertices that define a convex hull collider shape. Requires at least 3 points. | Vector |
| Shape | The shape of the collider. Valid shapes include sphere, box, and convex hull. | Variable or Value |
| Target | The physics object to target with this command. | Physics Object Reference |
| Width | The width of the collider along the X axis. | Variable or Value |
Examples¶
Set Entity Collider to a Sphere¶
Changes entity 0's collider to a sphere shape with width, height, and depth of 1.
{"Data":{"Depth":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"1","VariableIndex":0,"Metadata":null},"Height":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"1","VariableIndex":0,"Metadata":null},"Points":[],"Shape":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"Width":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"1","VariableIndex":0,"Metadata":null},"Target":{"IsDoodad":0,"IsDoodadOrEntity":1,"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"IsEntity":1,"IsIdentifiedByUniqueID":0,"IsPartyMember":0,"IsSelf":0,"Metadata":null},"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Physics.AlterColliderCommand"}
Set Entity Collider to a Box¶
Changes entity 0's collider to a box shape with width 2, height 3, and depth 1.
{"Data":{"Depth":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"1","VariableIndex":0,"Metadata":null},"Height":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"3","VariableIndex":0,"Metadata":null},"Points":[],"Shape":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"3","VariableIndex":0,"Metadata":null},"Width":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"2","VariableIndex":0,"Metadata":null},"Target":{"IsDoodad":0,"IsDoodadOrEntity":1,"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"IsEntity":1,"IsIdentifiedByUniqueID":0,"IsPartyMember":0,"IsSelf":0,"Metadata":null},"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Physics.AlterColliderCommand"}
Set Entity Collider to a Convex Hull with Points¶
Changes entity 0's collider to a convex hull shape defined by four vertices.
{"Data":{"Depth":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"1","VariableIndex":0,"Metadata":null},"Height":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"1","VariableIndex":0,"Metadata":null},"Points":["0,0,0","1,0,0","0,1,0","0,0,1"],"Shape":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"4","VariableIndex":0,"Metadata":null},"Width":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"1","VariableIndex":0,"Metadata":null},"Target":{"IsDoodad":0,"IsDoodadOrEntity":1,"Identifier":{"IsGlobalVariable":false,"IsLocalVariable":false,"IsValue":true,"Value":"0","VariableIndex":0,"Metadata":null},"IsEntity":1,"IsIdentifiedByUniqueID":0,"IsPartyMember":0,"IsSelf":0,"Metadata":null},"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Physics.AlterColliderCommand"}