local gravity = game.Workspace.Part.SpecificGravity gravity = .9999999999999 end
This is not working for me and I don't know why. Can someone help?
First off, you need a BodyForce
. Put that into the brick, and then edit the force so that X and Z are both 0, but Y is the number you need to counteract the gravity of the brick.
ROBLOX's gravity is about 196.2 studs/second^2
. Just like Earth's gravity is 9.81 meters/second^2
The gravity of a brick is measured by its volume. So to find the volume of the Brick, simply multiply its Length by its Width by its Height: Part.Size.X * Part.Size.Y * Part.Size.Z
Finally, you have to counter the gravity of the brick, so you have to multiply the volume of the brick by ROBLOX's gravitational acceleration, and you get this: Part.Size.X * Part.Size.Y * Part.Size.Z * 196.2
.
Once you have all that done, just put edit the BodyForce's force, like so:
local BodyForce = script.Parent.BodyForce local Part = script.Parent BodyForce.force = Vector3.new(0,Part.Size.X * Part.Size.Y * Part.Size.Z * 196.2,0)
Hope this helped!