I guys, i'm scripting a garage door that need to go from position in image 1 to image 2 when the sensor (the big transparent box) get touched by a player.
That is the code:
local tweenservice = game:GetService("TweenService")
local garagedoor = script.Parent.Parent
local base = garagedoor.BASE
local tweeninfo = TweenInfo.new(1.5, Enum.EasingStyle.Linear, Enum.EasingDirection.Out, 0, false, 0)
local properties = {Position = Vector3.new(-1334.171, 14.748, 144.9), CFrame.Angles(math.rad(0, -90, -90))}
local tween = tweenservice:Create(base, tweeninfo, properties)
local sensor = garagedoor.sensor
sensor.Touched:Connect(function(otherPart)
tween:Play()
end)
and it do nothing, there's why i'm here.
also gonna upload an image with the folder that contain anything
The part called BASE is a part welded to all the other part of the garage door, and the BASE is anchored.
P.s. the script is contained in the BASE with all the welds