Hello! I am not an experienced scripter, but I wanted to work on a more advanced Dialogue Gui for my game. I have a part which if you touch it, it activates an event, and then activates the gui script. But the thing is, I don’t like how it just pops up on your screen. I want it to fade and to tween up when appearing, and down when disappearing.
Problem is, I’m new to TweenService.
Here is my current script for the dialogue gui
ServerScriptService
local debounce = false
game.Workspace.Dialogue.Touched:Connect(function(hit) ---when i touch the dialogue block
if not debounce then
debounce = true
if game.Players:GetPlayerFromCharacter(hit.Parent) then
game.ReplicatedStorage.ShowGUI:FireClient(game.Players:GetPlayerFromCharacter(hit.Parent)) ---fires event
end
wait(11)
debounce = false
end
end)
StarterGui
game.ReplicatedStorage.ShowGUI.OnClientEvent:Connect(function() ---starts event
script.Parent.attic.Visible = true
wait(3)
script.Parent.attic.Visible = false
wait()
script.Parent.remember.Visible = true
wait(5)
script.Parent.remember.Visible = false
wait()
script.Parent.obj.Visible = true
wait(3)
script.Parent.obj.Visible = false
wait()
end)
---the "attic" "obj" and such are just the names of the texts
How do you make it so that when you touch a part, instead of it just popping up, it would tween up when appearing and vice versa, and fade in and out?
Hopefully this makes sense