Advertisement
ERROR_CODE

My nightmare 2

Sep 5th, 2023 (edited)
1,103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 185.05 KB | None | 0 0
  1. --[[if game.PlaceId ~= 15506075243 then
  2. local ScreenGui1 = Instance.new("ScreenGui")
  3. local QuestionFrame = Instance.new("Frame")
  4. local QuestionLabel = Instance.new("TextLabel")
  5. local QuestionLabelUICorner = Instance.new("UICorner")
  6. local QuestionFrameUICorner = Instance.new("UICorner")
  7. local TextLabel = Instance.new("TextLabel")
  8. local TextLabelUICorner = Instance.new("UICorner")
  9. local YesButton = Instance.new("TextButton")
  10. local YesButtonUICorner = Instance.new("UICorner")
  11. local NoButton = Instance.new("TextButton")
  12. local NoButtonUICorner = Instance.new("UICorner")
  13. local Blur = Instance.new("BlurEffect")
  14. Blur.Parent = game:GetService("Lighting")
  15.  
  16. Blur.Size = 100
  17.  
  18. ScreenGui1.Parent = game.CoreGui
  19.  
  20. QuestionFrame.Parent = ScreenGui1
  21. QuestionFrame.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
  22. QuestionFrame.Position = UDim2.new(0.3, 0, 0.2, 0)
  23. QuestionFrame.Size = UDim2.new(0, 400, 0, 250)
  24.  
  25. QuestionLabel.Name = "QuestionLabel"
  26. QuestionLabel.Parent = QuestionFrame
  27. QuestionLabel.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  28. QuestionLabel.Size = UDim2.new(0, 400, 0, 25)
  29. QuestionLabel.Font = Enum.Font.IndieFlower
  30. QuestionLabel.Text = "Teleport?"
  31. QuestionLabel.TextColor3 = Color3.fromRGB(0, 0, 0)
  32. QuestionLabel.TextSize = 30
  33.  
  34. QuestionFrameUICorner.Parent = QuestionFrame
  35.  
  36. QuestionLabelUICorner.Parent = QuestionLabel
  37.  
  38. TextLabel.Name = "TextLabel"
  39. TextLabel.Parent = QuestionFrame
  40. TextLabel.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
  41. TextLabel.Position = UDim2.new(0.05, 0, 0.1, 0)
  42. TextLabel.Size = UDim2.new(0, 350, 0, 150)
  43. TextLabel.Font = Enum.Font.IndieFlower
  44. TextLabel.Text = "When you click on the 'Yes' button, you will be teleported to the game 'For Visual Scripts'. After teleporting into the game, restart the script."
  45. TextLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
  46. TextLabel.TextSize = 30
  47. TextLabel.TextWrapped = true
  48. TextLabel.TextScaled = true
  49.  
  50. TextLabelUICorner.Parent = TextLabel
  51.  
  52. NoButton.Name = "NoButton"
  53. NoButton.Parent = QuestionFrame
  54. NoButton.BackgroundColor3 = Color3.fromRGB(255, 0, 0)
  55. NoButton.Position = UDim2.new(0.07, 0, 0.7, 0)
  56. NoButton.Size = UDim2.new(0, 125, 0, 50)
  57. NoButton.Font = Enum.Font.IndieFlower
  58. NoButton.Text = "No"
  59. NoButton.TextColor3 = Color3.fromRGB(0, 0, 0)
  60. NoButton.TextScaled = true
  61. NoButton.TextSize = 14.000
  62. NoButton.TextWrapped = true
  63. NoButton.MouseButton1Down:connect(function()
  64. ScreenGui1:Destroy()
  65. Blur.Size = 0
  66. end)
  67. NoButtonUICorner.Parent = NoButton
  68.  
  69. YesButton.Name = "YesButton"
  70. YesButton.Parent = QuestionFrame
  71. YesButton.BackgroundColor3 = Color3.fromRGB(0, 255, 0)
  72. YesButton.Position = UDim2.new(0.6, 0, 0.7, 0)
  73. YesButton.Size = UDim2.new(0, 125, 0, 50)
  74. YesButton.Font = Enum.Font.IndieFlower
  75. YesButton.Text = "Yes"
  76. YesButton.TextColor3 = Color3.fromRGB(0, 0, 0)
  77. YesButton.TextScaled = true
  78. YesButton.TextSize = 14.000
  79. YesButton.TextWrapped = true
  80. YesButton.MouseButton1Down:connect(function()
  81. game.Players.LocalPlayer:Kick("Teleporting...")
  82. wait(5)
  83. local TeleportService = game:GetService("TeleportService")
  84. local PId = 15506075243
  85. TeleportService:Teleport(PId, game.Players.LocalPlayer)
  86. end)
  87. YesButtonUICorner.Parent = YesButton
  88. else]]--
  89. game:GetObjects("rbxassetid://9505234463")[1].Parent = game.Workspace
  90. if loaded then
  91. game.Players.LocalPlayer:Kick("Restart")
  92. local TeleportService = game:GetService("TeleportService")
  93. local Players = game:GetService("Players")
  94. local LocalPlayer = Players.LocalPlayer
  95.  
  96. local Rejoin = coroutine.create(function()
  97.     local Success, ErrorMessage = pcall(function()
  98.         TeleportService:Teleport(game.PlaceId, LocalPlayer)
  99.     end)
  100.  
  101.     if ErrorMessage and not Success then
  102.         warn(ErrorMessage)
  103.     end
  104. end)
  105.  
  106. coroutine.resume(Rejoin)
  107. end
  108. pcall(function()
  109.     getgenv().loaded = true
  110. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = CFrame.new(-1612.68, 0.8, 566.899)
  111. local lighting = game:GetService("Lighting")
  112. lighting.FogEnd = 20
  113. lighting.FogColor = Color3.new(0, 0, 0)
  114. lighting.TimeOfDay = 0
  115. local camera = workspace.CurrentCamera
  116. local player = game.Players.LocalPlayer
  117. local character = player.Character
  118. local humanoid = character.Humanoid
  119. player.CameraMaxZoomDistance = 0.5
  120. camera.FieldOfView = 100
  121. humanoid.CameraOffset = Vector3.new(0, 0, -1)
  122.  
  123.  
  124. for childIndex, child in pairs(character:GetChildren()) do
  125.     if child:IsA("BasePart") and child.Name ~= "Head" then
  126.        
  127.         child:GetPropertyChangedSignal("LocalTransparencyModifier"):Connect(function()
  128.             child.LocalTransparencyModifier = child.Transparency
  129.         end)
  130.        
  131.         child.LocalTransparencyModifier = child.Transparency
  132.        
  133.     end
  134. end
  135.  
  136.  
  137. camera:GetPropertyChangedSignal("CameraSubject"):Connect(function()
  138.     if camera.CameraSubject:IsA("VehicleSeat") then
  139.         camera.CameraSubject = humanoid
  140.     end
  141. end)
  142.  
  143. local CameraPart = Instance.new("Part")
  144. CameraPart.Parent = workspace
  145. CameraPart.Anchored = true
  146. CameraPart.Size = Vector3.new(4, 1, 2)
  147. CameraPart.CanCollide = false
  148. CameraPart.Position = Vector3.new(-1631.281, 525.4, 608.398)
  149. CameraPart.Transparency = 1
  150.  
  151.  
  152. local FakeSoulForPrevPart = Instance.new("Part")
  153. FakeSoulForPrevPart.Parent = workspace
  154. FakeSoulForPrevPart.Anchored = true
  155. FakeSoulForPrevPart.Size = Vector3.new(2, 2, 2)
  156. FakeSoulForPrevPart.CanCollide = true
  157. FakeSoulForPrevPart.Position = Vector3.new(-1633.995, 525.4, 608.514)  
  158. FakeSoulForPrevPart.BrickColor = BrickColor.new("Institutional white")
  159. FakeSoulForPrevPart.Material = "ForceField"
  160. local FakeSoulForPrevPartMesh = Instance.new("SpecialMesh", FakeSoulForPrevPart)
  161. FakeSoulForPrevPartMesh.MeshType = Enum.MeshType.Sphere
  162. local FakeSoulForPrevPartFire = Instance.new("Fire", FakeSoulForPrevPart)
  163. FakeSoulForPrevPartFire.Size = 5
  164. FakeSoulForPrevPartFire.Color = Color3.new(255,255,255)
  165. FakeSoulForPrevPartFire.Heat = 0
  166.  
  167.  
  168.  
  169. local player = game.Players.LocalPlayer
  170. local character = player.Character
  171. local cam = workspace.CurrentCamera
  172. cam.CameraSubject = CameraPart
  173. local plr = game.Players.LocalPlayer
  174. local gui = Instance.new("ScreenGui")
  175. gui.Parent = plr.PlayerGui
  176. gui.ResetOnSpawn = false
  177. local Prev = Instance.new("TextLabel")
  178. Prev.Parent = gui
  179. Prev.BackgroundTransparency = 1
  180. Prev.Size = UDim2.new(2, 0, 2, 0)
  181. Prev.Position = UDim2.new(-0.5, 0, 0 ,-255)
  182. Prev.TextXAlignment = Enum.TextXAlignment.Center
  183. Prev.TextScaled = true
  184. Prev.Text = "My nightmare 2 Awakening"
  185. Prev.TextColor3 = Color3.new(255, 255, 255)
  186. Prev.Font = Enum.Font.IndieFlower
  187. local ScreenGui = Instance.new("ScreenGui")
  188. local PlayFrame = Instance.new("Frame")
  189. local Play = Instance.new("TextButton")
  190. ScreenGui.Parent = game.CoreGui
  191. PlayFrame.Name = "PlayFrame"
  192. PlayFrame.Parent = ScreenGui
  193. PlayFrame.BackgroundColor3 = Color3.new(255, 255, 255)
  194. PlayFrame.BackgroundTransparency = 1
  195. PlayFrame.Position = UDim2.new(0.105540894, 0, 0.778873265, 0)
  196. PlayFrame.Size = UDim2.new(0, 100, 0, 100)
  197. Play.Name = "Play"
  198. Play.Parent = PlayFrame
  199. Play.BackgroundColor3 = Color3.new(0, 0, 0)
  200. Play.BorderSizePixel = 0
  201. Play.Draggable = false
  202. Play.Position = UDim2.new(3, 0, 0, 0)
  203. Play.Size = UDim2.new(0, 155, 0, 95)
  204. Play.Font = Enum.Font.IndieFlower
  205. Play.FontSize = Enum.FontSize.Size48
  206. Play.Text = "Play"
  207. Play.TextColor3 = Color3.new(255, 255, 255)
  208. Play.TextSize = 100
  209. Play.MouseButton1Click:connect(function()
  210. cam.CameraSubject = character
  211. FakeSoulForPrevPart:Destroy()
  212. local L = game:GetService("Lighting") L.ClockTime = 0
  213. --ERROR_CODE'S CHARACTER
  214. game:GetObjects("rbxassetid://15008776812")[1].Parent = game.Workspace
  215. local CharacterPart = Instance.new("Part")
  216. CharacterPart.Parent = workspace
  217. CharacterPart.Anchored = true
  218. CharacterPart.Size = Vector3.new(4.935, 3.902, 4.857)
  219. CharacterPart.CanCollide = true
  220. CharacterPart.Position = Vector3.new(117.134, 1666.5, 133.078)
  221. CharacterPart.Transparency = 1
  222. Play:Destroy()
  223. Prev:Destroy()
  224. function createZombie()
  225. function sandbox(var,func)
  226.     local env = getfenv(func)
  227.     local newenv = setmetatable({},{
  228.         __index = function(self,k)
  229.             if k=="script" then
  230.                 return var
  231.             else
  232.                 return env[k]
  233.             end
  234.         end,
  235.     })
  236.     setfenv(func,newenv)
  237.     return func
  238. end
  239. cors = {}
  240. mas = Instance.new("Model",game:GetService("Lighting"))
  241. Model0 = Instance.new("Model")
  242. Part1 = Instance.new("Part")
  243. SpecialMesh2 = Instance.new("SpecialMesh")
  244. Vector3Value3 = Instance.new("Vector3Value")
  245. Motor6D4 = Instance.new("Motor6D")
  246. Decal5 = Instance.new("Decal")
  247. Sound6 = Instance.new("Sound")
  248. Sound7 = Instance.new("Sound")
  249. Sound8 = Instance.new("Sound")
  250. Sound9 = Instance.new("Sound")
  251. Sound10 = Instance.new("Sound")
  252. Part11 = Instance.new("Part")
  253. Vector3Value12 = Instance.new("Vector3Value")
  254. BodyColors13 = Instance.new("BodyColors")
  255. MeshPart14 = Instance.new("MeshPart")
  256. Vector3Value15 = Instance.new("Vector3Value")
  257. Motor6D16 = Instance.new("Motor6D")
  258. Script17 = Instance.new("Script")
  259. Humanoid18 = Instance.new("Humanoid")
  260. Script19 = Instance.new("Script")
  261. MeshPart20 = Instance.new("MeshPart")
  262. Vector3Value21 = Instance.new("Vector3Value")
  263. Motor6D22 = Instance.new("Motor6D")
  264. MeshPart23 = Instance.new("MeshPart")
  265. Vector3Value24 = Instance.new("Vector3Value")
  266. Motor6D25 = Instance.new("Motor6D")
  267. MeshPart26 = Instance.new("MeshPart")
  268. Vector3Value27 = Instance.new("Vector3Value")
  269. Motor6D28 = Instance.new("Motor6D")
  270. MeshPart29 = Instance.new("MeshPart")
  271. Vector3Value30 = Instance.new("Vector3Value")
  272. Motor6D31 = Instance.new("Motor6D")
  273. MeshPart32 = Instance.new("MeshPart")
  274. Vector3Value33 = Instance.new("Vector3Value")
  275. Motor6D34 = Instance.new("Motor6D")
  276. MeshPart35 = Instance.new("MeshPart")
  277. Vector3Value36 = Instance.new("Vector3Value")
  278. Motor6D37 = Instance.new("Motor6D")
  279. MeshPart38 = Instance.new("MeshPart")
  280. Vector3Value39 = Instance.new("Vector3Value")
  281. Motor6D40 = Instance.new("Motor6D")
  282. MeshPart41 = Instance.new("MeshPart")
  283. Vector3Value42 = Instance.new("Vector3Value")
  284. Motor6D43 = Instance.new("Motor6D")
  285. Script44 = Instance.new("Script")
  286. MeshPart45 = Instance.new("MeshPart")
  287. Vector3Value46 = Instance.new("Vector3Value")
  288. Motor6D47 = Instance.new("Motor6D")
  289. MeshPart48 = Instance.new("MeshPart")
  290. Vector3Value49 = Instance.new("Vector3Value")
  291. Motor6D50 = Instance.new("Motor6D")
  292. MeshPart51 = Instance.new("MeshPart")
  293. Vector3Value52 = Instance.new("Vector3Value")
  294. Motor6D53 = Instance.new("Motor6D")
  295. MeshPart54 = Instance.new("MeshPart")
  296. Vector3Value55 = Instance.new("Vector3Value")
  297. Motor6D56 = Instance.new("Motor6D")
  298. MeshPart57 = Instance.new("MeshPart")
  299. Vector3Value58 = Instance.new("Vector3Value")
  300. Motor6D59 = Instance.new("Motor6D")
  301. Script60 = Instance.new("Script")
  302. Script61 = Instance.new("Script")
  303. Script62 = Instance.new("Script")
  304. StringValue63 = Instance.new("StringValue")
  305. StringValue64 = Instance.new("StringValue")
  306. Animation65 = Instance.new("Animation")
  307. StringValue66 = Instance.new("StringValue")
  308. Animation67 = Instance.new("Animation")
  309. StringValue68 = Instance.new("StringValue")
  310. Animation69 = Instance.new("Animation")
  311. NumberValue70 = Instance.new("NumberValue")
  312. Animation71 = Instance.new("Animation")
  313. NumberValue72 = Instance.new("NumberValue")
  314. StringValue73 = Instance.new("StringValue")
  315. Animation74 = Instance.new("Animation")
  316. StringValue75 = Instance.new("StringValue")
  317. Animation76 = Instance.new("Animation")
  318. StringValue77 = Instance.new("StringValue")
  319. Animation78 = Instance.new("Animation")
  320. StringValue79 = Instance.new("StringValue")
  321. Animation80 = Instance.new("Animation")
  322. StringValue81 = Instance.new("StringValue")
  323. Animation82 = Instance.new("Animation")
  324. StringValue83 = Instance.new("StringValue")
  325. Animation84 = Instance.new("Animation")
  326. Script85 = Instance.new("Script")
  327. Model0.Name = "Zombie"
  328. Model0.Parent = mas
  329. Part1.Name = "Head"
  330. Part1.Parent = Model0
  331. Part1.CFrame = CFrame.new(-0.695644557, 4.56509781, -2.19861078, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  332. Part1.Orientation = Vector3.new(0, 90.1399994, 0)
  333. Part1.Position = Vector3.new(-0.695644557, 4.56509781, -2.19861078)
  334. Part1.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  335. Part1.Color = Color3.new(0.541176, 0.670588, 0.521569)
  336. Part1.Size = Vector3.new(1, 1, 1)
  337. Part1.BottomSurface = Enum.SurfaceType.Smooth
  338. Part1.BrickColor = BrickColor.new("Artichoke")
  339. Part1.TopSurface = Enum.SurfaceType.Smooth
  340. Part1.brickColor = BrickColor.new("Artichoke")
  341. Part1.FormFactor = Enum.FormFactor.Custom
  342. Part1.formFactor = Enum.FormFactor.Custom
  343. SpecialMesh2.Parent = Part1
  344. SpecialMesh2.MeshId = "http://www.roblox.com/asset?id=419776358"
  345. SpecialMesh2.MeshType = Enum.MeshType.FileMesh
  346. Vector3Value3.Name = "OriginalSize"
  347. Vector3Value3.Parent = Part1
  348. Vector3Value3.Value = Vector3.new(1, 1, 1)
  349. Motor6D4.Name = "Neck"
  350. Motor6D4.Parent = Part1
  351. Motor6D4.C0 = CFrame.new(0.000338107347, 0.806032121, -0.015560925, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  352. Motor6D4.C1 = CFrame.new(-2.72095203e-05, -0.565615535, 0.00386685133, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  353. Motor6D4.Part0 = MeshPart14
  354. Motor6D4.Part1 = Part1
  355. Motor6D4.part1 = Part1
  356. Decal5.Parent = Part1
  357. Decal5.Texture = "http://www.roblox.com/asset/?id=174393211"
  358. Sound6.Name = "Moan"
  359. Sound6.Parent = Part1
  360. Sound6.SoundId = "rbxassetid://131060249"
  361. Sound6.Volume = 1
  362. Sound7.Name = "Moan2"
  363. Sound7.Parent = Part1
  364. Sound7.SoundId = "rbxassetid://131060145"
  365. Sound7.Volume = 1
  366. Sound8.Name = "Moan3"
  367. Sound8.Parent = Part1
  368. Sound8.SoundId = "rbxassetid://131060210"
  369. Sound8.Volume = 1
  370. Sound9.Name = "Moan4"
  371. Sound9.Parent = Part1
  372. Sound9.SoundId = "rbxassetid://131138835"
  373. Sound9.Volume = 1
  374. Sound10.Name = "Death"
  375. Sound10.Parent = Part1
  376. Part11.Name = "HumanoidRootPart"
  377. Part11.Parent = Model0
  378. Part11.CFrame = CFrame.new(-0.691856027, 2.32588005, -2.1985929, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  379. Part11.Orientation = Vector3.new(0, 90.1399994, 0)
  380. Part11.Position = Vector3.new(-17.023, 2.4, 237.781)
  381. Part11.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  382. Part11.Transparency = 1
  383. Part11.Size = Vector3.new(2, 2, 1)
  384. Part11.CanCollide = false
  385. Vector3Value12.Name = "OriginalSize"
  386. Vector3Value12.Parent = Part11
  387. Vector3Value12.Value = Vector3.new(2, 2, 1)
  388. BodyColors13.Parent = Model0
  389. BodyColors13.HeadColor = BrickColor.new("Artichoke")
  390. BodyColors13.HeadColor3 = Color3.new(0.541176, 0.670588, 0.521569)
  391. BodyColors13.LeftArmColor = BrickColor.new("Artichoke")
  392. BodyColors13.LeftArmColor3 = Color3.new(0.541176, 0.670588, 0.521569)
  393. BodyColors13.LeftLegColor = BrickColor.new("Burnt Sienna")
  394. BodyColors13.LeftLegColor3 = Color3.new(0.415686, 0.223529, 0.0352941)
  395. BodyColors13.RightArmColor = BrickColor.new("Artichoke")
  396. BodyColors13.RightArmColor3 = Color3.new(0.541176, 0.670588, 0.521569)
  397. BodyColors13.RightLegColor = BrickColor.new("Burnt Sienna")
  398. BodyColors13.RightLegColor3 = Color3.new(0.415686, 0.223529, 0.0352941)
  399. BodyColors13.TorsoColor = BrickColor.new("Burnt Sienna")
  400. BodyColors13.TorsoColor3 = Color3.new(0.415686, 0.223529, 0.0352941)
  401. MeshPart14.Name = "UpperTorso"
  402. MeshPart14.Parent = Model0
  403. MeshPart14.CFrame = CFrame.new(-0.676263928, 3.1934495, -2.19829226, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  404. MeshPart14.Orientation = Vector3.new(0, 90.1399994, 0)
  405. MeshPart14.Position = Vector3.new(-0.676263928, 3.1934495, -2.19829226)
  406. MeshPart14.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  407. MeshPart14.Color = Color3.new(0.156863, 0.498039, 0.278431)
  408. MeshPart14.Size = Vector3.new(2.00029206, 1.60093355, 1.0005368)
  409. MeshPart14.BrickColor = BrickColor.new("Dark green")
  410. MeshPart14.brickColor = BrickColor.new("Dark green")
  411. Vector3Value15.Name = "OriginalSize"
  412. Vector3Value15.Parent = MeshPart14
  413. Vector3Value15.Value = Vector3.new(2.00029206, 1.60093355, 1.0005368)
  414. Motor6D16.Name = "Waist"
  415. Motor6D16.Parent = MeshPart14
  416. Motor6D16.C0 = CFrame.new(0.000280171633, 0.537143946, -0.0142721087, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  417. Motor6D16.C1 = CFrame.new(0.000338107347, -0.463463932, -0.015560925, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  418. Motor6D16.Part0 = MeshPart41
  419. Motor6D16.Part1 = MeshPart14
  420. Motor6D16.part1 = MeshPart14
  421. Script17.Name = "Damage Script"
  422. Script17.Parent = MeshPart14
  423. table.insert(cors,sandbox(Script17,function()
  424. function onTouched(hit)
  425.         local human = hit.Parent:findFirstChild("Humanoid")
  426.         if (human ~= nil) then
  427.                 human.Health = human.Health - 0.5
  428.         end
  429. end
  430. script.Parent.Touched:connect(onTouched)
  431. end))
  432. Humanoid18.Name = "Zombie"
  433. Humanoid18.Parent = Model0
  434. Humanoid18.DisplayDistanceType = Enum.HumanoidDisplayDistanceType.Subject
  435. Humanoid18.Health = 100
  436. Humanoid18.HealthDisplayType = Enum.HumanoidHealthDisplayType.AlwaysOff
  437. Humanoid18.HipHeight = 1.3500000238419
  438. Humanoid18.LeftLeg = MeshPart45
  439. Humanoid18.MaxHealth = 125
  440. Humanoid18.NameOcclusion = Enum.NameOcclusion.NoOcclusion
  441. Humanoid18.RigType = Enum.HumanoidRigType.R15
  442. Humanoid18.RightLeg = MeshPart20
  443. Humanoid18.Torso = Part11
  444. Humanoid18.WalkSpeed = 4
  445. Humanoid18.maxHealth = 100
  446. Script19.Parent = Model0
  447. table.insert(cors,sandbox(Script19,function()
  448. local larm = script.Parent:FindFirstChild("HumanoidRootPart")
  449. local rarm = script.Parent:FindFirstChild("HumanoidRootPart")
  450. local char = script.Parent
  451. local pathFinder = game:GetService("PathfindingService")
  452. local path = pathFinder:CreatePath()
  453.  
  454. function findNearestTorso(pos)
  455.     local list = game.Workspace:children()
  456.     local torso = nil
  457.     local dist = 100
  458.     local temp = nil
  459.     local human = nil
  460.     local temp2 = nil
  461.     for x = 1, #list do
  462.         temp2 = list[x]
  463.         if (temp2.className == "Model") and (temp2 ~= script.Parent) then
  464.             temp = temp2:findFirstChild("HumanoidRootPart")
  465.             human = temp2:findFirstChild("Humanoid")
  466.             if (temp ~= nil) and (human ~= nil) and (human.Health > 0) then
  467.                 if (temp.Position - pos).magnitude < dist then
  468.                     torso = temp
  469.                     dist = (temp.Position - pos).magnitude
  470.                 end
  471.             end
  472.         end
  473.     end
  474.     return torso
  475. end
  476.  
  477. while true do
  478.     wait()
  479.     local target = findNearestTorso(script.Parent.HumanoidRootPart.Position)
  480.     if target ~= nil then
  481.         path:ComputeAsync(char.HumanoidRootPart.Position, target.Position)
  482.  
  483.         for i, wayPoint in pairs(path:GetWaypoints()) do
  484.             char.Zombie:MoveTo(wayPoint.Position)
  485.  
  486.             if wayPoint.Action == Enum.PathWaypointAction.Jump then
  487.                 char.Zombie:ChangeState(Enum.HumanoidStateType.Jumping)
  488.             end
  489.  
  490.             char.Zombie.MoveToFinished:wait(0.0000001)
  491.         end
  492.     end
  493. end
  494.  
  495. end))
  496. MeshPart20.Name = "RightUpperLeg"
  497. MeshPart20.Parent = Model0
  498. MeshPart20.CFrame = CFrame.new(-0.67828238, 1.46466565, -2.69960117, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  499. MeshPart20.Orientation = Vector3.new(0, 90.1399994, 0)
  500. MeshPart20.Position = Vector3.new(-0.67828238, 1.46466565, -2.69960117)
  501. MeshPart20.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  502. MeshPart20.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  503. MeshPart20.Size = Vector3.new(1.00027561, 1.5362649, 1.00092912)
  504. MeshPart20.BrickColor = BrickColor.new("Bright blue")
  505. MeshPart20.CanCollide = false
  506. MeshPart20.brickColor = BrickColor.new("Bright blue")
  507. Vector3Value21.Name = "OriginalSize"
  508. Vector3Value21.Parent = MeshPart20
  509. Vector3Value21.Value = Vector3.new(1.00027561, 1.5362649, 1.00092912)
  510. Motor6D22.Name = "RightHip"
  511. Motor6D22.Parent = MeshPart20
  512. Motor6D22.C0 = CFrame.new(0.505080223, -0.243262246, 0.00102789141, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  513. Motor6D22.C1 = CFrame.new(0.00382620096, 0.484913796, 0.000486815348, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  514. Motor6D22.Part0 = MeshPart41
  515. Motor6D22.Part1 = MeshPart20
  516. Motor6D22.part1 = MeshPart20
  517. MeshPart23.Name = "RightUpperArm"
  518. MeshPart23.Parent = Model0
  519. MeshPart23.CFrame = CFrame.new(-0.685997844, 3.29312539, -3.69646788, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  520. MeshPart23.Orientation = Vector3.new(0, 90.1399994, 0)
  521. MeshPart23.Position = Vector3.new(-0.685997844, 3.29312539, -3.69646788)
  522. MeshPart23.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  523. MeshPart23.Color = Color3.new(0.992157, 0.917647, 0.552941)
  524. MeshPart23.Size = Vector3.new(1.00027633, 1.39554, 1.00025082)
  525. MeshPart23.BrickColor = BrickColor.new("Cool yellow")
  526. MeshPart23.CanCollide = false
  527. MeshPart23.brickColor = BrickColor.new("Cool yellow")
  528. Vector3Value24.Name = "OriginalSize"
  529. Vector3Value24.Parent = MeshPart23
  530. Vector3Value24.Value = Vector3.new(1.00027633, 1.39554, 1.00025082)
  531. Motor6D25.Name = "RightShoulder"
  532. Motor6D25.Parent = MeshPart23
  533. Motor6D25.C0 = CFrame.new(1.25031853, 0.5565539, -0.015560925, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  534. Motor6D25.C1 = CFrame.new(-0.24787569, 0.456878304, -0.00944012403, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  535. Motor6D25.Part0 = MeshPart14
  536. Motor6D25.Part1 = MeshPart23
  537. Motor6D25.part1 = MeshPart23
  538. MeshPart26.Name = "RightLowerLeg"
  539. MeshPart26.Parent = Model0
  540. MeshPart26.CFrame = CFrame.new(-0.678020656, 0.910310864, -2.69960189, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  541. MeshPart26.Orientation = Vector3.new(0, 90.1399994, 0)
  542. MeshPart26.Position = Vector3.new(-0.678020656, 0.910310864, -2.69960189)
  543. MeshPart26.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  544. MeshPart26.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  545. MeshPart26.Size = Vector3.new(1.00027585, 1.48964536, 1.00032854)
  546. MeshPart26.BrickColor = BrickColor.new("Bright blue")
  547. MeshPart26.CanCollide = false
  548. MeshPart26.brickColor = BrickColor.new("Bright blue")
  549. Vector3Value27.Name = "OriginalSize"
  550. Vector3Value27.Parent = MeshPart26
  551. Vector3Value27.Value = Vector3.new(1.00027585, 1.48964536, 1.00032854)
  552. Motor6D28.Name = "RightKnee"
  553. Motor6D28.Parent = MeshPart26
  554. Motor6D28.C0 = CFrame.new(0.00382620096, -0.265086174, 0.000426991843, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  555. Motor6D28.C1 = CFrame.new(0.00382620096, 0.289268613, 0.000145851634, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  556. Motor6D28.Part0 = MeshPart20
  557. Motor6D28.Part1 = MeshPart26
  558. Motor6D28.part1 = MeshPart26
  559. MeshPart29.Name = "RightLowerArm"
  560. MeshPart29.Parent = Model0
  561. MeshPart29.CFrame = CFrame.new(-0.685555518, 2.90703535, -3.69646835, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  562. MeshPart29.Orientation = Vector3.new(0, 90.1399994, 0)
  563. MeshPart29.Position = Vector3.new(-0.685555518, 2.90703535, -3.69646835)
  564. MeshPart29.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  565. MeshPart29.Color = Color3.new(0.992157, 0.917647, 0.552941)
  566. MeshPart29.Size = Vector3.new(1.00027657, 1.26567209, 1.00025082)
  567. MeshPart29.BrickColor = BrickColor.new("Cool yellow")
  568. MeshPart29.CanCollide = false
  569. MeshPart29.brickColor = BrickColor.new("Cool yellow")
  570. Vector3Value30.Name = "OriginalSize"
  571. Vector3Value30.Parent = MeshPart29
  572. Vector3Value30.Value = Vector3.new(1.00027657, 1.26567209, 1.00025082)
  573. Motor6D31.Name = "RightElbow"
  574. Motor6D31.Parent = MeshPart29
  575. Motor6D31.C0 = CFrame.new(0.00214397907, -0.263139546, -0.00944012403, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  576. Motor6D31.C1 = CFrame.new(0.00214457512, 0.122950554, -0.00989595056, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  577. Motor6D31.Part0 = MeshPart23
  578. Motor6D31.Part1 = MeshPart29
  579. Motor6D31.part1 = MeshPart29
  580. MeshPart32.Name = "RightHand"
  581. MeshPart32.Parent = Model0
  582. MeshPart32.CFrame = CFrame.new(-0.680041432, 2.1668787, -3.69776106, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  583. MeshPart32.Orientation = Vector3.new(0, 90.1399994, 0)
  584. MeshPart32.Position = Vector3.new(-0.680041432, 2.1668787, -3.69776106)
  585. MeshPart32.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  586. MeshPart32.Color = Color3.new(0.992157, 0.917647, 0.552941)
  587. MeshPart32.Size = Vector3.new(0.999299049, 0.335255772, 1.00029743)
  588. MeshPart32.BrickColor = BrickColor.new("Cool yellow")
  589. MeshPart32.CanCollide = false
  590. MeshPart32.brickColor = BrickColor.new("Cool yellow")
  591. Vector3Value33.Name = "OriginalSize"
  592. Vector3Value33.Parent = MeshPart32
  593. Vector3Value33.Value = Vector3.new(0.999299049, 0.335255772, 1.00029743)
  594. Motor6D34.Name = "RightWrist"
  595. Motor6D34.Parent = MeshPart32
  596. Motor6D34.C0 = CFrame.new(0.00214457512, -0.682049513, -0.00989595056, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  597. Motor6D34.C1 = CFrame.new(0.000865101814, 0.058106944, -0.0154390335, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  598. Motor6D34.Part0 = MeshPart29
  599. Motor6D34.Part1 = MeshPart32
  600. Motor6D34.part1 = MeshPart32
  601. MeshPart35.Name = "RightFoot"
  602. MeshPart35.Parent = Model0
  603. MeshPart35.CFrame = CFrame.new(-0.677906275, 0.167736173, -2.69441152, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  604. MeshPart35.Orientation = Vector3.new(0, 90.1399994, 0)
  605. MeshPart35.Position = Vector3.new(-0.677906275, 0.167736173, -2.69441152)
  606. MeshPart35.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  607. MeshPart35.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  608. MeshPart35.Size = Vector3.new(1.00063133, 0.335407376, 1.00020337)
  609. MeshPart35.BrickColor = BrickColor.new("Bright blue")
  610. MeshPart35.CanCollide = false
  611. MeshPart35.brickColor = BrickColor.new("Bright blue")
  612. Vector3Value36.Name = "OriginalSize"
  613. Vector3Value36.Parent = MeshPart35
  614. Vector3Value36.Value = Vector3.new(1.00063133, 0.335407376, 1.00020337)
  615. Motor6D37.Name = "RightAnkle"
  616. Motor6D37.Parent = MeshPart35
  617. Motor6D37.C0 = CFrame.new(0.00382620096, -0.710731506, 0.000283418223, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  618. Motor6D37.C1 = CFrame.new(0.00901681185, 0.0318431854, 0.000155551359, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  619. Motor6D37.Part0 = MeshPart26
  620. Motor6D37.Part1 = MeshPart35
  621. Motor6D37.part1 = MeshPart35
  622. MeshPart38.Name = "LeftFoot"
  623. MeshPart38.Parent = Model0
  624. MeshPart38.CFrame = CFrame.new(-0.675512314, 0.167736173, -1.70284736, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  625. MeshPart38.Orientation = Vector3.new(0, 90.1399994, 0)
  626. MeshPart38.Position = Vector3.new(-0.675512314, 0.167736173, -1.70284736)
  627. MeshPart38.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  628. MeshPart38.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  629. MeshPart38.Size = Vector3.new(1.00063133, 0.335407257, 1.00020337)
  630. MeshPart38.BrickColor = BrickColor.new("Bright blue")
  631. MeshPart38.CanCollide = false
  632. MeshPart38.brickColor = BrickColor.new("Bright blue")
  633. Vector3Value39.Name = "OriginalSize"
  634. Vector3Value39.Parent = MeshPart38
  635. Vector3Value39.Value = Vector3.new(1.00063133, 0.335407257, 1.00020337)
  636. Motor6D40.Name = "LeftAnkle"
  637. Motor6D40.Parent = MeshPart38
  638. Motor6D40.C0 = CFrame.new(-0.00382620096, -0.710131407, 0.00030554086, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  639. Motor6D40.C1 = CFrame.new(-0.00901681185, 0.032443285, 0.000177569687, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  640. Motor6D40.Part0 = MeshPart51
  641. Motor6D40.Part1 = MeshPart38
  642. Motor6D40.part1 = MeshPart38
  643. MeshPart41.Name = "LowerTorso"
  644. MeshPart41.Parent = Model0
  645. MeshPart41.CFrame = CFrame.new(-0.677587926, 2.19284177, -2.19834709, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  646. MeshPart41.Orientation = Vector3.new(0, 90.1399994, 0)
  647. MeshPart41.Position = Vector3.new(-0.677587926, 2.19284177, -2.19834709)
  648. MeshPart41.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  649. MeshPart41.Color = Color3.new(0.156863, 0.498039, 0.278431)
  650. MeshPart41.Size = Vector3.new(2.00017595, 0.400037616, 1.00021255)
  651. MeshPart41.BrickColor = BrickColor.new("Dark green")
  652. MeshPart41.brickColor = BrickColor.new("Dark green")
  653. Vector3Value42.Name = "OriginalSize"
  654. Vector3Value42.Parent = MeshPart41
  655. Vector3Value42.Value = Vector3.new(2.00017595, 0.400037616, 1.00021255)
  656. Motor6D43.Name = "Root"
  657. Motor6D43.Parent = MeshPart41
  658. Motor6D43.C1 = CFrame.new(0.000280171633, 0.133037761, -0.0142721087, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  659. Motor6D43.Part0 = Part11
  660. Motor6D43.Part1 = MeshPart41
  661. Motor6D43.part1 = MeshPart41
  662. Script44.Name = "Damage Script"
  663. Script44.Parent = MeshPart41
  664. table.insert(cors,sandbox(Script44,function()
  665. function onTouched(hit)
  666.         local human = hit.Parent:findFirstChild("Humanoid")
  667.         if (human ~= nil) then
  668.                 human.Health = human.Health - 0.5
  669.         end
  670. end
  671. script.Parent.Touched:connect(onTouched)
  672. end))
  673. MeshPart45.Name = "LeftUpperLeg"
  674. MeshPart45.Parent = Model0
  675. MeshPart45.CFrame = CFrame.new(-0.675863564, 1.46466565, -1.69765592, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  676. MeshPart45.Orientation = Vector3.new(0, 90.1399994, 0)
  677. MeshPart45.Position = Vector3.new(-0.675863564, 1.46466565, -1.69765592)
  678. MeshPart45.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  679. MeshPart45.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  680. MeshPart45.Size = Vector3.new(1.00027561, 1.5362649, 1.00092912)
  681. MeshPart45.BrickColor = BrickColor.new("Bright blue")
  682. MeshPart45.CanCollide = false
  683. MeshPart45.brickColor = BrickColor.new("Bright blue")
  684. Vector3Value46.Name = "OriginalSize"
  685. Vector3Value46.Parent = MeshPart45
  686. Vector3Value46.Value = Vector3.new(1.00027561, 1.5362649, 1.00092912)
  687. Motor6D47.Name = "LeftHip"
  688. Motor6D47.Parent = MeshPart45
  689. Motor6D47.C0 = CFrame.new(-0.50451982, -0.243062243, 0.00122789107, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  690. Motor6D47.C1 = CFrame.new(-0.00382620096, 0.4851138, 0.000686740503, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  691. Motor6D47.Part0 = MeshPart41
  692. Motor6D47.Part1 = MeshPart45
  693. Motor6D47.part1 = MeshPart45
  694. MeshPart48.Name = "LeftUpperArm"
  695. MeshPart48.Parent = Model0
  696. MeshPart48.CFrame = CFrame.new(-0.678766429, 3.29312539, -0.700763106, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  697. MeshPart48.Orientation = Vector3.new(0, 90.1399994, 0)
  698. MeshPart48.Position = Vector3.new(-0.678766429, 3.29312539, -0.700763106)
  699. MeshPart48.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  700. MeshPart48.Color = Color3.new(0.992157, 0.917647, 0.552941)
  701. MeshPart48.Size = Vector3.new(1.00027633, 1.39554, 1.00025082)
  702. MeshPart48.BrickColor = BrickColor.new("Cool yellow")
  703. MeshPart48.CanCollide = false
  704. MeshPart48.brickColor = BrickColor.new("Cool yellow")
  705. Vector3Value49.Name = "OriginalSize"
  706. Vector3Value49.Parent = MeshPart48
  707. Vector3Value49.Value = Vector3.new(1.00027633, 1.39554, 1.00025082)
  708. Motor6D50.Name = "LeftShoulder"
  709. Motor6D50.Parent = MeshPart48
  710. Motor6D50.C0 = CFrame.new(-1.24955308, 0.556408584, -0.015560925, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  711. Motor6D50.C1 = CFrame.new(0.247964978, 0.456732988, -0.00943991542, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  712. Motor6D50.Part0 = MeshPart14
  713. Motor6D50.Part1 = MeshPart48
  714. Motor6D50.part1 = MeshPart48
  715. MeshPart51.Name = "LeftLowerLeg"
  716. MeshPart51.Parent = Model0
  717. MeshPart51.CFrame = CFrame.new(-0.67560178, 0.910310864, -1.69765651, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  718. MeshPart51.Orientation = Vector3.new(0, 90.1399994, 0)
  719. MeshPart51.Position = Vector3.new(-0.67560178, 0.910310864, -1.69765651)
  720. MeshPart51.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  721. MeshPart51.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  722. MeshPart51.Size = Vector3.new(1.00027585, 1.48964536, 1.00032866)
  723. MeshPart51.BrickColor = BrickColor.new("Bright blue")
  724. MeshPart51.CanCollide = false
  725. MeshPart51.brickColor = BrickColor.new("Bright blue")
  726. Vector3Value52.Name = "OriginalSize"
  727. Vector3Value52.Parent = MeshPart51
  728. Vector3Value52.Value = Vector3.new(1.00027585, 1.48964536, 1.00032866)
  729. Motor6D53.Name = "LeftKnee"
  730. Motor6D53.Parent = MeshPart51
  731. Motor6D53.C0 = CFrame.new(-0.00382620096, -0.264486194, 0.000586740673, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  732. Motor6D53.C1 = CFrame.new(-0.00382620096, 0.289868593, 0.00030554086, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  733. Motor6D53.Part0 = MeshPart45
  734. Motor6D53.Part1 = MeshPart51
  735. Motor6D53.part1 = MeshPart51
  736. MeshPart54.Name = "LeftLowerArm"
  737. MeshPart54.Parent = Model0
  738. MeshPart54.CFrame = CFrame.new(-0.678323925, 2.90703535, -0.700764775, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  739. MeshPart54.Orientation = Vector3.new(0, 90.1399994, 0)
  740. MeshPart54.Position = Vector3.new(-0.678323925, 2.90703535, -0.700764775)
  741. MeshPart54.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  742. MeshPart54.Color = Color3.new(0.992157, 0.917647, 0.552941)
  743. MeshPart54.Size = Vector3.new(1.00027657, 1.26567209, 1.00025082)
  744. MeshPart54.BrickColor = BrickColor.new("Cool yellow")
  745. MeshPart54.CanCollide = false
  746. MeshPart54.brickColor = BrickColor.new("Cool yellow")
  747. Vector3Value55.Name = "OriginalSize"
  748. Vector3Value55.Parent = MeshPart54
  749. Vector3Value55.Value = Vector3.new(1.00027657, 1.26567209, 1.00025082)
  750. Motor6D56.Name = "LeftElbow"
  751. Motor6D56.Parent = MeshPart54
  752. Motor6D56.C0 = CFrame.new(-0.00166511536, -0.263139546, -0.00943991542, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  753. Motor6D56.C1 = CFrame.new(-0.0016657114, 0.122950554, -0.00989592075, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  754. Motor6D56.Part0 = MeshPart48
  755. Motor6D56.Part1 = MeshPart54
  756. Motor6D56.part1 = MeshPart54
  757. MeshPart57.Name = "LeftHand"
  758. MeshPart57.Parent = Model0
  759. MeshPart57.CFrame = CFrame.new(-0.67280364, 2.1668787, -0.699498653, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  760. MeshPart57.Orientation = Vector3.new(0, 90.1399994, 0)
  761. MeshPart57.Position = Vector3.new(-0.67280364, 2.1668787, -0.699498653)
  762. MeshPart57.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  763. MeshPart57.Color = Color3.new(0.992157, 0.917647, 0.552941)
  764. MeshPart57.Size = Vector3.new(0.999299049, 0.335255831, 1.00029743)
  765. MeshPart57.BrickColor = BrickColor.new("Cool yellow")
  766. MeshPart57.CanCollide = false
  767. MeshPart57.brickColor = BrickColor.new("Cool yellow")
  768. Vector3Value58.Name = "OriginalSize"
  769. Vector3Value58.Parent = MeshPart57
  770. Vector3Value58.Value = Vector3.new(0.999299049, 0.335255831, 1.00029743)
  771. Motor6D59.Name = "LeftWrist"
  772. Motor6D59.Parent = MeshPart57
  773. Motor6D59.C0 = CFrame.new(-0.0016657114, -0.682255626, -0.00989592075, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  774. Motor6D59.C1 = CFrame.new(-0.000386238098, 0.0579008311, -0.0154390335, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  775. Motor6D59.Part0 = MeshPart54
  776. Motor6D59.Part1 = MeshPart57
  777. Motor6D59.part1 = MeshPart57
  778. Script60.Name = "Respawn"
  779. Script60.Parent = Model0
  780. table.insert(cors,sandbox(Script60,function()
  781. z = script.Parent
  782.  
  783. backup = z:clone()
  784.  
  785. while true do
  786.     wait(5)
  787.     if z.Zombie.Health == 0 then
  788.         z:Remove()
  789.         wait(4)
  790.         backup.Parent = game.Workspace
  791.         backup.Head:MakeJoints()
  792.         backup.Torso:MakeJoints()
  793.     end
  794.     if z == nil then
  795.         wait(4)
  796.         backup.Parent = game.Workspace
  797.         backup.Head:MakeJoints()
  798.         backup.Torso:MakeJoints()
  799.     end
  800. end
  801. end))
  802. Script61.Name = "Health"
  803. Script61.Parent = Model0
  804. table.insert(cors,sandbox(Script61,function()
  805. --Responsible for regening a player's humanoid's health
  806.  
  807. -- declarations
  808. local Figure = script.Parent
  809. local Head = Figure:WaitForChild("Head")
  810. local Humanoid = Figure:WaitForChild("Humanoid")
  811. local regening = false
  812.  
  813. -- regeneration
  814. function regenHealth()
  815.     if regening then return end
  816.     regening = true
  817.    
  818.     while Humanoid.Health < Humanoid.MaxHealth do
  819.         local s = wait(1)
  820.         local health = Humanoid.Health
  821.         if health > 0 and health < Humanoid.MaxHealth then
  822.             local newHealthDelta = 0.01 * s * Humanoid.MaxHealth
  823.             health = health + newHealthDelta
  824.             Humanoid.Health = math.min(health,Humanoid.MaxHealth)
  825.         end
  826.     end
  827.    
  828.     if Humanoid.Health > Humanoid.MaxHealth then
  829.         Humanoid.Health = Humanoid.MaxHealth
  830.     end
  831.    
  832.     regening = false
  833. end
  834.  
  835. Humanoid.HealthChanged:connect(regenHealth)
  836.  
  837. end))
  838. Script62.Name = "Animate"
  839. Script62.Parent = Model0
  840. table.insert(cors,sandbox(Script62,function()
  841. function   waitForChild(parent, childName)
  842.     local child = parent:findFirstChild(childName)
  843.     if child then return child end
  844.     while true do
  845.         child = parent.ChildAdded:wait()
  846.         if child.Name==childName then return child end
  847.     end
  848. end
  849.  
  850. local Figure = script.Parent
  851. local Humanoid = waitForChild(Figure, "Zombie")
  852. local pose = "Standing"
  853.  
  854. local currentAnim = ""
  855. local currentAnimInstance = nil
  856. local currentAnimTrack = nil
  857. local currentAnimKeyframeHandler = nil
  858. local currentAnimSpeed = 1.0
  859. local animTable = {}
  860. local animNames = {
  861.     idle =  {  
  862.                 { id = "http://www.roblox.com/asset/?id=507766666", weight = 1 },
  863.                 { id = "http://www.roblox.com/asset/?id=507766951", weight = 1 },
  864.                 { id = "http://www.roblox.com/asset/?id=507766388", weight = 9 }
  865.             },
  866.     walk =  {  
  867.                 { id = "http://www.roblox.com/asset/?id=507777826", weight = 10 }
  868.             },
  869.     run =   {
  870.                 { id = "http://www.roblox.com/asset/?id=507767714", weight = 10 }
  871.             },
  872.     swim =  {
  873.                 { id = "http://www.roblox.com/asset/?id=507784897", weight = 10 }
  874.             },
  875.     swimidle =  {
  876.                 { id = "http://www.roblox.com/asset/?id=507785072", weight = 10 }
  877.             },
  878.     jump =  {
  879.                 { id = "http://www.roblox.com/asset/?id=507765000", weight = 10 }
  880.             },
  881.     fall =  {
  882.                 { id = "http://www.roblox.com/asset/?id=507767968", weight = 10 }
  883.             },
  884.     climb = {
  885.                 { id = "http://www.roblox.com/asset/?id=507765644", weight = 10 }
  886.             },
  887.     sit =   {
  888.                 { id = "http://www.roblox.com/asset/?id=507768133", weight = 10 }
  889.             }, 
  890.     toolnone = {
  891.                 { id = "http://www.roblox.com/asset/?id=507768375", weight = 10 }
  892.             },
  893.     toolslash = {
  894.                 { id = "http://www.roblox.com/asset/?id=507768375", weight = 10 }
  895. --              { id = "slash.xml", weight = 10 }
  896.             },
  897.     toollunge = {
  898.                 { id = "http://www.roblox.com/asset/?id=507768375", weight = 10 }
  899.             },
  900.     wave = {
  901.                 { id = "http://www.roblox.com/asset/?id=507770239", weight = 10 }
  902.             },
  903.     point = {
  904.                 { id = "http://www.roblox.com/asset/?id=507770453", weight = 10 }
  905.             },
  906.     dance = {
  907.                 { id = "http://www.roblox.com/asset/?id=507771019", weight = 10 },
  908.                 { id = "http://www.roblox.com/asset/?id=507771955", weight = 10 },
  909.                 { id = "http://www.roblox.com/asset/?id=507772104", weight = 10 }
  910.             },
  911.     dance2 = {
  912.                 { id = "http://www.roblox.com/asset/?id=507776043", weight = 10 },
  913.                 { id = "http://www.roblox.com/asset/?id=507776720", weight = 10 },
  914.                 { id = "http://www.roblox.com/asset/?id=507776879", weight = 10 }
  915.             },
  916.     dance3 = {
  917.                 { id = "http://www.roblox.com/asset/?id=507777268", weight = 10 },
  918.                 { id = "http://www.roblox.com/asset/?id=507777451", weight = 10 },
  919.                 { id = "http://www.roblox.com/asset/?id=507777623", weight = 10 }
  920.             },
  921.     laugh = {
  922.                 { id = "http://www.roblox.com/asset/?id=507770818", weight = 10 }
  923.             },
  924.     cheer = {
  925.                 { id = "http://www.roblox.com/asset/?id=507770677", weight = 10 }
  926.             },
  927. }
  928.  
  929. -- Existance in this list signifies that it is an emote, the value indicates if it is a looping emote
  930. local emoteNames = { wave = false, point = false, dance = true, dance2 = true, dance3 = true, laugh = false, cheer = false}
  931.  
  932. math.randomseed(tick())
  933.  
  934. function configureAnimationSet(name, fileList)
  935.     if (animTable[name] ~= nil) then
  936.         for _, connection in pairs(animTable[name].connections) do
  937.             connection:disconnect()
  938.         end
  939.     end
  940.     animTable[name] = {}
  941.     animTable[name].count = 0
  942.     animTable[name].totalWeight = 0
  943.     animTable[name].connections = {}
  944.  
  945.     -- check for config values
  946.     local config = script:FindFirstChild(name)
  947.     if (config ~= nil) then
  948. --      print("Loading anims " .. name)
  949.         table.insert(animTable[name].connections, config.ChildAdded:connect(function(child) configureAnimationSet(name, fileList) end))
  950.         table.insert(animTable[name].connections, config.ChildRemoved:connect(function(child) configureAnimationSet(name, fileList) end))
  951.         local idx = 1
  952.         for _, childPart in pairs(config:GetChildren()) do
  953.             if (childPart:IsA("Animation")) then
  954.                 table.insert(animTable[name].connections, childPart.Changed:connect(function(property) configureAnimationSet(name, fileList) end))
  955.                 animTable[name][idx] = {}
  956.                 animTable[name][idx].anim = childPart
  957.                 local weightObject = childPart:FindFirstChild("Weight")
  958.                 if (weightObject == nil) then
  959.                     animTable[name][idx].weight = 1
  960.                 else
  961.                     animTable[name][idx].weight = weightObject.Value
  962.                 end
  963.                 animTable[name].count = animTable[name].count + 1
  964.                 animTable[name].totalWeight = animTable[name].totalWeight + animTable[name][idx].weight
  965. --              print(name .. " [" .. idx .. "] " .. animTable[name][idx].anim.AnimationId .. " (" .. animTable[name][idx].weight .. ")")
  966.                 idx = idx + 1
  967.             end
  968.         end
  969.     end
  970.  
  971.     -- fallback to defaults
  972.     if (animTable[name].count <= 0) then
  973.         for idx, anim in pairs(fileList) do
  974.             animTable[name][idx] = {}
  975.             animTable[name][idx].anim = Instance.new("Animation")
  976.             animTable[name][idx].anim.Name = name
  977.             animTable[name][idx].anim.AnimationId = anim.id
  978.             animTable[name][idx].weight = anim.weight
  979.             animTable[name].count = animTable[name].count + 1
  980.             animTable[name].totalWeight = animTable[name].totalWeight + anim.weight
  981. --          print(name .. " [" .. idx .. "] " .. anim.id .. " (" .. anim.weight .. ")")
  982.         end
  983.     end
  984. end
  985.  
  986. -- Setup animation objects
  987. function scriptChildModified(child)
  988.     local fileList = animNames[child.Name]
  989.     if (fileList ~= nil) then
  990.         configureAnimationSet(child.Name, fileList)
  991.     end
  992. end
  993.  
  994. script.ChildAdded:connect(scriptChildModified)
  995. script.ChildRemoved:connect(scriptChildModified)
  996.  
  997.  
  998. for name, fileList in pairs(animNames) do
  999.     configureAnimationSet(name, fileList)
  1000. end
  1001.  
  1002. -- ANIMATION
  1003.  
  1004. -- declarations
  1005. local toolAnim = "None"
  1006. local toolAnimTime = 0
  1007.  
  1008. local jumpAnimTime = 0
  1009. local jumpAnimDuration = 0.31
  1010.  
  1011. local toolTransitionTime = 0.1
  1012. local fallTransitionTime = 0.2
  1013.  
  1014. -- functions
  1015.  
  1016. function stopAllAnimations()
  1017.     local oldAnim = currentAnim
  1018.  
  1019.     -- return to idle if finishing an emote
  1020.     if (emoteNames[oldAnim] ~= nil and emoteNames[oldAnim] == false) then
  1021.         oldAnim = "idle"
  1022.     end
  1023.  
  1024.     currentAnim = ""
  1025.     currentAnimInstance = nil
  1026.     if (currentAnimKeyframeHandler ~= nil) then
  1027.         currentAnimKeyframeHandler:disconnect()
  1028.     end
  1029.  
  1030.     if (currentAnimTrack ~= nil) then
  1031.         currentAnimTrack:Stop()
  1032.         currentAnimTrack:Destroy()
  1033.         currentAnimTrack = nil
  1034.     end
  1035.     return oldAnim
  1036. end
  1037.  
  1038. function setAnimationSpeed(speed)
  1039.     if speed ~= currentAnimSpeed then
  1040.         currentAnimSpeed = speed
  1041.         currentAnimTrack:AdjustSpeed(currentAnimSpeed)
  1042.     end
  1043. end
  1044.  
  1045. function keyFrameReachedFunc(frameName)
  1046.     if (frameName == "End") then
  1047. --      print("Keyframe : ".. frameName)
  1048.  
  1049.         local repeatAnim = currentAnim
  1050.         -- return to idle if finishing an emote
  1051.         if (emoteNames[repeatAnim] ~= nil and emoteNames[repeatAnim] == false) then
  1052.             repeatAnim = "idle"
  1053.         end
  1054.        
  1055.         local animSpeed = currentAnimSpeed
  1056.         playAnimation(repeatAnim, 0.15, Humanoid)
  1057.         setAnimationSpeed(animSpeed)
  1058.     end
  1059. end
  1060.  
  1061. -- Preload animations
  1062. function playAnimation(animName, transitionTime, humanoid)
  1063.        
  1064.     local roll = math.random(1, animTable[animName].totalWeight)
  1065.     local origRoll = roll
  1066.     local idx = 1
  1067.     while (roll > animTable[animName][idx].weight) do
  1068.         roll = roll - animTable[animName][idx].weight
  1069.         idx = idx + 1
  1070.     end
  1071.    
  1072. --  print(animName .. " " .. idx .. " [" .. origRoll .. "]")
  1073.    
  1074.     local anim = animTable[animName][idx].anim
  1075.  
  1076.     -- switch animation    
  1077.     if (anim ~= currentAnimInstance) then
  1078.        
  1079.         if (currentAnimTrack ~= nil) then
  1080.             currentAnimTrack:Stop(transitionTime)
  1081.             currentAnimTrack:Destroy()
  1082.         end
  1083.  
  1084.         currentAnimSpeed = 1.0
  1085.    
  1086.         -- load it to the humanoid; get AnimationTrack
  1087.         currentAnimTrack = humanoid:LoadAnimation(anim)
  1088.          
  1089.         -- play the animation
  1090.         currentAnimTrack:Play(transitionTime)
  1091.         currentAnim = animName
  1092.         currentAnimInstance = anim
  1093.  
  1094.         -- set up keyframe name triggers
  1095.         if (currentAnimKeyframeHandler ~= nil) then
  1096.             currentAnimKeyframeHandler:disconnect()
  1097.         end
  1098.         currentAnimKeyframeHandler = currentAnimTrack.KeyframeReached:connect(keyFrameReachedFunc)
  1099.        
  1100.     end
  1101.  
  1102. end
  1103.  
  1104. -------------------------------------------------------------------------------------------
  1105. -------------------------------------------------------------------------------------------
  1106.  
  1107. local toolAnimName = ""
  1108. local toolAnimTrack = nil
  1109. local toolAnimInstance = nil
  1110. local currentToolAnimKeyframeHandler = nil
  1111.  
  1112. function toolKeyFrameReachedFunc(frameName)
  1113.     if (frameName == "End") then
  1114. --      print("Keyframe : ".. frameName)   
  1115.         playToolAnimation(toolAnimName, 0.0, Humanoid)
  1116.     end
  1117. end
  1118.  
  1119.  
  1120. function playToolAnimation(animName, transitionTime, humanoid)   
  1121.        
  1122.         local roll = math.random(1, animTable[animName].totalWeight)
  1123.         local origRoll = roll
  1124.         local idx = 1
  1125.         while (roll > animTable[animName][idx].weight) do
  1126.             roll = roll - animTable[animName][idx].weight
  1127.             idx = idx + 1
  1128.         end
  1129. --      print(animName .. " * " .. idx .. " [" .. origRoll .. "]")
  1130.         local anim = animTable[animName][idx].anim
  1131.  
  1132.         if (toolAnimInstance ~= anim) then
  1133.            
  1134.             if (toolAnimTrack ~= nil) then
  1135.                 toolAnimTrack:Stop()
  1136.                 toolAnimTrack:Destroy()
  1137.                 transitionTime = 0
  1138.             end
  1139.                    
  1140.             -- load it to the humanoid; get AnimationTrack
  1141.             toolAnimTrack = humanoid:LoadAnimation(anim)
  1142.              
  1143.             -- play the animation
  1144.             toolAnimTrack:Play(transitionTime)
  1145.             toolAnimName = animName
  1146.             toolAnimInstance = anim
  1147.  
  1148.             currentToolAnimKeyframeHandler = toolAnimTrack.KeyframeReached:connect(toolKeyFrameReachedFunc)
  1149.         end
  1150. end
  1151.  
  1152. function stopToolAnimations()
  1153.     local oldAnim = toolAnimName
  1154.  
  1155.     if (currentToolAnimKeyframeHandler ~= nil) then
  1156.         currentToolAnimKeyframeHandler:disconnect()
  1157.     end
  1158.  
  1159.     toolAnimName = ""
  1160.     toolAnimInstance = nil
  1161.     if (toolAnimTrack ~= nil) then
  1162.         toolAnimTrack:Stop()
  1163.         toolAnimTrack:Destroy()
  1164.         toolAnimTrack = nil
  1165.     end
  1166.  
  1167.  
  1168.     return oldAnim
  1169. end
  1170.  
  1171. -------------------------------------------------------------------------------------------
  1172. -------------------------------------------------------------------------------------------
  1173.  
  1174.  
  1175. function onRunning(speed)
  1176.     if speed > 0.01 then
  1177.         local scale = 15.0
  1178.         playAnimation("walk", 0.1, Humanoid)
  1179.         setAnimationSpeed(speed / scale)
  1180.         pose = "Running"
  1181.     else
  1182.         playAnimation("idle", 0.1, Humanoid)
  1183.         pose = "Standing"
  1184.     end
  1185. end
  1186.  
  1187. function onDied()
  1188.     pose = "Dead"
  1189. end
  1190.  
  1191. function onJumping()
  1192.     playAnimation("jump", 0.1, Humanoid)
  1193.     jumpAnimTime = jumpAnimDuration
  1194.     pose = "Jumping"
  1195. end
  1196.  
  1197. function onClimbing(speed)
  1198.     local scale = 5.0
  1199.     playAnimation("climb", 0.1, Humanoid)
  1200.     setAnimationSpeed(speed / scale)
  1201.     pose = "Climbing"
  1202. end
  1203.  
  1204. function onGettingUp()
  1205.     pose = "GettingUp"
  1206. end
  1207.  
  1208. function onFreeFall()
  1209.     if (jumpAnimTime <= 0) then
  1210.         playAnimation("fall", fallTransitionTime, Humanoid)
  1211.     end
  1212.     pose = "FreeFall"
  1213. end
  1214.  
  1215. function onFallingDown()
  1216.     pose = "FallingDown"
  1217. end
  1218.  
  1219. function onSeated()
  1220.     pose = "Seated"
  1221. end
  1222.  
  1223. function onPlatformStanding()
  1224.     pose = "PlatformStanding"
  1225. end
  1226.  
  1227. function onSwimming(speed)
  1228.     if speed > 1.00 then
  1229.         local scale = 10.0
  1230.         playAnimation("swim", 0.4, Humanoid)
  1231.         setAnimationSpeed(speed / scale)
  1232.         pose = "Swimming"
  1233.     else
  1234.         playAnimation("swimidle", 0.4, Humanoid)
  1235.         pose = "Standing"
  1236.     end
  1237. end
  1238.  
  1239. function getTool() 
  1240.     for _, kid in ipairs(Figure:GetChildren()) do
  1241.         if kid.className == "Tool" then return kid end
  1242.     end
  1243.     return nil
  1244. end
  1245.  
  1246. function getToolAnim(tool)
  1247.     for _, c in ipairs(tool:GetChildren()) do
  1248.         if c.Name == "toolanim" and c.className == "StringValue" then
  1249.             return c
  1250.         end
  1251.     end
  1252.     return nil
  1253. end
  1254.  
  1255. function animateTool()
  1256.    
  1257.     if (toolAnim == "None") then
  1258.         playToolAnimation("toolnone", toolTransitionTime, Humanoid)
  1259.         return
  1260.     end
  1261.  
  1262.     if (toolAnim == "Slash") then
  1263.         playToolAnimation("toolslash", 0, Humanoid)
  1264.         return
  1265.     end
  1266.  
  1267.     if (toolAnim == "Lunge") then
  1268.         playToolAnimation("toollunge", 0, Humanoid)
  1269.         return
  1270.     end
  1271. end
  1272.  
  1273. function moveSit()
  1274.     RightShoulder.MaxVelocity = 0.15
  1275.     LeftShoulder.MaxVelocity = 0.15
  1276.     RightShoulder:SetDesiredAngle(3.14 /2)
  1277.     LeftShoulder:SetDesiredAngle(-3.14 /2)
  1278.     RightHip:SetDesiredAngle(3.14 /2)
  1279.     LeftHip:SetDesiredAngle(-3.14 /2)
  1280. end
  1281.  
  1282. local lastTick = 0
  1283.  
  1284. function move(time)
  1285.     local amplitude = 1
  1286.     local frequency = 1
  1287.     local deltaTime = time - lastTick
  1288.     lastTick = time
  1289.  
  1290.     local climbFudge = 0
  1291.     local setAngles = false
  1292.  
  1293.     if (jumpAnimTime > 0) then
  1294.         jumpAnimTime = jumpAnimTime - deltaTime
  1295.     end
  1296.  
  1297.     if (pose == "FreeFall" and jumpAnimTime <= 0) then
  1298.         playAnimation("fall", fallTransitionTime, Humanoid)
  1299.     elseif (pose == "Seated") then
  1300.         playAnimation("sit", 0.5, Humanoid)
  1301.         return
  1302.     elseif (pose == "Running") then
  1303.         playAnimation("walk", 0.1, Humanoid)
  1304.     elseif (pose == "Dead" or pose == "GettingUp" or pose == "FallingDown" or pose == "Seated" or pose == "PlatformStanding") then
  1305.         stopAllAnimations()
  1306.         amplitude = 0.1
  1307.         frequency = 1
  1308.         setAngles = true
  1309.     end
  1310.  
  1311.     -- Tool Animation handling
  1312.     local tool = getTool()
  1313.     if tool then
  1314.    
  1315.         animStringValueObject = getToolAnim(tool)
  1316.  
  1317.         if animStringValueObject then
  1318.             toolAnim = animStringValueObject.Value
  1319.             -- message recieved, delete StringValue
  1320.             animStringValueObject.Parent = nil
  1321.             toolAnimTime = time + .3
  1322.         end
  1323.  
  1324.         if time > toolAnimTime then
  1325.             toolAnimTime = 0
  1326.             toolAnim = "None"
  1327.         end
  1328.  
  1329.         animateTool()      
  1330.     else
  1331.         stopToolAnimations()
  1332.         toolAnim = "None"
  1333.         toolAnimInstance = nil
  1334.         toolAnimTime = 0
  1335.     end
  1336. end
  1337.  
  1338. -- connect events
  1339. Humanoid.Died:connect(onDied)
  1340. Humanoid.Running:connect(onRunning)
  1341. Humanoid.Jumping:connect(onJumping)
  1342. Humanoid.Climbing:connect(onClimbing)
  1343. Humanoid.GettingUp:connect(onGettingUp)
  1344. Humanoid.FreeFalling:connect(onFreeFall)
  1345. Humanoid.FallingDown:connect(onFallingDown)
  1346. Humanoid.Seated:connect(onSeated)
  1347. Humanoid.PlatformStanding:connect(onPlatformStanding)
  1348. Humanoid.Swimming:connect(onSwimming)
  1349.  
  1350. -- setup emote chat hook
  1351. script.msg.Changed:connect(function(msg)
  1352.     script.msg.Value = ""
  1353.     local emote = ""
  1354.     if (string.sub(msg, 1, 3) == "/e ") then
  1355.         emote = string.sub(msg, 4)
  1356.     elseif (string.sub(msg, 1, 7) == "/emote ") then
  1357.         emote = string.sub(msg, 8)
  1358.     end
  1359.    
  1360.     if (pose == "Standing" and emoteNames[emote] ~= nil) then
  1361.         playAnimation(emote, 0.1, Humanoid)
  1362.     end
  1363. --  print("===> " .. string.sub(msg, 1, 3) .. "(" .. emote .. ")")
  1364. end)
  1365.  
  1366.  
  1367. -- main program
  1368.  
  1369. local runService = game:service("RunService");
  1370.  
  1371. -- print("bottom")
  1372.  
  1373. -- initialize to idle
  1374. playAnimation("idle", 0.1, Humanoid)
  1375. pose = "Standing"
  1376.  
  1377. while Figure.Parent~=nil do
  1378.     local _, time = wait(0.1)
  1379.     move(time)
  1380. end
  1381.  
  1382.  
  1383.  
  1384. end))
  1385. StringValue63.Name = "msg"
  1386. StringValue63.Parent = Script62
  1387. StringValue64.Name = "climb"
  1388. StringValue64.Parent = Script62
  1389. Animation65.Name = "ClimbAnim"
  1390. Animation65.Parent = StringValue64
  1391. Animation65.AnimationId = "http://www.roblox.com/asset/?id=616156119"
  1392. StringValue66.Name = "fall"
  1393. StringValue66.Parent = Script62
  1394. Animation67.Name = "FallAnim"
  1395. Animation67.Parent = StringValue66
  1396. Animation67.AnimationId = "http://www.roblox.com/asset/?id=616157476"
  1397. StringValue68.Name = "idle"
  1398. StringValue68.Parent = Script62
  1399. Animation69.Name = "Animation1"
  1400. Animation69.Parent = StringValue68
  1401. Animation69.AnimationId = "http://www.roblox.com/asset/?id=616158929"
  1402. NumberValue70.Name = "Weight"
  1403. NumberValue70.Parent = Animation69
  1404. NumberValue70.Value = 9
  1405. Animation71.Name = "Animation2"
  1406. Animation71.Parent = StringValue68
  1407. Animation71.AnimationId = "http://www.roblox.com/asset/?id=616160636"
  1408. NumberValue72.Name = "Weight"
  1409. NumberValue72.Parent = Animation71
  1410. NumberValue72.Value = 1
  1411. StringValue73.Name = "jump"
  1412. StringValue73.Parent = Script62
  1413. Animation74.Name = "JumpAnim"
  1414. Animation74.Parent = StringValue73
  1415. Animation74.AnimationId = "http://www.roblox.com/asset/?id=616161997"
  1416. StringValue75.Name = "sit"
  1417. StringValue75.Parent = Script62
  1418. Animation76.Name = "SitAnim"
  1419. Animation76.Parent = StringValue75
  1420. Animation76.AnimationId = "http://www.roblox.com/asset/?id=507768133"
  1421. StringValue77.Name = "swim"
  1422. StringValue77.Parent = Script62
  1423. Animation78.Name = "Swim"
  1424. Animation78.Parent = StringValue77
  1425. Animation78.AnimationId = "http://www.roblox.com/asset/?id=616165109"
  1426. StringValue79.Name = "swimidle"
  1427. StringValue79.Parent = Script62
  1428. Animation80.Name = "SwimIdle"
  1429. Animation80.Parent = StringValue79
  1430. Animation80.AnimationId = "http://www.roblox.com/asset/?id=616166655"
  1431. StringValue81.Name = "toolnone"
  1432. StringValue81.Parent = Script62
  1433. Animation82.Name = "ToolNoneAnim"
  1434. Animation82.Parent = StringValue81
  1435. Animation82.AnimationId = "http://www.roblox.com/asset/?id=507768375"
  1436. StringValue83.Name = "walk"
  1437. StringValue83.Parent = Script62
  1438. Animation84.Name = "RunAnim"
  1439. Animation84.Parent = StringValue83
  1440. Animation84.AnimationId = "http://www.roblox.com/asset/?id=616168032"
  1441. Script85.Name = "SoundScript"
  1442. Script85.Parent = Model0
  1443. table.insert(cors,sandbox(Script85,function()
  1444. local moan = script.Parent.Head.Moan
  1445. local moan2 = script.parent.Head.Moan2
  1446. local moan3 = script.parent.Head.Moan3
  1447. local moan4 = script.Parent.Head.Moan4
  1448.  
  1449. while true do
  1450.     moan:Play()
  1451.     wait(8)
  1452.    
  1453.     moan2:Play()
  1454.     wait(5)
  1455.    
  1456.     moan3:Play()
  1457.     wait(7)
  1458.    
  1459.     moan4:Play()
  1460.     wait(6)
  1461. end
  1462.  
  1463.  
  1464. local death = script.Parent.Head.Death
  1465.  
  1466.  
  1467. end))
  1468. for i,v in pairs(mas:GetChildren()) do
  1469.     v.Parent = workspace
  1470.     pcall(function() v:MakeJoints() end)
  1471. end
  1472. mas:Destroy()
  1473. for i,v in pairs(cors) do
  1474.     spawn(function()
  1475.         pcall(v)
  1476.     end)
  1477. end
  1478. end
  1479.  
  1480. for i = 1,1 do
  1481. createZombie()
  1482. end
  1483.  
  1484.  
  1485.  
  1486. local CellerLamp1 = Instance.new("Part")
  1487. CellerLamp1.Parent = workspace
  1488. CellerLamp1.Anchored = true
  1489. CellerLamp1.Size = Vector3.new(1, 1,6)
  1490. CellerLamp1.CanCollide = true
  1491. CellerLamp1.Position = Vector3.new(143.615, 1678.5, 148.468)
  1492. CellerLamp1.Material = "Glass"
  1493. CellerLamp1.BrickColor = BrickColor.new("Institutional white")
  1494.  
  1495. local LampLight1 = Instance.new("PointLight", CellerLamp1)
  1496. LampLight1.Color = Color3.new(255, 255, 255)
  1497. LampLight1.Range = 15
  1498. LampLight1.Brightness = 5
  1499.  
  1500. local CellerLamp2 = Instance.new("Part")
  1501. CellerLamp2.Parent = workspace
  1502. CellerLamp2.Anchored = true
  1503. CellerLamp2.Size = Vector3.new(1, 1,6)
  1504. CellerLamp2.CanCollide = true
  1505. CellerLamp2.Position = Vector3.new(117.615, 1678.5, 148.468)
  1506. CellerLamp2.Material = "Glass"
  1507. CellerLamp2.BrickColor = BrickColor.new("Institutional white")
  1508.  
  1509. local LampLight2 = Instance.new("PointLight", CellerLamp2)
  1510. LampLight2.Color = Color3.new(255, 255, 255)
  1511. LampLight2.Range = 15
  1512. LampLight2.Brightness = 5
  1513.  
  1514.  
  1515. game.Players.LocalPlayer.Character.Humanoid.WalkSpeed = 0
  1516. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = CFrame.new(-26.146, 61.9, 248.911)
  1517. game:GetObjects("rbxassetid://1008107388")[1].Parent = game.Workspace
  1518.  
  1519. game:GetObjects("rbxassetid://12899113663")[1].Parent = game.Workspace
  1520. local LockedSkyScreaperDoor1 = Instance.new("Part")
  1521. LockedSkyScreaperDoor1.Parent = workspace
  1522. LockedSkyScreaperDoor1.Anchored = true
  1523. LockedSkyScreaperDoor1.Size = Vector3.new(4, 7, 1)
  1524. LockedSkyScreaperDoor1.CanCollide = true
  1525. LockedSkyScreaperDoor1.Position = Vector3.new(-1553.618, 538.1, 551.215)
  1526.  
  1527.  
  1528.  
  1529. local LockedSkyScreaperDoor2 = Instance.new("Part")
  1530. LockedSkyScreaperDoor2.Parent = workspace
  1531. LockedSkyScreaperDoor2.Anchored = true
  1532. LockedSkyScreaperDoor2.Size = Vector3.new(4, 7, 2)
  1533. LockedSkyScreaperDoor2.CanCollide = true
  1534. LockedSkyScreaperDoor2.Position = Vector3.new(-1553.778, 481.003, 551.766)
  1535. LockedSkyScreaperDoor2.Transparency = 1
  1536.  
  1537.  
  1538.  
  1539.  
  1540. local NoCheatPart = Instance.new("Part")
  1541. NoCheatPart.Parent = workspace
  1542. NoCheatPart.Anchored = true
  1543. NoCheatPart.Size = Vector3.new(19, 17, 30)
  1544. NoCheatPart.CanCollide = true
  1545. NoCheatPart.Position = Vector3.new(-1560.239, 543.1, 611.628)
  1546. NoCheatPart.Transparency = 1
  1547.  
  1548.  
  1549.  
  1550.  
  1551.  
  1552. local LockedSkyScreaperDoor3 = Instance.new("Part")
  1553. LockedSkyScreaperDoor3.Parent = workspace
  1554. LockedSkyScreaperDoor3.Anchored = true
  1555. LockedSkyScreaperDoor3.Size = Vector3.new(4, 7, 1)
  1556. LockedSkyScreaperDoor3.CanCollide = true
  1557. LockedSkyScreaperDoor3.Position = Vector3.new(-1553.752, 494.9, 551.204)
  1558.  
  1559. local LockedSkyScreaperDoor4 = Instance.new("Part")
  1560. LockedSkyScreaperDoor4.Parent = workspace
  1561. LockedSkyScreaperDoor4.Anchored = true
  1562. LockedSkyScreaperDoor4.Size = Vector3.new(4, 7, 1)
  1563. LockedSkyScreaperDoor4.CanCollide = true
  1564. LockedSkyScreaperDoor4.Position = Vector3.new(-1553.752, 509.363, 551.266)
  1565.  
  1566.  
  1567.  
  1568. local LockedSkyScreaperWall= Instance.new("Part")
  1569. LockedSkyScreaperWall.Parent = workspace
  1570. LockedSkyScreaperWall.Anchored = true
  1571. LockedSkyScreaperWall.Size = Vector3.new(9, 11, 2)
  1572. LockedSkyScreaperWall.CanCollide = true
  1573. LockedSkyScreaperWall.Position = Vector3.new(-1703.162, 528.749, 603.962)
  1574. LockedSkyScreaperWall.Transparency = 1
  1575.  
  1576.  
  1577.  
  1578. local SkyScreaperWall1= Instance.new("Part")
  1579. SkyScreaperWall1.Parent = workspace
  1580. SkyScreaperWall1.Anchored = true
  1581. SkyScreaperWall1.Size = Vector3.new(1, 31, 132)
  1582. SkyScreaperWall1.CanCollide = true
  1583. SkyScreaperWall1.Position = Vector3.new(-1531.379, 551.3, 574.172)
  1584. SkyScreaperWall1.Transparency = 1
  1585.  
  1586. local SkyScreaperWall2= Instance.new("Part")
  1587. SkyScreaperWall2.Parent = workspace
  1588. SkyScreaperWall2.Anchored = true
  1589. SkyScreaperWall2.Size = Vector3.new(1, 31, 132)
  1590. SkyScreaperWall2.CanCollide = true
  1591. SkyScreaperWall2.Position = Vector3.new(-1731.379, 551.3, 574.172)
  1592. SkyScreaperWall2.Transparency = 1
  1593.  
  1594.  
  1595. local SkyScreaperWall3= Instance.new("Part")
  1596. SkyScreaperWall3.Parent = workspace
  1597. SkyScreaperWall3.Anchored = true
  1598. SkyScreaperWall3.Size = Vector3.new(205, 31, 2)
  1599. SkyScreaperWall3.CanCollide = true
  1600. SkyScreaperWall3.Position = Vector3.new(-1633.256, 551.3, 508.352)
  1601. SkyScreaperWall3.Transparency = 1
  1602.  
  1603.  
  1604. local SkyScreaperWall4= Instance.new("Part")
  1605. SkyScreaperWall4.Parent = workspace
  1606. SkyScreaperWall4.Anchored = true
  1607. SkyScreaperWall4.Size = Vector3.new(205, 31, 2)
  1608. SkyScreaperWall4.CanCollide = true
  1609. SkyScreaperWall4.Position = Vector3.new(-1633.256, 551.3, 640.352)
  1610. SkyScreaperWall4.Transparency = 1
  1611.  
  1612.  
  1613.  
  1614. local LockedSkyScreaperDoor5 = Instance.new("Part")
  1615. LockedSkyScreaperDoor5.Parent = workspace
  1616. LockedSkyScreaperDoor5.Anchored = true
  1617. LockedSkyScreaperDoor5.Size = Vector3.new(1, 7, 4)
  1618. LockedSkyScreaperDoor5.CanCollide = true
  1619. LockedSkyScreaperDoor5.Position = Vector3.new(-1712.102, 538.656, 596.066)
  1620. LockedSkyScreaperDoor5.Rotation = Vector3.new(0, 90, 0)
  1621. local LockedSkyScreaperDoor5Mesh = Instance.new("SpecialMesh", LockedSkyScreaperDoor5)
  1622. LockedSkyScreaperDoor5Mesh.Scale = Vector3.new(0.3, 1.2, 2.3)
  1623. LockedSkyScreaperDoor5Mesh.MeshId = "rbxassetid://431484008"
  1624. LockedSkyScreaperDoor5Mesh.TextureId = "rbxassetid://431484036"
  1625. local ScreenGui = Instance.new("ScreenGui")
  1626. local SoulsLabelFrame = Instance.new("Frame")
  1627. local SoulsLabel = Instance.new("TextLabel")
  1628.  
  1629. ScreenGui.Parent = game.CoreGui
  1630. SoulsLabelFrame.Name = "SoulsLabelFrame"
  1631. SoulsLabelFrame.Parent = ScreenGui
  1632. SoulsLabelFrame.BackgroundColor3 = Color3.new(255, 255, 255)
  1633. SoulsLabelFrame.BackgroundTransparency = 1
  1634. SoulsLabelFrame.Position = UDim2.new(0.105540894, 0, 0.778873265, 0)
  1635. SoulsLabelFrame.Size = UDim2.new(0, 100, 0, 100)
  1636. SoulsLabel.Name = "SoulsLabel"
  1637. SoulsLabel.Parent = SoulsLabelFrame
  1638. SoulsLabel.BackgroundColor3 = Color3.new(0, 0, 0)
  1639. SoulsLabel.BorderSizePixel = 0
  1640. SoulsLabel.Draggable = false
  1641. SoulsLabel.Position = UDim2.new(3, 0, -3.5, 0)
  1642. SoulsLabel.Size = UDim2.new(0, 155, 0, 95)
  1643. SoulsLabel.Text = "Souls: 0/3"
  1644. SoulsLabel.Font = Enum.Font.IndieFlower
  1645. SoulsLabel.BackgroundTransparency = 1
  1646. SoulsLabel.FontSize = Enum.FontSize.Size48
  1647. SoulsLabel.TextColor3 = Color3.new(255, 255, 255)
  1648. SoulsLabel.TextSize = 100
  1649. SoulsLabelFrame.Visible =  false
  1650.  
  1651. SoulClickDetector1 = Instance.new("ClickDetector")
  1652. local SoulPart1 = Instance.new("Part")
  1653. local SoulPart2 = Instance.new("Part")
  1654. local SoulPart3 = Instance.new("Part")
  1655. SoulPart1.Parent = workspace
  1656. SoulPart1.Anchored = true
  1657. SoulPart1.Size = Vector3.new(2, 2, 2)
  1658. SoulPart1.CanCollide = true
  1659. SoulPart1.Position = Vector3.new(-1633.995, 525.4, 608.514)  
  1660. SoulPart1.BrickColor = BrickColor.new("Institutional white")
  1661. SoulPart1.Material = "ForceField"
  1662. local SoulPart1Mesh = Instance.new("SpecialMesh", SoulPart1)
  1663. SoulPart1Mesh.MeshType = Enum.MeshType.Sphere
  1664. local SoulPart1Fire = Instance.new("Fire", SoulPart1)
  1665. SoulPart1Fire.Size = 5
  1666. SoulPart1Fire.Color = Color3.new(255,255,255)
  1667. SoulPart1Fire.Heat = 0
  1668. SoulClickDetector1.Parent = SoulPart1
  1669.  
  1670. SoulClickDetector1.MouseClick:connect(function()
  1671. SoulsLabel.Text = "Souls: 1/3"
  1672. local SoulSound1 = Instance.new("Sound")
  1673. local Id = "297569488"
  1674. SoulSound1.Parent = game.Workspace
  1675. SoulSound1.SoundId = "rbxassetid://"..Id
  1676. SoulSound1.Playing = true
  1677. SoulSound1.Looped = false
  1678. SoulSound1.Volume = 1
  1679. SoulPart1.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  1680. SoulPart2.Position = Vector3.new(-1619.355, 525.27, 558.027)
  1681. end)
  1682.  
  1683.  
  1684.  
  1685. SoulClickDetector2 = Instance.new("ClickDetector")
  1686. SoulPart2.Parent = workspace
  1687. SoulPart2.Anchored = true
  1688. SoulPart2.Size = Vector3.new(2, 2, 2)
  1689. SoulPart2.CanCollide = true
  1690. SoulPart2.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)  
  1691. SoulPart2.BrickColor = BrickColor.new("Institutional white")
  1692. SoulPart2.Material = "ForceField"
  1693. local SoulPart2Mesh = Instance.new("SpecialMesh", SoulPart2)
  1694. SoulPart2Mesh.MeshType = Enum.MeshType.Sphere
  1695. local SoulPart2Fire = Instance.new("Fire", SoulPart2)
  1696. SoulPart2Fire.Size = 5
  1697. SoulPart2Fire.Color = Color3.new(255,255,255)
  1698. SoulPart2Fire.Heat = 0
  1699. SoulClickDetector2.Parent = SoulPart2
  1700.  
  1701. SoulClickDetector2.MouseClick:connect(function()
  1702. SoulsLabel.Text = "Souls: 2/3"
  1703. local SoulSound2 = Instance.new("Sound")
  1704. local Id = "297569488"
  1705. SoulSound2.Parent = game.Workspace
  1706. SoulSound2.SoundId = "rbxassetid://"..Id
  1707. SoulSound2.Playing = true
  1708. SoulSound2.Looped = false
  1709. SoulSound2.Volume = 1
  1710. SoulPart2.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  1711. SoulPart3.Position = Vector3.new(-1636.4, 524.3, 524.566)
  1712. end)
  1713.  
  1714.  
  1715.  
  1716. SoulClickDetector3 = Instance.new("ClickDetector")
  1717. SoulPart3.Parent = workspace
  1718. SoulPart3.Anchored = true
  1719. SoulPart3.Size = Vector3.new(2, 2, 2)
  1720. SoulPart3.CanCollide = true
  1721. SoulPart3.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)  
  1722. SoulPart3.BrickColor = BrickColor.new("Institutional white")
  1723. SoulPart3.Material = "ForceField"
  1724. local SoulPart3Mesh = Instance.new("SpecialMesh", SoulPart3)
  1725. SoulPart3Mesh.MeshType = Enum.MeshType.Sphere
  1726. local SoulPart3Fire = Instance.new("Fire", SoulPart3)
  1727. SoulPart3Fire.Size = 5
  1728. SoulPart3Fire.Color = Color3.new(255,255,255)
  1729. SoulPart3Fire.Heat = 0
  1730. SoulClickDetector3.Parent = SoulPart3
  1731.  
  1732. SoulClickDetector3.MouseClick:connect(function()
  1733. SoulsLabel.Text = "Souls: 3/3"
  1734. local SoulSound3 = Instance.new("Sound")
  1735. local Id = "297569488"
  1736. SoulSound3.Parent = game.Workspace
  1737. SoulSound3.SoundId = "rbxassetid://"..Id
  1738. SoulSound3.Playing = true
  1739. SoulSound3.Looped = false
  1740. SoulSound3.Volume = 1
  1741. SoulPart3.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  1742. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  1743.                Text = "[ERROR_CODE]:Good job, now go to the 2nd floor, to the heliport.";
  1744.                Color = Color3.fromRGB(255, 255, 255);
  1745.            })
  1746.  
  1747. wait(2)
  1748. SoulsLabel:Destroy()
  1749. LockedSkyScreaperDoor5.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  1750. local DoorSound = Instance.new("Sound")
  1751. local Id = "5468133300"
  1752. DoorSound.Parent = game.Workspace
  1753. DoorSound.SoundId = "rbxassetid://"..Id
  1754. DoorSound.Playing = true
  1755. DoorSound.Looped = false
  1756. DoorSound.Volume = 1
  1757. end)
  1758.  
  1759.  
  1760.  
  1761.  
  1762.  
  1763.  
  1764.  
  1765.  
  1766.  
  1767.  
  1768. local Dresser = Instance.new("Part")
  1769. Dresser.Parent = workspace
  1770. Dresser.Anchored = true
  1771. Dresser.Size = Vector3.new(2, 6.5, 6)
  1772. Dresser.CanCollide = true
  1773. Dresser.Position = Vector3.new(-28.71, 4.9, 232.908)
  1774. Dresser.Rotation = Vector3.new(0,90,0)
  1775. local DresserMesh = Instance.new("SpecialMesh", Dresser)
  1776. DresserMesh.Scale = Vector3.new(0.1, 0.15, 0.19)
  1777. DresserMesh.MeshId = "rbxassetid://6965783518"
  1778. DresserMesh.TextureId = "rbxassetid://6965783533"
  1779. game:FindService("RunService"):Set3dRenderingEnabled(false)
  1780. local plr = game.Players.LocalPlayer
  1781. local gui = Instance.new("ScreenGui")
  1782. gui.Parent = plr.PlayerGui
  1783. gui.ResetOnSpawn = false
  1784. local StartQuestion = Instance.new("TextLabel")
  1785. StartQuestion.Parent = gui
  1786. StartQuestion.BackgroundTransparency = 1
  1787. StartQuestion.Size = UDim2.new(2, 0, 2, 0)
  1788. StartQuestion.Position = UDim2.new(-0.5, 0, 0 ,-255)
  1789. StartQuestion.TextXAlignment = Enum.TextXAlignment.Center
  1790. StartQuestion.TextScaled = true
  1791. StartQuestion.Text = "Ugh...Terrible dream."
  1792. StartQuestion.TextColor3 = Color3.new(0, 0, 0)
  1793. StartQuestion.Font = Enum.Font.IndieFlower
  1794. wait(3)
  1795. StartQuestion:Destroy()
  1796. local StartQuestion2 = Instance.new("TextLabel")
  1797. StartQuestion2.Parent = gui
  1798. StartQuestion2.BackgroundTransparency = 1
  1799. StartQuestion2.Size = UDim2.new(2, 0, 2, 0)
  1800. StartQuestion2.Position = UDim2.new(-0.5, 0, 0 ,-255)
  1801. StartQuestion2.TextXAlignment = Enum.TextXAlignment.Center
  1802. StartQuestion2.TextScaled = true
  1803. StartQuestion2.Text = "Stop..."
  1804. StartQuestion2.TextColor3 = Color3.new(0, 0, 0)
  1805. StartQuestion2.Font = Enum.Font.IndieFlower
  1806. wait(3)
  1807. StartQuestion2:Destroy()
  1808.  local Blur = Instance.new("BlurEffect")
  1809. Blur.Size = 5
  1810.  
  1811. Blur.Parent = game:GetService("Lighting")
  1812. local SoundAlfa = Instance.new("Sound")
  1813. local Id = "1837901628"
  1814. SoundAlfa.Parent = game.Workspace
  1815. SoundAlfa.SoundId = "rbxassetid://"..Id
  1816. SoundAlfa.Playing = true
  1817. SoundAlfa.Looped = true
  1818. SoundAlfa.Volume = 1
  1819. game:FindService("RunService"):Set3dRenderingEnabled(true)
  1820. game.Players.LocalPlayer.Character.Humanoid.WalkSpeed = 5
  1821.  
  1822. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = CFrame.new(3.713, 13.6, 218.234)
  1823. local Player = game.Players.LocalPlayer
  1824. local Character = Player.Character
  1825. local Humanoid = Character.Humanoid
  1826. if Humanoid.WalkSpeed > 5 then
  1827. game.Players.LocalPlayer:Kick("DO NOT USE EXPLOIT!")
  1828. end
  1829.  Humanoid.MaxHealth = 100
  1830. Humanoid.HealthChanged:connect(function()
  1831. if Humanoid.Health < 5 then
  1832. Humanoid.Health = Humanoid.MaxHealth
  1833.  
  1834.  
  1835. localaction = math.random(1,5)
  1836. if localaction == 1 then
  1837. for i,v in pairs(game.Players:GetPlayers()) do
  1838.  
  1839.                spawn(function()
  1840.                        local newgui = Instance.new("ScreenGui",v.PlayerGui)
  1841.                        newgui.Name = "Screamer"
  1842.                        local newimage = Instance.new("ImageLabel",newgui)
  1843.                        newimage.Image = "rbxassetid://6679835009"
  1844.                        newimage.Size = UDim2.new(1,0,1,0)
  1845. local Sound = Instance.new("Sound")
  1846. local Id = "670599653"
  1847. Sound.Parent = game.Workspace
  1848. Sound.SoundId = "rbxassetid://"..Id
  1849. Sound.Playing = true
  1850. Sound.Looped = false
  1851. Sound.Volume = 999
  1852.                       wait(0.2)
  1853. newimage:Destroy()
  1854.     Sound:Stop()                  
  1855.    
  1856.                end)
  1857.        end
  1858.    
  1859.  
  1860. end
  1861. if localaction == 2 then
  1862. for i,v in pairs(game.Players:GetPlayers()) do
  1863.  
  1864.                spawn(function()
  1865.                        local newgui = Instance.new("ScreenGui",v.PlayerGui)
  1866.                        newgui.Name = "Screamer"
  1867.                        local newimage = Instance.new("ImageLabel",newgui)
  1868.                        newimage.Image = "rbxassetid://1119705746"
  1869.                        newimage.Size = UDim2.new(1,0,1,0)
  1870. local Sound = Instance.new("Sound")
  1871. local Id = "670599653"
  1872. Sound.Parent = game.Workspace
  1873. Sound.SoundId = "rbxassetid://"..Id
  1874. Sound.Playing = true
  1875. Sound.Looped = false
  1876. Sound.Volume = 999
  1877.                       wait(0.2)
  1878. newimage:Destroy()
  1879.   Sound:Stop()                    
  1880.    
  1881.                end)
  1882.        end
  1883.    
  1884.  
  1885. end
  1886. if localaction == 3 then
  1887. for i,v in pairs(game.Players:GetPlayers()) do
  1888.  
  1889.                spawn(function()
  1890.                        local newgui = Instance.new("ScreenGui",v.PlayerGui)
  1891.                        newgui.Name = "Screamer"
  1892.                        local newimage = Instance.new("ImageLabel",newgui)
  1893.                        newimage.Image = "rbxassetid://2293755576"
  1894.                        newimage.Size = UDim2.new(1,0,1,0)
  1895. local Sound = Instance.new("Sound")
  1896. local Id = "670599653"
  1897. Sound.Parent = game.Workspace
  1898. Sound.SoundId = "rbxassetid://"..Id
  1899. Sound.Playing = true
  1900. Sound.Looped = false
  1901. Sound.Volume = 999
  1902.                       wait(0.2)
  1903. newimage:Destroy()
  1904.                        
  1905.  Sound:Stop()  
  1906.                end)
  1907.        end
  1908. end
  1909.  
  1910. if localaction == 4 then
  1911. for i,v in pairs(game.Players:GetPlayers()) do
  1912.  
  1913.                spawn(function()
  1914.                        local newgui = Instance.new("ScreenGui",v.PlayerGui)
  1915.                        newgui.Name = "Screamer"
  1916.                        local newimage = Instance.new("ImageLabel",newgui)
  1917.                        newimage.Image = "rbxassetid://100876676"
  1918.                        newimage.Size = UDim2.new(1,0,1,0)
  1919. local Sound = Instance.new("Sound")
  1920. local Id = "670599653"
  1921. Sound.Parent = game.Workspace
  1922. Sound.SoundId = "rbxassetid://"..Id
  1923. Sound.Playing = true
  1924. Sound.Looped = false
  1925. Sound.Volume = 999
  1926.                       wait(0.2)
  1927. newimage:Destroy()
  1928.                        
  1929.  Sound:Stop()  
  1930.                end)
  1931.        end
  1932. end
  1933.  
  1934. if localaction == 5 then
  1935. for i,v in pairs(game.Players:GetPlayers()) do
  1936.  
  1937.                spawn(function()
  1938.                        local newgui = Instance.new("ScreenGui",v.PlayerGui)
  1939.                        newgui.Name = "Screamer"
  1940.                        local newimage = Instance.new("ImageLabel",newgui)
  1941.                        newimage.Image = "rbxassetid://11518873999"
  1942.                        newimage.Size = UDim2.new(1,0,1,0)
  1943. local Sound = Instance.new("Sound")
  1944. local Id = "670599653"
  1945. Sound.Parent = game.Workspace
  1946. Sound.SoundId = "rbxassetid://"..Id
  1947. Sound.Playing = true
  1948. Sound.Looped = false
  1949. Sound.Volume = 999
  1950.                       wait(0.2)
  1951. newimage:Destroy()
  1952.                        
  1953.  Sound:Stop()  
  1954.                end)
  1955.        end
  1956. end
  1957. end
  1958. SoulsLabelFrame.Visible = false
  1959. local Sound = Instance.new("Sound")
  1960. local Id = "131038747"
  1961. Sound.Parent = game.Workspace
  1962. Sound.SoundId = "rbxassetid://"..Id
  1963. Sound.Playing = true
  1964. Sound.Looped = true
  1965. Sound.Volume = 1
  1966. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = CFrame.new(-26.146, 61.9, 248.911)
  1967. local plr = game.Players.LocalPlayer
  1968. local gui = Instance.new("ScreenGui")
  1969. gui.Parent = plr.PlayerGui
  1970. gui.ResetOnSpawn = false
  1971. local Thx = Instance.new("TextLabel")
  1972. Thx.Parent = gui
  1973. Thx.BackgroundTransparency = 1
  1974. Thx.Size = UDim2.new(1, 0, 1, 0)
  1975. Thx.Position = UDim2.new(0, 0, 0.6 ,-255)
  1976. Thx.TextXAlignment = Enum.TextXAlignment.Center
  1977. Thx.TextScaled = true
  1978. Thx.Text = "Game Over"
  1979. Thx.TextColor3 = Color3.new(255, 255, 255)
  1980. Thx.Font = Enum.Font.IndieFlower
  1981. while true do
  1982. local Camera = game.Workspace.Camera
  1983. Camera.CameraType = Enum.CameraType.Scriptable
  1984. Camera.CFrame = CFrame.new(-38.902, 7.4, 229.421)
  1985. wait(2)
  1986. local Camera = game.Workspace.Camera
  1987. Camera.CameraType = Enum.CameraType.Scriptable
  1988. Camera.CFrame = CFrame.new(-2.172, 17, 259.511)
  1989. wait(2)
  1990. local Camera = game.Workspace.Camera
  1991. Camera.CameraType = Enum.CameraType.Scriptable
  1992. Camera.CFrame = CFrame.new(-8.936, 5.402, 235.685)
  1993. wait(2)
  1994. end
  1995. end)
  1996. function sandbox(var,func)
  1997.     local env = getfenv(func)
  1998.     local newenv = setmetatable({},{
  1999.         __index = function(self,k)
  2000.             if k=="script" then
  2001.                 return var
  2002.             else
  2003.                 return env[k]
  2004.             end
  2005.         end,
  2006.     })
  2007.     setfenv(func,newenv)
  2008.     return func
  2009. end
  2010. cors = {}
  2011. mas = Instance.new("Model",game:GetService("Lighting"))
  2012. Tool0 = Instance.new("Tool")
  2013. Part1 = Instance.new("Part")
  2014. Sound2 = Instance.new("Sound")
  2015. SpecialMesh3 = Instance.new("SpecialMesh")
  2016. SpotLight4 = Instance.new("SpotLight")
  2017. LocalScript5 = Instance.new("LocalScript")
  2018. LocalScript6 = Instance.new("LocalScript")
  2019. ModuleScript7 = Instance.new("ModuleScript")
  2020. Tool0.Name = "Flashlight"
  2021. Tool0.Parent = mas
  2022. Tool0.TextureId = "http://www.roblox.com/asset/?id=115955232"
  2023. Tool0.Grip = CFrame.new(0.100000001, -0.400000006, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  2024. Tool0.GripPos = Vector3.new(0.10000000149011612, -0.4000000059604645, 0)
  2025. Tool0.ToolTip = "Flashlight"
  2026. Part1.Name = "Handle"
  2027. Part1.Parent = Tool0
  2028. Part1.CFrame = CFrame.new(10.9154053, 0.25, -18.9892578, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  2029. Part1.Orientation = Vector3.new(0, 90, 0)
  2030. Part1.Position = Vector3.new(10.9154052734375, 0.25, -18.9892578125)
  2031. Part1.Rotation = Vector3.new(0, 90, 0)
  2032. Part1.Color = Color3.new(0.960784, 0.803922, 0.188235)
  2033. Part1.Size = Vector3.new(0.5, 0.5, 2)
  2034. Part1.BottomSurface = Enum.SurfaceType.Smooth
  2035. Part1.BrickColor = BrickColor.new("Bright yellow")
  2036. Part1.TopSurface = Enum.SurfaceType.Smooth
  2037. Part1.brickColor = BrickColor.new("Bright yellow")
  2038. Part1.FormFactor = Enum.FormFactor.Custom
  2039. Part1.formFactor = Enum.FormFactor.Custom
  2040. Sound2.Parent = Part1
  2041. Sound2.SoundId = "http://www.roblox.com/asset/?id=115959318"
  2042. Sound2.Volume = 1
  2043. SpecialMesh3.Parent = Part1
  2044. SpecialMesh3.MeshId = "http://www.roblox.com/asset/?id=115955313"
  2045. SpecialMesh3.Scale = Vector3.new(0.699999988079071, 0.699999988079071, 0.699999988079071)
  2046. SpecialMesh3.TextureId = "http://www.roblox.com/asset?id=115955343"
  2047. SpecialMesh3.MeshType = Enum.MeshType.FileMesh
  2048. SpotLight4.Parent = Part1
  2049. SpotLight4.Enabled = false
  2050. SpotLight4.Range = 40
  2051. SpotLight4.Brightness = 10
  2052. SpotLight4.Shadows = true
  2053. LocalScript5.Parent = Tool0
  2054. table.insert(cors,sandbox(LocalScript5,function()
  2055. player = game.Players.LocalPlayer
  2056. tool = script.Parent
  2057.  
  2058. repeat wait() until player
  2059.  
  2060. tool.Equipped:connect(function(mouse)
  2061.     mouse.Button1Down:connect(function()
  2062.         tool.Handle.SpotLight.Enabled = not tool.Handle.SpotLight.Enabled
  2063.         tool.Handle.Sound:Play()
  2064.     end)
  2065. end)
  2066. end))
  2067. LocalScript6.Parent = Tool0
  2068. table.insert(cors,sandbox(LocalScript6,function()
  2069. -- Variables for services
  2070. local render = game:GetService("RunService").RenderStepped
  2071. local contextActionService = game:GetService("ContextActionService")
  2072. local userInputService = game:GetService("UserInputService")
  2073.  
  2074. local player = game.Players.LocalPlayer
  2075. local mouse = player:GetMouse()
  2076. local Tool = script.Parent
  2077.  
  2078. -- Variables for Module Scripts
  2079. local screenSpace = require(Tool:WaitForChild("ScreenSpace"))
  2080.  
  2081. local connection
  2082.  
  2083. local neck, shoulder, oldNeckC0, oldShoulderC0
  2084.  
  2085. local mobileShouldTrack = true
  2086.  
  2087. -- Thourough check to see if a character is sitting
  2088. local function amISitting(character)
  2089.     local t = character.Torso
  2090.     for _, part in pairs(t:GetConnectedParts(true)) do
  2091.         if part:IsA("Seat") or part:IsA("VehicleSeat") then
  2092.             return true
  2093.         end
  2094.     end
  2095. end
  2096.  
  2097. -- Function to call on renderstepped. Orients the character so it is facing towards
  2098. -- the player mouse's position in world space. If character is sitting then the torso
  2099. -- should not track
  2100. local function frame(mousePosition)
  2101.     -- Special mobile consideration. We don't want to track if the user was touching a ui
  2102.     -- element such as the movement controls. Just return out of function if so to make sure
  2103.     -- character doesn't track
  2104.     if not mobileShouldTrack then return end
  2105.    
  2106.     -- Make sure character isn't swiming. If the character is swimming the following code will
  2107.     -- not work well; the character will not swim correctly. Besides, who shoots underwater?
  2108.     if player.Character.Humanoid:GetState() ~= Enum.HumanoidStateType.Swimming then
  2109.         local torso = player.Character.Torso
  2110.         local head = player.Character.Head
  2111.        
  2112.         local toMouse = (mousePosition - head.Position).unit
  2113.         local angle = math.acos(toMouse:Dot(Vector3.new(0,1,0)))
  2114.        
  2115.         local neckAngle = angle
  2116.    
  2117.         -- Limit how much the head can tilt down. Too far and the head looks unnatural
  2118.         if math.deg(neckAngle) > 110 then
  2119.             neckAngle = math.rad(110)
  2120.         end
  2121.         neck.C0 = CFrame.new(0,1,0) * CFrame.Angles(math.pi - neckAngle,math.pi,0)
  2122.        
  2123.         -- Calculate horizontal rotation
  2124.         local arm = player.Character:FindFirstChild("Right Arm")
  2125.         local fromArmPos = torso.Position + torso.CFrame:vectorToWorldSpace(Vector3.new(
  2126.             torso.Size.X/2 + arm.Size.X/2, torso.Size.Y/2 - arm.Size.Z/2, 0))
  2127.         local toMouseArm = ((mousePosition - fromArmPos) * Vector3.new(1,0,1)).unit
  2128.         local look = (torso.CFrame.lookVector * Vector3.new(1,0,1)).unit
  2129.         local lateralAngle = math.acos(toMouseArm:Dot(look))       
  2130.        
  2131.         -- Check for rogue math
  2132.         if tostring(lateralAngle) == "-1.#IND" then
  2133.             lateralAngle = 0
  2134.         end    
  2135.        
  2136.         -- Handle case where character is sitting down
  2137.         if player.Character.Humanoid:GetState() == Enum.HumanoidStateType.Seated then          
  2138.            
  2139.             local cross = torso.CFrame.lookVector:Cross(toMouseArm)
  2140.             if lateralAngle > math.pi/2 then
  2141.                 lateralAngle = math.pi/2
  2142.             end
  2143.             if cross.Y < 0 then
  2144.                 lateralAngle = -lateralAngle
  2145.             end
  2146.         end
  2147.        
  2148.         -- Turn shoulder to point to mouse
  2149.         shoulder.C0 = CFrame.new(1,0.5,0) * CFrame.Angles(math.pi/2 - angle,math.pi/2 + lateralAngle,0)
  2150.        
  2151.         -- If not sitting then aim torso laterally towards mouse
  2152.         if not amISitting(player.Character) then
  2153.             torso.CFrame = CFrame.new(torso.Position, torso.Position + (Vector3.new(
  2154.                 mousePosition.X, torso.Position.Y, mousePosition.Z)-torso.Position).unit)
  2155.         end
  2156.     end
  2157. end
  2158.  
  2159. -- Function to bind to render stepped if player is on PC
  2160. local function pcFrame()
  2161.     frame(mouse.Hit.p)
  2162. end
  2163.  
  2164. -- Function to bind to touch moved if player is on mobile
  2165. local function mobileFrame(touch, processed)
  2166.     -- Check to see if the touch was on a UI element. If so, we don't want to update anything
  2167.     if not processed then
  2168.         -- Calculate touch position in world space. Uses Stravant's ScreenSpace Module script
  2169.         -- to create a ray from the camera.
  2170.         local test = screenSpace.ScreenToWorld(touch.Position.X, touch.Position.Y, 1)
  2171.         local nearPos = game.Workspace.CurrentCamera.CoordinateFrame:vectorToWorldSpace(screenSpace.ScreenToWorld(touch.Position.X, touch.Position.Y, 1))
  2172.         nearPos = game.Workspace.CurrentCamera.CoordinateFrame.p - nearPos
  2173.         local farPos = screenSpace.ScreenToWorld(touch.Position.X, touch.Position.Y,50)
  2174.         farPos = game.Workspace.CurrentCamera.CoordinateFrame:vectorToWorldSpace(farPos) * -1
  2175.         if farPos.magnitude > 900 then
  2176.             farPos = farPos.unit * 900
  2177.         end
  2178.         local ray = Ray.new(nearPos, farPos)
  2179.         local part, pos = game.Workspace:FindPartOnRay(ray, player.Character)
  2180.        
  2181.         -- if a position was found on the ray then update the character's rotation
  2182.         if pos then
  2183.             frame(pos)
  2184.         end
  2185.     end
  2186. end
  2187.  
  2188. local function OnActivated()
  2189.     local myModel = player.Character
  2190.     if Tool.Enabled and myModel and myModel:FindFirstChild('Humanoid') and myModel.Humanoid.Health > 0 then
  2191.         Tool.Enabled = false
  2192.         game.ReplicatedStorage.ROBLOX_RocketFireEvent:FireServer(mouse.Hit.p)
  2193.         wait(2)
  2194.  
  2195.         Tool.Enabled = true
  2196.     end
  2197. end
  2198.  
  2199. local oldIcon = nil
  2200. -- Function to bind to equip event
  2201. local function equip()
  2202.     local torso = player.Character.Torso
  2203.    
  2204.     -- Setup joint variables
  2205.     neck = torso.Neck  
  2206.     oldNeckC0 = neck.C0
  2207.     shoulder = torso:FindFirstChild("Right Shoulder")
  2208.     oldShoulderC0 = shoulder.C0
  2209.    
  2210.     -- Remember old mouse icon and update current
  2211.     oldIcon = mouse.Icon
  2212.     mouse.Icon = "rbxasset://textures\\GunCursor.png"
  2213.    
  2214.     -- Bind TouchMoved event if on mobile. Otherwise connect to renderstepped
  2215.     if userInputService.TouchEnabled then
  2216.         connection = userInputService.TouchMoved:connect(mobileFrame)
  2217.     else
  2218.         connection = render:connect(pcFrame)
  2219.     end
  2220.    
  2221.     -- Bind TouchStarted and TouchEnded. Used to determine if character should rotate
  2222.     -- during touch input
  2223.     userInputService.TouchStarted:connect(function(touch, processed)
  2224.         mobileShouldTrack = not processed
  2225.     end)   
  2226.     userInputService.TouchEnded:connect(function(touch, processed)
  2227.         mobileShouldTrack = false
  2228.     end)
  2229.  
  2230.     -- If game uses filtering enabled then need to update server while tool is
  2231.     -- held by character.
  2232.     if workspace.FilteringEnabled then
  2233.         while connection do
  2234.             wait()
  2235.             game.ReplicatedStorage.ROBLOX_RocketUpdateEvent:FireServer(neck.C0, shoulder.C0)
  2236.         end
  2237.     end
  2238. end
  2239.  
  2240. -- Function to bind to Unequip event
  2241. local function unequip()
  2242.     if connection then connection:disconnect() end
  2243.    
  2244.     mouse.Icon = oldIcon
  2245.    
  2246.     neck.C0 = oldNeckC0
  2247.     shoulder.C0 = oldShoulderC0
  2248. end
  2249.  
  2250. -- Bind tool events
  2251. Tool.Equipped:connect(equip)
  2252. Tool.Unequipped:connect(unequip)
  2253. Tool.Activated:connect(OnActivated)
  2254. end))
  2255. ModuleScript7.Name = "ScreenSpace"
  2256. ModuleScript7.Parent = Tool0
  2257. table.insert(cors,sandbox(ModuleScript7,function()
  2258. local PlayerMouse = Game:GetService('Players').LocalPlayer:GetMouse()
  2259.  
  2260. local ScreenSpace = {}
  2261.  
  2262. -- Getter functions, with a couple of hacks for Ipad pre-focus.
  2263. function ScreenSpace.ViewSizeX()
  2264.     local x = PlayerMouse.ViewSizeX
  2265.     local y = PlayerMouse.ViewSizeY
  2266.     if x == 0 then
  2267.         return 1024
  2268.     else
  2269.         if x > y then
  2270.             return x
  2271.         else
  2272.             return y
  2273.         end
  2274.     end
  2275. end
  2276.  
  2277. function ScreenSpace.ViewSizeY()
  2278.     local x = PlayerMouse.ViewSizeX
  2279.     local y = PlayerMouse.ViewSizeY
  2280.     if y == 0 then
  2281.         return 768
  2282.     else
  2283.         if x > y then
  2284.             return y
  2285.         else
  2286.             return x
  2287.         end
  2288.     end
  2289. end
  2290.  
  2291. -- Nice getter for aspect ratio. Due to the checks in the ViewSize functions this
  2292. -- will never fail with a divide by zero error.
  2293. function ScreenSpace.AspectRatio()
  2294.     return ScreenSpace.ViewSizeX() / ScreenSpace.ViewSizeY()
  2295. end
  2296.  
  2297. -- WorldSpace -> ScreenSpace. Raw function taking a world position and giving you the
  2298. -- screen position.
  2299. function ScreenSpace.WorldToScreen(at)
  2300.     local point = Workspace.CurrentCamera.CoordinateFrame:pointToObjectSpace(at)
  2301.     local aspectRatio = ScreenSpace.AspectRatio()
  2302.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2303.     local wfactor = aspectRatio*hfactor
  2304.     --
  2305.     local x = (point.x/point.z) / -wfactor
  2306.     local y = (point.y/point.z) /  hfactor
  2307.     --
  2308.     return Vector2.new(ScreenSpace.ViewSizeX()*(0.5 + 0.5*x), ScreenSpace.ViewSizeY()*(0.5 + 0.5*y))
  2309. end
  2310.  
  2311. -- ScreenSpace -> WorldSpace. Raw function taking a screen position and a depth and
  2312. -- converting it into a world position.
  2313. function ScreenSpace.ScreenToWorld(x, y, depth)
  2314.     local aspectRatio = ScreenSpace.AspectRatio()
  2315.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2316.     local wfactor = aspectRatio*hfactor
  2317.     --
  2318.     local xf, yf = x/ScreenSpace.ViewSizeX()*2 - 1, y/ScreenSpace.ViewSizeY()*2 - 1
  2319.     local xpos = xf * -wfactor * depth
  2320.     local ypos = yf *  hfactor * depth
  2321.     --
  2322.     return Vector3.new(xpos, ypos, depth)
  2323. end
  2324.  
  2325. -- ScreenSize -> WorldSize
  2326. function ScreenSpace.ScreenWidthToWorldWidth(screenWidth, depth)   
  2327.     local aspectRatio = ScreenSpace.AspectRatio()
  2328.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2329.     local wfactor = aspectRatio*hfactor
  2330.     local sx = ScreenSpace.ViewSizeX()
  2331.     --
  2332.     return -(screenWidth / sx) * 2 * wfactor * depth
  2333. end
  2334. function ScreenSpace.ScreenHeightToWorldHeight(screenHeight, depth)
  2335.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2336.     local sy = ScreenSpace.ViewSizeY()
  2337.     --
  2338.     return -(screenHeight / sy) * 2 * hfactor * depth
  2339. end
  2340.  
  2341. -- WorldSize -> ScreenSize
  2342. function ScreenSpace.WorldWidthToScreenWidth(worldWidth, depth)
  2343.     local aspectRatio = ScreenSpace.AspectRatio()
  2344.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2345.     local wfactor = aspectRatio*hfactor
  2346.     local sx = ScreenSpace.ViewSizeX()
  2347.     --
  2348.     return -(worldWidth * sx) / (2 * wfactor * depth)
  2349. end
  2350. function ScreenSpace.WorldHeightToScreenHeight(worldHeight, depth)
  2351.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2352.     local sy = ScreenSpace.ViewSizeY()
  2353.     --
  2354.     return -(worldHeight * sy) / (2 * hfactor * depth)
  2355. end
  2356.  
  2357. -- WorldSize + ScreenSize -> Depth needed
  2358. function ScreenSpace.GetDepthForWidth(screenWidth, worldWidth)
  2359.     local aspectRatio = ScreenSpace.AspectRatio()
  2360.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2361.     local wfactor = aspectRatio*hfactor
  2362.     local sx, sy = ScreenSpace.ViewSizeX(), ScreenSpace.ViewSizeY()
  2363.     --
  2364.     return -(sx * worldWidth) / (screenWidth * 2 * wfactor)
  2365. end
  2366. function ScreenSpace.GetDepthForHeight(screenHeight, worldHeight)
  2367.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2368.     local sy = ScreenSpace.ViewSizeY()
  2369.     --
  2370.     return -(sy * worldHeight) / (screenHeight * 2 * hfactor)  
  2371. end
  2372.  
  2373. -- ScreenSpace -> WorldSpace. Taking a screen height, and a depth to put an object
  2374. -- at, and returning a size of how big that object has to be to appear that size
  2375. -- at that depth.
  2376. function ScreenSpace.ScreenToWorldByHeightDepth(x, y, screenHeight, depth)
  2377.     local aspectRatio = ScreenSpace.AspectRatio()
  2378.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2379.     local wfactor = aspectRatio*hfactor
  2380.     local sx, sy = ScreenSpace.ViewSizeX(), ScreenSpace.ViewSizeY()
  2381.     --
  2382.     local worldHeight = -(screenHeight/sy) * 2 * hfactor * depth
  2383.     --
  2384.     local xf, yf = x/sx*2 - 1, y/sy*2 - 1
  2385.     local xpos = xf * -wfactor * depth
  2386.     local ypos = yf *  hfactor * depth
  2387.     --
  2388.     return Vector3.new(xpos, ypos, depth), worldHeight
  2389. end
  2390.  
  2391. -- ScreenSpace -> WorldSpace. Taking a screen width, and a depth to put an object
  2392. -- at, and returning a size of how big that object has to be to appear that size
  2393. -- at that depth.
  2394. function ScreenSpace.ScreenToWorldByWidthDepth(x, y, screenWidth, depth)
  2395.     local aspectRatio = ScreenSpace.AspectRatio()
  2396.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2397.     local wfactor = aspectRatio*hfactor
  2398.     local sx, sy = ScreenSpace.ViewSizeX(), ScreenSpace.ViewSizeY()
  2399.     --
  2400.     local worldWidth = (screenWidth/sx) * 2 * -wfactor * depth
  2401.     --
  2402.     local xf, yf = x/sx*2 - 1, y/sy*2 - 1
  2403.     local xpos = xf * -wfactor * depth
  2404.     local ypos = yf *  hfactor * depth
  2405.     --
  2406.     return Vector3.new(xpos, ypos, depth), worldWidth
  2407. end
  2408.  
  2409. -- ScreenSpace -> WorldSpace. Taking a screen height that you want that object to be
  2410. -- and a world height that is the size of that object, and returning the position to
  2411. -- put that object at to satisfy those.
  2412. function ScreenSpace.ScreenToWorldByHeight(x, y, screenHeight, worldHeight)
  2413.     local aspectRatio = ScreenSpace.AspectRatio()
  2414.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2415.     local wfactor = aspectRatio*hfactor
  2416.     local sx, sy = ScreenSpace.ViewSizeX(), ScreenSpace.ViewSizeY()
  2417.     --
  2418.     local depth = - (sy * worldHeight) / (screenHeight * 2 * hfactor)
  2419.     --
  2420.     local xf, yf = x/sx*2 - 1, y/sy*2 - 1
  2421.     local xpos = xf * -wfactor * depth
  2422.     local ypos = yf *  hfactor * depth
  2423.     --
  2424.     return Vector3.new(xpos, ypos, depth)
  2425. end
  2426.  
  2427. -- ScreenSpace -> WorldSpace. Taking a screen width that you want that object to be
  2428. -- and a world width that is the size of that object, and returning the position to
  2429. -- put that object at to satisfy those.
  2430. function ScreenSpace.ScreenToWorldByWidth(x, y, screenWidth, worldWidth)
  2431.     local aspectRatio = ScreenSpace.AspectRatio()
  2432.     local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
  2433.     local wfactor = aspectRatio*hfactor
  2434.     local sx, sy = ScreenSpace.ViewSizeX(), ScreenSpace.ViewSizeY()
  2435.     --
  2436.     local depth = - (sx * worldWidth) / (screenWidth * 2 * wfactor)
  2437.     --
  2438.     local xf, yf = x/sx*2 - 1, y/sy*2 - 1
  2439.     local xpos = xf * -wfactor * depth
  2440.     local ypos = yf *  hfactor * depth
  2441.     --
  2442.     return Vector3.new(xpos, ypos, depth)
  2443. end
  2444.  
  2445. return ScreenSpace
  2446.  
  2447.  
  2448.  
  2449.  
  2450. end))
  2451. for i,v in pairs(mas:GetChildren()) do
  2452.     v.Parent = game:GetService("Players").LocalPlayer.Backpack
  2453.     pcall(function() v:MakeJoints() end)
  2454. end
  2455. mas:Destroy()
  2456. for i,v in pairs(cors) do
  2457.     spawn(function()
  2458.         pcall(v)
  2459.     end)
  2460. end
  2461.  
  2462.  
  2463.  
  2464.  
  2465.  
  2466.  
  2467.  
  2468. local DoorLocked1 = Instance.new("Part")
  2469. DoorLocked1.Parent = game.workspace
  2470. DoorLocked1.Anchored = true
  2471. DoorLocked1.Size = Vector3.new(4.5, 8, 1)
  2472. DoorLocked1.CanCollide = true
  2473. DoorLocked1.Position = Vector3.new(-40.343, 6.583, 243.74)
  2474. DoorLocked1.Transparency = 1
  2475.  
  2476. local DoorUnLocked1 = Instance.new("Part")
  2477. DoorUnLocked1.Parent = game.workspace
  2478. DoorUnLocked1.Anchored = true
  2479. DoorUnLocked1.Size = Vector3.new(4.5, 8, 1)
  2480. DoorUnLocked1.CanCollide = false
  2481. DoorUnLocked1.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  2482. DoorUnLocked1.Transparency = 1
  2483.  
  2484.  
  2485. local DoorLocked2 = Instance.new("Part")
  2486. DoorLocked2.Parent = game.workspace
  2487. DoorLocked2.Anchored = true
  2488. DoorLocked2.Size = Vector3.new(1, 8, 4)
  2489. DoorLocked2.CanCollide = true
  2490. DoorLocked2.Position = Vector3.new(10.4, 6.434, 231.317)
  2491. DoorLocked2.Transparency = 1
  2492.  
  2493. local DoorLocked2B = Instance.new("Part")
  2494. DoorLocked2B.Parent = game.workspace
  2495. DoorLocked2B.Anchored = true
  2496. DoorLocked2B.Size = Vector3.new(1, 8, 4)
  2497. DoorLocked2B.CanCollide = false
  2498. DoorLocked2B.Position = Vector3.new(10.4, 6.434, 231.317)
  2499. local DoorLocked2BMesh = Instance.new("SpecialMesh", DoorLocked2B)
  2500. DoorLocked2BMesh.Scale = Vector3.new(1, 8, 4)
  2501. DoorLocked2BMesh.TextureId = "rbxassetid://12095085"
  2502.  
  2503.  
  2504. local DoorUnLocked2 = Instance.new("Part")
  2505. DoorUnLocked2.Parent = game.workspace
  2506. DoorUnLocked2.Anchored = true
  2507. DoorUnLocked2.Size = Vector3.new(1, 8, 4)
  2508. DoorUnLocked2.CanCollide = false
  2509. DoorUnLocked2.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  2510. DoorUnLocked2.Transparency = 1
  2511.  
  2512. local DoorLocked3 = Instance.new("Part")
  2513. DoorLocked3.Parent = game.workspace
  2514. DoorLocked3.Anchored = true
  2515. DoorLocked3.Size = Vector3.new(1, 8, 10)
  2516. DoorLocked3.CanCollide = true
  2517. DoorLocked3.Position = Vector3.new(-55.6, 6.448, 235.82)
  2518. DoorLocked3.Transparency = 1
  2519.  
  2520.  
  2521.  
  2522.  
  2523. local ScreenGui = Instance.new("ScreenGui")
  2524. local PaperFame1 = Instance.new("Frame")
  2525. local PaperButton1 = Instance.new("TextLabel")
  2526. ScreenGui.Parent = game.CoreGui
  2527.  
  2528. PaperFame1.Name = "PaperFame1"
  2529. PaperFame1.Parent = ScreenGui
  2530. PaperFame1.BackgroundColor3 = Color3.new(255, 255, 255)
  2531. PaperFame1.BackgroundTransparency = 1
  2532. PaperFame1.Position = UDim2.new(0.105540894, 0, 0.778873265, 0)
  2533. PaperFame1.Size = UDim2.new(0, 100, 0, 100)
  2534.  
  2535. PaperButton1.Name = "PaperButton1"
  2536. PaperButton1.Parent = PaperFame1
  2537. PaperButton1.BackgroundColor3 = Color3.new(0, 0, 0)
  2538. PaperButton1.BorderSizePixel = 0
  2539. PaperButton1.Draggable = false
  2540. PaperButton1.Position = UDim2.new(2.2, 0, -3.4, 0)
  2541. PaperButton1.Size = UDim2.new(0, 350, 0, 400)
  2542. PaperButton1.Font = Enum.Font.IndieFlower
  2543. PaperButton1.FontSize = Enum.FontSize.Size48
  2544. PaperButton1.Text = "1.Find the key\n 2.Find the celler key\n 3.goto celler\n 4.find your friend."
  2545. PaperButton1.TextColor3 = Color3.new(155, 0, 0)
  2546. PaperButton1.TextSize = 50
  2547. PaperButton1.Visible = false
  2548.  
  2549. ClickDetector1 = Instance.new("ClickDetector")
  2550. local PaperPart = Instance.new("Part")
  2551. PaperPart.Parent = workspace
  2552. PaperPart.Anchored = true
  2553. PaperPart.Size = Vector3.new(2, 0.2, 2)
  2554. PaperPart.CanCollide = true
  2555. PaperPart.Position = Vector3.new(8.109, 16.009, 219.8)
  2556.  
  2557. local PaperPartMesh = Instance.new("SpecialMesh", PaperPart)
  2558. PaperPartMesh.Scale = Vector3.new(1.3, 0.2, 1)
  2559. PaperPartMesh.MeshId = "rbxassetid://6714051581"
  2560. PaperPartMesh.TextureId = "rbxassetid://6714051634"
  2561. ClickDetector1.Parent = PaperPart
  2562.  
  2563. ClickDetector1.MouseClick:connect(function()
  2564. local Sound = Instance.new("Sound")
  2565. local Id = "9117231552"
  2566. Sound.Parent = game.Workspace
  2567. Sound.SoundId = "rbxassetid://"..Id
  2568. Sound.Playing = true
  2569. Sound.Looped = false
  2570. Sound.Volume = 1
  2571. PaperPart.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  2572. Papertool = Instance.new("Tool")
  2573. Papertool.RequiresHandle = false
  2574. Papertool.Name = "Paper"
  2575. Papertool.Equipped:Connect(function()
  2576. local Sound = Instance.new("Sound")
  2577. local Id = "2217513097"
  2578. Sound.Parent = game.Workspace
  2579. Sound.SoundId = "rbxassetid://"..Id
  2580. Sound.Playing = true
  2581. Sound.Looped = false
  2582. Sound.Volume = 1
  2583. PaperButton1.Visible = true
  2584. end)
  2585.  
  2586. Papertool.Unequipped:Connect(function()
  2587. local Sound = Instance.new("Sound")
  2588. local Id = "9117231552"
  2589. Sound.Parent = game.Workspace
  2590. Sound.SoundId = "rbxassetid://"..Id
  2591. Sound.Playing = true
  2592. Sound.Looped = false
  2593. Sound.Volume = 1
  2594. PaperButton1.Visible = false
  2595. end)
  2596. Papertool.Parent = game.Players.LocalPlayer.Backpack
  2597. end)
  2598.  
  2599. bbg=Instance.new('BillboardGui',PaperPart)
  2600.    
  2601.     bbg.Size=UDim2.new(2.5,0,2.5,0)
  2602.     bbg.StudsOffset=Vector3.new(0,2,0)
  2603.     tlb=Instance.new'TextLabel'
  2604.     tlb.Text='Paper'
  2605.     tlb.TextSize = 100
  2606.     tlb.Font='IndieFlower'
  2607.     tlb.FontSize='Size48'
  2608.     tlb.TextColor3=Color3.new(1,1,1)
  2609.     tlb.Size=UDim2.new(1,0,1,0)
  2610.     tlb.Position=UDim2.new(-0.125,-0.9,-0.5,0)
  2611.     tlb.BackgroundTransparency=1
  2612.     tlb.Parent=bbg
  2613.  
  2614. ClickDetector2 = Instance.new("ClickDetector")
  2615. local Key1Part = Instance.new("Part")
  2616. Key1Part.Parent = workspace
  2617. Key1Part.Anchored = true
  2618. Key1Part.Size = Vector3.new(2, 2, 2)
  2619. Key1Part.CanCollide = false
  2620. Key1Part.Position = Vector3.new(-20.516, 17.9, 258.578)
  2621.  
  2622. local Key1PartMesh = Instance.new("SpecialMesh", Key1Part)
  2623. Key1PartMesh.Scale = Vector3.new(0.05, 0.05, 0.05)
  2624. Key1PartMesh.MeshId = "rbxassetid://554079568"
  2625. Key1PartMesh.TextureId = "rbxassetid://554079576"
  2626. ClickDetector2.Parent = Key1Part
  2627.  
  2628. bbg2=Instance.new('BillboardGui',Key1Part)
  2629.    
  2630.     bbg2.Size=UDim2.new(2.5,0,2.5,0)
  2631.     bbg2.StudsOffset=Vector3.new(0,2,0)
  2632.     tlb2=Instance.new'TextLabel'
  2633.     tlb2.Text='pantry key'
  2634.     tlb2.TextSize = 100
  2635.     tlb2.Font='IndieFlower'
  2636.     tlb2.FontSize='Size48'
  2637.     tlb2.TextColor3=Color3.new(1,1,1)
  2638.     tlb2.Size=UDim2.new(1,0,1,0)
  2639.     tlb2.Position=UDim2.new(-0.125,-0.9,-0.5,0)
  2640.     tlb2.BackgroundTransparency=1
  2641.     tlb2.Parent=bbg2
  2642.  
  2643.  
  2644. ClickDetector2.MouseClick:connect(function()
  2645. local Sound = Instance.new("Sound")
  2646. local Id = "1498950813"
  2647. Sound.Parent = game.Workspace
  2648. Sound.SoundId = "rbxassetid://"..Id
  2649. Sound.Playing = true
  2650. Sound.Looped = false
  2651. Sound.Volume = 1
  2652. Key1Part.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  2653. Tool0 = Instance.new("Tool")
  2654. Part1 = Instance.new("Part")
  2655. SpecialMesh2 = Instance.new("SpecialMesh")
  2656. Tool0.Name = "Key1"
  2657. Tool0.Parent = game.Players.LocalPlayer.Backpack
  2658. Tool0.TextureId = "http://www.roblox.com/asset/?id=221748793"
  2659. Tool0.Grip = CFrame.new(0.100000001, -0.400000006, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  2660. Tool0.GripPos = Vector3.new(0.10000000149011612, -0.4000000059604645, 0)
  2661. Tool0.ToolTip = "pantry key"
  2662. Part1.Name = "Handle"
  2663. Part1.Parent = Tool0
  2664. Part1.CFrame = CFrame.new(10.9154053, 0.25, -18.9892578, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  2665. Part1.Orientation = Vector3.new(90, 0, 0)
  2666. Part1.Position = Vector3.new(10.9154052734375, 0.25, -18.9892578125)
  2667. Part1.Rotation = Vector3.new(-90, 0, 0)
  2668. Part1.Color = Color3.new(0.960784, 0.803922, 0.188235)
  2669. Part1.Size = Vector3.new(0.05, 0.05, 0.05)
  2670. Part1.BottomSurface = Enum.SurfaceType.Smooth
  2671. Part1.BrickColor = BrickColor.new("Bright yellow")
  2672. Part1.TopSurface = Enum.SurfaceType.Smooth
  2673. Part1.brickColor = BrickColor.new("Bright yellow")
  2674. Part1.FormFactor = Enum.FormFactor.Custom
  2675. Part1.formFactor = Enum.FormFactor.Custom
  2676. SpecialMesh2.Parent = Part1
  2677. SpecialMesh2.MeshId = "http://www.roblox.com/asset/?id=554079568"
  2678. SpecialMesh2.Scale = Vector3.new(0.05, 0.05, 0.05)
  2679. SpecialMesh2.TextureId = "http://www.roblox.com/asset?id=554079576"
  2680. SpecialMesh2.MeshType = Enum.MeshType.FileMesh
  2681.  
  2682. Tool0.Equipped:Connect(function()
  2683. DoorLocked1.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  2684. DoorUnLocked1.Position = Vector3.new(-40.343, 6.583, 243.74)
  2685. local Sound = Instance.new("Sound")
  2686. local Id = "1498950813"
  2687. Sound.Parent = game.Workspace
  2688. Sound.SoundId = "rbxassetid://"..Id
  2689. Sound.Playing = true
  2690. Sound.Looped = false
  2691. Sound.Volume = 1
  2692. end)
  2693.  
  2694. Tool0.Unequipped:Connect(function()
  2695. DoorLocked1.Position = Vector3.new(-40.343, 6.583, 243.74)
  2696. DoorUnLocked1.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  2697. local Sound = Instance.new("Sound")
  2698. local Id = "7886392420"
  2699. Sound.Parent = game.Workspace
  2700. Sound.SoundId = "rbxassetid://"..Id
  2701. Sound.Playing = true
  2702. Sound.Looped = false
  2703. Sound.Volume = 1
  2704. end)
  2705. end)
  2706.  
  2707.  
  2708. Touched = false
  2709. DoorUnLocked1.Touched:connect(function(player)
  2710. if Touched == false then
  2711. Touched = true
  2712. Tool0:Remove()
  2713. Part1:Remove()
  2714. DoorUnLocked1.Position = Vector3.new(-40.343, 6.583, 243.74)
  2715.  DoorLocked1.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  2716.  
  2717.  
  2718. wait(1)
  2719. Touched = false
  2720. end
  2721. end)
  2722.  
  2723.  
  2724.  
  2725. ClickDetector3 = Instance.new("ClickDetector")
  2726. local Key2Part = Instance.new("Part")
  2727. Key2Part.Parent = workspace
  2728. Key2Part.Anchored = true
  2729. Key2Part.Size = Vector3.new(2, 2, 2)
  2730. Key2Part.CanCollide = false
  2731. Key2Part.Position = Vector3.new(-39.48, 2.902, 250.642)
  2732.  
  2733. local Key1PartMesh = Instance.new("SpecialMesh", Key2Part)
  2734. Key1PartMesh.Scale = Vector3.new(0.05, 0.05, 0.05)
  2735. Key1PartMesh.MeshId = "rbxassetid://10681451177"
  2736. Key1PartMesh.TextureId = "rbxassetid://10681451256"
  2737. ClickDetector3.Parent = Key2Part
  2738.  
  2739. bbg3=Instance.new('BillboardGui',Key2Part)
  2740.    
  2741.     bbg3.Size=UDim2.new(2.5,0,2.5,0)
  2742.     bbg3.StudsOffset=Vector3.new(0,2,0)
  2743.     tlb3=Instance.new'TextLabel'
  2744.     tlb3.Text='celler key'
  2745.     tlb3.TextSize = 100
  2746.     tlb3.Font='IndieFlower'
  2747.     tlb3.FontSize='Size48'
  2748.     tlb3.TextColor3=Color3.new(1,1,1)
  2749.     tlb3.Size=UDim2.new(1,0,1,0)
  2750.     tlb3.Position=UDim2.new(-0.125,-0.9,-0.5,0)
  2751.     tlb3.BackgroundTransparency=1
  2752.     tlb3.Parent=bbg3
  2753.  
  2754.  
  2755. ClickDetector3.MouseClick:connect(function()
  2756. local Sound = Instance.new("Sound")
  2757. local Id = "1498950813"
  2758. Sound.Parent = game.Workspace
  2759. Sound.SoundId = "rbxassetid://"..Id
  2760. Sound.Playing = true
  2761. Sound.Looped = false
  2762. Sound.Volume = 1
  2763. Key2Part.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  2764. Tool0:Remove()
  2765. Part1:Remove()
  2766. Tool0B = Instance.new("Tool")
  2767. Part1B = Instance.new("Part")
  2768. SpecialMesh2B = Instance.new("SpecialMesh")
  2769. Tool0B.Name = "Key2"
  2770. Tool0B.Parent = game.Players.LocalPlayer.Backpack
  2771. Tool0B.TextureId = "http://www.roblox.com/asset/?id=221748793"
  2772. Tool0B.Grip = CFrame.new(0.100000001, -0.400000006, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  2773. Tool0B.GripPos = Vector3.new(0.10000000149011612, -0.4000000059604645, 0)
  2774. Tool0B.ToolTip = "celler key"
  2775. Part1B.Name = "Handle"
  2776. Part1B.Parent = Tool0B
  2777. Part1B.CFrame = CFrame.new(10.9154053, 0.25, -18.9892578, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  2778. Part1B.Orientation = Vector3.new(90, 0, 0)
  2779. Part1B.Position = Vector3.new(10.9154052734375, 0.25, -18.9892578125)
  2780. Part1B.Rotation = Vector3.new(-90, 0, 0)
  2781. Part1B.Color = Color3.new(0.960784, 0.803922, 0.188235)
  2782. Part1B.Size = Vector3.new(0.05, 0.05, 0.05)
  2783. Part1B.BottomSurface = Enum.SurfaceType.Smooth
  2784. Part1B.BrickColor = BrickColor.new("Bright yellow")
  2785. Part1B.TopSurface = Enum.SurfaceType.Smooth
  2786. Part1B.brickColor = BrickColor.new("Bright yellow")
  2787. Part1B.FormFactor = Enum.FormFactor.Custom
  2788. Part1B.formFactor = Enum.FormFactor.Custom
  2789. SpecialMesh2B.Parent = Part1B
  2790. SpecialMesh2B.MeshId = "http://www.roblox.com/asset/?id=10681451177"
  2791. SpecialMesh2B.Scale = Vector3.new(0.05, 0.05, 0.05)
  2792. SpecialMesh2B.TextureId = "http://www.roblox.com/asset?id=10681451256"
  2793. SpecialMesh2B.MeshType = Enum.MeshType.FileMesh
  2794.  
  2795. Tool0B.Equipped:Connect(function()
  2796. DoorLocked2.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  2797. DoorUnLocked2.Position = Vector3.new(10.4, 6.434, 231.317)
  2798. local Sound = Instance.new("Sound")
  2799. local Id = "1498950813"
  2800. Sound.Parent = game.Workspace
  2801. Sound.SoundId = "rbxassetid://"..Id
  2802. Sound.Playing = true
  2803. Sound.Looped = false
  2804. Sound.Volume = 1
  2805. end)
  2806.  
  2807. Tool0B.Unequipped:Connect(function()
  2808. DoorLocked2.Position = Vector3.new(10.4, 6.434, 231.317)
  2809. DoorUnLocked2.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  2810. local Sound = Instance.new("Sound")
  2811. local Id = "7886392420"
  2812. Sound.Parent = game.Workspace
  2813. Sound.SoundId = "rbxassetid://"..Id
  2814. Sound.Playing = true
  2815. Sound.Looped = false
  2816. Sound.Volume = 1
  2817. end)
  2818. end)
  2819.  
  2820.  
  2821.  
  2822.  
  2823.  
  2824. local HarassmentSound = Instance.new("Sound")
  2825. local Id2 = "1846453309"
  2826. HarassmentSound.Parent = game.Workspace
  2827. HarassmentSound.SoundId = "rbxassetid://"..Id2
  2828. HarassmentSound.Looped = true
  2829. HarassmentSound.Volume = 1
  2830. function createZombie()
  2831. function sandbox(var,func)
  2832.     local env = getfenv(func)
  2833.     local newenv = setmetatable({},{
  2834.         __index = function(self,k)
  2835.             if k=="script" then
  2836.                 return var
  2837.             else
  2838.                 return env[k]
  2839.             end
  2840.         end,
  2841.     })
  2842.     setfenv(func,newenv)
  2843.     return func
  2844. end
  2845. cors = {}
  2846. mas = Instance.new("Model",game:GetService("Lighting"))
  2847. Model0 = Instance.new("Model")
  2848. Part1A = Instance.new("Part")
  2849. SpecialMesh2 = Instance.new("SpecialMesh")
  2850. Vector3Value3 = Instance.new("Vector3Value")
  2851. Motor6D4 = Instance.new("Motor6D")
  2852. Decal5 = Instance.new("Decal")
  2853. Sound6 = Instance.new("Sound")
  2854. Sound7 = Instance.new("Sound")
  2855. Sound8 = Instance.new("Sound")
  2856. Sound9 = Instance.new("Sound")
  2857. Sound10 = Instance.new("Sound")
  2858. Part11 = Instance.new("Part")
  2859. Vector3Value12 = Instance.new("Vector3Value")
  2860. BodyColors13 = Instance.new("BodyColors")
  2861. MeshPart14 = Instance.new("MeshPart")
  2862. Vector3Value15 = Instance.new("Vector3Value")
  2863. Motor6D16 = Instance.new("Motor6D")
  2864. Script17 = Instance.new("Script")
  2865. Humanoid18 = Instance.new("Humanoid")
  2866. Script19 = Instance.new("Script")
  2867. MeshPart20 = Instance.new("MeshPart")
  2868. Vector3Value21 = Instance.new("Vector3Value")
  2869. Motor6D22 = Instance.new("Motor6D")
  2870. MeshPart23 = Instance.new("MeshPart")
  2871. Vector3Value24 = Instance.new("Vector3Value")
  2872. Motor6D25 = Instance.new("Motor6D")
  2873. MeshPart26 = Instance.new("MeshPart")
  2874. Vector3Value27 = Instance.new("Vector3Value")
  2875. Motor6D28 = Instance.new("Motor6D")
  2876. MeshPart29 = Instance.new("MeshPart")
  2877. Vector3Value30 = Instance.new("Vector3Value")
  2878. Motor6D31 = Instance.new("Motor6D")
  2879. MeshPart32 = Instance.new("MeshPart")
  2880. Vector3Value33 = Instance.new("Vector3Value")
  2881. Motor6D34 = Instance.new("Motor6D")
  2882. MeshPart35 = Instance.new("MeshPart")
  2883. Vector3Value36 = Instance.new("Vector3Value")
  2884. Motor6D37 = Instance.new("Motor6D")
  2885. MeshPart38 = Instance.new("MeshPart")
  2886. Vector3Value39 = Instance.new("Vector3Value")
  2887. Motor6D40 = Instance.new("Motor6D")
  2888. MeshPart41 = Instance.new("MeshPart")
  2889. Vector3Value42 = Instance.new("Vector3Value")
  2890. Motor6D43 = Instance.new("Motor6D")
  2891. Script44 = Instance.new("Script")
  2892. MeshPart45 = Instance.new("MeshPart")
  2893. Vector3Value46 = Instance.new("Vector3Value")
  2894. Motor6D47 = Instance.new("Motor6D")
  2895. MeshPart48 = Instance.new("MeshPart")
  2896. Vector3Value49 = Instance.new("Vector3Value")
  2897. Motor6D50 = Instance.new("Motor6D")
  2898. MeshPart51 = Instance.new("MeshPart")
  2899. Vector3Value52 = Instance.new("Vector3Value")
  2900. Motor6D53 = Instance.new("Motor6D")
  2901. MeshPart54 = Instance.new("MeshPart")
  2902. Vector3Value55 = Instance.new("Vector3Value")
  2903. Motor6D56 = Instance.new("Motor6D")
  2904. MeshPart57 = Instance.new("MeshPart")
  2905. Vector3Value58 = Instance.new("Vector3Value")
  2906. Motor6D59 = Instance.new("Motor6D")
  2907. Script60 = Instance.new("Script")
  2908. Script61 = Instance.new("Script")
  2909. Script62 = Instance.new("Script")
  2910. StringValue63 = Instance.new("StringValue")
  2911. StringValue64 = Instance.new("StringValue")
  2912. Animation65 = Instance.new("Animation")
  2913. StringValue66 = Instance.new("StringValue")
  2914. Animation67 = Instance.new("Animation")
  2915. StringValue68 = Instance.new("StringValue")
  2916. Animation69 = Instance.new("Animation")
  2917. NumberValue70 = Instance.new("NumberValue")
  2918. Animation71 = Instance.new("Animation")
  2919. NumberValue72 = Instance.new("NumberValue")
  2920. StringValue73 = Instance.new("StringValue")
  2921. Animation74 = Instance.new("Animation")
  2922. StringValue75 = Instance.new("StringValue")
  2923. Animation76 = Instance.new("Animation")
  2924. StringValue77 = Instance.new("StringValue")
  2925. Animation78 = Instance.new("Animation")
  2926. StringValue79 = Instance.new("StringValue")
  2927. Animation80 = Instance.new("Animation")
  2928. StringValue81 = Instance.new("StringValue")
  2929. Animation82 = Instance.new("Animation")
  2930. StringValue83 = Instance.new("StringValue")
  2931. Animation84 = Instance.new("Animation")
  2932. Script85 = Instance.new("Script")
  2933. Model0.Name = "Zombie"
  2934. Model0.Parent = mas
  2935. Part1A.Name = "Head"
  2936. Part1A.Parent = Model0
  2937. Part1A.CFrame = CFrame.new(-0.695644557, 4.56509781, -2.19861078, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  2938. Part1A.Orientation = Vector3.new(0, 90.1399994, 0)
  2939. Part1A.Position = Vector3.new(-0.695644557, 4.56509781, -2.19861078)
  2940. Part1A.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  2941. Part1A.Color = Color3.new(0.541176, 0.670588, 0.521569)
  2942. Part1A.Size = Vector3.new(1, 1, 1)
  2943. Part1A.BottomSurface = Enum.SurfaceType.Smooth
  2944. Part1A.BrickColor = BrickColor.new("Artichoke")
  2945. Part1A.TopSurface = Enum.SurfaceType.Smooth
  2946. Part1A.brickColor = BrickColor.new("Artichoke")
  2947. Part1A.FormFactor = Enum.FormFactor.Custom
  2948. Part1A.formFactor = Enum.FormFactor.Custom
  2949. SpecialMesh2.Parent = Part1A
  2950. SpecialMesh2.MeshId = "http://www.roblox.com/asset?id=419776358"
  2951. SpecialMesh2.MeshType = Enum.MeshType.FileMesh
  2952. Vector3Value3.Name = "OriginalSize"
  2953. Vector3Value3.Parent = Part1
  2954. Vector3Value3.Value = Vector3.new(1, 1, 1)
  2955. Motor6D4.Name = "Neck"
  2956. Motor6D4.Parent = Part1A
  2957. Motor6D4.C0 = CFrame.new(0.000338107347, 0.806032121, -0.015560925, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  2958. Motor6D4.C1 = CFrame.new(-2.72095203e-05, -0.565615535, 0.00386685133, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  2959. Motor6D4.Part0 = MeshPart14
  2960. Motor6D4.Part1 = Part1A
  2961. Motor6D4.part1 = Part1A
  2962. Decal5.Parent = Part1A
  2963. Decal5.Texture = "http://www.roblox.com/asset/?id=174393211"
  2964. Sound6.Name = "Moan"
  2965. Sound6.Parent = Part1A
  2966. Sound6.SoundId = "rbxassetid://131060249"
  2967. Sound6.Volume = 1
  2968. Sound7.Name = "Moan2"
  2969. Sound7.Parent = Part1
  2970. Sound7.SoundId = "rbxassetid://131060145"
  2971. Sound7.Volume = 1
  2972. Sound8.Name = "Moan3"
  2973. Sound8.Parent = Part1A
  2974. Sound8.SoundId = "rbxassetid://131060210"
  2975. Sound8.Volume = 1
  2976. Sound9.Name = "Moan4"
  2977. Sound9.Parent = Part1
  2978. Sound9.SoundId = "rbxassetid://131138835"
  2979. Sound9.Volume = 1
  2980. Sound10.Name = "Death"
  2981. Sound10.Parent = Part1A
  2982. Part11.Name = "HumanoidRootPart"
  2983. Part11.Parent = Model0
  2984. Part11.CFrame = CFrame.new(-0.691856027, 2.32588005, -2.1985929, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  2985. Part11.Orientation = Vector3.new(0, 90.1399994, 0)
  2986. Part11.Position = Vector3.new(-1732.735, 521, 590.03)
  2987. Part11.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  2988. Part11.Transparency = 1
  2989. Part11.Size = Vector3.new(2, 2, 1)
  2990. Part11.CanCollide = false
  2991. Vector3Value12.Name = "OriginalSize"
  2992. Vector3Value12.Parent = Part11
  2993. Vector3Value12.Value = Vector3.new(2, 2, 1)
  2994. BodyColors13.Parent = Model0
  2995. BodyColors13.HeadColor = BrickColor.new("Artichoke")
  2996. BodyColors13.HeadColor3 = Color3.new(0.541176, 0.670588, 0.521569)
  2997. BodyColors13.LeftArmColor = BrickColor.new("Artichoke")
  2998. BodyColors13.LeftArmColor3 = Color3.new(0.541176, 0.670588, 0.521569)
  2999. BodyColors13.LeftLegColor = BrickColor.new("Burnt Sienna")
  3000. BodyColors13.LeftLegColor3 = Color3.new(0.415686, 0.223529, 0.0352941)
  3001. BodyColors13.RightArmColor = BrickColor.new("Artichoke")
  3002. BodyColors13.RightArmColor3 = Color3.new(0.541176, 0.670588, 0.521569)
  3003. BodyColors13.RightLegColor = BrickColor.new("Burnt Sienna")
  3004. BodyColors13.RightLegColor3 = Color3.new(0.415686, 0.223529, 0.0352941)
  3005. BodyColors13.TorsoColor = BrickColor.new("Burnt Sienna")
  3006. BodyColors13.TorsoColor3 = Color3.new(0.415686, 0.223529, 0.0352941)
  3007. MeshPart14.Name = "UpperTorso"
  3008. MeshPart14.Parent = Model0
  3009. MeshPart14.CFrame = CFrame.new(-0.676263928, 3.1934495, -2.19829226, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3010. MeshPart14.Orientation = Vector3.new(0, 90.1399994, 0)
  3011. MeshPart14.Position = Vector3.new(-0.676263928, 3.1934495, -2.19829226)
  3012. MeshPart14.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3013. MeshPart14.Color = Color3.new(0.156863, 0.498039, 0.278431)
  3014. MeshPart14.Size = Vector3.new(2.00029206, 1.60093355, 1.0005368)
  3015. MeshPart14.BrickColor = BrickColor.new("Dark green")
  3016. MeshPart14.brickColor = BrickColor.new("Dark green")
  3017. Vector3Value15.Name = "OriginalSize"
  3018. Vector3Value15.Parent = MeshPart14
  3019. Vector3Value15.Value = Vector3.new(2.00029206, 1.60093355, 1.0005368)
  3020. Motor6D16.Name = "Waist"
  3021. Motor6D16.Parent = MeshPart14
  3022. Motor6D16.C0 = CFrame.new(0.000280171633, 0.537143946, -0.0142721087, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3023. Motor6D16.C1 = CFrame.new(0.000338107347, -0.463463932, -0.015560925, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3024. Motor6D16.Part0 = MeshPart41
  3025. Motor6D16.Part1 = MeshPart14
  3026. Motor6D16.part1 = MeshPart14
  3027. Script17.Name = "Damage Script"
  3028. Script17.Parent = MeshPart14
  3029. table.insert(cors,sandbox(Script17,function()
  3030. function onTouched(hit)
  3031.         local human = hit.Parent:findFirstChild("Humanoid")
  3032.         if (human ~= nil) then
  3033.                 human.Health = human.Health - 0.5
  3034.         end
  3035. end
  3036. script.Parent.Touched:connect(onTouched)
  3037. end))
  3038. Humanoid18.Name = "Zombie"
  3039. Humanoid18.Parent = Model0
  3040. Humanoid18.DisplayDistanceType = Enum.HumanoidDisplayDistanceType.Subject
  3041. Humanoid18.Health = 999999999999999999
  3042. Humanoid18.HealthDisplayType = Enum.HumanoidHealthDisplayType.AlwaysOff
  3043. Humanoid18.HipHeight = 1.3500000238419
  3044. Humanoid18.LeftLeg = MeshPart45
  3045. Humanoid18.MaxHealth = 100
  3046. Humanoid18.NameOcclusion = Enum.NameOcclusion.NoOcclusion
  3047. Humanoid18.RigType = Enum.HumanoidRigType.R15
  3048. Humanoid18.RightLeg = MeshPart20
  3049. Humanoid18.Torso = Part11
  3050. Humanoid18.WalkSpeed = 15
  3051. Humanoid18.maxHealth = 100
  3052. Script19.Parent = Model0
  3053. table.insert(cors,sandbox(Script19,function()
  3054. local larm = script.Parent:FindFirstChild("HumanoidRootPart")
  3055. local rarm = script.Parent:FindFirstChild("HumanoidRootPart")
  3056. local char = script.Parent
  3057. local pathFinder = game:GetService("PathfindingService")
  3058. local path = pathFinder:CreatePath()
  3059.  
  3060. function findNearestTorso(pos)
  3061.     local list = game.Workspace:children()
  3062.     local torso = nil
  3063.     local dist = 100
  3064.     local temp = nil
  3065.     local human = nil
  3066.     local temp2 = nil
  3067.     for x = 1, #list do
  3068.         temp2 = list[x]
  3069.         if (temp2.className == "Model") and (temp2 ~= script.Parent) then
  3070.             temp = temp2:findFirstChild("HumanoidRootPart")
  3071.             human = temp2:findFirstChild("Humanoid")
  3072.             if (temp ~= nil) and (human ~= nil) and (human.Health > 0) then
  3073.                 if (temp.Position - pos).magnitude < dist then
  3074.                     torso = temp
  3075.                     dist = (temp.Position - pos).magnitude
  3076.                 end
  3077.             end
  3078.         end
  3079.     end
  3080.     return torso
  3081. end
  3082.  
  3083. while true do
  3084.     wait()
  3085.     local target = findNearestTorso(script.Parent.HumanoidRootPart.Position)
  3086.     if target ~= nil then
  3087.         path:ComputeAsync(char.HumanoidRootPart.Position, target.Position)
  3088.  
  3089.         for i, wayPoint in pairs(path:GetWaypoints()) do
  3090.             char.Zombie:MoveTo(wayPoint.Position)
  3091.  
  3092.             if wayPoint.Action == Enum.PathWaypointAction.Jump then
  3093.                 char.Zombie:ChangeState(Enum.HumanoidStateType.Jumping)
  3094.             end
  3095.  
  3096.             char.Zombie.MoveToFinished:wait(0.0000001)
  3097.         end
  3098.     end
  3099. end
  3100.  
  3101. end))
  3102. MeshPart20.Name = "RightUpperLeg"
  3103. MeshPart20.Parent = Model0
  3104. MeshPart20.CFrame = CFrame.new(-0.67828238, 1.46466565, -2.69960117, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3105. MeshPart20.Orientation = Vector3.new(0, 90.1399994, 0)
  3106. MeshPart20.Position = Vector3.new(-0.67828238, 1.46466565, -2.69960117)
  3107. MeshPart20.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3108. MeshPart20.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  3109. MeshPart20.Size = Vector3.new(1.00027561, 1.5362649, 1.00092912)
  3110. MeshPart20.BrickColor = BrickColor.new("Bright blue")
  3111. MeshPart20.CanCollide = false
  3112. MeshPart20.brickColor = BrickColor.new("Bright blue")
  3113. Vector3Value21.Name = "OriginalSize"
  3114. Vector3Value21.Parent = MeshPart20
  3115. Vector3Value21.Value = Vector3.new(1.00027561, 1.5362649, 1.00092912)
  3116. Motor6D22.Name = "RightHip"
  3117. Motor6D22.Parent = MeshPart20
  3118. Motor6D22.C0 = CFrame.new(0.505080223, -0.243262246, 0.00102789141, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3119. Motor6D22.C1 = CFrame.new(0.00382620096, 0.484913796, 0.000486815348, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3120. Motor6D22.Part0 = MeshPart41
  3121. Motor6D22.Part1 = MeshPart20
  3122. Motor6D22.part1 = MeshPart20
  3123. MeshPart23.Name = "RightUpperArm"
  3124. MeshPart23.Parent = Model0
  3125. MeshPart23.CFrame = CFrame.new(-0.685997844, 3.29312539, -3.69646788, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3126. MeshPart23.Orientation = Vector3.new(0, 90.1399994, 0)
  3127. MeshPart23.Position = Vector3.new(-0.685997844, 3.29312539, -3.69646788)
  3128. MeshPart23.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3129. MeshPart23.Color = Color3.new(0.992157, 0.917647, 0.552941)
  3130. MeshPart23.Size = Vector3.new(1.00027633, 1.39554, 1.00025082)
  3131. MeshPart23.BrickColor = BrickColor.new("Cool yellow")
  3132. MeshPart23.CanCollide = false
  3133. MeshPart23.brickColor = BrickColor.new("Cool yellow")
  3134. Vector3Value24.Name = "OriginalSize"
  3135. Vector3Value24.Parent = MeshPart23
  3136. Vector3Value24.Value = Vector3.new(1.00027633, 1.39554, 1.00025082)
  3137. Motor6D25.Name = "RightShoulder"
  3138. Motor6D25.Parent = MeshPart23
  3139. Motor6D25.C0 = CFrame.new(1.25031853, 0.5565539, -0.015560925, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3140. Motor6D25.C1 = CFrame.new(-0.24787569, 0.456878304, -0.00944012403, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3141. Motor6D25.Part0 = MeshPart14
  3142. Motor6D25.Part1 = MeshPart23
  3143. Motor6D25.part1 = MeshPart23
  3144. MeshPart26.Name = "RightLowerLeg"
  3145. MeshPart26.Parent = Model0
  3146. MeshPart26.CFrame = CFrame.new(-0.678020656, 0.910310864, -2.69960189, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3147. MeshPart26.Orientation = Vector3.new(0, 90.1399994, 0)
  3148. MeshPart26.Position = Vector3.new(-0.678020656, 0.910310864, -2.69960189)
  3149. MeshPart26.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3150. MeshPart26.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  3151. MeshPart26.Size = Vector3.new(1.00027585, 1.48964536, 1.00032854)
  3152. MeshPart26.BrickColor = BrickColor.new("Bright blue")
  3153. MeshPart26.CanCollide = false
  3154. MeshPart26.brickColor = BrickColor.new("Bright blue")
  3155. Vector3Value27.Name = "OriginalSize"
  3156. Vector3Value27.Parent = MeshPart26
  3157. Vector3Value27.Value = Vector3.new(1.00027585, 1.48964536, 1.00032854)
  3158. Motor6D28.Name = "RightKnee"
  3159. Motor6D28.Parent = MeshPart26
  3160. Motor6D28.C0 = CFrame.new(0.00382620096, -0.265086174, 0.000426991843, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3161. Motor6D28.C1 = CFrame.new(0.00382620096, 0.289268613, 0.000145851634, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3162. Motor6D28.Part0 = MeshPart20
  3163. Motor6D28.Part1 = MeshPart26
  3164. Motor6D28.part1 = MeshPart26
  3165. MeshPart29.Name = "RightLowerArm"
  3166. MeshPart29.Parent = Model0
  3167. MeshPart29.CFrame = CFrame.new(-0.685555518, 2.90703535, -3.69646835, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3168. MeshPart29.Orientation = Vector3.new(0, 90.1399994, 0)
  3169. MeshPart29.Position = Vector3.new(-0.685555518, 2.90703535, -3.69646835)
  3170. MeshPart29.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3171. MeshPart29.Color = Color3.new(0.992157, 0.917647, 0.552941)
  3172. MeshPart29.Size = Vector3.new(1.00027657, 1.26567209, 1.00025082)
  3173. MeshPart29.BrickColor = BrickColor.new("Cool yellow")
  3174. MeshPart29.CanCollide = false
  3175. MeshPart29.brickColor = BrickColor.new("Cool yellow")
  3176. Vector3Value30.Name = "OriginalSize"
  3177. Vector3Value30.Parent = MeshPart29
  3178. Vector3Value30.Value = Vector3.new(1.00027657, 1.26567209, 1.00025082)
  3179. Motor6D31.Name = "RightElbow"
  3180. Motor6D31.Parent = MeshPart29
  3181. Motor6D31.C0 = CFrame.new(0.00214397907, -0.263139546, -0.00944012403, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3182. Motor6D31.C1 = CFrame.new(0.00214457512, 0.122950554, -0.00989595056, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3183. Motor6D31.Part0 = MeshPart23
  3184. Motor6D31.Part1 = MeshPart29
  3185. Motor6D31.part1 = MeshPart29
  3186. MeshPart32.Name = "RightHand"
  3187. MeshPart32.Parent = Model0
  3188. MeshPart32.CFrame = CFrame.new(-0.680041432, 2.1668787, -3.69776106, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3189. MeshPart32.Orientation = Vector3.new(0, 90.1399994, 0)
  3190. MeshPart32.Position = Vector3.new(-0.680041432, 2.1668787, -3.69776106)
  3191. MeshPart32.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3192. MeshPart32.Color = Color3.new(0.992157, 0.917647, 0.552941)
  3193. MeshPart32.Size = Vector3.new(0.999299049, 0.335255772, 1.00029743)
  3194. MeshPart32.BrickColor = BrickColor.new("Cool yellow")
  3195. MeshPart32.CanCollide = false
  3196. MeshPart32.brickColor = BrickColor.new("Cool yellow")
  3197. Vector3Value33.Name = "OriginalSize"
  3198. Vector3Value33.Parent = MeshPart32
  3199. Vector3Value33.Value = Vector3.new(0.999299049, 0.335255772, 1.00029743)
  3200. Motor6D34.Name = "RightWrist"
  3201. Motor6D34.Parent = MeshPart32
  3202. Motor6D34.C0 = CFrame.new(0.00214457512, -0.682049513, -0.00989595056, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3203. Motor6D34.C1 = CFrame.new(0.000865101814, 0.058106944, -0.0154390335, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3204. Motor6D34.Part0 = MeshPart29
  3205. Motor6D34.Part1 = MeshPart32
  3206. Motor6D34.part1 = MeshPart32
  3207. MeshPart35.Name = "RightFoot"
  3208. MeshPart35.Parent = Model0
  3209. MeshPart35.CFrame = CFrame.new(-0.677906275, 0.167736173, -2.69441152, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3210. MeshPart35.Orientation = Vector3.new(0, 90.1399994, 0)
  3211. MeshPart35.Position = Vector3.new(-0.677906275, 0.167736173, -2.69441152)
  3212. MeshPart35.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3213. MeshPart35.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  3214. MeshPart35.Size = Vector3.new(1.00063133, 0.335407376, 1.00020337)
  3215. MeshPart35.BrickColor = BrickColor.new("Bright blue")
  3216. MeshPart35.CanCollide = false
  3217. MeshPart35.brickColor = BrickColor.new("Bright blue")
  3218. Vector3Value36.Name = "OriginalSize"
  3219. Vector3Value36.Parent = MeshPart35
  3220. Vector3Value36.Value = Vector3.new(1.00063133, 0.335407376, 1.00020337)
  3221. Motor6D37.Name = "RightAnkle"
  3222. Motor6D37.Parent = MeshPart35
  3223. Motor6D37.C0 = CFrame.new(0.00382620096, -0.710731506, 0.000283418223, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3224. Motor6D37.C1 = CFrame.new(0.00901681185, 0.0318431854, 0.000155551359, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3225. Motor6D37.Part0 = MeshPart26
  3226. Motor6D37.Part1 = MeshPart35
  3227. Motor6D37.part1 = MeshPart35
  3228. MeshPart38.Name = "LeftFoot"
  3229. MeshPart38.Parent = Model0
  3230. MeshPart38.CFrame = CFrame.new(-0.675512314, 0.167736173, -1.70284736, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3231. MeshPart38.Orientation = Vector3.new(0, 90.1399994, 0)
  3232. MeshPart38.Position = Vector3.new(-0.675512314, 0.167736173, -1.70284736)
  3233. MeshPart38.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3234. MeshPart38.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  3235. MeshPart38.Size = Vector3.new(1.00063133, 0.335407257, 1.00020337)
  3236. MeshPart38.BrickColor = BrickColor.new("Bright blue")
  3237. MeshPart38.CanCollide = false
  3238. MeshPart38.brickColor = BrickColor.new("Bright blue")
  3239. Vector3Value39.Name = "OriginalSize"
  3240. Vector3Value39.Parent = MeshPart38
  3241. Vector3Value39.Value = Vector3.new(1.00063133, 0.335407257, 1.00020337)
  3242. Motor6D40.Name = "LeftAnkle"
  3243. Motor6D40.Parent = MeshPart38
  3244. Motor6D40.C0 = CFrame.new(-0.00382620096, -0.710131407, 0.00030554086, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3245. Motor6D40.C1 = CFrame.new(-0.00901681185, 0.032443285, 0.000177569687, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3246. Motor6D40.Part0 = MeshPart51
  3247. Motor6D40.Part1 = MeshPart38
  3248. Motor6D40.part1 = MeshPart38
  3249. MeshPart41.Name = "LowerTorso"
  3250. MeshPart41.Parent = Model0
  3251. MeshPart41.CFrame = CFrame.new(-0.677587926, 2.19284177, -2.19834709, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3252. MeshPart41.Orientation = Vector3.new(0, 90.1399994, 0)
  3253. MeshPart41.Position = Vector3.new(-0.677587926, 2.19284177, -2.19834709)
  3254. MeshPart41.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3255. MeshPart41.Color = Color3.new(0.156863, 0.498039, 0.278431)
  3256. MeshPart41.Size = Vector3.new(2.00017595, 0.400037616, 1.00021255)
  3257. MeshPart41.BrickColor = BrickColor.new("Dark green")
  3258. MeshPart41.brickColor = BrickColor.new("Dark green")
  3259. Vector3Value42.Name = "OriginalSize"
  3260. Vector3Value42.Parent = MeshPart41
  3261. Vector3Value42.Value = Vector3.new(2.00017595, 0.400037616, 1.00021255)
  3262. Motor6D43.Name = "Root"
  3263. Motor6D43.Parent = MeshPart41
  3264. Motor6D43.C1 = CFrame.new(0.000280171633, 0.133037761, -0.0142721087, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3265. Motor6D43.Part0 = Part11
  3266. Motor6D43.Part1 = MeshPart41
  3267. Motor6D43.part1 = MeshPart41
  3268. Script44.Name = "Damage Script"
  3269. Script44.Parent = MeshPart41
  3270. table.insert(cors,sandbox(Script44,function()
  3271. function onTouched(hit)
  3272.         local human = hit.Parent:findFirstChild("Humanoid")
  3273.         if (human ~= nil) then
  3274.                 human.Health = human.Health - 0.5
  3275.         end
  3276. end
  3277. script.Parent.Touched:connect(onTouched)
  3278. end))
  3279. MeshPart45.Name = "LeftUpperLeg"
  3280. MeshPart45.Parent = Model0
  3281. MeshPart45.CFrame = CFrame.new(-0.675863564, 1.46466565, -1.69765592, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3282. MeshPart45.Orientation = Vector3.new(0, 90.1399994, 0)
  3283. MeshPart45.Position = Vector3.new(-0.675863564, 1.46466565, -1.69765592)
  3284. MeshPart45.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3285. MeshPart45.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  3286. MeshPart45.Size = Vector3.new(1.00027561, 1.5362649, 1.00092912)
  3287. MeshPart45.BrickColor = BrickColor.new("Bright blue")
  3288. MeshPart45.CanCollide = false
  3289. MeshPart45.brickColor = BrickColor.new("Bright blue")
  3290. Vector3Value46.Name = "OriginalSize"
  3291. Vector3Value46.Parent = MeshPart45
  3292. Vector3Value46.Value = Vector3.new(1.00027561, 1.5362649, 1.00092912)
  3293. Motor6D47.Name = "LeftHip"
  3294. Motor6D47.Parent = MeshPart45
  3295. Motor6D47.C0 = CFrame.new(-0.50451982, -0.243062243, 0.00122789107, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3296. Motor6D47.C1 = CFrame.new(-0.00382620096, 0.4851138, 0.000686740503, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3297. Motor6D47.Part0 = MeshPart41
  3298. Motor6D47.Part1 = MeshPart45
  3299. Motor6D47.part1 = MeshPart45
  3300. MeshPart48.Name = "LeftUpperArm"
  3301. MeshPart48.Parent = Model0
  3302. MeshPart48.CFrame = CFrame.new(-0.678766429, 3.29312539, -0.700763106, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3303. MeshPart48.Orientation = Vector3.new(0, 90.1399994, 0)
  3304. MeshPart48.Position = Vector3.new(-0.678766429, 3.29312539, -0.700763106)
  3305. MeshPart48.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3306. MeshPart48.Color = Color3.new(0.992157, 0.917647, 0.552941)
  3307. MeshPart48.Size = Vector3.new(1.00027633, 1.39554, 1.00025082)
  3308. MeshPart48.BrickColor = BrickColor.new("Cool yellow")
  3309. MeshPart48.CanCollide = false
  3310. MeshPart48.brickColor = BrickColor.new("Cool yellow")
  3311. Vector3Value49.Name = "OriginalSize"
  3312. Vector3Value49.Parent = MeshPart48
  3313. Vector3Value49.Value = Vector3.new(1.00027633, 1.39554, 1.00025082)
  3314. Motor6D50.Name = "LeftShoulder"
  3315. Motor6D50.Parent = MeshPart48
  3316. Motor6D50.C0 = CFrame.new(-1.24955308, 0.556408584, -0.015560925, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3317. Motor6D50.C1 = CFrame.new(0.247964978, 0.456732988, -0.00943991542, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3318. Motor6D50.Part0 = MeshPart14
  3319. Motor6D50.Part1 = MeshPart48
  3320. Motor6D50.part1 = MeshPart48
  3321. MeshPart51.Name = "LeftLowerLeg"
  3322. MeshPart51.Parent = Model0
  3323. MeshPart51.CFrame = CFrame.new(-0.67560178, 0.910310864, -1.69765651, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3324. MeshPart51.Orientation = Vector3.new(0, 90.1399994, 0)
  3325. MeshPart51.Position = Vector3.new(-0.67560178, 0.910310864, -1.69765651)
  3326. MeshPart51.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3327. MeshPart51.Color = Color3.new(0.0509804, 0.411765, 0.67451)
  3328. MeshPart51.Size = Vector3.new(1.00027585, 1.48964536, 1.00032866)
  3329. MeshPart51.BrickColor = BrickColor.new("Bright blue")
  3330. MeshPart51.CanCollide = false
  3331. MeshPart51.brickColor = BrickColor.new("Bright blue")
  3332. Vector3Value52.Name = "OriginalSize"
  3333. Vector3Value52.Parent = MeshPart51
  3334. Vector3Value52.Value = Vector3.new(1.00027585, 1.48964536, 1.00032866)
  3335. Motor6D53.Name = "LeftKnee"
  3336. Motor6D53.Parent = MeshPart51
  3337. Motor6D53.C0 = CFrame.new(-0.00382620096, -0.264486194, 0.000586740673, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3338. Motor6D53.C1 = CFrame.new(-0.00382620096, 0.289868593, 0.00030554086, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3339. Motor6D53.Part0 = MeshPart45
  3340. Motor6D53.Part1 = MeshPart51
  3341. Motor6D53.part1 = MeshPart51
  3342. MeshPart54.Name = "LeftLowerArm"
  3343. MeshPart54.Parent = Model0
  3344. MeshPart54.CFrame = CFrame.new(-0.678323925, 2.90703535, -0.700764775, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3345. MeshPart54.Orientation = Vector3.new(0, 90.1399994, 0)
  3346. MeshPart54.Position = Vector3.new(-0.678323925, 2.90703535, -0.700764775)
  3347. MeshPart54.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3348. MeshPart54.Color = Color3.new(0.992157, 0.917647, 0.552941)
  3349. MeshPart54.Size = Vector3.new(1.00027657, 1.26567209, 1.00025082)
  3350. MeshPart54.BrickColor = BrickColor.new("Cool yellow")
  3351. MeshPart54.CanCollide = false
  3352. MeshPart54.brickColor = BrickColor.new("Cool yellow")
  3353. Vector3Value55.Name = "OriginalSize"
  3354. Vector3Value55.Parent = MeshPart54
  3355. Vector3Value55.Value = Vector3.new(1.00027657, 1.26567209, 1.00025082)
  3356. Motor6D56.Name = "LeftElbow"
  3357. Motor6D56.Parent = MeshPart54
  3358. Motor6D56.C0 = CFrame.new(-0.00166511536, -0.263139546, -0.00943991542, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3359. Motor6D56.C1 = CFrame.new(-0.0016657114, 0.122950554, -0.00989592075, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3360. Motor6D56.Part0 = MeshPart48
  3361. Motor6D56.Part1 = MeshPart54
  3362. Motor6D56.part1 = MeshPart54
  3363. MeshPart57.Name = "LeftHand"
  3364. MeshPart57.Parent = Model0
  3365. MeshPart57.CFrame = CFrame.new(-0.67280364, 2.1668787, -0.699498653, -0.00241400092, 3.49997972e-05, 0.999997497, 0, 1, -3.499991e-05, -0.999997497, -8.44897698e-08, -0.00241400092)
  3366. MeshPart57.Orientation = Vector3.new(0, 90.1399994, 0)
  3367. MeshPart57.Position = Vector3.new(-0.67280364, 2.1668787, -0.699498653)
  3368. MeshPart57.Rotation = Vector3.new(179.169998, 89.8700027, -179.169998)
  3369. MeshPart57.Color = Color3.new(0.992157, 0.917647, 0.552941)
  3370. MeshPart57.Size = Vector3.new(0.999299049, 0.335255831, 1.00029743)
  3371. MeshPart57.BrickColor = BrickColor.new("Cool yellow")
  3372. MeshPart57.CanCollide = false
  3373. MeshPart57.brickColor = BrickColor.new("Cool yellow")
  3374. Vector3Value58.Name = "OriginalSize"
  3375. Vector3Value58.Parent = MeshPart57
  3376. Vector3Value58.Value = Vector3.new(0.999299049, 0.335255831, 1.00029743)
  3377. Motor6D59.Name = "LeftWrist"
  3378. Motor6D59.Parent = MeshPart57
  3379. Motor6D59.C0 = CFrame.new(-0.0016657114, -0.682255626, -0.00989592075, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3380. Motor6D59.C1 = CFrame.new(-0.000386238098, 0.0579008311, -0.0154390335, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  3381. Motor6D59.Part0 = MeshPart54
  3382. Motor6D59.Part1 = MeshPart57
  3383. Motor6D59.part1 = MeshPart57
  3384. Script60.Name = "Respawn"
  3385. Script60.Parent = Model0
  3386. table.insert(cors,sandbox(Script60,function()
  3387. z = script.Parent
  3388.  
  3389. backup = z:clone()
  3390.  
  3391. while true do
  3392.     wait(5)
  3393.     if z.Zombie.Health == 0 then
  3394.         z:Remove()
  3395.         wait(4)
  3396.         backup.Parent = game.Workspace
  3397.         backup.Head:MakeJoints()
  3398.         backup.Torso:MakeJoints()
  3399.     end
  3400.     if z == nil then
  3401.         wait(4)
  3402.         backup.Parent = game.Workspace
  3403.         backup.Head:MakeJoints()
  3404.         backup.Torso:MakeJoints()
  3405.     end
  3406. end
  3407. end))
  3408. Script61.Name = "Health"
  3409. Script61.Parent = Model0
  3410. table.insert(cors,sandbox(Script61,function()
  3411. --Responsible for regening a player's humanoid's health
  3412.  
  3413. -- declarations
  3414. local Figure = script.Parent
  3415. local Head = Figure:WaitForChild("Head")
  3416. local Humanoid = Figure:WaitForChild("Humanoid")
  3417. local regening = false
  3418.  
  3419. -- regeneration
  3420. function regenHealth()
  3421.     if regening then return end
  3422.     regening = true
  3423.    
  3424.     while Humanoid.Health < Humanoid.MaxHealth do
  3425.         local s = wait(1)
  3426.         local health = Humanoid.Health
  3427.         if health > 0 and health < Humanoid.MaxHealth then
  3428.             local newHealthDelta = 0.01 * s * Humanoid.MaxHealth
  3429.             health = health + newHealthDelta
  3430.             Humanoid.Health = math.min(health,Humanoid.MaxHealth)
  3431.         end
  3432.     end
  3433.    
  3434.     if Humanoid.Health > Humanoid.MaxHealth then
  3435.         Humanoid.Health = Humanoid.MaxHealth
  3436.     end
  3437.    
  3438.     regening = false
  3439. end
  3440.  
  3441. Humanoid.HealthChanged:connect(regenHealth)
  3442.  
  3443. end))
  3444. Script62.Name = "Animate"
  3445. Script62.Parent = Model0
  3446. table.insert(cors,sandbox(Script62,function()
  3447. function   waitForChild(parent, childName)
  3448.     local child = parent:findFirstChild(childName)
  3449.     if child then return child end
  3450.     while true do
  3451.         child = parent.ChildAdded:wait()
  3452.         if child.Name==childName then return child end
  3453.     end
  3454. end
  3455.  
  3456. local Figure = script.Parent
  3457. local Humanoid = waitForChild(Figure, "Zombie")
  3458. local pose = "Standing"
  3459.  
  3460. local currentAnim = ""
  3461. local currentAnimInstance = nil
  3462. local currentAnimTrack = nil
  3463. local currentAnimKeyframeHandler = nil
  3464. local currentAnimSpeed = 1.0
  3465. local animTable = {}
  3466. local animNames = {
  3467.     idle =  {  
  3468.                 { id = "http://www.roblox.com/asset/?id=507766666", weight = 1 },
  3469.                 { id = "http://www.roblox.com/asset/?id=507766951", weight = 1 },
  3470.                 { id = "http://www.roblox.com/asset/?id=507766388", weight = 9 }
  3471.             },
  3472.     walk =  {  
  3473.                 { id = "http://www.roblox.com/asset/?id=507777826", weight = 10 }
  3474.             },
  3475.     run =   {
  3476.                 { id = "http://www.roblox.com/asset/?id=507767714", weight = 10 }
  3477.             },
  3478.     swim =  {
  3479.                 { id = "http://www.roblox.com/asset/?id=507784897", weight = 10 }
  3480.             },
  3481.     swimidle =  {
  3482.                 { id = "http://www.roblox.com/asset/?id=507785072", weight = 10 }
  3483.             },
  3484.     jump =  {
  3485.                 { id = "http://www.roblox.com/asset/?id=507765000", weight = 10 }
  3486.             },
  3487.     fall =  {
  3488.                 { id = "http://www.roblox.com/asset/?id=507767968", weight = 10 }
  3489.             },
  3490.     climb = {
  3491.                 { id = "http://www.roblox.com/asset/?id=507765644", weight = 10 }
  3492.             },
  3493.     sit =   {
  3494.                 { id = "http://www.roblox.com/asset/?id=507768133", weight = 10 }
  3495.             }, 
  3496.     toolnone = {
  3497.                 { id = "http://www.roblox.com/asset/?id=507768375", weight = 10 }
  3498.             },
  3499.     toolslash = {
  3500.                 { id = "http://www.roblox.com/asset/?id=507768375", weight = 10 }
  3501. --              { id = "slash.xml", weight = 10 }
  3502.             },
  3503.     toollunge = {
  3504.                 { id = "http://www.roblox.com/asset/?id=507768375", weight = 10 }
  3505.             },
  3506.     wave = {
  3507.                 { id = "http://www.roblox.com/asset/?id=507770239", weight = 10 }
  3508.             },
  3509.     point = {
  3510.                 { id = "http://www.roblox.com/asset/?id=507770453", weight = 10 }
  3511.             },
  3512.     dance = {
  3513.                 { id = "http://www.roblox.com/asset/?id=507771019", weight = 10 },
  3514.                 { id = "http://www.roblox.com/asset/?id=507771955", weight = 10 },
  3515.                 { id = "http://www.roblox.com/asset/?id=507772104", weight = 10 }
  3516.             },
  3517.     dance2 = {
  3518.                 { id = "http://www.roblox.com/asset/?id=507776043", weight = 10 },
  3519.                 { id = "http://www.roblox.com/asset/?id=507776720", weight = 10 },
  3520.                 { id = "http://www.roblox.com/asset/?id=507776879", weight = 10 }
  3521.             },
  3522.     dance3 = {
  3523.                 { id = "http://www.roblox.com/asset/?id=507777268", weight = 10 },
  3524.                 { id = "http://www.roblox.com/asset/?id=507777451", weight = 10 },
  3525.                 { id = "http://www.roblox.com/asset/?id=507777623", weight = 10 }
  3526.             },
  3527.     laugh = {
  3528.                 { id = "http://www.roblox.com/asset/?id=507770818", weight = 10 }
  3529.             },
  3530.     cheer = {
  3531.                 { id = "http://www.roblox.com/asset/?id=507770677", weight = 10 }
  3532.             },
  3533. }
  3534.  
  3535. -- Existance in this list signifies that it is an emote, the value indicates if it is a looping emote
  3536. local emoteNames = { wave = false, point = false, dance = true, dance2 = true, dance3 = true, laugh = false, cheer = false}
  3537.  
  3538. math.randomseed(tick())
  3539.  
  3540. function configureAnimationSet(name, fileList)
  3541.     if (animTable[name] ~= nil) then
  3542.         for _, connection in pairs(animTable[name].connections) do
  3543.             connection:disconnect()
  3544.         end
  3545.     end
  3546.     animTable[name] = {}
  3547.     animTable[name].count = 0
  3548.     animTable[name].totalWeight = 0
  3549.     animTable[name].connections = {}
  3550.  
  3551.     -- check for config values
  3552.     local config = script:FindFirstChild(name)
  3553.     if (config ~= nil) then
  3554. --      print("Loading anims " .. name)
  3555.         table.insert(animTable[name].connections, config.ChildAdded:connect(function(child) configureAnimationSet(name, fileList) end))
  3556.         table.insert(animTable[name].connections, config.ChildRemoved:connect(function(child) configureAnimationSet(name, fileList) end))
  3557.         local idx = 1
  3558.         for _, childPart in pairs(config:GetChildren()) do
  3559.             if (childPart:IsA("Animation")) then
  3560.                 table.insert(animTable[name].connections, childPart.Changed:connect(function(property) configureAnimationSet(name, fileList) end))
  3561.                 animTable[name][idx] = {}
  3562.                 animTable[name][idx].anim = childPart
  3563.                 local weightObject = childPart:FindFirstChild("Weight")
  3564.                 if (weightObject == nil) then
  3565.                     animTable[name][idx].weight = 1
  3566.                 else
  3567.                     animTable[name][idx].weight = weightObject.Value
  3568.                 end
  3569.                 animTable[name].count = animTable[name].count + 1
  3570.                 animTable[name].totalWeight = animTable[name].totalWeight + animTable[name][idx].weight
  3571. --              print(name .. " [" .. idx .. "] " .. animTable[name][idx].anim.AnimationId .. " (" .. animTable[name][idx].weight .. ")")
  3572.                 idx = idx + 1
  3573.             end
  3574.         end
  3575.     end
  3576.  
  3577.     -- fallback to defaults
  3578.     if (animTable[name].count <= 0) then
  3579.         for idx, anim in pairs(fileList) do
  3580.             animTable[name][idx] = {}
  3581.             animTable[name][idx].anim = Instance.new("Animation")
  3582.             animTable[name][idx].anim.Name = name
  3583.             animTable[name][idx].anim.AnimationId = anim.id
  3584.             animTable[name][idx].weight = anim.weight
  3585.             animTable[name].count = animTable[name].count + 1
  3586.             animTable[name].totalWeight = animTable[name].totalWeight + anim.weight
  3587. --          print(name .. " [" .. idx .. "] " .. anim.id .. " (" .. anim.weight .. ")")
  3588.         end
  3589.     end
  3590. end
  3591.  
  3592. -- Setup animation objects
  3593. function scriptChildModified(child)
  3594.     local fileList = animNames[child.Name]
  3595.     if (fileList ~= nil) then
  3596.         configureAnimationSet(child.Name, fileList)
  3597.     end
  3598. end
  3599.  
  3600. script.ChildAdded:connect(scriptChildModified)
  3601. script.ChildRemoved:connect(scriptChildModified)
  3602.  
  3603.  
  3604. for name, fileList in pairs(animNames) do
  3605.     configureAnimationSet(name, fileList)
  3606. end
  3607.  
  3608. -- ANIMATION
  3609.  
  3610. -- declarations
  3611. local toolAnim = "None"
  3612. local toolAnimTime = 0
  3613.  
  3614. local jumpAnimTime = 0
  3615. local jumpAnimDuration = 0.31
  3616.  
  3617. local toolTransitionTime = 0.1
  3618. local fallTransitionTime = 0.2
  3619.  
  3620. -- functions
  3621.  
  3622. function stopAllAnimations()
  3623.     local oldAnim = currentAnim
  3624.  
  3625.     -- return to idle if finishing an emote
  3626.     if (emoteNames[oldAnim] ~= nil and emoteNames[oldAnim] == false) then
  3627.         oldAnim = "idle"
  3628.     end
  3629.  
  3630.     currentAnim = ""
  3631.     currentAnimInstance = nil
  3632.     if (currentAnimKeyframeHandler ~= nil) then
  3633.         currentAnimKeyframeHandler:disconnect()
  3634.     end
  3635.  
  3636.     if (currentAnimTrack ~= nil) then
  3637.         currentAnimTrack:Stop()
  3638.         currentAnimTrack:Destroy()
  3639.         currentAnimTrack = nil
  3640.     end
  3641.     return oldAnim
  3642. end
  3643.  
  3644. function setAnimationSpeed(speed)
  3645.     if speed ~= currentAnimSpeed then
  3646.         currentAnimSpeed = speed
  3647.         currentAnimTrack:AdjustSpeed(currentAnimSpeed)
  3648.     end
  3649. end
  3650.  
  3651. function keyFrameReachedFunc(frameName)
  3652.     if (frameName == "End") then
  3653. --      print("Keyframe : ".. frameName)
  3654.  
  3655.         local repeatAnim = currentAnim
  3656.         -- return to idle if finishing an emote
  3657.         if (emoteNames[repeatAnim] ~= nil and emoteNames[repeatAnim] == false) then
  3658.             repeatAnim = "idle"
  3659.         end
  3660.        
  3661.         local animSpeed = currentAnimSpeed
  3662.         playAnimation(repeatAnim, 0.15, Humanoid)
  3663.         setAnimationSpeed(animSpeed)
  3664.     end
  3665. end
  3666.  
  3667. -- Preload animations
  3668. function playAnimation(animName, transitionTime, humanoid)
  3669.        
  3670.     local roll = math.random(1, animTable[animName].totalWeight)
  3671.     local origRoll = roll
  3672.     local idx = 1
  3673.     while (roll > animTable[animName][idx].weight) do
  3674.         roll = roll - animTable[animName][idx].weight
  3675.         idx = idx + 1
  3676.     end
  3677.    
  3678. --  print(animName .. " " .. idx .. " [" .. origRoll .. "]")
  3679.    
  3680.     local anim = animTable[animName][idx].anim
  3681.  
  3682.     -- switch animation    
  3683.     if (anim ~= currentAnimInstance) then
  3684.        
  3685.         if (currentAnimTrack ~= nil) then
  3686.             currentAnimTrack:Stop(transitionTime)
  3687.             currentAnimTrack:Destroy()
  3688.         end
  3689.  
  3690.         currentAnimSpeed = 1.0
  3691.    
  3692.         -- load it to the humanoid; get AnimationTrack
  3693.         currentAnimTrack = humanoid:LoadAnimation(anim)
  3694.          
  3695.         -- play the animation
  3696.         currentAnimTrack:Play(transitionTime)
  3697.         currentAnim = animName
  3698.         currentAnimInstance = anim
  3699.  
  3700.         -- set up keyframe name triggers
  3701.         if (currentAnimKeyframeHandler ~= nil) then
  3702.             currentAnimKeyframeHandler:disconnect()
  3703.         end
  3704.         currentAnimKeyframeHandler = currentAnimTrack.KeyframeReached:connect(keyFrameReachedFunc)
  3705.        
  3706.     end
  3707.  
  3708. end
  3709.  
  3710. -------------------------------------------------------------------------------------------
  3711. -------------------------------------------------------------------------------------------
  3712.  
  3713. local toolAnimName = ""
  3714. local toolAnimTrack = nil
  3715. local toolAnimInstance = nil
  3716. local currentToolAnimKeyframeHandler = nil
  3717.  
  3718. function toolKeyFrameReachedFunc(frameName)
  3719.     if (frameName == "End") then
  3720. --      print("Keyframe : ".. frameName)   
  3721.         playToolAnimation(toolAnimName, 0.0, Humanoid)
  3722.     end
  3723. end
  3724.  
  3725.  
  3726. function playToolAnimation(animName, transitionTime, humanoid)   
  3727.        
  3728.         local roll = math.random(1, animTable[animName].totalWeight)
  3729.         local origRoll = roll
  3730.         local idx = 1
  3731.         while (roll > animTable[animName][idx].weight) do
  3732.             roll = roll - animTable[animName][idx].weight
  3733.             idx = idx + 1
  3734.         end
  3735. --      print(animName .. " * " .. idx .. " [" .. origRoll .. "]")
  3736.         local anim = animTable[animName][idx].anim
  3737.  
  3738.         if (toolAnimInstance ~= anim) then
  3739.            
  3740.             if (toolAnimTrack ~= nil) then
  3741.                 toolAnimTrack:Stop()
  3742.                 toolAnimTrack:Destroy()
  3743.                 transitionTime = 0
  3744.             end
  3745.                    
  3746.             -- load it to the humanoid; get AnimationTrack
  3747.             toolAnimTrack = humanoid:LoadAnimation(anim)
  3748.              
  3749.             -- play the animation
  3750.             toolAnimTrack:Play(transitionTime)
  3751.             toolAnimName = animName
  3752.             toolAnimInstance = anim
  3753.  
  3754.             currentToolAnimKeyframeHandler = toolAnimTrack.KeyframeReached:connect(toolKeyFrameReachedFunc)
  3755.         end
  3756. end
  3757.  
  3758. function stopToolAnimations()
  3759.     local oldAnim = toolAnimName
  3760.  
  3761.     if (currentToolAnimKeyframeHandler ~= nil) then
  3762.         currentToolAnimKeyframeHandler:disconnect()
  3763.     end
  3764.  
  3765.     toolAnimName = ""
  3766.     toolAnimInstance = nil
  3767.     if (toolAnimTrack ~= nil) then
  3768.         toolAnimTrack:Stop()
  3769.         toolAnimTrack:Destroy()
  3770.         toolAnimTrack = nil
  3771.     end
  3772.  
  3773.  
  3774.     return oldAnim
  3775. end
  3776.  
  3777. -------------------------------------------------------------------------------------------
  3778. -------------------------------------------------------------------------------------------
  3779.  
  3780.  
  3781. function onRunning(speed)
  3782.     if speed > 0.01 then
  3783.         local scale = 15.0
  3784.         playAnimation("walk", 0.1, Humanoid)
  3785.         setAnimationSpeed(speed / scale)
  3786.         pose = "Running"
  3787.     else
  3788.         playAnimation("idle", 0.1, Humanoid)
  3789.         pose = "Standing"
  3790.     end
  3791. end
  3792.  
  3793. function onDied()
  3794.     pose = "Dead"
  3795. end
  3796.  
  3797. function onJumping()
  3798.     playAnimation("jump", 0.1, Humanoid)
  3799.     jumpAnimTime = jumpAnimDuration
  3800.     pose = "Jumping"
  3801. end
  3802.  
  3803. function onClimbing(speed)
  3804.     local scale = 5.0
  3805.     playAnimation("climb", 0.1, Humanoid)
  3806.     setAnimationSpeed(speed / scale)
  3807.     pose = "Climbing"
  3808. end
  3809.  
  3810. function onGettingUp()
  3811.     pose = "GettingUp"
  3812. end
  3813.  
  3814. function onFreeFall()
  3815.     if (jumpAnimTime <= 0) then
  3816.         playAnimation("fall", fallTransitionTime, Humanoid)
  3817.     end
  3818.     pose = "FreeFall"
  3819. end
  3820.  
  3821. function onFallingDown()
  3822.     pose = "FallingDown"
  3823. end
  3824.  
  3825. function onSeated()
  3826.     pose = "Seated"
  3827. end
  3828.  
  3829. function onPlatformStanding()
  3830.     pose = "PlatformStanding"
  3831. end
  3832.  
  3833. function onSwimming(speed)
  3834.     if speed > 1.00 then
  3835.         local scale = 10.0
  3836.         playAnimation("swim", 0.4, Humanoid)
  3837.         setAnimationSpeed(speed / scale)
  3838.         pose = "Swimming"
  3839.     else
  3840.         playAnimation("swimidle", 0.4, Humanoid)
  3841.         pose = "Standing"
  3842.     end
  3843. end
  3844.  
  3845. function getTool() 
  3846.     for _, kid in ipairs(Figure:GetChildren()) do
  3847.         if kid.className == "Tool" then return kid end
  3848.     end
  3849.     return nil
  3850. end
  3851.  
  3852. function getToolAnim(tool)
  3853.     for _, c in ipairs(tool:GetChildren()) do
  3854.         if c.Name == "toolanim" and c.className == "StringValue" then
  3855.             return c
  3856.         end
  3857.     end
  3858.     return nil
  3859. end
  3860.  
  3861. function animateTool()
  3862.    
  3863.     if (toolAnim == "None") then
  3864.         playToolAnimation("toolnone", toolTransitionTime, Humanoid)
  3865.         return
  3866.     end
  3867.  
  3868.     if (toolAnim == "Slash") then
  3869.         playToolAnimation("toolslash", 0, Humanoid)
  3870.         return
  3871.     end
  3872.  
  3873.     if (toolAnim == "Lunge") then
  3874.         playToolAnimation("toollunge", 0, Humanoid)
  3875.         return
  3876.     end
  3877. end
  3878.  
  3879. function moveSit()
  3880.     RightShoulder.MaxVelocity = 0.15
  3881.     LeftShoulder.MaxVelocity = 0.15
  3882.     RightShoulder:SetDesiredAngle(3.14 /2)
  3883.     LeftShoulder:SetDesiredAngle(-3.14 /2)
  3884.     RightHip:SetDesiredAngle(3.14 /2)
  3885.     LeftHip:SetDesiredAngle(-3.14 /2)
  3886. end
  3887.  
  3888. local lastTick = 0
  3889.  
  3890. function move(time)
  3891.     local amplitude = 1
  3892.     local frequency = 1
  3893.     local deltaTime = time - lastTick
  3894.     lastTick = time
  3895.  
  3896.     local climbFudge = 0
  3897.     local setAngles = false
  3898.  
  3899.     if (jumpAnimTime > 0) then
  3900.         jumpAnimTime = jumpAnimTime - deltaTime
  3901.     end
  3902.  
  3903.     if (pose == "FreeFall" and jumpAnimTime <= 0) then
  3904.         playAnimation("fall", fallTransitionTime, Humanoid)
  3905.     elseif (pose == "Seated") then
  3906.         playAnimation("sit", 0.5, Humanoid)
  3907.         return
  3908.     elseif (pose == "Running") then
  3909.         playAnimation("walk", 0.1, Humanoid)
  3910.     elseif (pose == "Dead" or pose == "GettingUp" or pose == "FallingDown" or pose == "Seated" or pose == "PlatformStanding") then
  3911.         stopAllAnimations()
  3912.         amplitude = 0.1
  3913.         frequency = 1
  3914.         setAngles = true
  3915.     end
  3916.  
  3917.     -- Tool Animation handling
  3918.     local tool = getTool()
  3919.     if tool then
  3920.    
  3921.         animStringValueObject = getToolAnim(tool)
  3922.  
  3923.         if animStringValueObject then
  3924.             toolAnim = animStringValueObject.Value
  3925.             -- message recieved, delete StringValue
  3926.             animStringValueObject.Parent = nil
  3927.             toolAnimTime = time + .3
  3928.         end
  3929.  
  3930.         if time > toolAnimTime then
  3931.             toolAnimTime = 0
  3932.             toolAnim = "None"
  3933.         end
  3934.  
  3935.         animateTool()      
  3936.     else
  3937.         stopToolAnimations()
  3938.         toolAnim = "None"
  3939.         toolAnimInstance = nil
  3940.         toolAnimTime = 0
  3941.     end
  3942. end
  3943.  
  3944. -- connect events
  3945. Humanoid.Died:connect(onDied)
  3946. Humanoid.Running:connect(onRunning)
  3947. Humanoid.Jumping:connect(onJumping)
  3948. Humanoid.Climbing:connect(onClimbing)
  3949. Humanoid.GettingUp:connect(onGettingUp)
  3950. Humanoid.FreeFalling:connect(onFreeFall)
  3951. Humanoid.FallingDown:connect(onFallingDown)
  3952. Humanoid.Seated:connect(onSeated)
  3953. Humanoid.PlatformStanding:connect(onPlatformStanding)
  3954. Humanoid.Swimming:connect(onSwimming)
  3955.  
  3956. -- setup emote chat hook
  3957. script.msg.Changed:connect(function(msg)
  3958.     script.msg.Value = ""
  3959.     local emote = ""
  3960.     if (string.sub(msg, 1, 3) == "/e ") then
  3961.         emote = string.sub(msg, 4)
  3962.     elseif (string.sub(msg, 1, 7) == "/emote ") then
  3963.         emote = string.sub(msg, 8)
  3964.     end
  3965.    
  3966.     if (pose == "Standing" and emoteNames[emote] ~= nil) then
  3967.         playAnimation(emote, 0.1, Humanoid)
  3968.     end
  3969. --  print("===> " .. string.sub(msg, 1, 3) .. "(" .. emote .. ")")
  3970. end)
  3971.  
  3972.  
  3973. -- main program
  3974.  
  3975. local runService = game:service("RunService");
  3976.  
  3977. -- print("bottom")
  3978.  
  3979. -- initialize to idle
  3980. playAnimation("idle", 0.1, Humanoid)
  3981. pose = "Standing"
  3982.  
  3983. while Figure.Parent~=nil do
  3984.     local _, time = wait(0.1)
  3985.     move(time)
  3986. end
  3987.  
  3988.  
  3989.  
  3990. end))
  3991. StringValue63.Name = "msg"
  3992. StringValue63.Parent = Script62
  3993. StringValue64.Name = "climb"
  3994. StringValue64.Parent = Script62
  3995. Animation65.Name = "ClimbAnim"
  3996. Animation65.Parent = StringValue64
  3997. Animation65.AnimationId = "http://www.roblox.com/asset/?id=616156119"
  3998. StringValue66.Name = "fall"
  3999. StringValue66.Parent = Script62
  4000. Animation67.Name = "FallAnim"
  4001. Animation67.Parent = StringValue66
  4002. Animation67.AnimationId = "http://www.roblox.com/asset/?id=616157476"
  4003. StringValue68.Name = "idle"
  4004. StringValue68.Parent = Script62
  4005. Animation69.Name = "Animation1"
  4006. Animation69.Parent = StringValue68
  4007. Animation69.AnimationId = "http://www.roblox.com/asset/?id=616158929"
  4008. NumberValue70.Name = "Weight"
  4009. NumberValue70.Parent = Animation69
  4010. NumberValue70.Value = 9
  4011. Animation71.Name = "Animation2"
  4012. Animation71.Parent = StringValue68
  4013. Animation71.AnimationId = "http://www.roblox.com/asset/?id=616160636"
  4014. NumberValue72.Name = "Weight"
  4015. NumberValue72.Parent = Animation71
  4016. NumberValue72.Value = 1
  4017. StringValue73.Name = "jump"
  4018. StringValue73.Parent = Script62
  4019. Animation74.Name = "JumpAnim"
  4020. Animation74.Parent = StringValue73
  4021. Animation74.AnimationId = "http://www.roblox.com/asset/?id=616161997"
  4022. StringValue75.Name = "sit"
  4023. StringValue75.Parent = Script62
  4024. Animation76.Name = "SitAnim"
  4025. Animation76.Parent = StringValue75
  4026. Animation76.AnimationId = "http://www.roblox.com/asset/?id=507768133"
  4027. StringValue77.Name = "swim"
  4028. StringValue77.Parent = Script62
  4029. Animation78.Name = "Swim"
  4030. Animation78.Parent = StringValue77
  4031. Animation78.AnimationId = "http://www.roblox.com/asset/?id=616165109"
  4032. StringValue79.Name = "swimidle"
  4033. StringValue79.Parent = Script62
  4034. Animation80.Name = "SwimIdle"
  4035. Animation80.Parent = StringValue79
  4036. Animation80.AnimationId = "http://www.roblox.com/asset/?id=616166655"
  4037. StringValue81.Name = "toolnone"
  4038. StringValue81.Parent = Script62
  4039. Animation82.Name = "ToolNoneAnim"
  4040. Animation82.Parent = StringValue81
  4041. Animation82.AnimationId = "http://www.roblox.com/asset/?id=507768375"
  4042. StringValue83.Name = "walk"
  4043. StringValue83.Parent = Script62
  4044. Animation84.Name = "RunAnim"
  4045. Animation84.Parent = StringValue83
  4046. Animation84.AnimationId = "http://www.roblox.com/asset/?id=616168032"
  4047. Script85.Name = "SoundScript"
  4048. Script85.Parent = Model0
  4049. table.insert(cors,sandbox(Script85,function()
  4050. local moan = script.Parent.Head.Moan
  4051. local moan2 = script.parent.Head.Moan2
  4052. local moan3 = script.parent.Head.Moan3
  4053. local moan4 = script.Parent.Head.Moan4
  4054.  
  4055. while true do
  4056.     moan:Play()
  4057.     wait(8)
  4058.    
  4059.     moan2:Play()
  4060.     wait(5)
  4061.    
  4062.     moan3:Play()
  4063.     wait(7)
  4064.    
  4065.     moan4:Play()
  4066.     wait(6)
  4067. end
  4068.  
  4069.  
  4070. local death = script.Parent.Head.Death
  4071.  
  4072.  
  4073. end))
  4074. for i,v in pairs(mas:GetChildren()) do
  4075.     v.Parent = workspace
  4076.     pcall(function() v:MakeJoints() end)
  4077. end
  4078. mas:Destroy()
  4079. for i,v in pairs(cors) do
  4080.     spawn(function()
  4081.         pcall(v)
  4082.     end)
  4083. end
  4084. end
  4085.  
  4086. for i = 1,5 do
  4087. createZombie()
  4088. end
  4089.  
  4090.  
  4091.  
  4092. Touched = false
  4093. DoorUnLocked2.Touched:connect(function(player)
  4094. if Touched == false then
  4095. Touched = true
  4096. Tool0B:Remove()
  4097. Part1B:Remove()
  4098. DoorUnLocked2.Position = Vector3.new(10.4, 6.434, 231.317)
  4099.  DoorLocked2.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  4100. SoundAlfa:Stop()
  4101. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = CFrame.new(146.243, 1666.5, 136.792)
  4102. wait(1)
  4103. Touched = false
  4104. end
  4105. end)
  4106. local screen = Instance.new("Part")
  4107. screen.Parent = workspace
  4108. screen.Anchored = true
  4109. screen.Size = Vector3.new(0.1, 3, 4.5)
  4110. screen.CanCollide = true
  4111. screen.Position = Vector3.new(-57.2, 6.94, 220.7)
  4112. screen.Material = "Plastic"
  4113. screen.BrickColor = BrickColor.new("Really black")
  4114.  
  4115.  
  4116. local TVFloor = Instance.new("Part")
  4117. TVFloor.Parent = workspace
  4118. TVFloor.Anchored = true
  4119. TVFloor.Size = Vector3.new(15, 1, 12)
  4120. TVFloor.CanCollide = false
  4121. TVFloor.Position = Vector3.new(-48.739, 2.8, 220.917)
  4122. TVFloor.Transparency = 1
  4123. Touched = false
  4124. TVFloor.Touched:connect(function(player)
  4125. if Touched == false then
  4126. Touched = true
  4127. local screenmesh = Instance.new("SpecialMesh", screen)
  4128. screenmesh.Scale = Vector3.new(0.1, 3, 4.5)
  4129. screenmesh.TextureId = "rbxassetid://12095085"
  4130. TVFloor.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  4131. local SoundScreen = Instance.new("Sound")
  4132. local Id = "132081621"
  4133. SoundScreen.Parent = screen
  4134. SoundScreen.SoundId = "rbxassetid://"..Id
  4135. SoundScreen.Playing = true
  4136. SoundScreen.Looped = true
  4137. SoundScreen.Volume = 1
  4138. wait(1)
  4139. Touched = false
  4140. end
  4141. end)
  4142.  
  4143.  
  4144.  
  4145.  
  4146.  
  4147. local CellerDoor2 = Instance.new("Part")
  4148. CellerDoor2.Parent = workspace
  4149. CellerDoor2.Anchored = true
  4150. CellerDoor2.Size = Vector3.new(4, 7,2)
  4151. CellerDoor2.CanCollide = true
  4152. CellerDoor2.Position = Vector3.new(146.482, 1669.5, 131.572)
  4153. CellerDoor2.Material = "Corroded Metal"
  4154. CellerDoor2.BrickColor = BrickColor.new("Really black")
  4155. Touched = false
  4156. CellerDoor2.Touched:connect(function(player)
  4157. if Touched == false then
  4158. Touched = true
  4159. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = CFrame.new(3.718, 2.4, 231.087)
  4160. wait(1)
  4161. Touched = false
  4162. end
  4163. end)
  4164.  
  4165. local CellerWall6 = Instance.new("Part")
  4166. CellerWall6.Parent = workspace
  4167. CellerWall6.Anchored = true
  4168. CellerWall6.Size = Vector3.new(55, 1, 44)
  4169. CellerWall6.CanCollide = true
  4170. CellerWall6.Position = Vector3.new(129.427, 1679, 153.559)
  4171. CellerWall6.Material = "Concrete"
  4172.  
  4173. local CellerWall5 = Instance.new("Part")
  4174. CellerWall5.Parent = workspace
  4175. CellerWall5.Anchored = true
  4176. CellerWall5.Size = Vector3.new(1, 13,23)
  4177. CellerWall5.CanCollide = true
  4178. CellerWall5.Position = Vector3.new(131.769, 1672.5, 142.493)
  4179. CellerWall5.Material = "Concrete"
  4180.  
  4181. local CellerWall4 = Instance.new("Part")
  4182. CellerWall4.Parent = workspace
  4183. CellerWall4.Anchored = true
  4184. CellerWall4.Size = Vector3.new(1, 13,45)
  4185. CellerWall4.CanCollide = true
  4186. CellerWall4.Position = Vector3.new(102.781, 1672.5, 153.497)
  4187. CellerWall4.Material = "Concrete"
  4188.  
  4189. local CellerWall3 = Instance.new("Part")
  4190. CellerWall3.Parent = workspace
  4191. CellerWall3.Anchored = true
  4192. CellerWall3.Size = Vector3.new(1, 13,45)
  4193. CellerWall3.CanCollide = true
  4194. CellerWall3.Position = Vector3.new(156.781, 1672.5, 153.497)
  4195. CellerWall3.Material = "Concrete"
  4196.  
  4197. local CellerWall2 = Instance.new("Part")
  4198. CellerWall2.Parent = workspace
  4199. CellerWall2.Anchored = true
  4200. CellerWall2.Size = Vector3.new(55, 13,1)
  4201. CellerWall2.CanCollide = true
  4202. CellerWall2.Position = Vector3.new(129.794, 1672.5, 175.493)
  4203. CellerWall2.Material = "Concrete"
  4204.  
  4205. local CellerWall1 = Instance.new("Part")
  4206. CellerWall1.Parent = workspace
  4207. CellerWall1.Anchored = true
  4208. CellerWall1.Size = Vector3.new(55, 13,1)
  4209. CellerWall1.CanCollide = true
  4210. CellerWall1.Position = Vector3.new(129.794, 1672.5, 131.493)
  4211. CellerWall1.Material = "Concrete"
  4212.  
  4213.  
  4214. local CellerBazeFloor2 = Instance.new("Part")
  4215. CellerBazeFloor2.Parent = workspace
  4216. CellerBazeFloor2.Anchored = true
  4217. CellerBazeFloor2.Size = Vector3.new(55, 1, 44)
  4218. CellerBazeFloor2.CanCollide = true
  4219. CellerBazeFloor2.Position = Vector3.new(129.427, 1666, 153.559)
  4220. CellerBazeFloor2.Material = "Concrete"
  4221. local SoundCeller = Instance.new("Sound")
  4222. local Id = "9039981149"
  4223. SoundCeller.Parent = CellerBazeFloor2
  4224. SoundCeller.SoundId = "rbxassetid://"..Id
  4225. SoundCeller.Playing = true
  4226. SoundCeller.Looped = true
  4227. SoundCeller.Volume = 1
  4228.  
  4229.  
  4230. local CharacterPart2= Instance.new("Part")
  4231. CharacterPart2.Parent = workspace
  4232. CharacterPart2.Anchored = true
  4233. CharacterPart2.Size = Vector3.new(30, 1, 18)
  4234. CharacterPart2.CanCollide = false
  4235. CharacterPart2.Position = Vector3.new(117.144, 1666.5, 141.912)
  4236. CharacterPart2.Transparency = 1
  4237. Touched = false
  4238. CharacterPart2.Touched:connect(function(player)
  4239. if Touched == false then
  4240. Touched = true
  4241.  
  4242.   CharacterPart2.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  4243. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4244.                Text = "[ERROR_CODE]:hello.";
  4245.                Color = Color3.fromRGB(255, 255, 255);
  4246.            })
  4247. wait(3)
  4248. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4249.                Text = "[ERROR_CODE]:I'm your friend.";
  4250.                Color = Color3.fromRGB(255, 255, 255);
  4251.            })
  4252. wait(2)
  4253. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4254.                Text = "[ERROR_CODE]:You're in a coma and I want to help you get out of it.";
  4255.                Color = Color3.fromRGB(255, 255, 255);
  4256.            })
  4257. wait(3)
  4258. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4259.                Text = "[ERROR_CODE]:Just trust me, you need to end this dream.";
  4260.                Color = Color3.fromRGB(255, 255, 255);
  4261.            })
  4262.  
  4263. wait(2)
  4264. SoundCeller:Stop()
  4265. HarassmentSound.Playing = true
  4266. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = CFrame.new(-1561.953, 391.1, 536.761)
  4267. game.Players.LocalPlayer.Character.Humanoid.WalkSpeed = 18
  4268. wait(2)
  4269. SoulsLabelFrame.Visible = true
  4270. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4271.                Text = "[ERROR_CODE]:Find all souls.";
  4272.                Color = Color3.fromRGB(255, 255, 255);
  4273.            })
  4274.  
  4275.  
  4276. wait(1)
  4277. Touched = false
  4278. end
  4279. end)
  4280.  
  4281. local CellerBazeFloor1 = Instance.new("Part")
  4282. CellerBazeFloor1.Parent = workspace
  4283. CellerBazeFloor1.Anchored = true
  4284. CellerBazeFloor1.Size = Vector3.new(55, 1, 44)
  4285. CellerBazeFloor1.CanCollide = true
  4286. CellerBazeFloor1.Position = Vector3.new(129.427, 1666, 153.559)
  4287. CellerBazeFloor1.Material = "Concrete"
  4288.  
  4289. Touched = false
  4290. CellerBazeFloor1.Touched:connect(function(player)
  4291. if Touched == false then
  4292. Touched = true
  4293.  
  4294.   CellerBazeFloor1.Position = Vector3.new(9999999999999, 9999999999999, 9999999999999)
  4295.  
  4296. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4297.                Text = "[ERROR_CODE]:I'm here!";
  4298.                Color = Color3.fromRGB(255, 255, 255);
  4299.            })
  4300. wait(1)
  4301. Touched = false
  4302. end
  4303. end)
  4304.  
  4305.  
  4306.  
  4307.  
  4308.  
  4309. wait(1)
  4310. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4311.                Text = "[ERROR_CODE]:Oh, You Waked Up.";
  4312.                Color = Color3.fromRGB(255, 255, 255);
  4313.            })
  4314. wait(2.5)
  4315.  
  4316. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4317.                Text = "["..game.Players.LocalPlayer.DisplayName.."]:Who are you?";
  4318.                Color = Color3.fromRGB(255, 255, 255);
  4319.            })
  4320. wait(2.5)
  4321.  
  4322. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4323.                Text = "[ERROR_CODE]:Don't worry its your dream.";
  4324.                Color = Color3.fromRGB(255, 255, 255);
  4325.            })
  4326. wait(2)
  4327. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4328.                Text = "[ERROR_CODE]:I am yours... no matter.";
  4329.                Color = Color3.fromRGB(255, 255, 255);
  4330.            })
  4331. wait(3)
  4332. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4333.                Text = "[ERROR_CODE]:Soon I'll show yorself.";
  4334.                Color = Color3.fromRGB(255, 255, 255);
  4335.            })
  4336. local ScreenGui = Instance.new("ScreenGui")
  4337. local LockwalkingFrame = Instance.new("ImageButton")
  4338. local LockwalkingFrame2 = Instance.new("ImageButton")
  4339. local ResumeTextButton = Instance.new("TextButton")
  4340. local WakeUpTextButton = Instance.new("TextButton")
  4341. local me = game.Players.LocalPlayer
  4342. local mouse = me:GetMouse()
  4343. local char = me.Character
  4344. local hum = char:FindFirstChild('Humanoid')
  4345. local hd = char:FindFirstChild('Head')
  4346. local ts = char:FindFirstChild('Torso') or char:FindFirstChild('UpperTorso')
  4347. local ra = char:FindFirstChild('Right Arm') or char:FindFirstChild('RightUpperArm')
  4348. local la = char:FindFirstChild('Left Arm') or char:FindFirstChild('LeftUpperArm')
  4349. local rl = char:FindFirstChild('Right Leg') or char:FindFirstChild('RightUpperLeg')
  4350. local ll = char:FindFirstChild('Left Leg') or char:FindFirstChild('LeftUpperLeg')
  4351. local root = char:FindFirstChild('HumanoidRootPart')
  4352. local rj = root:FindFirstChild('RootJoint')
  4353. local rs = ts:FindFirstChild('Right Shoulder')
  4354. local ls = ts:FindFirstChild('Left Shoulder')
  4355. local rh = ts:FindFirstChild('Right Hip')
  4356. local lh = ts:FindFirstChild('Left Hip')
  4357. local nk = ts:FindFirstChild('Neck')
  4358. local anim = char:FindFirstChild('Animate')
  4359. local base = workspace:FindFirstChild('Baseplate') or workspace:FindFirstChild('Base')
  4360. local cantimestop = true
  4361. local cooldown = false
  4362. local cc = workspace.CurrentCamera
  4363. local cos = math.cos
  4364. local sin = math.sin
  4365. local rad = math.rad
  4366. local rand = math.random
  4367. local cfn = CFrame.new
  4368. local cfa = CFrame.Angles
  4369. local v3 = Vector3.new
  4370. local str = string
  4371. local unfreeze = {}
  4372. local health = {}
  4373. local connect = {}
  4374. local sine = 0
  4375. local effects = nil
  4376.  
  4377. ScreenGui.Parent = game.CoreGui
  4378.  
  4379.  
  4380. LockwalkingFrame.Parent = ScreenGui
  4381. LockwalkingFrame.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
  4382. LockwalkingFrame.BackgroundTransparency = 1
  4383. LockwalkingFrame.Position = UDim2.new(0, 0, 0.3, 0)
  4384. LockwalkingFrame.Size = UDim2.new(0, 500, 0, 500)
  4385.  
  4386.  
  4387. LockwalkingFrame2.Parent = ScreenGui
  4388. LockwalkingFrame2.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
  4389. LockwalkingFrame2.BackgroundTransparency = 1
  4390. LockwalkingFrame2.Position = UDim2.new(0.7, 0, 0.5, 0)
  4391. LockwalkingFrame2.Size = UDim2.new(0, 300, 0, 300)
  4392. LockwalkingFrame.Visible = false
  4393. LockwalkingFrame2.Visible = false
  4394.  
  4395.  
  4396.  
  4397. local CameraPart = Instance.new("Part")
  4398. CameraPart.Parent = workspace
  4399. CameraPart.Anchored = true
  4400. CameraPart.Size = Vector3.new(4, 1, 2)
  4401. CameraPart.CanCollide = false
  4402. CameraPart.Position = Vector3.new(-1597.811, 559, 578)
  4403. CameraPart.Transparency = 1
  4404.  
  4405. local player = game.Players.LocalPlayer
  4406. local character = player.Character
  4407. local cam = workspace.CurrentCamera
  4408.  
  4409.  
  4410.  
  4411.  
  4412.  
  4413.  
  4414. if char:FindFirstChild('Effects') then
  4415.     effects = char:FindFirstChild('Effects')
  4416. else
  4417.     effects = Instance.new('Folder', char)
  4418.     effects.Name = 'Effects'
  4419. end
  4420.  
  4421. ArtificialHB = Instance.new('BindableEvent', script)
  4422. ArtificialHB.Name = 'Heartbeat'
  4423. script:WaitForChild('Heartbeat')
  4424.  
  4425. frame = 1 / 60
  4426. tf = 0
  4427. allowframeloss = false
  4428. tossremainder = false
  4429. lastframe = tick()
  4430. script.Heartbeat:Fire()
  4431.  
  4432. game:GetService('RunService').Heartbeat:connect(function(s, p)
  4433.     tf = tf + s
  4434.     if tf >= frame then
  4435.         if allowframeloss then
  4436.             script.Heartbeat:Fire()
  4437.             lastframe = tick()
  4438.         else
  4439.             for i = 1, math.floor(tf / frame) do
  4440.                 script.Heartbeat:Fire()
  4441.             end
  4442.             lastframe = tick()
  4443.         end
  4444.         if tossremainder then
  4445.             tf = 0
  4446.         else
  4447.             tf = tf - frame * math.floor(tf / frame)
  4448.         end
  4449.     end
  4450. end)
  4451.  
  4452. function swait(t)
  4453.     if t == 0 or t == nil then
  4454.         script.Heartbeat.Event:Wait()
  4455.     else
  4456.         for i = 0, t do
  4457.             script.Heartbeat.Event:Wait()
  4458.         end
  4459.     end
  4460. end
  4461.  
  4462. function sound(id, parent, vol, pitch, timepos)
  4463.     local s = Instance.new('Sound')
  4464.     s.Parent = parent
  4465.     s.SoundId = id
  4466.     s.Volume = vol
  4467.     s.PlaybackSpeed = pitch
  4468.     s.TimePosition = timepos
  4469.     s:Play()
  4470.     game.Debris:AddItem(s, s.PlaybackSpeed + 5)
  4471. end
  4472.  
  4473. function camshake(duration, intensity)
  4474.     coroutine.wrap(function()
  4475.         for i = 1, duration do
  4476.             hum.CameraOffset = hum.CameraOffset:lerp(v3(rand(-1, 1), rand(-1, 1), rand(-1, 1)), 0.1 * intensity)
  4477.             swait()
  4478.         end
  4479.         hum.CameraOffset = v3(0, 0, 0)
  4480.     end)()
  4481. end
  4482.  
  4483. function findascendant(obj, class)
  4484.     local par = obj
  4485.     local ret = nil
  4486.     pcall(function()
  4487.         repeat
  4488.             par = par.Parent
  4489.             if par:IsA(class) then
  4490.                 ret = par
  4491.                 break
  4492.             end
  4493.         until par == nil
  4494.     end)
  4495.     return ret
  4496. end
  4497.  
  4498.  
  4499. function timestop()
  4500.     cantimestop = false
  4501.     coroutine.wrap(function()
  4502.     local effect1 = Instance.new('Part', effects)
  4503.     effect1.Shape = 'Ball'
  4504.     effect1.Material = 'ForceField'
  4505.     effect1.Anchored = true
  4506.     effect1.CanCollide = false
  4507.     effect1.Size = v3(0, 0, 0)
  4508.     effect1.Transparency = 0
  4509.    
  4510.     for i,v in pairs(workspace:GetDescendants()) do
  4511.         if v:IsA('BasePart') then
  4512.             if not v.Anchored and not findascendant(v, 'Tool') and not findascendant(v, 'HopperBin') then
  4513.                 if not v:IsDescendantOf(char) then
  4514.                     v.Anchored = true
  4515.                     table.insert(unfreeze, v)
  4516.                 end
  4517.             end
  4518.         end
  4519.        
  4520.         if v:IsA('Humanoid') then
  4521.             local last = v.Health
  4522.             local always = last
  4523.             local e = v.HealthChanged:connect(function(hp)
  4524.                 if last - hp > 0 then
  4525.                     table.insert(health, {humanoid = v, change = last - hp})
  4526.                 end
  4527.                 last = hp
  4528.                 v.Health = always
  4529.             end)
  4530.             table.insert(connect, e)
  4531.         end
  4532.         if v:IsA('BodyVelocity') then
  4533.             local lastforce = v.MaxForce
  4534.             v.MaxForce = v3(0, 0, 0)
  4535.             table.insert(unfreeze, {force = v, change = lastforce})
  4536.         end
  4537.         if v:IsA('BodyPosition') then
  4538.             local lastposition = v.MaxForce
  4539.             local lastD = v.D
  4540.             local lastP = v.P
  4541.             v.MaxForce = v3(0, 0, 0)
  4542.             v.D = 0
  4543.             v.P = 0
  4544.             table.insert(unfreeze, {position = v, change = lastposition, dchange = lastD, pchange = lastP})
  4545.         end
  4546.         if v:IsA('BodyForce') then
  4547.             local lastforce2 = v.Force
  4548.             v.Force = v3(0, 0, 0)
  4549.             table.insert(unfreeze, {force2 = v, fchange = lastforce2})
  4550.         end
  4551.     end
  4552.     ee = workspace.DescendantAdded:Connect(function(v)
  4553.         if v:IsA('BasePart') then
  4554.             if not v.Anchored and not findascendant(v, 'Tool') and not findascendant(v, 'HopperBin') then
  4555.                 if not v:IsDescendantOf(char) then
  4556.                     v.Anchored = true
  4557.                     table.insert(unfreeze, v)
  4558.                 end
  4559.             end
  4560.         end
  4561.         if v:IsA('Sound') then
  4562.             if not v:IsDescendantOf(char) then
  4563.                 if v.IsPlaying then
  4564.                     v:Pause()
  4565.                     table.insert(unfreeze, v)
  4566.                 end
  4567.             end
  4568.         end
  4569.         if v:IsA('Humanoid') then
  4570.             local last = v.Health
  4571.             local always = last
  4572.             local e = v.HealthChanged:connect(function(hp)
  4573.                 if last - hp > 0 then
  4574.                     table.insert(health, {humanoid = v, change = last - hp})
  4575.                 end
  4576.                 last = hp
  4577.                 v.Health = always
  4578.             end)
  4579.             table.insert(connect, e)
  4580.         end
  4581.     end)
  4582.     cce = Instance.new('ColorCorrectionEffect', game.Lighting)
  4583.     coroutine.wrap(function()
  4584.         for i = 1, 10 do
  4585.             camshake(70, 2)
  4586.             cce.Saturation = cce.Saturation - 0.1
  4587.             cce.Contrast = cce.Contrast + 0.1
  4588.             swait(5)
  4589.         end
  4590.     end)()
  4591.     coroutine.wrap(function()
  4592.     for i = 1, 1000 do
  4593.         effect1.CFrame = ts.CFrame
  4594.         effect1.Size = effect1.Size:lerp(v3(50, 50, 50), 0.015)
  4595.         effect1.Transparency = effect1.Transparency + 0.010
  4596.         if effect1.Transparency >= 1 then
  4597.             effect1:Destroy()
  4598.         end
  4599.         swait()
  4600.     end
  4601.     end)()
  4602.     wait(0.5)
  4603.     local effect2 = Instance.new('Part', effects)
  4604.     local effect3 = Instance.new('Part', effects)
  4605.     effect3.Shape = 'Ball'
  4606.     effect3.Material = 'ForceField'
  4607.     effect3.Anchored = true
  4608.     effect3.CanCollide = false
  4609.     effect3.Size = v3(0, 0, 0)
  4610.     effect3.Transparency = 0
  4611.     effect2.Shape = 'Ball'
  4612.     effect2.Material = 'ForceField'
  4613.     effect2.Anchored = true
  4614.     effect2.CanCollide = false
  4615.     effect2.Size = v3(40, 40, 40)
  4616.     effect2.Transparency = 1
  4617.     coroutine.wrap(function()
  4618.         for i = 1, 15 do
  4619.             effect2.Transparency = effect2.Transparency - 0.11
  4620.             swait()
  4621.         end
  4622.     end)()
  4623.     coroutine.wrap(function()
  4624.         for i = 1, 1000 do
  4625.             effect3.CFrame = ts.CFrame
  4626.             effect3.Size = effect3.Size:lerp(v3(50, 50, 50), 0.015)
  4627.             effect3.Transparency = effect3.Transparency + 0.010
  4628.             if effect3.Transparency >= 1 then
  4629.                 effect3:Destroy()
  4630.             end
  4631.             swait()
  4632.         end
  4633.     end)()
  4634.     for i = 1, 1000 do
  4635.         effect2.CFrame = ts.CFrame
  4636.         effect2.Size = effect2.Size:lerp(v3(0, 0, 0), 0.015)
  4637.         effect2.Transparency = effect2.Transparency + 0.015
  4638.         if effect2.Transparency >= 1 then
  4639.             effect2:Destroy()
  4640.         end
  4641.         swait()
  4642.     end
  4643.     end)()
  4644.     wait(1.5)
  4645.     cooldown = true
  4646. end
  4647.  
  4648. function timeresume()
  4649.     coroutine.wrap(function()
  4650.    
  4651.     coroutine.wrap(function()
  4652.         for i = 1, 10 do
  4653.             camshake(20, 0.3)
  4654.             cce.Saturation = cce.Saturation + 0.1
  4655.             cce.Contrast = cce.Contrast - 0.1
  4656.             swait(5)
  4657.         end
  4658.         cce:Destroy()
  4659.     end)()
  4660.     coroutine.wrap(function()
  4661.         wait(1.5)
  4662.     for i,v in pairs(unfreeze) do
  4663.         pcall(function()
  4664.             v.Anchored = false
  4665.         end)
  4666.         pcall(function()
  4667.             v:Resume()
  4668.         end)
  4669.     end
  4670.     for i,v in pairs(connect) do
  4671.         pcall(function()
  4672.             v:Disconnect()
  4673.         end)
  4674.     end
  4675.     for i,v in pairs(health) do
  4676.         pcall(function()
  4677.             local humanoid = v.humanoid
  4678.             humanoid.Health = humanoid.Health - v.change
  4679.             if humanoid.Parent:FindFirstChild('Health') then
  4680.                 pcall(function()
  4681.                     humanoid.Parent.Health.Disabled = false
  4682.                 end)
  4683.             end
  4684.         end)
  4685.     end
  4686.     pcall(function()
  4687.         ee:Disconnect()
  4688.     end)
  4689.     health = {}
  4690.     unfreeze = {}
  4691.     end)()
  4692.     cantimestop = true
  4693.     end)()
  4694.     wait(1.5)
  4695.     cooldown = false
  4696. end
  4697.  
  4698.  
  4699. local PortalPart1 = Instance.new("Part")
  4700. PortalPart1.Parent = workspace
  4701. PortalPart1.Anchored = true
  4702. PortalPart1.Size = Vector3.new(2.001, 15, 12)
  4703. PortalPart1.CanCollide = true
  4704. PortalPart1.Position = Vector3.new(-1570.681, 555, 602.302)  
  4705. PortalPart1.BrickColor = BrickColor.new("Institutional white")
  4706. PortalPart1.Material = "ForceField"
  4707. local PortalPart1Mesh = Instance.new("SpecialMesh", PortalPart1)
  4708. PortalPart1Mesh.MeshType = Enum.MeshType.Sphere
  4709. local PortalPart2 = Instance.new("Part")
  4710. PortalPart2.Parent = workspace
  4711. PortalPart2.Anchored = true
  4712. PortalPart2.Size = Vector3.new(0.001, 15, 12)
  4713. PortalPart2.CanCollide = true
  4714. PortalPart2.Position = Vector3.new(-1570.681, 555, 602.302)  
  4715. PortalPart2.BrickColor = BrickColor.new("Institutional white")
  4716. PortalPart2.Material = "Neon"
  4717. local PortalPart2Mesh = Instance.new("SpecialMesh", PortalPart2)
  4718. PortalPart2Mesh.MeshType = Enum.MeshType.Sphere
  4719.  
  4720.  
  4721.  
  4722.  
  4723. local TouchForEnd = Instance.new("Part")
  4724. TouchForEnd.Parent = game.workspace
  4725. TouchForEnd.Anchored = true
  4726. TouchForEnd.Size = Vector3.new(49, 1, 40)
  4727. TouchForEnd.CanCollide = false
  4728. TouchForEnd.Position = Vector3.new(-1597.1, 548.5, 605.666)
  4729. TouchForEnd.Transparency = 1
  4730.  
  4731.  
  4732.  
  4733.  
  4734. Touched = false
  4735. TouchForEnd.Touched:connect(function(player)
  4736. if Touched == false then
  4737. Touched = true
  4738. game.Players.LocalPlayer.Character.Humanoid.WalkSpeed = 5
  4739. lighting.FogEnd = 10000
  4740. LockwalkingFrame.Visible = true
  4741. LockwalkingFrame2.Visible = true
  4742. HarassmentSound:Stop()
  4743. TouchForEnd:Remove()
  4744.  
  4745.  
  4746. cam.CameraSubject = CameraPart
  4747.  
  4748. local TimeStopSound = Instance.new("Sound")
  4749. local Id = "5832251994"
  4750. TimeStopSound.Parent = game.Workspace
  4751. TimeStopSound.SoundId = "rbxassetid://"..Id
  4752. TimeStopSound.Playing = true
  4753. TimeStopSound.Looped = false
  4754. TimeStopSound.Volume = 1
  4755.  
  4756. timestop()
  4757.  
  4758. local EndSound = Instance.new("Sound")
  4759. local Id = "1842572665"
  4760. EndSound.Parent = game.Workspace
  4761. EndSound.SoundId = "rbxassetid://"..Id
  4762. EndSound.Playing = true
  4763. EndSound.Looped = true
  4764. EndSound.Volume = 1
  4765.  
  4766.  
  4767. local WalkAndTouchPart = Instance.new("Part")
  4768. WalkAndTouchPart.Parent = workspace
  4769. WalkAndTouchPart.Anchored = true
  4770. WalkAndTouchPart.Size = Vector3.new(2, 1, 46)
  4771. WalkAndTouchPart.CanCollide = false
  4772. WalkAndTouchPart.Transparency = 1
  4773. WalkAndTouchPart.Position = Vector3.new(-1581.35, 548, 605.662)
  4774. Touched = false
  4775. WalkAndTouchPart.Touched:connect(function(player)
  4776. if Touched == false then
  4777. Touched = true
  4778. WalkAndTouchPart:Remove()
  4779. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4780.                Text = "[ERROR_CODE]:Wait!";
  4781.                Color = Color3.fromRGB(255, 255, 255);
  4782.            })
  4783.  
  4784.  
  4785. wait(2)
  4786.  
  4787.  
  4788.  
  4789. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4790.                Text = "["..game.Players.LocalPlayer.DisplayName.."]:What?";
  4791.                Color = Color3.fromRGB(255, 255, 255);
  4792.            })
  4793. wait(2.5)
  4794.  
  4795.  
  4796. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4797.                Text = "[ERROR_CODE]:You need to think before you enter the portal.";
  4798.                Color = Color3.fromRGB(255, 255, 255);
  4799.            })
  4800.  
  4801. wait(3)
  4802.  
  4803.  
  4804. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4805.                Text = "[ERROR_CODE]:If you enter the portal, you will find out what happened to you. If not, you will just wake up.";
  4806.                Color = Color3.fromRGB(255, 255, 255);
  4807.            })
  4808. wait(2)
  4809.  
  4810.  
  4811. game.StarterGui:SetCore("ChatMakeSystemMessage", {
  4812.                Text = "[ERROR_CODE]:It's up to you.";
  4813.                Color = Color3.fromRGB(255, 255, 255);
  4814.            })
  4815. wait(1)
  4816. ResumeTextButton.Name = "ResumeTextButton"
  4817. ResumeTextButton.Parent = ScreenGui
  4818. ResumeTextButton.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  4819. ResumeTextButton.Position = UDim2.new(0.1, 0, 0.3, 0)
  4820. ResumeTextButton.Size = UDim2.new(0, 300, 0, 200)
  4821. ResumeTextButton.Font = Enum.Font.GothamBold
  4822. ResumeTextButton.Text = "Resume Adventure"
  4823. ResumeTextButton.TextColor3 = Color3.fromRGB(0, 0, 0)
  4824. ResumeTextButton.TextScaled = true
  4825. ResumeTextButton.TextSize = 14.000
  4826. ResumeTextButton.TextWrapped = true
  4827. ResumeTextButton.MouseButton1Down:connect(function()
  4828. ResumeTextButton:Destroy()
  4829. WakeUpTextButton:Destroy()
  4830. game.Players.LocalPlayer.Character:WaitForChild("Humanoid"):MoveTo(PortalPart2.Position)
  4831. game.Players.LocalPlayer.Character:WaitForChild("Humanoid").MoveToFinished:Wait()
  4832. timeresume()
  4833. wait(2)
  4834. game:FindService("RunService"):Set3dRenderingEnabled(true)
  4835. end)
  4836.  
  4837.  
  4838.  
  4839. WakeUpTextButton.Name = "WakeUpTextButton"
  4840. WakeUpTextButton.Parent = ScreenGui
  4841. WakeUpTextButton.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
  4842. WakeUpTextButton.Position = UDim2.new(0.6, 0, 0.3, 0)
  4843. WakeUpTextButton.Size = UDim2.new(0, 300, 0, 200)
  4844. WakeUpTextButton.Font = Enum.Font.GothamBold
  4845. WakeUpTextButton.Text = "Wake Up"
  4846. WakeUpTextButton.TextColor3 = Color3.fromRGB(255, 255, 255)
  4847. WakeUpTextButton.TextScaled = true
  4848. WakeUpTextButton.TextSize = 14.000
  4849. WakeUpTextButton.TextWrapped = true
  4850. WakeUpTextButton.MouseButton1Down:connect(function()
  4851. LockwalkingFrame2:Destroy()
  4852. LockwalkingFrame:Destroy()
  4853. EndSound:Stop()
  4854. WakeUpTextButton:Destroy()
  4855. ResumeTextButton:Destroy()
  4856. game:FindService("RunService"):Set3dRenderingEnabled(false)
  4857. local WakeUpSound = Instance.new("Sound")
  4858. local Id = "1837093849"
  4859. WakeUpSound.Parent = game.Workspace
  4860. WakeUpSound.SoundId = "rbxassetid://"..Id
  4861. WakeUpSound.Playing = true
  4862. WakeUpSound.Looped = true
  4863. WakeUpSound.Volume = 1
  4864. timeresume()
  4865. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = CFrame.new(-1612.68, 0.8, 566.899)
  4866. lighting.FogEnd = 20
  4867. wait(5)
  4868. game:FindService("RunService"):Set3dRenderingEnabled(true)
  4869. local Camera = game.Workspace.Camera
  4870. Camera.CameraType = Enum.CameraType.Scriptable
  4871. Camera.CFrame = CFrame.new(459.51, 57.152, 68.027)
  4872. wait(0.05)
  4873. local Camera = game.Workspace.Camera
  4874. Camera.CameraType = Enum.CameraType.Scriptable
  4875. Camera.CFrame = CFrame.new(459.51, 57.152, 67.027)
  4876. wait(0.05)
  4877. local Camera = game.Workspace.Camera
  4878. Camera.CameraType = Enum.CameraType.Scriptable
  4879. Camera.CFrame = CFrame.new(459.51, 57.152, 66.027)
  4880. wait(0.05)
  4881. local Camera = game.Workspace.Camera
  4882. Camera.CameraType = Enum.CameraType.Scriptable
  4883. Camera.CFrame = CFrame.new(459.51, 57.152, 65.027)
  4884. wait(0.05)
  4885. local Camera = game.Workspace.Camera
  4886. Camera.CameraType = Enum.CameraType.Scriptable
  4887. Camera.CFrame = CFrame.new(459.51, 57.152, 64.027)
  4888. wait(0.05)
  4889. local Camera = game.Workspace.Camera
  4890. Camera.CameraType = Enum.CameraType.Scriptable
  4891. Camera.CFrame = CFrame.new(459.51, 57.152, 63.027)
  4892. wait(0.05)
  4893. local Camera = game.Workspace.Camera
  4894. Camera.CameraType = Enum.CameraType.Scriptable
  4895. Camera.CFrame = CFrame.new(459.51, 57.152, 62.027)
  4896. wait(0.05)
  4897. local Camera = game.Workspace.Camera
  4898. Camera.CameraType = Enum.CameraType.Scriptable
  4899. Camera.CFrame = CFrame.new(459.51, 57.152, 61.027)
  4900. wait(0.05)
  4901. local Camera = game.Workspace.Camera
  4902. Camera.CameraType = Enum.CameraType.Scriptable
  4903. Camera.CFrame = CFrame.new(459.51, 57.152, 60.027)
  4904. wait(0.05)
  4905. local Camera = game.Workspace.Camera
  4906. Camera.CameraType = Enum.CameraType.Scriptable
  4907. Camera.CFrame = CFrame.new(459.51, 57.152, 59.027)
  4908. wait(0.05)
  4909. local Camera = game.Workspace.Camera
  4910. Camera.CameraType = Enum.CameraType.Scriptable
  4911. Camera.CFrame = CFrame.new(459.51, 57.152, 58.027)
  4912. wait(0.05)
  4913. local Camera = game.Workspace.Camera
  4914. Camera.CameraType = Enum.CameraType.Scriptable
  4915. Camera.CFrame = CFrame.new(459.51, 57.152, 57.027)
  4916. wait(0.05)
  4917. local Camera = game.Workspace.Camera
  4918. Camera.CameraType = Enum.CameraType.Scriptable
  4919. Camera.CFrame = CFrame.new(459.51, 57.152, 56.027)
  4920. wait(0.05)
  4921. local Camera = game.Workspace.Camera
  4922. Camera.CameraType = Enum.CameraType.Scriptable
  4923. Camera.CFrame = CFrame.new(459.51, 57.152, 55.027)
  4924. wait(0.05)
  4925. local Camera = game.Workspace.Camera
  4926. Camera.CameraType = Enum.CameraType.Scriptable
  4927. Camera.CFrame = CFrame.new(459.51, 57.152, 54.027)
  4928. wait(0.05)
  4929. local Camera = game.Workspace.Camera
  4930. Camera.CameraType = Enum.CameraType.Scriptable
  4931. Camera.CFrame = CFrame.new(459.51, 57.152, 53.027)
  4932. wait(0.05)
  4933. local Camera = game.Workspace.Camera
  4934. Camera.CameraType = Enum.CameraType.Scriptable
  4935. Camera.CFrame = CFrame.new(459.51, 57.152, 52.027)
  4936. wait(0.05)
  4937. local Camera = game.Workspace.Camera
  4938. Camera.CameraType = Enum.CameraType.Scriptable
  4939. Camera.CFrame = CFrame.new(459.51, 57.152, 51.027)
  4940. wait(0.05)
  4941. local Camera = game.Workspace.Camera
  4942. Camera.CameraType = Enum.CameraType.Scriptable
  4943. Camera.CFrame = CFrame.new(459.51, 57.152, 50.027)
  4944. wait(0.05)
  4945. local Camera = game.Workspace.Camera
  4946. Camera.CameraType = Enum.CameraType.Scriptable
  4947. Camera.CFrame = CFrame.new(459.51, 57.152, 49.027)
  4948. wait(0.05)
  4949. local Camera = game.Workspace.Camera
  4950. Camera.CameraType = Enum.CameraType.Scriptable
  4951. Camera.CFrame = CFrame.new(459.51, 57.152, 48.027)
  4952. wait(0.05)
  4953. local Camera = game.Workspace.Camera
  4954. Camera.CameraType = Enum.CameraType.Scriptable
  4955. Camera.CFrame = CFrame.new(459.51, 57.152, 47.027)
  4956. wait(0.05)
  4957. local Camera = game.Workspace.Camera
  4958. Camera.CameraType = Enum.CameraType.Scriptable
  4959. Camera.CFrame = CFrame.new(459.51, 57.152, 46.027)
  4960. wait(0.05)
  4961. local Camera = game.Workspace.Camera
  4962. Camera.CameraType = Enum.CameraType.Scriptable
  4963. Camera.CFrame = CFrame.new(459.51, 57.152, 45.027)
  4964. wait(0.05)
  4965. local Camera = game.Workspace.Camera
  4966. Camera.CameraType = Enum.CameraType.Scriptable
  4967. Camera.CFrame = CFrame.new(459.51, 57.152, 44.027)
  4968. wait(0.05)
  4969. local Camera = game.Workspace.Camera
  4970. Camera.CameraType = Enum.CameraType.Scriptable
  4971. Camera.CFrame = CFrame.new(459.51, 57.152, 43.027)
  4972. wait(0.05)
  4973. local Camera = game.Workspace.Camera
  4974. Camera.CameraType = Enum.CameraType.Scriptable
  4975. Camera.CFrame = CFrame.new(459.51, 57.152, 42.027)
  4976. wait(0.05)
  4977. local Camera = game.Workspace.Camera
  4978. Camera.CameraType = Enum.CameraType.Scriptable
  4979. Camera.CFrame = CFrame.new(459.51, 57.152, 41.027)
  4980. wait(0.05)
  4981. local Camera = game.Workspace.Camera
  4982. Camera.CameraType = Enum.CameraType.Scriptable
  4983. Camera.CFrame = CFrame.new(459.51, 57.152, 40.027)
  4984. wait(0.05)
  4985. local Camera = game.Workspace.Camera
  4986. Camera.CameraType = Enum.CameraType.Scriptable
  4987. Camera.CFrame = CFrame.new(459.51, 57.152, 39.027)
  4988. wait(0.05)
  4989. local Camera = game.Workspace.Camera
  4990. Camera.CameraType = Enum.CameraType.Scriptable
  4991. Camera.CFrame = CFrame.new(459.51, 57.152, 38.027)
  4992. wait(0.05)
  4993. local Camera = game.Workspace.Camera
  4994. Camera.CameraType = Enum.CameraType.Scriptable
  4995. Camera.CFrame = CFrame.new(459.51, 57.152, 37.027)
  4996. wait(0.05)
  4997. local Camera = game.Workspace.Camera
  4998. Camera.CameraType = Enum.CameraType.Scriptable
  4999. Camera.CFrame = CFrame.new(459.51, 57.152, 36.027)
  5000. wait(0.05)
  5001. local Camera = game.Workspace.Camera
  5002. Camera.CameraType = Enum.CameraType.Scriptable
  5003. Camera.CFrame = CFrame.new(459.51, 57.152, 35.027)
  5004. wait(0.05)
  5005. local Camera = game.Workspace.Camera
  5006. Camera.CameraType = Enum.CameraType.Scriptable
  5007. Camera.CFrame = CFrame.new(459.51, 57.152, 34.027)
  5008. wait(0.05)
  5009. local Camera = game.Workspace.Camera
  5010. Camera.CameraType = Enum.CameraType.Scriptable
  5011. Camera.CFrame = CFrame.new(459.51, 57.152, 33.027)
  5012. wait(0.05)
  5013. local Camera = game.Workspace.Camera
  5014. Camera.CameraType = Enum.CameraType.Scriptable
  5015. Camera.CFrame = CFrame.new(459.51, 57.152, 32.027)
  5016. wait(0.05)
  5017. local Camera = game.Workspace.Camera
  5018. Camera.CameraType = Enum.CameraType.Scriptable
  5019. Camera.CFrame = CFrame.new(459.51, 57.152, 31.027)
  5020. wait(0.05)
  5021. local Camera = game.Workspace.Camera
  5022. Camera.CameraType = Enum.CameraType.Scriptable
  5023. Camera.CFrame = CFrame.new(459.51, 57.152, 30.027)
  5024. wait(0.05)
  5025. local Camera = game.Workspace.Camera
  5026. Camera.CameraType = Enum.CameraType.Scriptable
  5027. Camera.CFrame = CFrame.new(459.51, 57.152, 29.027)
  5028. wait(0.05)
  5029. local Camera = game.Workspace.Camera
  5030. Camera.CameraType = Enum.CameraType.Scriptable
  5031. Camera.CFrame = CFrame.new(459.51, 57.152, 28.027)
  5032. wait(0.05)
  5033. local Camera = game.Workspace.Camera
  5034. Camera.CameraType = Enum.CameraType.Scriptable
  5035. Camera.CFrame = CFrame.new(459.51, 57.152, 27.027)
  5036. wait(0.05)
  5037. local Camera = game.Workspace.Camera
  5038. Camera.CameraType = Enum.CameraType.Scriptable
  5039. Camera.CFrame = CFrame.new(459.51, 57.152, 26.027)
  5040. wait(0.05)
  5041. local Camera = game.Workspace.Camera
  5042. Camera.CameraType = Enum.CameraType.Scriptable
  5043. Camera.CFrame = CFrame.new(459.51, 57.152, 25.027)
  5044. wait(0.05)
  5045. local Camera = game.Workspace.Camera
  5046. Camera.CameraType = Enum.CameraType.Scriptable
  5047. Camera.CFrame = CFrame.new(459.51, 57.152, 24.027)
  5048. wait(0.05)
  5049. local Camera = game.Workspace.Camera
  5050. Camera.CameraType = Enum.CameraType.Scriptable
  5051. Camera.CFrame = CFrame.new(459.51, 57.152, 23.027)
  5052. wait(0.05)
  5053. local Camera = game.Workspace.Camera
  5054. Camera.CameraType = Enum.CameraType.Scriptable
  5055. Camera.CFrame = CFrame.new(459.51, 57.152, 22.027)
  5056. wait(0.05)
  5057. local Camera = game.Workspace.Camera
  5058. Camera.CameraType = Enum.CameraType.Scriptable
  5059. Camera.CFrame = CFrame.new(459.51, 57.152, 21.027)
  5060. wait(0.05)
  5061. local Camera = game.Workspace.Camera
  5062. Camera.CameraType = Enum.CameraType.Scriptable
  5063. Camera.CFrame = CFrame.new(459.51, 57.152, 20.027)
  5064. wait(0.05)
  5065. local Camera = game.Workspace.Camera
  5066. Camera.CameraType = Enum.CameraType.Scriptable
  5067. Camera.CFrame = CFrame.new(459.51, 57.152, 19.027)
  5068. wait(0.05)
  5069. local Camera = game.Workspace.Camera
  5070. Camera.CameraType = Enum.CameraType.Scriptable
  5071. Camera.CFrame = CFrame.new(459.51, 57.152, 18.027)
  5072. wait(0.05)
  5073. local Camera = game.Workspace.Camera
  5074. Camera.CameraType = Enum.CameraType.Scriptable
  5075. Camera.CFrame = CFrame.new(459.51, 57.152, 17.027)
  5076. wait(0.05)
  5077. local Camera = game.Workspace.Camera
  5078. Camera.CameraType = Enum.CameraType.Scriptable
  5079. Camera.CFrame = CFrame.new(459.51, 57.152, 16.027)
  5080. wait(0.05)
  5081. local Camera = game.Workspace.Camera
  5082. Camera.CameraType = Enum.CameraType.Scriptable
  5083. Camera.CFrame = CFrame.new(459.51, 57.152, 15.027)
  5084. wait(0.05)
  5085. local Camera = game.Workspace.Camera
  5086. Camera.CameraType = Enum.CameraType.Scriptable
  5087. Camera.CFrame = CFrame.new(459.51, 57.152, 14.027)
  5088. wait(0.05)
  5089. local Camera = game.Workspace.Camera
  5090. Camera.CameraType = Enum.CameraType.Scriptable
  5091. Camera.CFrame = CFrame.new(459.51, 57.152, 13.027)
  5092. wait(0.05)
  5093. local Camera = game.Workspace.Camera
  5094. Camera.CameraType = Enum.CameraType.Scriptable
  5095. Camera.CFrame = CFrame.new(459.51, 57.152, 12.027)
  5096. wait(0.05)
  5097. local Camera = game.Workspace.Camera
  5098. Camera.CameraType = Enum.CameraType.Scriptable
  5099. Camera.CFrame = CFrame.new(459.51, 57.152, 11.027)
  5100. wait(0.05)
  5101. local Camera = game.Workspace.Camera
  5102. Camera.CameraType = Enum.CameraType.Scriptable
  5103. Camera.CFrame = CFrame.new(459.51, 57.152, 10.027)
  5104. wait(0.05)
  5105. local Camera = game.Workspace.Camera
  5106. Camera.CameraType = Enum.CameraType.Scriptable
  5107. Camera.CFrame = CFrame.new(459.51, 57.152, 9.027)
  5108. wait(0.05)
  5109. local Camera = game.Workspace.Camera
  5110. Camera.CameraType = Enum.CameraType.Scriptable
  5111. Camera.CFrame = CFrame.new(459.51, 57.152, 8.027)
  5112. wait(0.05)
  5113. local Camera = game.Workspace.Camera
  5114. Camera.CameraType = Enum.CameraType.Scriptable
  5115. Camera.CFrame = CFrame.new(459.51, 57.152, 7.027)
  5116. wait(0.05)
  5117. local Camera = game.Workspace.Camera
  5118. Camera.CameraType = Enum.CameraType.Scriptable
  5119. Camera.CFrame = CFrame.new(459.51, 57.152, 6.027)
  5120. wait(0.05)
  5121. local Camera = game.Workspace.Camera
  5122. Camera.CameraType = Enum.CameraType.Scriptable
  5123. Camera.CFrame = CFrame.new(459.51, 57.152, 5.027)
  5124. wait(0.05)
  5125. local Camera = game.Workspace.Camera
  5126. Camera.CameraType = Enum.CameraType.Scriptable
  5127. Camera.CFrame = CFrame.new(459.51, 57.152, 4.027)
  5128. wait(0.05)
  5129. local Camera = game.Workspace.Camera
  5130. Camera.CameraType = Enum.CameraType.Scriptable
  5131. Camera.CFrame = CFrame.new(459.51, 57.152, 3.027)
  5132. wait(0.05)
  5133. local Camera = game.Workspace.Camera
  5134. Camera.CameraType = Enum.CameraType.Scriptable
  5135. Camera.CFrame = CFrame.new(459.51, 57.152, 2.027)
  5136. wait(0.05)
  5137. local Camera = game.Workspace.Camera
  5138. Camera.CameraType = Enum.CameraType.Scriptable
  5139. Camera.CFrame = CFrame.new(459.51, 57.152, 1.027)
  5140. wait(0.05)
  5141. local Camera = game.Workspace.Camera
  5142. Camera.CameraType = Enum.CameraType.Scriptable
  5143. Camera.CFrame = CFrame.new(459.51, 57.152, 0.027)
  5144. wait(0.05)
  5145. local Camera = game.Workspace.Camera
  5146. Camera.CameraType = Enum.CameraType.Scriptable
  5147. Camera.CFrame = CFrame.new(459.51, 57.152, -1.027)
  5148. wait(0.05)
  5149. local Camera = game.Workspace.Camera
  5150. Camera.CameraType = Enum.CameraType.Scriptable
  5151. Camera.CFrame = CFrame.new(459.51, 57.152, -2.027)
  5152. wait(0.05)
  5153. local Camera = game.Workspace.Camera
  5154. Camera.CameraType = Enum.CameraType.Scriptable
  5155. Camera.CFrame = CFrame.new(459.51, 57.152, -3.027)
  5156. wait(0.05)
  5157. local Camera = game.Workspace.Camera
  5158. Camera.CameraType = Enum.CameraType.Scriptable
  5159. Camera.CFrame = CFrame.new(459.51, 57.152, -4.027)
  5160. wait(0.05)
  5161. local Camera = game.Workspace.Camera
  5162. Camera.CameraType = Enum.CameraType.Scriptable
  5163. Camera.CFrame = CFrame.new(459.51, 57.152, -5.027)
  5164. wait(0.05)
  5165. local Camera = game.Workspace.Camera
  5166. Camera.CameraType = Enum.CameraType.Scriptable
  5167. Camera.CFrame = CFrame.new(459.51, 57.152, -6.027)
  5168. wait(0.05)
  5169. local Camera = game.Workspace.Camera
  5170. Camera.CameraType = Enum.CameraType.Scriptable
  5171. Camera.CFrame = CFrame.new(459.51, 57.152, -7.027)
  5172. wait(0.05)
  5173. local Camera = game.Workspace.Camera
  5174. Camera.CameraType = Enum.CameraType.Scriptable
  5175. Camera.CFrame = CFrame.new(459.51, 57.152, -8.027)
  5176. wait(0.05)
  5177. local Camera = game.Workspace.Camera
  5178. Camera.CameraType = Enum.CameraType.Scriptable
  5179. Camera.CFrame = CFrame.new(459.51, 57.152, -9.027)
  5180. wait(0.05)
  5181. local Camera = game.Workspace.Camera
  5182. Camera.CameraType = Enum.CameraType.Scriptable
  5183. Camera.CFrame = CFrame.new(459.51, 57.152, -10.027)
  5184. wait(0.05)
  5185. local Camera = game.Workspace.Camera
  5186. Camera.CameraType = Enum.CameraType.Scriptable
  5187. Camera.CFrame = CFrame.new(459.51, 57.152, -11.027)
  5188. wait(0.05)
  5189. local Camera = game.Workspace.Camera
  5190. Camera.CameraType = Enum.CameraType.Scriptable
  5191. Camera.CFrame = CFrame.new(459.51, 57.152, -12.027)
  5192. wait(0.05)
  5193. local Camera = game.Workspace.Camera
  5194. Camera.CameraType = Enum.CameraType.Scriptable
  5195. Camera.CFrame = CFrame.new(459.51, 57.152, -13.027)
  5196. wait(0.05)
  5197. local Camera = game.Workspace.Camera
  5198. Camera.CameraType = Enum.CameraType.Scriptable
  5199. Camera.CFrame = CFrame.new(459.51, 57.152, -14.027)
  5200. wait(0.05)
  5201. local Camera = game.Workspace.Camera
  5202. Camera.CameraType = Enum.CameraType.Scriptable
  5203. Camera.CFrame = CFrame.new(459.51, 57.152, -15.027)
  5204. wait(0.05)
  5205. local Camera = game.Workspace.Camera
  5206. Camera.CameraType = Enum.CameraType.Scriptable
  5207. Camera.CFrame = CFrame.new(459.51, 57.152, -16.027)
  5208. wait(0.05)
  5209. local Camera = game.Workspace.Camera
  5210. Camera.CameraType = Enum.CameraType.Scriptable
  5211. Camera.CFrame = CFrame.new(459.51, 57.152, -17.027)
  5212. wait(0.05)
  5213. local Camera = game.Workspace.Camera
  5214. Camera.CameraType = Enum.CameraType.Scriptable
  5215. Camera.CFrame = CFrame.new(459.51, 57.152, -18.027)
  5216. wait(0.05)
  5217. local Camera = game.Workspace.Camera
  5218. Camera.CameraType = Enum.CameraType.Scriptable
  5219. Camera.CFrame = CFrame.new(459.51, 57.152, -19.027)
  5220. wait(0.05)
  5221. local Camera = game.Workspace.Camera
  5222. Camera.CameraType = Enum.CameraType.Scriptable
  5223. Camera.CFrame = CFrame.new(459.51, 57.152, -20.027)
  5224. wait(0.05)
  5225. local Camera = game.Workspace.Camera
  5226. Camera.CameraType = Enum.CameraType.Scriptable
  5227. Camera.CFrame = CFrame.new(459.51, 57.152, -21.027)
  5228. wait(0.05)
  5229. local Camera = game.Workspace.Camera
  5230. Camera.CameraType = Enum.CameraType.Scriptable
  5231. Camera.CFrame = CFrame.new(459.51, 57.152, -22.027)
  5232. wait(0.05)
  5233. local Camera = game.Workspace.Camera
  5234. Camera.CameraType = Enum.CameraType.Scriptable
  5235. Camera.CFrame = CFrame.new(459.51, 57.152, -23.027)
  5236. wait(0.05)
  5237. local Camera = game.Workspace.Camera
  5238. Camera.CameraType = Enum.CameraType.Scriptable
  5239. Camera.CFrame = CFrame.new(459.51, 57.152, -24.027)
  5240. wait(0.05)
  5241. local Camera = game.Workspace.Camera
  5242. Camera.CameraType = Enum.CameraType.Scriptable
  5243. Camera.CFrame = CFrame.new(459.51, 57.152, -25.027)
  5244. wait(0.05)
  5245. local Camera = game.Workspace.Camera
  5246. Camera.CameraType = Enum.CameraType.Scriptable
  5247. Camera.CFrame = CFrame.new(459.51, 57.152, -26.027)
  5248. wait(0.05)
  5249. local Camera = game.Workspace.Camera
  5250. Camera.CameraType = Enum.CameraType.Scriptable
  5251. Camera.CFrame = CFrame.new(459.51, 57.152, -27.027)
  5252. wait(0.05)
  5253. local Camera = game.Workspace.Camera
  5254. Camera.CameraType = Enum.CameraType.Scriptable
  5255. Camera.CFrame = CFrame.new(459.51, 57.152, -28.027)
  5256. wait(0.05)
  5257. local Camera = game.Workspace.Camera
  5258. Camera.CameraType = Enum.CameraType.Scriptable
  5259. Camera.CFrame = CFrame.new(459.51, 57.152, -29.027)
  5260. wait(0.05)
  5261. local Camera = game.Workspace.Camera
  5262. Camera.CameraType = Enum.CameraType.Scriptable
  5263. Camera.CFrame = CFrame.new(459.51, 57.152, -30.027)
  5264. wait(0.05)
  5265. local Camera = game.Workspace.Camera
  5266. Camera.CameraType = Enum.CameraType.Scriptable
  5267. Camera.CFrame = CFrame.new(459.51, 57.152, -31.027)
  5268. wait(0.05)
  5269. local Camera = game.Workspace.Camera
  5270. Camera.CameraType = Enum.CameraType.Scriptable
  5271. Camera.CFrame = CFrame.new(459.51, 57.152, -32.027)
  5272. wait(0.05)
  5273. local Camera = game.Workspace.Camera
  5274. Camera.CameraType = Enum.CameraType.Scriptable
  5275. Camera.CFrame = CFrame.new(459.51, 57.152, -33.027)
  5276. wait(0.05)
  5277. local Camera = game.Workspace.Camera
  5278. Camera.CameraType = Enum.CameraType.Scriptable
  5279. Camera.CFrame = CFrame.new(459.51, 57.152, -34.027)
  5280. wait(0.05)
  5281. local Camera = game.Workspace.Camera
  5282. Camera.CameraType = Enum.CameraType.Scriptable
  5283. Camera.CFrame = CFrame.new(459.51, 57.152, -35.027)
  5284. wait(0.05)
  5285. local Camera = game.Workspace.Camera
  5286. Camera.CameraType = Enum.CameraType.Scriptable
  5287. Camera.CFrame = CFrame.new(459.51, 57.152, -36.027)
  5288. wait(0.05)
  5289. local Camera = game.Workspace.Camera
  5290. Camera.CameraType = Enum.CameraType.Scriptable
  5291. Camera.CFrame = CFrame.new(459.51, 57.152, -37.027)
  5292. wait(0.05)
  5293. local Camera = game.Workspace.Camera
  5294. Camera.CameraType = Enum.CameraType.Scriptable
  5295. Camera.CFrame = CFrame.new(459.51, 57.152, -38.027)
  5296. wait(0.05)
  5297. local Camera = game.Workspace.Camera
  5298. Camera.CameraType = Enum.CameraType.Scriptable
  5299. Camera.CFrame = CFrame.new(459.51, 57.152, -39.027)
  5300. wait(0.05)
  5301. local Camera = game.Workspace.Camera
  5302. Camera.CameraType = Enum.CameraType.Scriptable
  5303. Camera.CFrame = CFrame.new(459.51, 57.152, -40.027)
  5304. wait(0.05)
  5305. local Camera = game.Workspace.Camera
  5306. Camera.CameraType = Enum.CameraType.Scriptable
  5307. Camera.CFrame = CFrame.new(459.51, 57.152, -41.027)
  5308. wait(0.05)
  5309. local Camera = game.Workspace.Camera
  5310. Camera.CameraType = Enum.CameraType.Scriptable
  5311. Camera.CFrame = CFrame.new(459.51, 57.152, -42.027)
  5312. wait(0.05)
  5313. local Camera = game.Workspace.Camera
  5314. Camera.CameraType = Enum.CameraType.Scriptable
  5315. Camera.CFrame = CFrame.new(459.51, 57.152, -43.027)
  5316. wait(0.05)
  5317. local Camera = game.Workspace.Camera
  5318. Camera.CameraType = Enum.CameraType.Scriptable
  5319. Camera.CFrame = CFrame.new(459.51, 57.152, -44.027)
  5320. wait(0.05)
  5321. local Camera = game.Workspace.Camera
  5322. Camera.CameraType = Enum.CameraType.Scriptable
  5323. Camera.CFrame = CFrame.new(459.51, 57.152, -45.027)
  5324. wait(0.05)
  5325. local Camera = game.Workspace.Camera
  5326. Camera.CameraType = Enum.CameraType.Scriptable
  5327. Camera.CFrame = CFrame.new(459.51, 57.152, -46.027)
  5328. wait(0.05)
  5329. local Camera = game.Workspace.Camera
  5330. Camera.CameraType = Enum.CameraType.Scriptable
  5331. Camera.CFrame = CFrame.new(459.51, 57.152, -47.027)
  5332. wait(0.05)
  5333. local Camera = game.Workspace.Camera
  5334. Camera.CameraType = Enum.CameraType.Scriptable
  5335. Camera.CFrame = CFrame.new(459.51, 57.152, -48.027)
  5336. wait(0.05)
  5337. local Camera = game.Workspace.Camera
  5338. Camera.CameraType = Enum.CameraType.Scriptable
  5339. Camera.CFrame = CFrame.new(459.51, 57.152, -49.027)
  5340. wait(0.05)
  5341. local Camera = game.Workspace.Camera
  5342. Camera.CameraType = Enum.CameraType.Scriptable
  5343. Camera.CFrame = CFrame.new(459.51, 57.152, -50.027)
  5344. wait(0.05)
  5345. local Camera = game.Workspace.Camera
  5346. Camera.CameraType = Enum.CameraType.Scriptable
  5347. Camera.CFrame = CFrame.new(459.51, 57.152, -51.027)
  5348. wait(0.05)
  5349. local Camera = game.Workspace.Camera
  5350. Camera.CameraType = Enum.CameraType.Scriptable
  5351. Camera.CFrame = CFrame.new(459.51, 57.152, -52.027)
  5352. wait(0.05)
  5353. local plr = game.Players.LocalPlayer
  5354. local gui = Instance.new("ScreenGui")
  5355. gui.Parent = plr.PlayerGui
  5356. gui.ResetOnSpawn = false
  5357. local Soon = Instance.new("TextLabel")
  5358. Soon.Parent = gui
  5359. Soon.BackgroundTransparency = 1
  5360. Soon.Size = UDim2.new(1, 0, 1, 0)
  5361. Soon.Position = UDim2.new(0, 0, 0.6 ,-255)
  5362. Soon.TextXAlignment = Enum.TextXAlignment.Center
  5363. Soon.TextScaled = true
  5364. Soon.Text = "Game Over"
  5365. Soon.TextColor3 = Color3.new(255, 255, 255)
  5366. Soon.Font = Enum.Font.IndieFlower
  5367. end)
  5368.  
  5369.  
  5370.  
  5371.  
  5372. end
  5373. end)
  5374. game.Players.LocalPlayer.Character:WaitForChild("Humanoid"):MoveTo(WalkAndTouchPart.Position)
  5375.    game.Players.LocalPlayer.Character:WaitForChild("Humanoid").MoveToFinished:Wait()
  5376.  
  5377.  
  5378. Touched = false
  5379. PortalPart1.Touched:connect(function(player)
  5380. if Touched == false then
  5381. Touched = true
  5382. game:FindService("RunService"):Set3dRenderingEnabled(false)
  5383. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = CFrame.new(-1612.68, 0.8, 566.899)
  5384.  
  5385. wait(4)
  5386.  
  5387. local Camera = game.Workspace.Camera
  5388. Camera.CameraType = Enum.CameraType.Scriptable
  5389. Camera.CFrame = CFrame.new(-1596.789, 552, 645.71)
  5390.  
  5391. wait(0.5)
  5392. PortalPart2:Destroy()
  5393. wait(0.1)
  5394. PortalPart1:Destroy()
  5395.  
  5396. wait(1)
  5397. local SoundBoom = Instance.new("Sound")
  5398. local Id = "8699897760"
  5399. SoundBoom.Parent = screen
  5400. SoundBoom.SoundId = "rbxassetid://"..Id
  5401. SoundBoom.Playing = true
  5402. SoundBoom.Looped = false
  5403. SoundBoom.Volume = 1
  5404. local explosion = Instance.new("Explosion")
  5405. local nuke = Instance.new("Part")
  5406. explosion.Position = Vector3.new(-1597.196, 549, 605.403)
  5407. nuke.Position = explosion.Position
  5408. nuke.Anchored = true
  5409. nuke.Parent = game.Workspace
  5410. explosion.Parent = game.Workspace
  5411. local x, y, z = 5, 5, 5
  5412. nuke.BrickColor = BrickColor.new ("New Yeller")
  5413. nuke.Size = Vector3.new(x, y, z)
  5414. nuke.CanCollide = false
  5415. nuke.Name = "nuke"
  5416. nuke.Shape = "Ball"
  5417. nuke.Transparency = 0.3
  5418. nuke.Material = "Neon"
  5419. nuke.Locked = true
  5420. for i = 1,50 do
  5421. wait()
  5422. x, y, z = x+1, y+1, z+1
  5423. nuke.Size = Vector3.new(x, y, z)
  5424. explosion.BlastPressure = 100000000000000000
  5425. explosion.DestroyJointRadiusPercent = 1000000000000000000000000000000000000000000
  5426. explosion.ExplosionType = "Craters"
  5427. explosion.BlastRadius = x+5000000000
  5428. local explosion2 = Instance.new("Explosion")
  5429. explosion2.BlastPressure = 9999999999999999999999999999999999999999999999999
  5430. explosion2.BlastRadius = x+999999999999999999999999999999999999999999999999999
  5431. explosion2.DestroyJointRadiusPercent = 9999999999999999999999999999999999999999999999
  5432. explosion2.ExplosionType = "Craters"
  5433. explosion2.Parent = nuke
  5434. explosion2.Position = explosion.Position
  5435. end
  5436. nuke:Destroy()
  5437.  
  5438.  
  5439.  
  5440. local plr = game.Players.LocalPlayer
  5441. local gui = Instance.new("ScreenGui")
  5442. gui.Parent = plr.PlayerGui
  5443. gui.ResetOnSpawn = false
  5444. local Soon = Instance.new("TextLabel")
  5445. Soon.Parent = gui
  5446. Soon.BackgroundTransparency = 1
  5447. Soon.Size = UDim2.new(1, 0, 1, 0)
  5448. Soon.Position = UDim2.new(0, 0, 0.6 ,-255)
  5449. Soon.TextXAlignment = Enum.TextXAlignment.Center
  5450. Soon.TextScaled = true
  5451. Soon.Text = "Chapter 3 Coming Soon"
  5452. Soon.TextColor3 = Color3.new(255, 255, 255)
  5453. Soon.Font = Enum.Font.IndieFlower
  5454.  
  5455.  
  5456. end
  5457. end)
  5458.  
  5459. Touched = false
  5460. end
  5461. end)
  5462. end)
  5463. end)
  5464. --end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement