Universal Script 📌
10.2k Views
22 Executions
Key System

Key system script

Universal Script 📌
indonesiangamer777
indonesiangamer777Published 10
3 years ago
Get an executor
Please login to perform these actions:

Does it work?

No reports yet

No reports yet. Tried it? Be the first to say.

Also noticed:

Description

Key system script for all of you who need a key system script

Updates

  1. Script edited: Create script

View Raw
-- Create a GUI for the key system
local keyGui = Instance.new("ScreenGui")
keyGui.Name = "KeyGui"
keyGui.Parent = game.Players.LocalPlayer:WaitForChild("PlayerGui")

-- Create a frame for the key input
local keyFrame = Instance.new("Frame")
keyFrame.Parent = keyGui
keyFrame.Size = UDim2.new(0.5, 0, 0.5, 0)
keyFrame.Position = UDim2.new(0.25, 0, 0.25, 0)
keyFrame.BackgroundTransparency = 0.5

-- Create a label for the key input
local keyLabel = Instance.new("TextLabel")
keyLabel.Parent = keyFrame
keyLabel.Size = UDim2.new(1, 0, 0.2, 0)
keyLabel.Position = UDim2.new(0, 0, 0, 0)
keyLabel.Text = "Enter the key to unlock it:"

-- Create a text box for the key input
local keyTextBox = Instance.new("TextBox")
keyTextBox.Parent = keyFrame
keyTextBox.Size = UDim2.new(1, 0, 0.2, 0)
keyTextBox.Position = UDim2.new(0, 0, 0.2, 0)
keyTextBox.BackgroundTransparency = 0.5

-- Create a button for submitting the key
local keyButton = Instance.new("TextButton")
keyButton.Parent = keyFrame
keyButton.Size = UDim2.new(1, 0, 0.2, 0)
keyButton.Position = UDim2.new(0, 0, 0.4, 0)
keyButton.BackgroundTransparency = 0.5
keyButton.Text = "Submit"

-- Create a BoolValue to track if the key has been entered correctly
local keyUnlocked = Instance.new("BoolValue")
keyUnlocked.Name = "KeyUnlocked"
keyUnlocked.Parent = keyGui
keyUnlocked.Value = false



Comments

0
Log in to join the conversation. Login
No comments yet. Be the first!

Tags

More universal scripts

See all
Universal Script 📌
48.4k
46.5k
Bumped 2 hours ago
Universal Script 📌
1.4k
1.3k
Bumped 5 hours ago
Universal Script 📌
4.2k
56.4k
Bumped 6 hours ago
Universal Script 📌
7.1k
71.4k
Bumped 6 hours ago
Script hub
3.5M
1.2M
Bumped 7 hours ago
Key System
Universal Script 📌
5.0k
92.0k
Bumped 12 hours ago