Custom Rigid Body Manipulation
Custom Rigid Body Manipulation
- Removed restrictions for custom rigid bodies.
RigidBody:Rotate()
RigidBody:SetPosition()
- Optimized rigid bodies with CanRotate set to false (Avoided 2 loops in
RigidBody:Update()
andRigidBody:Anchor()
). - Added
RigidBody:SetScale()
method as an alternative toRigidBody:SetSize()
but only for custom rigid bodies.RigidBody:SetScale(scale: number)
- The scale of the default size is 1. Passing in 2 as the scale will double the size of the custom rigid body, etc. Similar to how UDim's scale property works.
RigidBody:SetPosition()
now works with custom rigid bodies.RigidBody:Rotate()
now works with custom rigid bodies.- Fixed bug in
RigidBody:SetSize()
. EarlierRigidBody:SetSize()
changed only the size of the GuiObject and not the point-constraint structure.