Run it
Copy the script and paste it into your executor.
-- Create the ScreenGui
local screenGui = Instance.new("ScreenGui")
screenGui.Name = "UsernameGui"
screenGui.Parent = game.Players.LocalPlayer:WaitForChild("PlayerGui")
-- Create a frame to hold the TextBox and TextButton
frame = .()
frame.Size = .(, , , )
frame.Position = .(, , , )
frame.BackgroundColor3 = .(, , )
frame.Parent = screenGui
usernameTextBox = .()
usernameTextBox.Name =
usernameTextBox.Size = .(, , , )
usernameTextBox.Position = .(, , , )
usernameTextBox.PlaceholderText =
usernameTextBox.Parent = frame
submitButton = .()
submitButton.Name =
submitButton.Size = .(, , , )
submitButton.Position = .(, , , )
submitButton.Text =
submitButton.Parent = frame
devLabel = .()
devLabel.Size = .(, , , )
devLabel.Position = .(, , , )
devLabel.Text =
devLabel.TextColor3 = .(, , )
devLabel.BackgroundTransparency =
devLabel.Parent = frame
()
username = usernameTextBox.Text
player = .Players:(username)
player
player:()
()
submitButton.MouseButton1Click:(onButtonClick)
userInputService = :()
dragging, dragInput, startPos
(input)
delta = input.Position - dragInput
frame.Position = .(startPos.X.Scale, startPos.X.Offset + delta.X, startPos.Y.Scale, startPos.Y.Offset + delta.Y)
(input)
input.UserInputType == .UserInputType.MouseButton1
dragging =
dragInput = input.Position
startPos = frame.Position
input.Changed:(()
input.UserInputState == .UserInputState.End
dragging =
)
userInputService.InputChanged:((input)
dragging
(input)
)
userInputService.InputBegan:(onInputBegan)
You can this in anygame Enter name after name was full no space