#I need help with my Menu GUI script

16 messages · Page 1 of 1 (latest)

naive valeBOT
#

studio** You are now Level 2! **studio

torn burrow
#

Well this sure is a description issue

crude oar
#

Alright so

#

When I hit deploy button

#

and I get into the game

#

My screen is stuck in one spot but I can still move

#

this is the script

#

local tween_frame = script.Parent.Parent.Parent.Parent.tween_frame
local tweenservice = game:GetService('TweenService')
local tweenin = tweenservice:Create(tween_frame,TweenInfo.new(1),{BackgroundTransparency = 0})
local tweenout = tweenservice:Create(tween_frame,TweenInfo.new(1),{BackgroundTransparency = 1})
local Camera = workspace.CurrentCamera

script.Parent.MouseButton1Click:Connect(function()
tweenin:Play()
tweenin.Completed:Connect(function(playbackstate)
if playbackstate == Enum.PlaybackState.Completed then
tweenout:Play()
script.Parent.Parent.Parent.Parent.main_frame.Visible = false
tweenservice:Create(game:GetService('Lighting').Blur,TweenInfo.new(1),{Size = 0}):Play()
game.Players.LocalPlayer.Character.Humanoid.WalkSpeed = 16
Camera.CameraType = Enum.CameraType.Custom

    end
end)

end)

torn burrow
#

So I can read the code a tad better

crude oar
#

How do u want me to help dm me?

sacred vapor
# torn burrow
local tween_frame = script.Parent.Parent.Parent.Parent.tween_frame
local tweenservice = game:GetService('TweenService')
local tweenin = tweenservice:Create(tween_frame,TweenInfo.new(1),{BackgroundTransparency = 0})
local tweenout = tweenservice:Create(tween_frame,TweenInfo.new(1),{BackgroundTransparency = 1})
local Camera = workspace.CurrentCamera

script.Parent.MouseButton1Click:Connect(function()
    tweenin:Play()
    tweenin.Completed:Connect(function(playbackstate)
        if playbackstate == Enum.PlaybackState.Completed then
            tweenout:Play()
            script.Parent.Parent.Parent.Parent.main_frame.Visible = false
            tweenservice:Create(game:GetService('Lighting').Blur,TweenInfo.new(1),{Size = 0}):Play()
            game.Players.LocalPlayer.Character.Humanoid.WalkSpeed = 16
            Camera.CameraType = Enum.CameraType.Custom
            
        end
    end)
end)

there u go picky

warped shell
#

do you not want to be able to move?

torn burrow
#

@crude oar .Completed is an event, so it cannot be used in an if else, this also makes it so your cameratype never gets set to custom

#

oh wait, nevermind read that wrong

#

but I would still just use tweenin.Completed:Wait() over a function