Hello, I’m trying to achieve a replica of the well known Splash text that is one of Minecraft’s neat features!
Minecraft Splash Text:
What I’m trying to do is add this, but only the animation. In the title screen of Minecraft, this text sort of slowly goes closer and farther. Sort of like a pulse going in and out.
I’m here to ask, how should I go about this? What are my options, methods, and different ways to make this possible? Thank you!
You could set the text’s AnchorPoint to (.5, .5) and then you can use TweenService to smoothly animate it’s size, example for that below:
local tween_service = game:GetService("TweenService")
local someText = script.Parent --//Path to the text
local function Animate_Title(txt)
local original_size = txt.Size
local tween_info = TweenInfo.new(3, Enum.EasingStyle.Linear) --//First parameter is the time of the tween
local fade_out = tween_service:Create(txt, tween_info, {Size = original_size - UDim2.new(0, 20, 0, 20)})
local fade_in = tween_service:Create(txt, tween_info, {Size = original_size + UDim2.new(0, 20, 0, 20)})
fade_out:Play()
fade_out.Completed:Connect(function()
fade_in:Play()
end)
fade_in.Completed:Connect(function()
fade_out:Play()
end)
end
Animate_Title(someText)
I don’t know what all the animations look like but I usually just use sine and linear, you would probably just want to experiment with them and find which looks the best. For tween direction you would want to use inout though.
For future reference I’ll learn to use a function with looping (Tweening) and per character loop to make my titles more fluent with my work. Thank you so much.
You could use GuiObject:TweenSize to tween it’s size.
local GuiObject = script.Parent -- Change the value to the desired GuiObject you want to tween.
local function callbackFunction()
GuiObject:TweenSize(size_you_want_in_UDim2, Enum.EasingDirection.InOut, Enum.EasingStyle.Linear, 0.5, true, startTween)
end
local function startTween()
GuiObject:TweenSize(size_you_want_in_UDim2, Enum.EasingDirection.InOut, Enum.EasingStyle.Linear, 0.5, true, callbackFunction)
end
startTween()