SHOW:
|
|
- or go back to the newest paste.
| 1 | -- This script has been converted to FE by iPxter | |
| 2 | ||
| 3 | ||
| 4 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
| |
| 5 | local Player,Mouse,mouse,UserInputService,ContextActionService = owner | |
| 6 | do | |
| 7 | print("FE Compatibility code by Mokiros | Translated to FE by iPxter")
| |
| 8 | script.Parent = Player.Character | |
| 9 | ||
| 10 | --RemoteEvent for communicating | |
| 11 | local Event = Instance.new("RemoteEvent")
| |
| 12 | Event.Name = "UserInput_Event" | |
| 13 | ||
| 14 | --Fake event to make stuff like Mouse.KeyDown work | |
| 15 | local function fakeEvent() | |
| 16 | local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
| |
| 17 | t.connect = t.Connect | |
| 18 | return t | |
| 19 | end | |
| 20 | ||
| 21 | --Creating fake input objects with fake variables | |
| 22 | local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
| |
| 23 | local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
| |
| 24 | local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
| |
| 25 | CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
| |
| 26 | end} | |
| 27 | --Merged 2 functions into one by checking amount of arguments | |
| 28 | CAS.UnbindAction = CAS.BindAction | |
| 29 | ||
| 30 | --This function will trigger the events that have been :Connect()'ed | |
| 31 | local function te(self,ev,...) | |
| 32 | local t = m[ev] | |
| 33 | if t and t._fakeEvent and t.Function then | |
| 34 | t.Function(...) | |
| 35 | end | |
| 36 | - | local plr = game:GetService('Players').LocalPlayer
|
| 36 | + | |
| 37 | m.TrigEvent = te | |
| 38 | - | local mouse = plr:GetMouse() |
| 38 | + | UIS.TrigEvent = te |
| 39 | ||
| 40 | Event.OnServerEvent:Connect(function(plr,io) | |
| 41 | if plr~=Player then return end | |
| 42 | if io.isMouse then | |
| 43 | m.Target = io.Target | |
| 44 | m.Hit = io.Hit | |
| 45 | else | |
| 46 | local b = io.UserInputState == Enum.UserInputState.Begin | |
| 47 | if io.UserInputType == Enum.UserInputType.MouseButton1 then | |
| 48 | return m:TrigEvent(b and "Button1Down" or "Button1Up") | |
| 49 | end | |
| 50 | for _,t in pairs(CAS.Actions) do | |
| 51 | for _,k in pairs(t.Keys) do | |
| 52 | if k==io.KeyCode then | |
| 53 | t.Function(t.Name,io.UserInputState,io) | |
| 54 | end | |
| 55 | end | |
| 56 | end | |
| 57 | m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower()) | |
| 58 | UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false) | |
| 59 | end | |
| 60 | end) | |
| 61 | Event.Parent = NLS([==[ | |
| 62 | local Player = game:GetService("Players").LocalPlayer
| |
| 63 | local Event = script:WaitForChild("UserInput_Event")
| |
| 64 | ||
| 65 | local UIS = game:GetService("UserInputService")
| |
| 66 | local input = function(io,a) | |
| 67 | if a then return end | |
| 68 | --Since InputObject is a client-side instance, we create and pass table instead | |
| 69 | Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
| |
| 70 | end | |
| 71 | UIS.InputBegan:Connect(input) | |
| 72 | UIS.InputEnded:Connect(input) | |
| 73 | ||
| 74 | local Mouse = Player:GetMouse() | |
| 75 | local h,t | |
| 76 | --Give the server mouse data 30 times every second, but only if the values changed | |
| 77 | --If player is not moving their mouse, client won't fire events | |
| 78 | while wait(1/30) do | |
| 79 | if h~=Mouse.Hit or t~=Mouse.Target then | |
| 80 | h,t=Mouse.Hit,Mouse.Target | |
| 81 | Event:FireServer({isMouse=true,Target=t,Hit=h})
| |
| 82 | end | |
| 83 | end]==],Player.Character) | |
| 84 | Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS | |
| 85 | end | |
| 86 | --[[ Time Testing ]]-- | |
| 87 | ------------------------------------------------------- | |
| 88 | --[[ | |
| 89 | ||
| 90 | This script was created by WafflesAreVeryGood. | |
| 91 | ATTACKS | |
| 92 | _______ | |
| 93 | ||
| 94 | ||
| 95 | --]] | |
| 96 | ------------------------------------------------------- | |
| 97 | print("This script was created by WafflesAreVeryGood!")
| |
| 98 | --[[Changeable Variables]]-- | |
| 99 | local multiplier = 1 --Attack multiplier (default is 1) | |
| 100 | local soundlist = {
| |
| 101 | HardHit1 = "rbxassetid://565207203", | |
| 102 | HardHit2 = "rbxassetid://541909913", | |
| 103 | HardHit3 = "rbxassetid://541909983", | |
| 104 | WeakHit1 = "rbxassetid://558642292", | |
| 105 | WeakHit2 = "rbxassetid://541907812", | |
| 106 | Slice1 = "rbxassetid://260429964", | |
| 107 | Slice2 = "rbxassetid://260430015", | |
| 108 | Explosion1 = "rbxassetid://138186576", | |
| 109 | Explosion2 = "rbxassetid://157878578", | |
| 110 | Woosh1 = "rbxassetid://541909867", | |
| 111 | Woosh2 = "rbxassetid://541909763", | |
| 112 | TimeSlow = "rbxassetid://615678808", | |
| 113 | TimeStop = "rbxassetid://926382097", | |
| 114 | TimeResume = "rbxassetid://894793352", | |
| 115 | TimeFast = "rbxassetid://743499393", | |
| 116 | TimeReverse = "rbxassetid://618737332", | |
| 117 | ||
| 118 | } | |
| 119 | ||
| 120 | --[[Important Variables]]-- | |
| 121 | local plr = owner | |
| 122 | local char = plr.Character | |
| 123 | local input = game:GetService('UserInputService')
| |
| 124 | ---- | |
| 125 | local joints = {"Right Shoulder", "Left Shoulder", "Right Hip", "Left Hip", "Neck", "RootJoint"}
| |
| 126 | local torso,head,rootpart = char.Torso,char.Head,char.HumanoidRootPart | |
| 127 | local rs = torso["Right Shoulder"] | |
| 128 | local ls = torso["Left Shoulder"] | |
| 129 | local rh = torso["Right Hip"] | |
| 130 | local lh = torso["Left Hip"] | |
| 131 | local neck = torso.Neck | |
| 132 | local rj = rootpart["RootJoint"] | |
| 133 | ---- | |
| 134 | local huge = Vector3.new(math.huge, math.huge, math.huge) | |
| 135 | local attacking = false | |
| 136 | local cananim = true | |
| 137 | local timestop = false | |
| 138 | local timeslow = false | |
| 139 | local timefast = false | |
| 140 | local reversing = false | |
| 141 | local unfreeze = {}
| |
| 142 | local sounddata = {}
| |
| 143 | local connections = {}
| |
| 144 | local healthstuff = {}
| |
| 145 | ||
| 146 | --[[ Functions ]]-- | |
| 147 | function addattack(keycode, func) | |
| 148 | input.InputBegan:connect(function(inp) | |
| 149 | if inp.KeyCode == keycode and not input:GetFocusedTextBox() then | |
| 150 | func() | |
| 151 | end | |
| 152 | end) | |
| 153 | end | |
| 154 | function attackend(keycode, func) | |
| 155 | input.InputEnded:connect(function(inp) | |
| 156 | if inp.KeyCode == keycode and not input:GetFocusedTextBox() then | |
| 157 | func() | |
| 158 | end | |
| 159 | end) | |
| 160 | end | |
| 161 | function swait(t) | |
| 162 | if t then | |
| 163 | for i = 0, t do | |
| 164 | game:GetService('RunService').Stepped:wait(0)
| |
| 165 | end | |
| 166 | else | |
| 167 | game:GetService('RunService').Stepped:wait(0)
| |
| 168 | end | |
| 169 | return true | |
| 170 | end | |
| 171 | function fade(obj, dest, grow) | |
| 172 | spawn(function() | |
| 173 | local oldcf = obj.CFrame | |
| 174 | for i = 0, 10 do | |
| 175 | if grow then | |
| 176 | obj.Size = obj.Size +Vector3.new(1,1,1) | |
| 177 | obj.CFrame = oldcf | |
| 178 | end | |
| 179 | obj.Transparency = obj.Transparency +0.1 | |
| 180 | swait() | |
| 181 | end | |
| 182 | if dest then | |
| 183 | obj:Destroy() | |
| 184 | end | |
| 185 | end) | |
| 186 | end | |
| 187 | function replacejoint(name) | |
| 188 | local j = torso:FindFirstChild(name) | |
| 189 | if not j then j = char.HumanoidRootPart:FindFirstChild(name) end | |
| 190 | if j then | |
| 191 | if true then | |
| 192 | local already = j.Parent:FindFirstChild(j.Name.." Replacement") | |
| 193 | local new = Instance.new("Weld")
| |
| 194 | local c0 = j.C0 | |
| 195 | local c1 = j.C1 | |
| 196 | new.Part0 = j.Part0 | |
| 197 | j.Part0 = nil | |
| 198 | new.Name = j.Name.." Replacement" | |
| 199 | if already then c0 = already.C0 c1 = already.C1 already:Destroy() end | |
| 200 | new.Parent = j.Parent | |
| 201 | new.Part1 = j.Part1 | |
| 202 | new.C0 = c0 | |
| 203 | new.C1 = c1 | |
| 204 | return new | |
| 205 | end | |
| 206 | end | |
| 207 | end | |
| 208 | function removejoint(name, fast) | |
| 209 | local j = torso:FindFirstChild(name.." Replacement") | |
| 210 | if not j then j = char.HumanoidRootPart:FindFirstChild(name.." Replacement") end | |
| 211 | if j then | |
| 212 | local p0 = j.Part0 | |
| 213 | if p0 ~= nil then | |
| 214 | local c0 = j.C0 | |
| 215 | local c1 = j.C1 | |
| 216 | j:Destroy() | |
| 217 | local new = p0:FindFirstChild(name) | |
| 218 | local ac0 = new.C0 | |
| 219 | local ac1 = new.C1 | |
| 220 | new.Part0 = p0 | |
| 221 | new.C0 = c0 | |
| 222 | new.C1 = c1 | |
| 223 | spawn(function() | |
| 224 | if name ~= "RootJoint" then | |
| 225 | if not fast then | |
| 226 | for i = 0, 0.6, 0.1 do | |
| 227 | new.C0 = new.C0:Lerp(ac0, 0.5) | |
| 228 | new.C1 = new.C1:lerp(ac1, 0.5) | |
| 229 | swait() | |
| 230 | end | |
| 231 | else | |
| 232 | new.C0 = new.C0:Lerp(ac0, 1) | |
| 233 | new.C1 = new.C1:lerp(ac1, 1) | |
| 234 | end | |
| 235 | end | |
| 236 | end) | |
| 237 | end | |
| 238 | end | |
| 239 | end | |
| 240 | function fixalljoints(fast) | |
| 241 | for i,v in pairs({"Right Shoulder", "Left Shoulder", "Right Hip", "Left Hip", "Neck", "RootJoint"}) do
| |
| 242 | removejoint(v, fast) | |
| 243 | end | |
| 244 | end | |
| 245 | function getnewjoints() | |
| 246 | local rs = replacejoint("Right Shoulder")
| |
| 247 | local ls = replacejoint("Left Shoulder")
| |
| 248 | local rh = replacejoint("Right Hip")
| |
| 249 | local lh = replacejoint("Left Hip")
| |
| 250 | local neck = replacejoint("Neck")
| |
| 251 | local rj = replacejoint("RootJoint")
| |
| 252 | return rs,ls,rh,lh,neck,rj | |
| 253 | end | |
| 254 | function knockback(hit, force) | |
| 255 | local bv = Instance.new("BodyVelocity")
| |
| 256 | bv.MaxForce = huge | |
| 257 | bv.Velocity = force | |
| 258 | bv.Parent = hit | |
| 259 | game:GetService('Debris'):AddItem(bv, 0.15)
| |
| 260 | end | |
| 261 | function soundeffect(id, volume, speed, parent, forcewait) | |
| 262 | local func = function() | |
| 263 | local s = LoadLibrary("RbxUtility").Create("Sound")()
| |
| 264 | s.Name = "SoundEffect" | |
| 265 | s.Volume = volume | |
| 266 | s.PlaybackSpeed = speed | |
| 267 | s.SoundId = id | |
| 268 | s.Name = "dont" | |
| 269 | s.Looped = false | |
| 270 | s.Parent = parent | |
| 271 | s:Play() | |
| 272 | repeat wait() until not s.Playing | |
| 273 | s:Destroy() | |
| 274 | end | |
| 275 | if forcewait then | |
| 276 | func() | |
| 277 | else | |
| 278 | spawn(func) | |
| 279 | end | |
| 280 | end | |
| 281 | function getascendants(obj) | |
| 282 | local par = obj | |
| 283 | local ret = {}
| |
| 284 | pcall(function() | |
| 285 | repeat | |
| 286 | par = par.Parent | |
| 287 | if par ~= nil then | |
| 288 | table.insert(ret, par) | |
| 289 | end | |
| 290 | until par == nil | |
| 291 | end) | |
| 292 | return ret | |
| 293 | end | |
| 294 | function findascendant(obj, class) | |
| 295 | local par = obj | |
| 296 | local ret = nil | |
| 297 | pcall(function() | |
| 298 | repeat | |
| 299 | par = par.Parent | |
| 300 | if par:IsA(class) then | |
| 301 | ret = par | |
| 302 | break | |
| 303 | end | |
| 304 | until par == nil | |
| 305 | end) | |
| 306 | return ret | |
| 307 | end | |
| 308 | function hurt(hit, dmg) | |
| 309 | --pcall(function() | |
| 310 | local hum = hit.Parent:FindFirstChildOfClass("Humanoid")
| |
| 311 | if hum then | |
| 312 | if hum.Parent ~= char then | |
| 313 | hum.Health = hum.Health - dmg | |
| 314 | hum.Health = hum.Health - dmg | |
| 315 | soundeffect(soundlist.Headshot, 1.5, 1, workspace.CurrentCamera) | |
| 316 | return true | |
| 317 | end | |
| 318 | end | |
| 319 | --end) | |
| 320 | end | |
| 321 | --[[ Actual script :OOOOOOOOOO ]]-- | |
| 322 | addattack(Enum.KeyCode.G, function() | |
| 323 | if not timeslow and not timefast and not reversing then | |
| 324 | local p = Instance.new("Part")
| |
| 325 | p.Anchored = true | |
| 326 | p.Material = "Glass" | |
| 327 | p.Size = Vector3.new(0.1,0.1,0.1) | |
| 328 | p.BrickColor = BrickColor.new("Toothpaste")
| |
| 329 | p.CanCollide = false | |
| 330 | p.CFrame = char.HumanoidRootPart.CFrame | |
| 331 | local m = Instance.new("SpecialMesh")
| |
| 332 | m.MeshType = "Sphere" | |
| 333 | m.Parent = p | |
| 334 | p.Parent = char | |
| 335 | spawn(function() | |
| 336 | for i = 1, 50 do | |
| 337 | p.Transparency = i/50 | |
| 338 | p.Size = p.Size:Lerp(Vector3.new(40,40,40),0.1) | |
| 339 | p.CFrame = char.HumanoidRootPart.CFrame | |
| 340 | swait() | |
| 341 | end | |
| 342 | p:Destroy() | |
| 343 | end) | |
| 344 | if not timestop then | |
| 345 | local s = Instance.new("Sound")
| |
| 346 | s.Volume = 3 | |
| 347 | s.Name = "dont" | |
| 348 | s.SoundId = soundlist.TimeStop | |
| 349 | s.Parent = char | |
| 350 | s:Play() | |
| 351 | dcon = workspace.DescendantAdded:connect(function(obj) | |
| 352 | pcall(function() | |
| 353 | swait() | |
| 354 | local ok = true | |
| 355 | for i,v in pairs(getascendants(obj)) do | |
| 356 | if v.Name:lower():find("ignoremodel") then
| |
| 357 | ok = false | |
| 358 | end | |
| 359 | end | |
| 360 | if obj:IsA("BasePart") and ok and not findascendant(obj, "Tool") and not findascendant(obj, "HopperBin") and not findascendant(obj, "Camera") then
| |
| 361 | if not obj.Anchored and obj.Name ~= "HumanoidRootPart" then | |
| 362 | table.insert(unfreeze, obj) | |
| 363 | obj.Anchored = true | |
| 364 | end | |
| 365 | end | |
| 366 | if obj:IsA("Sound") and obj.Name ~= "dont" then
| |
| 367 | if obj.Playing then | |
| 368 | obj:Pause() | |
| 369 | table.insert(unfreeze, obj) | |
| 370 | end | |
| 371 | end | |
| 372 | if obj:IsA("Humanoid") then
| |
| 373 | local last = obj.Health | |
| 374 | local always = last | |
| 375 | local con = obj.HealthChanged:connect(function(health) | |
| 376 | if last-health > 0 then | |
| 377 | table.insert(healthstuff, {hum = obj, change = last-health})
| |
| 378 | end | |
| 379 | last = health | |
| 380 | obj.Health = always | |
| 381 | end) | |
| 382 | table.insert(connections, con) | |
| 383 | end | |
| 384 | end) | |
| 385 | end) | |
| 386 | for i,v in pairs(workspace:GetDescendants()) do | |
| 387 | pcall(function() | |
| 388 | if v:IsA("BasePart") then
| |
| 389 | local ok = true | |
| 390 | for i,e in pairs(getascendants(v)) do | |
| 391 | if e.Name:lower():find("ignore_model") then
| |
| 392 | ok = false | |
| 393 | end | |
| 394 | if e:IsA("Camera") then
| |
| 395 | ok = false | |
| 396 | end | |
| 397 | end | |
| 398 | if not v.Anchored and ok and v.Parent ~= char and not findascendant(v, "Camera") and not findascendant(v, "Tool") and not findascendant(v, "HopperBin") then | |
| 399 | local ok = true | |
| 400 | if v.Parent:IsA("Accessory") then ok = false end
| |
| 401 | if ok and v.Name ~= "HumanoidRootPart" then | |
| 402 | v.Anchored = true | |
| 403 | table.insert(unfreeze, v) | |
| 404 | end | |
| 405 | end | |
| 406 | end | |
| 407 | end) | |
| 408 | pcall(function() | |
| 409 | if v:IsA("Sound") and v.Name ~= "dont" then
| |
| 410 | if v.Playing then | |
| 411 | v:Pause() | |
| 412 | table.insert(unfreeze, v) | |
| 413 | end | |
| 414 | end | |
| 415 | end) | |
| 416 | pcall(function() | |
| 417 | if v:IsA("Humanoid") then
| |
| 418 | local last = v.Health | |
| 419 | local always = last | |
| 420 | local con = v.HealthChanged:connect(function(health) | |
| 421 | if last-health > 0 then | |
| 422 | table.insert(healthstuff, {hum = v, change = last-health})
| |
| 423 | end | |
| 424 | last = health | |
| 425 | v.Health = always | |
| 426 | end) | |
| 427 | table.insert(connections, con) | |
| 428 | end | |
| 429 | end) | |
| 430 | end | |
| 431 | timestop = true | |
| 432 | local cor = Instance.new("ColorCorrectionEffect")
| |
| 433 | cor.Name = "tstopef" | |
| 434 | cor.Parent = game:GetService('Lighting')
| |
| 435 | for i = 1, 50 do | |
| 436 | cor.Saturation = Vector3.new(cor.Saturation,0,0):Lerp(Vector3.new(-5,0,0), 0.05).X | |
| 437 | swait() | |
| 438 | end | |
| 439 | game.Debris:AddItem(s, 2) | |
| 440 | else | |
| 441 | local s = Instance.new("Sound")
| |
| 442 | s.Volume = 7 | |
| 443 | s.Name = "dont" | |
| 444 | s.SoundId = soundlist.TimeResume | |
| 445 | s.Parent = char | |
| 446 | s:Play() | |
| 447 | local cor = game:GetService('Lighting'):FindFirstChild("tstopef")
| |
| 448 | if cor then | |
| 449 | for i = 1, 50 do | |
| 450 | cor.Saturation = Vector3.new(cor.Saturation,0,0):Lerp(Vector3.new(0,0,0), 0.05).X | |
| 451 | swait() | |
| 452 | end | |
| 453 | cor:Destroy() | |
| 454 | end | |
| 455 | game.Debris:AddItem(s, 2) | |
| 456 | timestop = false | |
| 457 | for i,v in pairs(unfreeze) do | |
| 458 | pcall(function() | |
| 459 | v.Anchored = false | |
| 460 | end) | |
| 461 | pcall(function() | |
| 462 | v:Resume() | |
| 463 | end) | |
| 464 | end | |
| 465 | for i,v in pairs(connections) do | |
| 466 | pcall(function() | |
| 467 | v:disconnect() | |
| 468 | end) | |
| 469 | end | |
| 470 | for i,v in pairs(healthstuff) do | |
| 471 | pcall(function() | |
| 472 | local hum = v.hum | |
| 473 | hum.Health = hum.Health - v.change | |
| 474 | if hum.Parent:FindFirstChild("Health") then
| |
| 475 | pcall(function() | |
| 476 | hum.Parent.Health.Disabled = false | |
| 477 | end) | |
| 478 | end | |
| 479 | end) | |
| 480 | end | |
| 481 | pcall(function() | |
| 482 | dcon:disconnect() | |
| 483 | end) | |
| 484 | healthstuff = {}
| |
| 485 | unfreeze = {}
| |
| 486 | end | |
| 487 | end | |
| 488 | end) | |
| 489 | local humanoiddata = {}
| |
| 490 | local bodymoverdata = {}
| |
| 491 | local dcon2 | |
| 492 | local connectionsdata = {}
| |
| 493 | addattack(Enum.KeyCode.H, function() | |
| 494 | if not timeslow and not timestop and not reversing then | |
| 495 | local p = Instance.new("Part")
| |
| 496 | p.Anchored = true | |
| 497 | p.Material = "Glass" | |
| 498 | p.Size = Vector3.new(0.1,0.1,0.1) | |
| 499 | p.BrickColor = BrickColor.new("Toothpaste")
| |
| 500 | p.CanCollide = false | |
| 501 | p.CFrame = char.HumanoidRootPart.CFrame | |
| 502 | local m = Instance.new("SpecialMesh")
| |
| 503 | m.MeshType = "Sphere" | |
| 504 | m.Parent = p | |
| 505 | p.Parent = char | |
| 506 | spawn(function() | |
| 507 | for i = 1, 50 do | |
| 508 | p.Transparency = i/50 | |
| 509 | p.Size = p.Size:Lerp(Vector3.new(40,40,40),0.1) | |
| 510 | p.CFrame = char.HumanoidRootPart.CFrame | |
| 511 | swait() | |
| 512 | end | |
| 513 | p:Destroy() | |
| 514 | end) | |
| 515 | if not timefast then | |
| 516 | timefast = true | |
| 517 | soundeffect(soundlist.TimeFast, 1.5, 1, char) | |
| 518 | for i,v in pairs(workspace:GetDescendants()) do | |
| 519 | if v:IsA("Humanoid") then
| |
| 520 | table.insert(humanoiddata, {Hum = v, WS = v.WalkSpeed, JP = v.JumpPower})
| |
| 521 | for _,track in pairs(v:GetPlayingAnimationTracks()) do | |
| 522 | end | |
| 523 | local con = v.AnimationPlayed:connect(function(track) | |
| 524 | end) | |
| 525 | table.insert(connections, con) | |
| 526 | end | |
| 527 | if v:IsA("BodyVelocity") then
| |
| 528 | table.insert(bodymoverdata, {Mover = v, Vel = v.Velocity})
| |
| 529 | end | |
| 530 | if v:IsA("BodyPosition") then
| |
| 531 | table.insert(bodymoverdata, {Mover = v, Vel = v.P})
| |
| 532 | end | |
| 533 | if v.Name == "HumanoidRootPart" and v:IsA("BasePart") then
| |
| 534 | end | |
| 535 | if v:IsA("Sound") and v.Name ~= "dont" then
| |
| 536 | table.insert(sounddata, {Sound = v, Speed = v.PlaybackSpeed})
| |
| 537 | end | |
| 538 | end | |
| 539 | dcon2 = workspace.DescendantAdded:connect(function(v) | |
| 540 | swait(2) | |
| 541 | if v:IsA("Humanoid") then
| |
| 542 | - | for _,track in pairs(v:GetPlayingAnimationTracks()) domoverdata, {Mover = v, Vel = v.P})
|
| 542 | + | |
| 543 | for _,track in pairs(v:GetPlayingAnimationTracks()) do | |
| 544 | track:AdjustSpeed(1.4) | |
| 545 | end | |
| 546 | local con = v.AnimationPlayed:connect(function(track) | |
| 547 | track:AdjustSpeed(1.4) | |
| 548 | end) | |
| 549 | table.insert(connections, con) | |
| 550 | end | |
| 551 | if v:IsA("BodyVelocity") then
| |
| 552 | table.insert(bodymoverdata, {Mover = v, Vel = v.Velocity})
| |
| 553 | end | |
| 554 | if v:IsA("BodyPosition") then
| |
| 555 | table.insert(bodymoverdata, {Mover = v, Vel = v.P})
| |
| 556 | end | |
| 557 | if v.Name == "HumanoidRootPart" and v:IsA("BasePart") then
| |
| 558 | end | |
| 559 | if v:IsA("Sound") and v.Name ~= "dont" then
| |
| 560 | table.insert(sounddata, {Sound = v, Speed = v.PlaybackSpeed})
| |
| 561 | end | |
| 562 | end) | |
| 563 | else | |
| 564 | timefast = false | |
| 565 | soundeffect(soundlist.TimeResume, 1.5, 1, char) | |
| 566 | for i,v in pairs(humanoiddata) do | |
| 567 | pcall(function() | |
| 568 | v["Hum"].WalkSpeed = v["WS"] | |
| 569 | v["Hum"].JumpPower = v["JP"] | |
| 570 | end) | |
| 571 | end | |
| 572 | for i,v in pairs(bodymoverdata) do | |
| 573 | pcall(function() | |
| 574 | if v["Mover"]:IsA("BodyVelocity") then
| |
| 575 | v["Mover"].Velocity = v["Vel"] | |
| 576 | end | |
| 577 | if v["Mover"]:IsA("BodyPosition") then
| |
| 578 | v["Mover"].P = v["Vel"] | |
| 579 | end | |
| 580 | end) | |
| 581 | end | |
| 582 | for i,v in pairs(sounddata) do | |
| 583 | pcall(function() | |
| 584 | v["Sound"].PlaybackSpeed = v["Speed"] | |
| 585 | end) | |
| 586 | end | |
| 587 | for i,v in pairs(connections) do | |
| 588 | pcall(function() | |
| 589 | v:disconnect() | |
| 590 | end) | |
| 591 | end | |
| 592 | connections = {}
| |
| 593 | pcall(function() | |
| 594 | dcon2:disconnect() | |
| 595 | end) | |
| 596 | humanoiddata = {}
| |
| 597 | end | |
| 598 | end | |
| 599 | end) | |
| 600 | addattack(Enum.KeyCode.F, function() | |
| 601 | if not timestop and not timefast and not reversing then | |
| 602 | local p = Instance.new("Part")
| |
| 603 | p.Anchored = true | |
| 604 | p.Material = "Glass" | |
| 605 | p.Size = Vector3.new(0.1,0.1,0.1) | |
| 606 | p.BrickColor = BrickColor.new("Toothpaste")
| |
| 607 | p.CanCollide = false | |
| 608 | p.CFrame = char.HumanoidRootPart.CFrame | |
| 609 | local m = Instance.new("SpecialMesh")
| |
| 610 | local cor = Instance.new("ColorCorrectionEffect")
| |
| 611 | cor.Name = "slowcor" | |
| 612 | cor.Parent = game:GetService('Lighting')
| |
| 613 | spawn(function() | |
| 614 | for i = 1, 20 do | |
| 615 | pcall(function() | |
| 616 | swait() | |
| 617 | table.insert(bodymoverdata, {Mover = v, Vel = v.Velocity})
| |
| 618 | end) | |
| 619 | if v:IsA("BodyPosition") then
| |
| 620 | table.insert(bodymoverdata, {Mover = v, Vel = v.P})
| |
| 621 | end | |
| 622 | dcon2 = workspace.DescendantAdded:connect(function(v) | |
| 623 | swait(2) | |
| 624 | if v:IsA("Humanoid") then
| |
| 625 | table.insert(humanoiddata, {Hum = v, WS = v.WalkSpeed, JP = v.JumpPower})
| |
| 626 | for _,track in pairs(v:GetPlayingAnimationTracks()) domovedata, {Mover = v, Vel = v.P})
| |
| 627 | end | |
| 628 | if v.Name == "HumanoidRootPart" and v:IsA("BasePart") then
| |
| 629 | end | |
| 630 | if v:IsA("Sound") and v.Name ~= "dont" then
| |
| 631 | table.insert(sounddata, {Sound = v, Speed = v.PlaybackSpeed})
| |
| 632 | end | |
| 633 | end) | |
| 634 | else | |
| 635 | local cor = game:GetService('Lighting'):FindFirstChild("slowcor")
| |
| 636 | if cor then | |
| 637 | spawn(function() | |
| 638 | pcall(function() | |
| 639 | cor:Destroy() | |
| 640 | end) | |
| 641 | end) | |
| 642 | end | |
| 643 | timeslow = false | |
| 644 | soundeffect(soundlist.TimeResume, 1.5, 1, char) | |
| 645 | pcall(function() | |
| 646 | if v["Mover"]:IsA("BodyVelocity") then
| |
| 647 | v["Mover"].Velocity = v["Vel"] | |
| 648 | end | |
| 649 | connections = {}
| |
| 650 | pcall(function() | |
| 651 | dcon2:disconnect() | |
| 652 | end) | |
| 653 | humanoiddata = {}
| |
| 654 | end | |
| 655 | end | |
| 656 | end) | |
| 657 | local reversedata = {}
| |
| 658 | local saved = false | |
| 659 | addattack(Enum.KeyCode.C, function() | |
| 660 | if not timestop and not timeslow and not timefast then | |
| 661 | if not saved then | |
| 662 | saved = true | |
| 663 | for i,v in pairs(workspace:GetDescendants()) do | |
| 664 | }a) | |
| 665 | end | |
| 666 | end | |
| 667 | else | |
| 668 | reversing = true | |
| 669 | saved = false | |
| 670 | soundeffect(soundlist.TimeReverse, 2, 1, workspace) | |
| 671 | for i = 1, 10 do | |
| 672 | for _,v in pairs(reversedata) do | |
| 673 | local obj = v.obj | |
| 674 | local cf = v.cf obj.Anchored = true | |
| 675 | end) | |
| 676 | end | |
| 677 | swait() | |
| 678 | end | |
| 679 | char.HumanoidRootPart.Velocity = Vector3.new(0,0,0) | |
| 680 | reversedata = {}
| |
| 681 | reversing = false | |
| 682 | end | |
| 683 | end | |
| 684 | end) |