SHOW:
|
|
- or go back to the newest paste.
| 1 | - | --By Rufus14 |
| 1 | + | --Edited by carlosname/XqDIOpX |
| 2 | players = game:GetService("Players")
| |
| 3 | runservice = game:GetService("RunService")
| |
| 4 | --owner = players:GetPlayerFromCharacter(script.Parent) | |
| 5 | plrgui = owner:findFirstChildOfClass("PlayerGui")
| |
| 6 | character = owner.Character | |
| 7 | NLS([[players = game:GetService("Players")
| |
| 8 | runservice = game:GetService("RunService")
| |
| 9 | localplayer = players.LocalPlayer | |
| 10 | plrgui = localplayer:findFirstChildOfClass("PlayerGui")
| |
| 11 | character = localplayer.Character | |
| 12 | remote = character:WaitForChild("funkyremotedoe")
| |
| 13 | gui = plrgui:WaitForChild("ohshitagh0st")
| |
| 14 | ghostframe = gui:WaitForChild("gh0stframe")
| |
| 15 | ghostbutton = ghostframe:WaitForChild("gh0stbutton")
| |
| 16 | visibleframe = gui:WaitForChild("visibleframe")
| |
| 17 | visiblebutton = visibleframe:WaitForChild("visiblebutton")
| |
| 18 | modeframe = gui:WaitForChild("modeframe")
| |
| 19 | modebutton = modeframe:WaitForChild("modebutton")
| |
| 20 | ghosted = false | |
| 21 | visible = true | |
| 22 | - | bodytype = "Ghost" |
| 22 | + | bodytype = "Skip" |
| 23 | function mufflesound(what) | |
| 24 | local eq = Instance.new("EqualizerSoundEffect", what)
| |
| 25 | eq.HighGain = -30 | |
| 26 | eq.MidGain = -30 | |
| 27 | eq.LowGain = 0 | |
| 28 | eq.Name = "GhostMuffleSound" | |
| 29 | end | |
| 30 | function unmufflesound(what) | |
| 31 | if what:findFirstChild("GhostMuffleSound") then
| |
| 32 | what.GhostMuffleSound:destroy() | |
| 33 | end | |
| 34 | end | |
| 35 | workspace.DescendantAdded:connect(function(what) | |
| 36 | if what.ClassName == "Sound" then | |
| 37 | if ghosted then | |
| 38 | mufflesound(what) | |
| 39 | end | |
| 40 | end | |
| 41 | end) | |
| 42 | modebutton.MouseButton1Click:connect(function() | |
| 43 | - | if bodytype == "Ghost" then |
| 43 | + | if bodytype == "Skip" then |
| 44 | modebutton.Active = false | |
| 45 | remote:FireServer("humanoidbody", character.Head.CFrame)
| |
| 46 | elseif bodytype == "Humanoid" then | |
| 47 | modebutton.Active = false | |
| 48 | remote:FireServer("ghostbody", character.Head.CFrame)
| |
| 49 | end | |
| 50 | end) | |
| 51 | ghostbutton.MouseButton1Click:connect(function() | |
| 52 | if not ghosted then | |
| 53 | ghostbutton.Active = false | |
| 54 | remote:FireServer("ghostmeplease")
| |
| 55 | else | |
| 56 | ghostbutton.Active = false | |
| 57 | remote:FireServer("unghostmeplease", character.Head.CFrame)
| |
| 58 | end | |
| 59 | end) | |
| 60 | visiblebutton.MouseButton1Click:connect(function() | |
| 61 | if not visible then | |
| 62 | visiblebutton.Active = false | |
| 63 | remote:FireServer("visiblemepls", character.Head.CFrame)
| |
| 64 | else | |
| 65 | visiblebutton.Active = false | |
| 66 | remote:FireServer("invisiblemepls", character.Head.CFrame)
| |
| 67 | end | |
| 68 | end) | |
| 69 | remote.OnClientEvent:connect(function(WHAT) | |
| 70 | if WHAT == "ghostlocal" then | |
| 71 | ghosted = true | |
| 72 | - | ghostbutton.Text = "Ghost: On" |
| 72 | + | ghostbutton.Text = "Skip: On" |
| 73 | ghostbutton.Active = true | |
| 74 | character.Parent = workspace | |
| 75 | workspace.CurrentCamera.FieldOfView = workspace.CurrentCamera.FieldOfView + 10 | |
| 76 | local correct = Instance.new("ColorCorrectionEffect", workspace.CurrentCamera)
| |
| 77 | correct.TintColor = Color3.fromRGB(255, 200, 255) | |
| 78 | correct.Name = "ghosteffect" | |
| 79 | for i,v in pairs(workspace:GetDescendants()) do | |
| 80 | if v.ClassName == "Sound" then | |
| 81 | mufflesound(v) | |
| 82 | end | |
| 83 | end | |
| 84 | for i = 1,20 do | |
| 85 | workspace.CurrentCamera.FieldOfView = workspace.CurrentCamera.FieldOfView - 0.5 | |
| 86 | runservice.RenderStepped:wait() | |
| 87 | end | |
| 88 | elseif WHAT == "unghostlocal" then | |
| 89 | ghosted = false | |
| 90 | - | ghostbutton.Text = "Ghost: Off" |
| 90 | + | ghostbutton.Text = "Skip: Off" |
| 91 | ghostbutton.Active = true | |
| 92 | if workspace.CurrentCamera:findFirstChild("ghosteffect") then
| |
| 93 | workspace.CurrentCamera.ghosteffect:destroy() | |
| 94 | end | |
| 95 | workspace.CurrentCamera.FieldOfView = workspace.CurrentCamera.FieldOfView + 10 | |
| 96 | for i,v in pairs(workspace:GetDescendants()) do | |
| 97 | if v.ClassName == "Sound" then | |
| 98 | unmufflesound(v) | |
| 99 | end | |
| 100 | end | |
| 101 | for i = 1,20 do | |
| 102 | workspace.CurrentCamera.FieldOfView = workspace.CurrentCamera.FieldOfView - 0.5 | |
| 103 | runservice.RenderStepped:wait() | |
| 104 | end | |
| 105 | elseif WHAT == "invisiblelocal" then | |
| 106 | visible = false | |
| 107 | visiblebutton.Text = "Visible: Off" | |
| 108 | visiblebutton.Active = true | |
| 109 | elseif WHAT == "visiblelocal" then | |
| 110 | visible = true | |
| 111 | visiblebutton.Text = "Visible: On" | |
| 112 | visiblebutton.Active = true | |
| 113 | elseif WHAT == "ghostedbody" then | |
| 114 | - | bodytype = "Ghost" |
| 114 | + | bodytype = "Skip" |
| 115 | - | modebutton.Text = "Body Type: Ghost" |
| 115 | + | modebutton.Text = "Body Type: Skip" |
| 116 | modebutton.Active = true | |
| 117 | elseif WHAT == "humanoidedbody" then | |
| 118 | bodytype = "Humanoid" | |
| 119 | modebutton.Text = "Body Type: Humanoid" | |
| 120 | modebutton.Active = true | |
| 121 | end | |
| 122 | end) | |
| 123 | coroutine.wrap(function() | |
| 124 | while runservice.Stepped:wait() do | |
| 125 | - | if workspace:findFirstChild("GH0ST ("..string.lower(localplayer.Name)..")") then
|
| 125 | + | if workspace:findFirstChild(" ("..string.lower(localplayer.Name)..")") then
|
| 126 | - | local themodel = workspace:findFirstChild("GH0ST ("..string.lower(localplayer.Name)..")")
|
| 126 | + | local themodel = workspace:findFirstChild(" ("..string.lower(localplayer.Name)..")")
|
| 127 | if themodel:findFirstChildOfClass("Humanoid") then
| |
| 128 | for i,v in pairs(themodel:GetDescendants()) do | |
| 129 | if v.ClassName == "SpawnLocation" then | |
| 130 | v.CanCollide = false | |
| 131 | end | |
| 132 | end | |
| 133 | end | |
| 134 | end | |
| 135 | end | |
| 136 | end)() | |
| 137 | while runservice.RenderStepped:wait() do | |
| 138 | - | if workspace:findFirstChild("GH0ST ("..string.lower(localplayer.Name)..")") then
|
| 138 | + | if workspace:findFirstChild(" ("..string.lower(localplayer.Name)..")") then
|
| 139 | - | local themodel = workspace:findFirstChild("GH0ST ("..string.lower(localplayer.Name)..")")
|
| 139 | + | local themodel = workspace:findFirstChild(" ("..string.lower(localplayer.Name)..")")
|
| 140 | for i,v in pairs(character:GetDescendants()) do | |
| 141 | for q,w in pairs(themodel:GetDescendants()) do | |
| 142 | if w.Name == v.Name then | |
| 143 | if w.ClassName == "SpawnLocation" and w.Parent.ClassName ~= "Accessory" and w.Parent.ClassName ~= "Hat" then | |
| 144 | w.CFrame = v.CFrame | |
| 145 | w.Velocity = Vector3.new() | |
| 146 | w.RotVelocity = Vector3.new() | |
| 147 | end | |
| 148 | end | |
| 149 | end | |
| 150 | end | |
| 151 | for i,v in pairs(character:GetChildren()) do | |
| 152 | for q,w in pairs(themodel:GetChildren()) do | |
| 153 | if w.Name == v.Name then | |
| 154 | if w.ClassName == "Accessory" or w.ClassName == "Hat" then | |
| 155 | if w:findFirstChild("Handle") and v:findFirstChild("Handle") then
| |
| 156 | w.Handle.CFrame = v.Handle.CFrame | |
| 157 | w.Handle.Velocity = Vector3.new() | |
| 158 | w.Handle.RotVelocity = Vector3.new() | |
| 159 | end | |
| 160 | end | |
| 161 | end | |
| 162 | end | |
| 163 | end | |
| 164 | end | |
| 165 | end]], character) | |
| 166 | visible = true | |
| 167 | ghosted = false | |
| 168 | - | bodytype = "Ghost" |
| 168 | + | bodytype = "Skip" |
| 169 | local remote = Instance.new("RemoteEvent", character)
| |
| 170 | remote.Name = "funkyremotedoe" | |
| 171 | --Converted with ttyyuu12345's model to script plugin v4 | |
| 172 | function sandbox(var,func) | |
| 173 | local env = getfenv(func) | |
| 174 | local newenv = setmetatable({},{
| |
| 175 | __index = function(self,k) | |
| 176 | if k=="script" then | |
| 177 | return var | |
| 178 | else | |
| 179 | return env[k] | |
| 180 | end | |
| 181 | end, | |
| 182 | }) | |
| 183 | setfenv(func,newenv) | |
| 184 | return func | |
| 185 | end | |
| 186 | cors = {}
| |
| 187 | mas = Instance.new("Model",game:GetService("Lighting"))
| |
| 188 | ScreenGui0 = Instance.new("ScreenGui")
| |
| 189 | Frame1 = Instance.new("Frame")
| |
| 190 | ghostbutton = Instance.new("TextButton")
| |
| 191 | Frame3 = Instance.new("Frame")
| |
| 192 | visiblebutton = Instance.new("TextButton")
| |
| 193 | Frame5 = Instance.new("Frame")
| |
| 194 | modebutton = Instance.new("TextButton")
| |
| 195 | ScreenGui0.Name = "ohshitagh0st" | |
| 196 | ScreenGui0.Parent = mas | |
| 197 | ScreenGui0.ZIndexBehavior = Enum.ZIndexBehavior.Sibling | |
| 198 | Frame1.Name = "gh0stframe" | |
| 199 | Frame1.Parent = ScreenGui0 | |
| 200 | Frame1.Position = UDim2.new(0.816999972, 0, 0.950999975, 0) | |
| 201 | Frame1.Size = UDim2.new(0, 234, 0, 35) | |
| 202 | Frame1.BackgroundColor = BrickColor.new("Institutional white")
| |
| 203 | Frame1.BackgroundColor3 = Color3.new(1, 1, 1) | |
| 204 | Frame1.Style = Enum.FrameStyle.RobloxRound | |
| 205 | ghostbutton.Name = "gh0stbutton" | |
| 206 | ghostbutton.Parent = Frame1 | |
| 207 | ghostbutton.Position = UDim2.new(0.0164168887, 0, -0.225141287, 0) | |
| 208 | ghostbutton.Size = UDim2.new(0, 210, 0, 29) | |
| 209 | ghostbutton.BackgroundColor = BrickColor.new("Institutional white")
| |
| 210 | ghostbutton.BackgroundColor3 = Color3.new(1, 1, 1) | |
| 211 | ghostbutton.Style = Enum.ButtonStyle.RobloxButtonDefault | |
| 212 | ghostbutton.Font = Enum.Font.SourceSans | |
| 213 | ghostbutton.FontSize = Enum.FontSize.Size14 | |
| 214 | - | ghostbutton.Text = "Ghost: Off" |
| 214 | + | ghostbutton.Text = "Skip: Off" |
| 215 | ghostbutton.TextColor = BrickColor.new("Institutional white")
| |
| 216 | ghostbutton.TextColor3 = Color3.new(1, 1, 1) | |
| 217 | ghostbutton.TextScaled = true | |
| 218 | ghostbutton.TextSize = 14 | |
| 219 | ghostbutton.TextWrap = true | |
| 220 | ghostbutton.TextWrapped = true | |
| 221 | Frame3.Name = "visibleframe" | |
| 222 | Frame3.Parent = ScreenGui0 | |
| 223 | Frame3.Position = UDim2.new(0.816999972, 0, 0.902999997, 0) | |
| 224 | Frame3.Size = UDim2.new(0, 234, 0, 35) | |
| 225 | Frame3.BackgroundColor = BrickColor.new("Institutional white")
| |
| 226 | Frame3.BackgroundColor3 = Color3.new(1, 1, 1) | |
| 227 | Frame3.Style = Enum.FrameStyle.RobloxRound | |
| 228 | visiblebutton.Name = "visiblebutton" | |
| 229 | visiblebutton.Parent = Frame3 | |
| 230 | visiblebutton.Position = UDim2.new(0.0164168887, 0, -0.225141287, 0) | |
| 231 | visiblebutton.Size = UDim2.new(0, 210, 0, 29) | |
| 232 | visiblebutton.BackgroundColor = BrickColor.new("Institutional white")
| |
| 233 | visiblebutton.BackgroundColor3 = Color3.new(1, 1, 1) | |
| 234 | visiblebutton.Style = Enum.ButtonStyle.RobloxButtonDefault | |
| 235 | visiblebutton.Font = Enum.Font.SourceSans | |
| 236 | visiblebutton.FontSize = Enum.FontSize.Size14 | |
| 237 | visiblebutton.Text = "Visible: On" | |
| 238 | visiblebutton.TextColor = BrickColor.new("Institutional white")
| |
| 239 | visiblebutton.TextColor3 = Color3.new(1, 1, 1) | |
| 240 | visiblebutton.TextScaled = true | |
| 241 | visiblebutton.TextSize = 14 | |
| 242 | visiblebutton.TextWrap = true | |
| 243 | visiblebutton.TextWrapped = true | |
| 244 | Frame5.Name = "modeframe" | |
| 245 | Frame5.Parent = ScreenGui0 | |
| 246 | Frame5.Position = UDim2.new(0.816999972, 0, 0.853999972, 0) | |
| 247 | Frame5.Size = UDim2.new(0, 234, 0, 35) | |
| 248 | Frame5.BackgroundColor = BrickColor.new("Institutional white")
| |
| 249 | Frame5.BackgroundColor3 = Color3.new(1, 1, 1) | |
| 250 | Frame5.Style = Enum.FrameStyle.RobloxRound | |
| 251 | modebutton.Name = "modebutton" | |
| 252 | modebutton.Parent = Frame5 | |
| 253 | modebutton.Position = UDim2.new(0.0164168887, 0, -0.225141287, 0) | |
| 254 | modebutton.Size = UDim2.new(0, 210, 0, 29) | |
| 255 | modebutton.BackgroundColor = BrickColor.new("Institutional white")
| |
| 256 | modebutton.BackgroundColor3 = Color3.new(1, 1, 1) | |
| 257 | modebutton.Style = Enum.ButtonStyle.RobloxButtonDefault | |
| 258 | modebutton.Font = Enum.Font.SourceSans | |
| 259 | modebutton.FontSize = Enum.FontSize.Size14 | |
| 260 | - | modebutton.Text = "Body Type: Ghost" |
| 260 | + | modebutton.Text = "Body Type: Skipping" |
| 261 | modebutton.TextColor = BrickColor.new("Institutional white")
| |
| 262 | modebutton.TextColor3 = Color3.new(1, 1, 1) | |
| 263 | modebutton.TextScaled = true | |
| 264 | modebutton.TextSize = 14 | |
| 265 | modebutton.TextWrap = true | |
| 266 | modebutton.TextWrapped = true | |
| 267 | for i,v in pairs(mas:GetChildren()) do | |
| 268 | v.Parent = plrgui | |
| 269 | pcall(function() v:MakeJoints() end) | |
| 270 | end | |
| 271 | mas:Destroy() | |
| 272 | for i,v in pairs(cors) do | |
| 273 | spawn(function() | |
| 274 | pcall(v) | |
| 275 | end) | |
| 276 | end | |
| 277 | remote.OnServerEvent:connect(function(WHO, WHAT, VALUE) | |
| 278 | if WHO == owner then | |
| 279 | if WHAT == "ghostmeplease" then | |
| 280 | ghosted = true | |
| 281 | local sphereeffect = Instance.new("Part", workspace)
| |
| 282 | sphereeffect.Material = "Neon" | |
| 283 | sphereeffect.Shape = "Ball" | |
| 284 | sphereeffect.Anchored = true | |
| 285 | sphereeffect.BrickColor = BrickColor.new('Really red')
| |
| 286 | sphereeffect.Name = "GhostTransitionEffect" | |
| 287 | sphereeffect.CanCollide = false | |
| 288 | sphereeffect.CFrame = character.Head.CFrame * CFrame.new(0,-1.5,0) | |
| 289 | sphereeffect.Size = Vector3.new(10,10,10) | |
| 290 | game.Debris:AddItem(sphereeffect, 3.8) | |
| 291 | coroutine.wrap(function() | |
| 292 | - | sound.SoundId = "rbxassetid://182981587" |
| 292 | + | |
| 293 | sound.SoundId = "rbxassetid://3280066384" | |
| 294 | sound.Volume = 1 | |
| 295 | sound.PlaybackSpeed = 0.5 | |
| 296 | sound:Play() | |
| 297 | game.Debris:AddItem(sound, 3.8) | |
| 298 | end)() | |
| 299 | coroutine.wrap(function() | |
| 300 | for i = 1,20 do | |
| 301 | sphereeffect.Transparency = sphereeffect.Transparency + 0.05 | |
| 302 | sphereeffect.Size = sphereeffect.Size - Vector3.new(0.5,0.5,0.5) | |
| 303 | runservice.Stepped:wait() | |
| 304 | end | |
| 305 | end)() | |
| 306 | local invisff = Instance.new("ForceField", character)
| |
| 307 | invisff.Visible = false | |
| 308 | invisff.Name = "AntiExplosionFF" | |
| 309 | character.Parent = ScreenGui0 | |
| 310 | remote:FireClient(owner, "ghostlocal") | |
| 311 | elseif WHAT == "unghostmeplease" then | |
| 312 | ghosted = false | |
| 313 | if character:findFirstChild("AntiExplosionFF") then
| |
| 314 | character.AntiExplosionFF:destroy() | |
| 315 | end | |
| 316 | local sphereeffect = Instance.new("Part", workspace)
| |
| 317 | sphereeffect.Material = "Neon" | |
| 318 | sphereeffect.Shape = "Ball" | |
| 319 | sphereeffect.Anchored = true | |
| 320 | sphereeffect.CanCollide = false | |
| 321 | sphereeffect.BrickColor = BrickColor.new('Really red')
| |
| 322 | sphereeffect.CFrame = VALUE * CFrame.new(0,-1.5,0) | |
| 323 | sphereeffect.Size = Vector3.new(6,6,6) | |
| 324 | game.Debris:AddItem(sphereeffect, 4) | |
| 325 | - | sound.SoundId = "rbxassetid://171399373" |
| 325 | + | |
| 326 | local sound = Instance.new("Sound", sphereeffect)
| |
| 327 | sound.SoundId = "rbxassetid://3373983916" | |
| 328 | sound.Volume = 1 | |
| 329 | sound.PlaybackSpeed = 0.8 | |
| 330 | sound:Play() | |
| 331 | game.Debris:AddItem(sound, 4) | |
| 332 | end)() | |
| 333 | coroutine.wrap(function() | |
| 334 | for i = 1,20 do | |
| 335 | sphereeffect.Transparency = sphereeffect.Transparency + 0.05 | |
| 336 | sphereeffect.Size = sphereeffect.Size + Vector3.new(0.3,0.3,0.3) | |
| 337 | runservice.Stepped:wait() | |
| 338 | end | |
| 339 | end)() | |
| 340 | remote:FireClient(owner, "unghostlocal") | |
| 341 | character.Parent = workspace | |
| 342 | - | if workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")") then
|
| 342 | + | |
| 343 | - | workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")"):destroy()
|
| 343 | + | |
| 344 | if workspace:findFirstChild(" ("..string.lower(owner.Name)..")") then
| |
| 345 | workspace:findFirstChild(" ("..string.lower(owner.Name)..")"):destroy()
| |
| 346 | end | |
| 347 | local sphereeffect = Instance.new("Part", workspace)
| |
| 348 | sphereeffect.Material = "ForceField" | |
| 349 | sphereeffect.Shape = "Ball" | |
| 350 | sphereeffect.Anchored = true | |
| 351 | sphereeffect.Name = "GhostVisibilityEffect" | |
| 352 | sphereeffect.CanCollide = false | |
| 353 | sphereeffect.BrickColor = BrickColor.new('Really red')
| |
| 354 | sphereeffect.CFrame = VALUE * CFrame.new(0,-1.5,0) | |
| 355 | sphereeffect.Size = Vector3.new(10,10,10) | |
| 356 | coroutine.wrap(function() | |
| 357 | for i = 1,20 do | |
| 358 | sphereeffect.Transparency = sphereeffect.Transparency + 0.05 | |
| 359 | sphereeffect.Size = sphereeffect.Size - Vector3.new(0.5,0.5,0.5) | |
| 360 | runservice.Stepped:wait() | |
| 361 | end | |
| 362 | sphereeffect:destroy() | |
| 363 | end)() | |
| 364 | remote:FireClient(owner, "invisiblelocal") | |
| 365 | elseif WHAT == "visiblemepls" then | |
| 366 | visible = true | |
| 367 | local sphereeffect = Instance.new("Part", workspace)
| |
| 368 | sphereeffect.Material = "ForceField" | |
| 369 | sphereeffect.Shape = "Ball" | |
| 370 | sphereeffect.Anchored = true | |
| 371 | sphereeffect.BrickColor = BrickColor.new('Really red')
| |
| 372 | sphereeffect.Name = "GhostVisibilityEffect" | |
| 373 | sphereeffect.CanCollide = false | |
| 374 | sphereeffect.CFrame = VALUE * CFrame.new(0,-1.5,0) | |
| 375 | sphereeffect.Size = Vector3.new(1,1,1) | |
| 376 | coroutine.wrap(function() | |
| 377 | for i = 1,20 do | |
| 378 | sphereeffect.Transparency = sphereeffect.Transparency + 0.05 | |
| 379 | sphereeffect.Size = sphereeffect.Size + Vector3.new(0.5,0.5,0.5) | |
| 380 | runservice.Stepped:wait() | |
| 381 | end | |
| 382 | sphereeffect:destroy() | |
| 383 | - | if workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")") then
|
| 383 | + | |
| 384 | - | workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")"):destroy()
|
| 384 | + | |
| 385 | elseif WHAT == "humanoidbody" then | |
| 386 | bodytype = "Humanoid" | |
| 387 | if workspace:findFirstChild(" ("..string.lower(owner.Name)..")") then
| |
| 388 | workspace:findFirstChild(" ("..string.lower(owner.Name)..")"):destroy()
| |
| 389 | end | |
| 390 | local sphereeffect = Instance.new("Part", workspace)
| |
| 391 | sphereeffect.Material = "Neon" | |
| 392 | sphereeffect.Shape = "Ball" | |
| 393 | sphereeffect.BrickColor = BrickColor.Black() | |
| 394 | sphereeffect.Anchored = true | |
| 395 | sphereeffect.Name = "GhostModeEffect" | |
| 396 | sphereeffect.CanCollide = false | |
| 397 | sphereeffect.CFrame = VALUE * CFrame.new(0,-1.5,0) | |
| 398 | sphereeffect.Size = Vector3.new(10,10,10) | |
| 399 | coroutine.wrap(function() | |
| 400 | local sound = Instance.new("Sound", sphereeffect)
| |
| 401 | sound.SoundId = "rbxassetid://34320976" | |
| 402 | sound.Volume = 1 | |
| 403 | sound:Play() | |
| 404 | end)() | |
| 405 | coroutine.wrap(function() | |
| 406 | for i = 1,20 do | |
| 407 | sphereeffect.Transparency = sphereeffect.Transparency + 0.05 | |
| 408 | sphereeffect.Size = sphereeffect.Size - Vector3.new(0.5,0.5,0.5) | |
| 409 | runservice.Stepped:wait() | |
| 410 | end | |
| 411 | wait(1.5) | |
| 412 | sphereeffect:destroy() | |
| 413 | - | if workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")") then
|
| 413 | + | |
| 414 | - | workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")"):destroy()
|
| 414 | + | |
| 415 | elseif WHAT == "ghostbody" then | |
| 416 | bodytype = "Ghost" | |
| 417 | if workspace:findFirstChild(" ("..string.lower(owner.Name)..")") then
| |
| 418 | workspace:findFirstChild(" ("..string.lower(owner.Name)..")"):destroy()
| |
| 419 | end | |
| 420 | local sphereeffect = Instance.new("Part", workspace)
| |
| 421 | sphereeffect.Material = "Neon" | |
| 422 | sphereeffect.Shape = "Ball" | |
| 423 | sphereeffect.BrickColor = BrickColor.Black() | |
| 424 | sphereeffect.Anchored = true | |
| 425 | sphereeffect.Name = "GhostModeEffect" | |
| 426 | sphereeffect.CanCollide = false | |
| 427 | sphereeffect.CFrame = VALUE * CFrame.new(0,-1.5,0) | |
| 428 | sphereeffect.Size = Vector3.new(10,10,10) | |
| 429 | coroutine.wrap(function() | |
| 430 | local sound = Instance.new("Sound", sphereeffect)
| |
| 431 | sound.SoundId = "rbxassetid://34320976" | |
| 432 | sound.Volume = 1 | |
| 433 | sound:Play() | |
| 434 | end)() | |
| 435 | coroutine.wrap(function() | |
| 436 | for i = 1,20 do | |
| 437 | sphereeffect.Transparency = sphereeffect.Transparency + 0.05 | |
| 438 | sphereeffect.Size = sphereeffect.Size - Vector3.new(0.5,0.5,0.5) | |
| 439 | runservice.Stepped:wait() | |
| 440 | end | |
| 441 | wait(1.5) | |
| 442 | sphereeffect:destroy() | |
| 443 | end)() | |
| 444 | remote:FireClient(owner, "ghostedbody") | |
| 445 | end | |
| 446 | end | |
| 447 | - | if not workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")") then
|
| 447 | + | |
| 448 | - | Instance.new("Model", workspace).Name = "GH0ST ("..string.lower(owner.Name)..")"
|
| 448 | + | |
| 449 | if ghosted then | |
| 450 | - | local human0id = Instance.new("Humanoid", workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")"))
|
| 450 | + | |
| 451 | if not workspace:findFirstChild(" ("..string.lower(owner.Name)..")") then
| |
| 452 | Instance.new("Model", workspace).Name = " ("..string.lower(owner.Name)..")"
| |
| 453 | if bodytype == "Humanoid" then | |
| 454 | local human0id = Instance.new("Humanoid", workspace:findFirstChild(" ("..string.lower(owner.Name)..")"))
| |
| 455 | human0id.Died:connect(function() | |
| 456 | - | local model = workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")")
|
| 456 | + | |
| 457 | end) | |
| 458 | end | |
| 459 | end | |
| 460 | local model = workspace:findFirstChild(" ("..string.lower(owner.Name)..")")
| |
| 461 | for i,v in pairs(character:GetChildren()) do | |
| 462 | local found = nil | |
| 463 | for q,w in pairs(model:GetChildren()) do | |
| 464 | if v.Name == w.Name then | |
| 465 | if v.ClassName == "Accessory" or v.ClassName == "Hat" then | |
| 466 | found = v | |
| 467 | end | |
| 468 | if bodytype == "Humanoid" then | |
| 469 | if v.ClassName == "CharacterMesh" or v.ClassName == "ShirtGraphic" or v.ClassName == "Shirt" or v.ClassName == "Pants" then | |
| 470 | found = v | |
| 471 | end | |
| 472 | end | |
| 473 | end | |
| 474 | end | |
| 475 | if found == nil then | |
| 476 | if v.ClassName == "Accessory" or v.ClassName == "Hat" then | |
| 477 | if v:findFirstChild("Handle") then
| |
| 478 | local handdle = v.Handle | |
| 479 | local hatt = Instance.new("Accessory", model)
| |
| 480 | hatt.Name = v.Name | |
| 481 | local limb = Instance.new("SpawnLocation", hatt)
| |
| 482 | limb.Neutral = false | |
| 483 | limb.Name = "Handle" | |
| 484 | - | limb.Transparency = 0.9 |
| 484 | + | |
| 485 | limb.CFrame = handdle.CFrame | |
| 486 | if bodytype == "Ghost" then | |
| 487 | limb.Material = "Glass" | |
| 488 | limb.Transparency = 1 | |
| 489 | elseif bodytype == "Humanoid" then | |
| 490 | limb.Material = handdle.Material | |
| 491 | limb.Transparency = handdle.Transparency | |
| 492 | end | |
| 493 | limb.BrickColor = handdle.BrickColor | |
| 494 | limb.CanCollide = false | |
| 495 | limb:SetNetworkOwner(owner) | |
| 496 | if v.Handle:findFirstChildOfClass("SpecialMesh") then
| |
| 497 | v.Handle:findFirstChildOfClass("SpecialMesh"):Clone().Parent = limb
| |
| 498 | end | |
| 499 | end | |
| 500 | elseif bodytype == "Humanoid" then | |
| 501 | if v.ClassName == "CharacterMesh" or v.ClassName == "ShirtGraphic" or v.ClassName == "Shirt" or v.ClassName == "Pants" then | |
| 502 | v:Clone().Parent = model | |
| 503 | end | |
| 504 | end | |
| 505 | end | |
| 506 | end | |
| 507 | for i,v in pairs(character:GetDescendants()) do | |
| 508 | local found = nil | |
| 509 | for q,w in pairs(model:GetDescendants()) do | |
| 510 | if v.Name == w.Name then | |
| 511 | if v.ClassName == "Part" or v.ClassName == "MeshPart" then | |
| 512 | found = v | |
| 513 | end | |
| 514 | end | |
| 515 | end | |
| 516 | if found == nil then | |
| 517 | if v.ClassName == "Part" or v.ClassName == "MeshPart" then | |
| 518 | if v.Name == "Handle" and v.Parent.ClassName ~= "Tool" then return end | |
| 519 | local limb = Instance.new("SpawnLocation", model)
| |
| 520 | limb.Neutral = false | |
| 521 | limb.Name = v.Name | |
| 522 | limb.Size = v.Size | |
| 523 | limb.CFrame = v.CFrame | |
| 524 | if bodytype == "Ghost" then | |
| 525 | limb.Material = "Glass" | |
| 526 | limb.Transparency = 0.9 | |
| 527 | elseif bodytype == "Humanoid" then | |
| 528 | limb.Material = v.Material | |
| 529 | limb.Transparency = v.Transparency | |
| 530 | end | |
| 531 | limb.BrickColor = v.BrickColor | |
| 532 | limb.CanCollide = false | |
| 533 | limb:SetNetworkOwner(owner) | |
| 534 | if v.Name == "Head" then | |
| 535 | if bodytype == "Humanoid" then | |
| 536 | if character.Head:findFirstChildOfClass("Decal") then
| |
| 537 | character.Head:findFirstChildOfClass("Decal"):Clone().Parent = limb
| |
| 538 | end | |
| 539 | end | |
| 540 | if v:findFirstChildOfClass("SpecialMesh") then
| |
| 541 | v:findFirstChildOfClass("SpecialMesh"):Clone().Parent = limb
| |
| 542 | end | |
| 543 | end | |
| 544 | - | if workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")") then
|
| 544 | + | |
| 545 | - | workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")"):destroy()
|
| 545 | + | |
| 546 | end | |
| 547 | else | |
| 548 | if workspace:findFirstChild(" ("..string.lower(owner.Name)..")") then
| |
| 549 | - | if workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")") then
|
| 549 | + | workspace:findFirstChild(" ("..string.lower(owner.Name)..")"):destroy()
|
| 550 | - | workspace:findFirstChild("GH0ST ("..string.lower(owner.Name)..")"):destroy()
|
| 550 | + | |
| 551 | end | |
| 552 | else | |
| 553 | if workspace:findFirstChild(" ("..string.lower(owner.Name)..")") then
| |
| 554 | workspace:findFirstChild(" ("..string.lower(owner.Name)..")"):destroy()
| |
| 555 | end | |
| 556 | end | |
| 557 | end |