It would preferable that we talk in discord, due to the urgency and the limits of the devforum. Keep in mind you can still reply here, I value all of your feedback and support. Username: x_ussupport
My goal is this: Click button on surface GUI, part gets tweened to a part (camera is locked to the part which gets tweened), make previous surface GUI disabled, make new surface GUI enabled and repeat. That’s it.
It works the first time I did this but the second time it doesn’t seem to work. Did everything. Tried to up the ZIndex, tried many different methods, but nothing works. Could I get some help here? (nothing in output too)
script #1 (this works for some reason)
script.Parent.MouseButton1Click:Connect(function()
local part = game.Workspace.CameraPart
local TweenService = game:GetService("TweenService")
local tweenInfo = TweenInfo.new(
0.1, --Time
Enum.EasingStyle.Linear, --Easing Style
Enum.EasingDirection.Out --EasingDirection
)
local tween = TweenService:Create(part, tweenInfo, {Position = game.Workspace.target.Position})
tween:Play()
TweenService:Create(
game.Lighting.Blur,
TweenInfo.new(0.2),
{Size = 56}
):Play()
task.wait(0.6)
TweenService:Create(
game.Lighting.Blur,
TweenInfo.new(0.2),
{Size = 0}
):Play()
workspace.places.camerathing.SurfaceGui.Enabled = false
workspace.places.xx.SurfaceGui.Enabled = false
workspace.places.camm.SurfaceGui.Enabled = true
workspace.places.cammm.SurfaceGui.Enabled = true
end)
script #2 (doesn’t work for some reason)
script.Parent.MouseButton1Click:Connect(function()
local part = game.Workspace.CameraPart
local TweenService = game:GetService("TweenService")
local tweenInfo = TweenInfo.new(
0.1, --Time
Enum.EasingStyle.Linear, --Easing Style
Enum.EasingDirection.Out --EasingDirection
)
local tween = TweenService:Create(part, tweenInfo, {Position = game.Workspace.target2.Position})
tween:Play()
TweenService:Create(
game.Lighting.Blur,
TweenInfo.new(0.2),
{Size = 56}
):Play()
task.wait(0.6)
TweenService:Create(
game.Lighting.Blur,
TweenInfo.new(0.2),
{Size = 0}
):Play()
workspace.places.camm.SurfaceGui.Enabled = false
workspace.places.cammm.SurfaceGui.Enabled = false
workspace.places.camm2.SurfaceGui.Enabled = true
workspace.places.cammm2.SurfaceGui.Enabled = true
end)