Summon AI player GUI
Key RequiredUniversal

Summon AI player GUI

Universal Scriptmscript32mscript32 3.2K views 45 executesUpdated Jan 12, 2025
Unrated
00
Lua Script•145 lines (4731 chars)
-- Create ScreenGui
local summonHub = Instance.new("ScreenGui")
summonHub.Name = "SummonHub"
summonHub.Parent = game.Players.LocalPlayer:WaitForChild("PlayerGui")
summonHub.ResetOnSpawn = false

-- Create Key Frame
local keyFrame = Instance.new("Frame")
keyFrame.Name = "KeyFrame"
keyFrame.Parent = summonHub
keyFrame.BackgroundColor3 = Color3.fromRGB(45, 45, 45)
keyFrame.BorderSizePixel = 0
keyFrame.Size = UDim2.new(0, 300, 0, 150)
keyFrame.Position = UDim2.new(0.5, -150, 0.5, -75)
keyFrame.Active = true
keyFrame.Draggable = true

-- Key Title
local keyTitle = Instance.new("TextLabel")
keyTitle.Name = "KeyTitle"
keyTitle.Parent = keyFrame
keyTitle.BackgroundColor3 = Color3.fromRGB(35, 35, 35)
keyTitle.Size = UDim2.new(1, 0, 0, 30)
keyTitle.Font = Enum.Font.SourceSansBold
keyTitle.Text = "Enter Key to Proceed"
keyTitle.TextColor3 = Color3.fromRGB(255, 255, 255)
keyTitle.TextSize = 20

-- Key Textbox
local keyBox = Instance.new("TextBox")
keyBox.Name = "KeyBox"
keyBox.Parent = keyFrame
keyBox.BackgroundColor3 = Color3.fromRGB(25, 25, 25)
keyBox.Position = UDim2.new(0.1, 0, 0.4, 0)
keyBox.Size = UDim2.new(0.8, 0, 0.3, 0)
keyBox.Font = Enum.Font.SourceSans
keyBox.PlaceholderText = "Enter Key"
keyBox.Text = ""
keyBox.TextColor3 = Color3.fromRGB(255, 255, 255)
keyBox.TextSize = 18

-- Submit Button
local submitButton = Instance.new("TextButton")
submitButton.Name = "SubmitButton"
submitButton.Parent = keyFrame
submitButton.BackgroundColor3 = Color3.fromRGB(25, 25, 25)
submitButton.Position = UDim2.new(0.3, 0, 0.8, 0)
submitButton.Size = UDim2.new(0.4, 0, 0.2, 0)
submitButton.Font = Enum.Font.SourceSansBold
submitButton.Text = "Submit"
submitButton.TextColor3 = Color3.fromRGB(255, 255, 255)
submitButton.TextSize = 18

-- AI Frame (Hidden by Default)
local aiFrame = Instance.new("Frame")
aiFrame.Name = "AIFrame"
aiFrame.Parent = summonHub
aiFrame.BackgroundColor3 = Color3.fromRGB(45, 45, 45)
aiFrame.BorderSizePixel = 0
aiFrame.Size = UDim2.new(0, 300, 0, 150)
aiFrame.Position = UDim2.new(0.5, -150, 0.5, -75)
aiFrame.Visible = false
aiFrame.Active = true
aiFrame.Draggable = true

-- AI Title
local aiTitle = Instance.new("TextLabel")
aiTitle.Name = "AITitle"
aiTitle.Parent = aiFrame
aiTitle.BackgroundColor3 = Color3.fromRGB(35, 35, 35)
aiTitle.Size = UDim2.new(1, 0, 0, 30)
aiTitle.Font = Enum.Font.SourceSansBold
aiTitle.Text = "Summon AI Player"
aiTitle.TextColor3 = Color3.fromRGB(255, 255, 255)
aiTitle.TextSize = 20

-- Name Textbox
local nameBox = Instance.new("TextBox")
nameBox.Name = "NameBox"
nameBox.Parent = aiFrame
nameBox.BackgroundColor3 = Color3.fromRGB(25, 25, 25)
nameBox.Position = UDim2.new(0.1, 0, 0.4, 0)
nameBox.Size = UDim2.new(0.8, 0, 0.2, 0)
nameBox.Font = Enum.Font.SourceSans
nameBox.PlaceholderText = "Enter AI Name"
nameBox.Text = ""
nameBox.TextColor3 = Color3.fromRGB(255, 255, 255)
nameBox.TextSize = 18

-- Apply Button
local applyButton = Instance.new("TextButton")
applyButton.Name = "ApplyButton"
applyButton.Parent = aiFrame
applyButton.BackgroundColor3 = Color3.fromRGB(25, 25, 25)
applyButton.Position = UDim2.new(0.3, 0, 0.7, 0)
applyButton.Size = UDim2.new(0.4, 0, 0.2, 0)
applyButton.Font = Enum.Font.SourceSansBold
applyButton.Text = "Apply"
applyButton.TextColor3 = Color3.fromRGB(255, 255, 255)
applyButton.TextSize = 18

-- Key System
local validKey = "User91" -- Set the correct key

submitButton.MouseButton1Click:Connect(function()
    if keyBox.Text == validKey then
        -- Hide Key Frame and Show AI Frame
        keyFrame.Visible = false
        aiFrame.Visible = true
    else
        keyBox.Text = "Invalid Key!"
        wait(1)
        keyBox.Text = ""
    end
end)

-- AI System
applyButton.MouseButton1Click:Connect(function()
    local aiName = nameBox.Text

    if aiName and aiName ~= "" then
        -- Clone the StarterCharacter
        local starterCharacter = game:GetService("Players"):CreateHumanoidModelFromUserId(1) -- Bacon Hair avatar
        starterCharacter.Name = aiName
        starterCharacter.Parent = workspace

        -- Position the AI player
        local player = game.Players.LocalPlayer
        local spawnPosition = player.Character and player.Character:FindFirstChild("HumanoidRootPart") and player.Character.HumanoidRootPart.Position + Vector3.new(0, 5, 0) or Vector3.new(0, 5, 0)
        starterCharacter:SetPrimaryPartCFrame(CFrame.new(spawnPosition))

        -- AI Chat
        local function aiRespond(message)
            print(aiName .. ": " .. message) -- Debugging in Output
        end

        game.Players.LocalPlayer.Chatted:Connect(function(message)
            aiRespond(message)
        end)
    else
        nameBox.Text = "Invalid Name!"
        wait(1)
        nameBox.Text = ""
    end
end)

Features & Information

Summon

Community Comments (3)

mscript32mscript32Jan 12, 2025(edited)

Made by chatgpt

mscript32mscript32Jan 12, 2025(edited)

Say to AI bot Hi How are you Bye

mscript32mscript32Jan 13, 2025(edited)

There's a key the key is User91

More Scripts for Universal Scripts