Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- print("RAN a")
- local player = game.Players.LocalPlayer
- local c = player.Character
- local mouse = player:GetMouse()
- p = Instance.new("ForceField")
- p.Parent = c
- p.Visible = false
- for i,v in pairs(c:GetChildren()) do
- if v.ClassName == ("Part") then
- v.Transparency = 1
- end
- if v.ClassName == ("Accessory") then
- v:Destroy()
- end
- v:Destroy()
- end
- if c:FindFirstChild("Head") ~= nil then
- if c.Head:FindFirstChild("face") ~= nil then
- c.Head.face:Destroy()
- end
- end
- moveup = 0
- movedown = 0
- moveforward = 0
- movebackward = 0
- moveleft = 0
- moveright = 0
- local character = Instance.new("Model")
- character.Parent = game.Workspace
- script.Parent = character
- core = nil
- coreframe = nil
- --GUI
- local screengui = Instance.new("ScreenGui")
- screengui.Parent = player.PlayerGui
- local frame = Instance.new("Frame")
- frame.Parent = screengui
- frame.Size = UDim2.new(1, 0, 1, 0)
- frame.BackgroundTransparency = 1
- local SubmitMessageButton = Instance.new("TextButton")
- SubmitMessageButton.Parent = frame
- SubmitMessageButton.Position = UDim2.new(0, 0, 0.5, 0)
- SubmitMessageButton.Size = UDim2.new(0.05, 0, 0.03, 0)
- SubmitMessageButton.Text = ("Submit Message")
- local TypeMessageBox = Instance.new("TextBox")
- TypeMessageBox.Parent = frame
- TypeMessageBox.Position = UDim2.new(0, 0, 0.47, 0)
- TypeMessageBox.Size = UDim2.new(0.1, 0, 0.03, 0)
- function SubmitMessage()
- local bill = Instance.new("BillboardGui")
- bill.Parent = core
- bill.Adornee = core
- bill.StudsOffset = Vector3.new(0, 3, 0)
- local Message = Instance.new("TextLabel")
- Message.Parent = bill
- Message.BackgroundTransparency = 1
- Message.Text = TypeMessageBox.Text
- Message.TextColor3 = Color3.fromRGB(255,255,255)
- Message.TextStrokeTransparency = 0
- end
- SubmitMessageButton.MouseButton1Down:Connect(SubmitMessage)
- --Generate Character
- local core1 = Instance.new("Part")
- core1.Parent = character
- core1.Material = ("Neon")
- core1.Size = Vector3.new(2,2,1)
- core1.Transparency = 0.3
- core1.Anchored = true
- core1.CanCollide = false
- core = core1
- game.Workspace.Camera.CameraSubject = core
- local head = Instance.new("Part")
- head.Parent = character
- head.Material = ("Neon")
- head.Size = Vector3.new(1,1,1)
- head.Transparency = 0.3
- head.Anchored = true
- head.CanCollide = false
- local larm = Instance.new("Part")
- larm.Parent = character
- larm.Material = ("Neon")
- larm.Size = Vector3.new(1,2,1)
- larm.Transparency = 0.3
- larm.Anchored = true
- larm.CanCollide = false
- local rarm = Instance.new("Part")
- rarm.Parent = character
- rarm.Material = ("Neon")
- rarm.Size = Vector3.new(1,2,1)
- rarm.Transparency = 0.3
- rarm.Anchored = true
- rarm.CanCollide = false
- local lleg = Instance.new("Part")
- lleg.Parent = character
- lleg.Material = ("Neon")
- lleg.Size = Vector3.new(1,2,1)
- lleg.Transparency = 0.3
- lleg.Anchored = true
- lleg.CanCollide = false
- local rleg = Instance.new("Part")
- rleg.Parent = character
- rleg.Material = ("Neon")
- rleg.Size = Vector3.new(1,2,1)
- rleg.Transparency = 0.3
- rleg.Anchored = true
- rleg.CanCollide = false
- local mouth = Instance.new("Part")
- mouth.Parent = character
- mouth.Material = ("Glass")
- mouth.Color = Color3.fromRGB(0, 0, 0)
- mouth.Size = Vector3.new(1.95,0.1,0.05)
- mouth.Transparency = 0
- mouth.Anchored = true
- mouth.CanCollide = false
- --Generate Room
- local RoomHolder = Instance.new("Model")
- RoomHolder.Parent = game.Workspace
- local Room1 = Instance.new("Part")
- Room1.Parent = RoomHolder
- Room1.Position = Vector3.new(20000,20000,20000)
- Room1.Size = Vector3.new(200,1,200)
- Room1.Color = Color3.fromRGB(0, 0, 0)
- Room1.Material = ("Neon")
- Room1.Anchored = true
- local Room2 = Instance.new("Part")
- Room2.Parent = RoomHolder
- Room2.Position = Vector3.new(20000,20100,20000)
- Room2.Size = Vector3.new(200,1,200)
- Room2.Color = Color3.fromRGB(0, 0, 0)
- Room2.Material = ("Neon")
- Room2.Anchored = true
- local Room3 = Instance.new("Part")
- Room3.Parent = RoomHolder
- Room3.Position = Vector3.new(19900,20000,20000)
- Room3.Size = Vector3.new(1,200,200)
- Room3.Color = Color3.fromRGB(0, 0, 0)
- Room3.Material = ("Neon")
- Room3.Anchored = true
- local Room4 = Instance.new("Part")
- Room4.Parent = RoomHolder
- Room4.Position = Vector3.new(20100,20000,20000)
- Room4.Size = Vector3.new(1,200,200)
- Room4.Color = Color3.fromRGB(0, 0, 0)
- Room4.Material = ("Neon")
- Room4.Anchored = true
- local Room5 = Instance.new("Part")
- Room5.Parent = RoomHolder
- Room5.Position = Vector3.new(20000,20000,20100)
- Room5.Size = Vector3.new(200,200,1)
- Room5.Color = Color3.fromRGB(0, 0, 0)
- Room5.Material = ("Neon")
- Room5.Anchored = true
- local Room6 = Instance.new("Part")
- Room6.Parent = RoomHolder
- Room6.Position = Vector3.new(20000,20000,19900)
- Room6.Size = Vector3.new(200,200,1)
- Room6.Color = Color3.fromRGB(0, 0, 0)
- Room6.Material = ("Neon")
- Room6.Anchored = true
- --Movement
- game:GetService("UserInputService").InputBegan:connect(function(input)
- if input.KeyCode == Enum.KeyCode.E then
- moveup = 1
- end
- end)
- game:GetService("UserInputService").InputEnded:connect(function(input)
- if input.KeyCode == Enum.KeyCode.E then
- moveup = 0
- end
- end)
- game:GetService("UserInputService").InputBegan:connect(function(input)
- if input.KeyCode == Enum.KeyCode.Q then
- movedown = 1
- end
- end)
- game:GetService("UserInputService").InputEnded:connect(function(input)
- if input.KeyCode == Enum.KeyCode.Q then
- movedown = 0
- end
- end)
- game:GetService("UserInputService").InputBegan:connect(function(input)
- if input.KeyCode == Enum.KeyCode.W then
- moveforward = 1
- end
- end)
- game:GetService("UserInputService").InputEnded:connect(function(input)
- if input.KeyCode == Enum.KeyCode.W then
- moveforward = 0
- end
- end)
- game:GetService("UserInputService").InputBegan:connect(function(input)
- if input.KeyCode == Enum.KeyCode.S then
- movebackward = 1
- end
- end)
- game:GetService("UserInputService").InputEnded:connect(function(input)
- if input.KeyCode == Enum.KeyCode.S then
- movebackward = 0
- end
- end)
- game:GetService("UserInputService").InputBegan:connect(function(input)
- if input.KeyCode == Enum.KeyCode.A then
- moveleft = 1
- end
- end)
- game:GetService("UserInputService").InputEnded:connect(function(input)
- if input.KeyCode == Enum.KeyCode.A then
- moveleft = 0
- end
- end)
- game:GetService("UserInputService").InputBegan:connect(function(input)
- if input.KeyCode == Enum.KeyCode.D then
- moveright = 1
- end
- end)
- game:GetService("UserInputService").InputEnded:connect(function(input)
- if input.KeyCode == Enum.KeyCode.D then
- moveright = 0
- end
- end)
- game:GetService("UserInputService").InputEnded:connect(function(input)
- if input.KeyCode == Enum.KeyCode.P then
- core.Position = Vector3.new(20000, 20000, 20000)
- end
- end)
- game:GetService("UserInputService").InputEnded:connect(function(input)
- if input.KeyCode == Enum.KeyCode.M then
- mouth.Size = Vector3.new(1000, 1000, 1000)
- end
- end)
- game:GetService("UserInputService").InputBegan:connect(function(input)
- if input.KeyCode == Enum.KeyCode.R then
- local core1 = Instance.new("Part")
- core1.Parent = character
- core1.Material = ("Neon")
- core1.Size = Vector3.new(2,2,1)
- core1.Transparency = 0.3
- core1.Anchored = true
- core1.CanCollide = false
- core = core1
- game.Workspace.Camera.CameraSubject = core
- local head = Instance.new("Part")
- head.Parent = character
- head.Material = ("Neon")
- head.Size = Vector3.new(1,1,1)
- head.Transparency = 0.3
- head.Anchored = true
- head.CanCollide = false
- local larm = Instance.new("Part")
- larm.Parent = character
- larm.Material = ("Neon")
- larm.Size = Vector3.new(1,2,1)
- larm.Transparency = 0.3
- larm.Anchored = true
- larm.CanCollide = false
- local rarm = Instance.new("Part")
- rarm.Parent = character
- rarm.Material = ("Neon")
- rarm.Size = Vector3.new(1,2,1)
- rarm.Transparency = 0.3
- rarm.Anchored = true
- rarm.CanCollide = false
- local lleg = Instance.new("Part")
- lleg.Parent = character
- lleg.Material = ("Neon")
- lleg.Size = Vector3.new(1,2,1)
- lleg.Transparency = 0.3
- lleg.Anchored = true
- lleg.CanCollide = false
- local rleg = Instance.new("Part")
- rleg.Parent = character
- rleg.Material = ("Neon")
- rleg.Size = Vector3.new(1,2,1)
- rleg.Transparency = 0.3
- rleg.Anchored = true
- rleg.CanCollide = false
- local mouth = Instance.new("Part")
- mouth.Parent = character
- mouth.Material = ("Glass")
- mouth.Color = Color3.fromRGB(0, 0, 0)
- mouth.Size = Vector3.new(1.95,0.1,0.05)
- mouth.Transparency = 0
- mouth.Anchored = true
- mouth.CanCollide = true
- end
- end)
- --Eat
- function EatObject(Object)
- print(1)
- if Object.ClassName ~= ("Terrain") then
- if Object.Parent:FindFirstChild("Torso") ~= nil then
- local p = Instance.new("Part")
- p.Position = Vector3.new(20000,20010,20000)
- Object.Parent.Torso.CFrame = p.CFrame
- p:Destroy()
- else
- Object.Position = Vector3.new(20000,20010,20000)
- end
- end
- end
- mouth.Touched:Connect(EatObject)
- function closemouth(Object)
- mouth.Size = Vector3.new(1.95, Object.Size.Y, 0.05)
- for i = 1, Object.Size.Y * 10 do
- wait(0.1)
- mouth.Size = Vector3.new(1.95, i / 10 , 0.05)
- end
- end
- while true do
- wait(0.01)
- if core == nil or core.Parent == nil then
- local core2 = Instance.new("Part")
- core2.Parent = character
- core2.Material = ("Neon")
- core2.Size = Vector3.new(3,3,3)
- core2.Transparency = 0.5
- core2.Anchored = true
- core2.Shape = ("Ball")
- core = core2
- game.Workspace.Camera.CameraSubject = core
- end
- if core.Parent ~= character then
- core.Parent = character
- end
- if moveup == 1 then
- core.CFrame = core.CFrame + core.CFrame.upVector
- end
- if movedown == 1 then
- core.CFrame = core.CFrame - core.CFrame.upVector
- end
- if moveforward == 1 then
- core.CFrame = core.CFrame + core.CFrame.lookVector
- end
- if movebackward == 1 then
- core.CFrame = core.CFrame - core.CFrame.lookVector
- end
- if moveright == 1 then
- core.CFrame = core.CFrame + core.CFrame.rightVector
- end
- if moveleft == 1 then
- core.CFrame = core.CFrame - core.CFrame.rightVector
- end
- co = core.Position
- core.CFrame = mouse.Hit
- core.Position = co
- head.CFrame = core.CFrame + (core.CFrame.upVector * 1.5)
- rarm.CFrame = core.CFrame + (core.CFrame.rightVector * 1.5)
- larm.CFrame = core.CFrame - (core.CFrame.rightVector * 1.5)
- rleg.CFrame = core.CFrame - (core.CFrame.upVector * 2) + (core.CFrame.rightVector * 0.5)
- lleg.CFrame = core.CFrame - (core.CFrame.upVector * 2) - (core.CFrame.rightVector * 0.5)
- mouth.CFrame = core.CFrame + (core.CFrame.lookVector * -0.6)
- if RoomHolder == nil or Room1 == nil or Room2 == nil or Room3 == nil or Room4 == nil or Room5 == nil or Room6 == nil then
- if RoomHolder ~= nil then
- RoomHolder:Destroy()
- end
- local RoomHolder = Instance.new("Model")
- RoomHolder.Parent = game.Workspace
- local Room1 = Instance.new("Part")
- Room1.Parent = RoomHolder
- Room1.Position = Vector3.new(20000,20000,20000)
- Room1.Size = Vector3.new(200,1,200)
- Room1.Color = Color3.fromRGB(0, 0, 0)
- Room1.Material = ("Neon")
- Room1.Anchored = true
- local Room2 = Instance.new("Part")
- Room2.Parent = RoomHolder
- Room2.Position = Vector3.new(20000,20100,20000)
- Room2.Size = Vector3.new(200,1,200)
- Room2.Color = Color3.fromRGB(0, 0, 0)
- Room2.Material = ("Neon")
- Room2.Anchored = true
- local Room3 = Instance.new("Part")
- Room3.Parent = RoomHolder
- Room3.Position = Vector3.new(19900,20000,20000)
- Room3.Size = Vector3.new(1,200,200)
- Room3.Color = Color3.fromRGB(0, 0, 0)
- Room3.Material = ("Neon")
- Room3.Anchored = true
- local Room4 = Instance.new("Part")
- Room4.Parent = RoomHolder
- Room4.Position = Vector3.new(20100,20000,20000)
- Room4.Size = Vector3.new(1,200,200)
- Room4.Color = Color3.fromRGB(0, 0, 0)
- Room4.Material = ("Neon")
- Room4.Anchored = true
- local Room5 = Instance.new("Part")
- Room5.Parent = RoomHolder
- Room5.Position = Vector3.new(20000,20000,20100)
- Room5.Size = Vector3.new(200,200,1)
- Room5.Color = Color3.fromRGB(0, 0, 0)
- Room5.Material = ("Neon")
- Room5.Anchored = true
- local Room6 = Instance.new("Part")
- Room6.Parent = RoomHolder
- Room6.Position = Vector3.new(20000,20000,19900)
- Room6.Size = Vector3.new(200,200,1)
- Room6.Color = Color3.fromRGB(0, 0, 0)
- Room6.Material = ("Neon")
- Room6.Anchored = true
- end
- if core ~= nil then
- coreframe = core.CFrame
- end
- if core == nil then
- local core1 = Instance.new("Part")
- core1.Parent = character
- core1.Material = ("Neon")
- core1.Size = Vector3.new(2,2,1)
- core1.Transparency = 0.5
- core1.Anchored = true
- core1.CanCollide = false
- core1.CFrame = coreframe
- core = core1
- end
- if c:FindFirstChild("ForceField") == nil then
- p = Instance.new("ForceField")
- p.Parent = c
- p.Visible = false
- end
- --c.Humanoid.MaxHealth = math.huge
- --c.Humanoid.Health = math.huge
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement