Empty
Empty
Empty
ReplicatedFirst는 플레이어가 게임에 접속할 때 즉시 전송되어야 하는 자산과 스크립트를 저장하는 특별한 영역입니다. 이는 게임의 나머지 부분이 로드되기 전에 실행됩니다.
Empty
Empty
Empty
게임의 나머지 부분이 여전히 로드되고 있는 동안 플레이어에게 로딩 화면이나 초기 지침을 표시하는 데 사용됩니다.
Empty
Empty
Empty
local ReplicatedFirst = game:GetService("ReplicatedFirst")
local Players = game:GetService("Players")
local player = Players.LocalPlayer
local playerGui = player:WaitForChild("PlayerGui")
local screenGui = Instance.new("ScreenGui")
screenGui.IgnoreGuiInset = true
screenGui.Parent = playerGui
local textLabel = Instance.new("TextLabel", screenGui)
textLabel.Size = UDim2.new(1, 0, 1, 0)
textLabel.BackgroundColor3 = Color3.new(1, 1, 1)
textLabel.Font = Enum.Font.GothamSemibold
textLabel.TextColor3 = Color3.new(0.8, 0.8, 0.8)
textLabel.Text = "Loading...."
textLabel.TextSize = 28
ReplicatedFirst:RemoveDefaultLoadingScreen()
if not game:IsLoaded() then
game.Loaded:Wait()
end
wait(2) -- Minimum wait time to show the screen
screenGui:Destroy()
Roblox Studio