TruWorlds

PhysicsInstance

Inherits: DynamicInstance

Properties

Anchored boolean
AngularVelocity Vector3
AssemblyLocalOffset CMatrix
CanCollide boolean
local ghost = new Part()
ghost.CanCollide = false
ghost.Transparency = 0.5
ghost.Parent = world
LinearVelocity Vector3
local ball = new Part()
ball.Shape = PartShape.Ball
ball.Parent = world
ball.LinearVelocity = Vector3(0, 50, 0)
Mass number read-only
Massless boolean
Touching PhysicsInstance[] read-only

Functions

GetTouching() Returns PhysicsInstance[]
local sensor = world.FindFirstChild("Sensor")
if sensor:
    for hit in sensor.GetTouching():
        if hit.IsA("Part"):
            hit.Color = Color3(1, 0, 0)
IsWeldedTo(other: PhysicsInstance) Returns boolean
MakeJoint(other: PhysicsInstance) Returns Weld
local bodyA = world.FindFirstChild("BodyA")
local bodyB = world.FindFirstChild("BodyB")
if bodyA and bodyB:
    local weld = bodyA.MakeJoint(bodyB)
RemoveJoint(other: PhysicsInstance) Returns number
SetNetworkOwner(player: Player)

Signals

TouchEnded Instance
Touched Instance