Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local plr = game.Players.G_osty
- local character = plr.Character
- RootPart=character.HumanoidRootPart
- RootJoint=RootPart.RootJoint
- character.Torso.roblox:Destroy()
- tors = character.Torso
- local Player_Size = 1
- vt=Vector3.new
- VT=Vector3.new
- cf=CFrame.new
- euler=CFrame.fromEulerAnglesXYZ
- necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
- necko2=cf(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
- LHC0=cf(-1,-1,0,-0,-0,-1,0,1,0,1,0,0)
- LHC1=cf(-0.5,1,0,-0,-0,-1,0,1,0,1,0,0)
- RHC0=cf(1,-1,0,0,0,1,0,1,0,-1,-0,-0)
- RHC1=cf(0.5,1,0,0,0,1,0,1,0,-1,-0,-0)
- RootPart=character.HumanoidRootPart
- RootJoint=RootPart.RootJoint
- RootCF=euler(-1.57,0,3.14)
- RAD=math.rad
- COS=math.cos
- local r = 255,0,0
- local g = 0,255,0
- local b = 0,0,255
- coroutine.resume(coroutine.create(function()
- while wait(1) do
- for i,v in pairs(character:GetChildren()) do
- if v:IsA("Part") and v.Name ~= "Head" then
- local v2 = v:Clone()
- v2:ClearAllChildren()
- v2.Name = "Glow"
- v2.Transparency = 0.7
- v2.CanCollide = false
- v2.Anchored = true
- v2.Material = Enum.Material.Neon
- v2.Parent = character
- v2.Color = Color3.fromRGB(r)
- v2.Position = v.Position + Vector3.new(-math.random(0.1,3),math.random(0.1,3),-math.random(0.1,3))
- local v3 = v:Clone()
- v3:ClearAllChildren()
- v3.Name = "Glow"
- v3.Transparency = 0.7
- v3.CanCollide = false
- v3.Anchored = true
- v3.Material = Enum.Material.Neon
- v3.Parent = character
- v3.Color = Color3.fromRGB(0,255,0)
- v3.Position = v.Position + Vector3.new(math.random(0.1,3),-math.random(0.1,3),math.random(0.1,3))
- local v4 = v:Clone()
- v4:ClearAllChildren()
- v4.Name = "Glow"
- v4.Transparency = 0.7
- v4.CanCollide = false
- v4.Anchored = true
- v4.Material = Enum.Material.Neon
- v4.Parent = character
- v4.Color = Color3.fromRGB(0,0,255)
- v4.Position = v.Position + Vector3.new(-math.random(0.1,3),math.random(0.1,3),-math.random(0.1,3))
- wait()
- v3:Destroy()
- v4:Destroy()
- v2:Destroy()
- end
- end
- end
- end))
- function clerp(a,b,t)
- local qa = {QuaternionFromCFrame(a)}
- local qb = {QuaternionFromCFrame(b)}
- local ax, ay, az = a.x, a.y, a.z
- local bx, by, bz = b.x, b.y, b.z
- local _t = 1-t
- return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
- end
- function aclerp(startCF,endCF,alpha)
- return startCF:lerp(endCF, alpha)
- end
- function Clerp(a,b,t)
- local qa = {QuaternionFromCFrame(a)}
- local qb = {QuaternionFromCFrame(b)}
- local ax, ay, az = a.x, a.y, a.z
- local bx, by, bz = b.x, b.y, b.z
- local _t = 1-t
- return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
- end
- function QuaternionFromCFrame(cf)
- local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
- local trace = m00 + m11 + m22
- if trace > 0 then
- local s = math.sqrt(1 + trace)
- local recip = 0.5/s
- return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
- else
- local i = 0
- if m11 > m00 then
- i = 1
- end
- if m22 > (i == 0 and m00 or m11) then
- i = 2
- end
- if i == 0 then
- local s = math.sqrt(m00-m11-m22+1)
- local recip = 0.5/s
- return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
- elseif i == 1 then
- local s = math.sqrt(m11-m22-m00+1)
- local recip = 0.5/s
- return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
- elseif i == 2 then
- local s = math.sqrt(m22-m00-m11+1)
- local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
- end
- end
- end
- function QuaternionToCFrame(px, py, pz, x, y, z, w)
- local xs, ys, zs = x + x, y + y, z + z
- local wx, wy, wz = w*xs, w*ys, w*zs
- local xx = x*xs
- local xy = x*ys
- local xz = x*zs
- local yy = y*ys
- local yz = y*zs
- local zz = z*zs
- return CFrame.new(px, py, pz,1-(yy+zz), xy - wz, xz + wy,xy + wz, 1-(xx+zz), yz - wx, xz - wy, yz + wx, 1-(xx+yy))
- end
- function QuaternionSlerp(a, b, t)
- local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
- local startInterp, finishInterp;
- if cosTheta >= 0.0001 then
- if (1 - cosTheta) > 0.0001 then
- local theta = math.acos(cosTheta)
- local invSinTheta = 1/math.sin(theta)
- startInterp = math.sin((1-t)*theta)*invSinTheta
- finishInterp = math.sin(t*theta)*invSinTheta
- else
- startInterp = 1-t
- finishInterp = t
- end
- else
- if (1+cosTheta) > 0.0001 then
- local theta = math.acos(-cosTheta)
- local invSinTheta = 1/math.sin(theta)
- startInterp = math.sin((t-1)*theta)*invSinTheta
- finishInterp = math.sin(t*theta)*invSinTheta
- else
- startInterp = t-1
- finishInterp = t
- end
- end
- return a[1]*startInterp + b[1]*finishInterp, a[2]*startInterp + b[2]*finishInterp, a[3]*startInterp + b[3]*finishInterp, a[4]*startInterp + b[4]*finishInterp
- end
- LW=tors["Left Shoulder"]
- LH=tors["Left Hip"]
- RW=tors["Right Shoulder"]
- RH=tors["Right Hip"]
- CF = CFrame.new
- Sin = math.sin
- Cos = math.cos
- Rad = math.rad
- angles=CFrame.Angles
- local sine = 0
- coroutine.resume(coroutine.create(function()
- while wait() do
- RootJoint.C0 = clerp(RootJoint.C0, RootCF * CF(0* Player_Size, 0* Player_Size, 2 + 0.25* Player_Size * Cos(sine / 12)) * angles(Rad(25), Rad(0), Rad(0)), 0.1)
- tors.Neck.C0 = clerp(tors.Neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(15 - 6.5 * Sin(sine / 12)), Rad(0), Rad(0)), 0.05)
- RH.C0 = clerp(RH.C0, CF(1* Player_Size, -1 - 0.15 * Cos(sine / 20)* Player_Size, -0.1* Player_Size) * angles(Rad(0), Rad(76), Rad(0)) * angles(Rad(-8.5 - 6.5 * Sin(sine / 12)), Rad(0), Rad(15)), 0.1)
- LH.C0 = clerp(LH.C0, CF(-1.1* Player_Size, -0.6 - 0.15 * Cos(sine / 20)* Player_Size, -0.3* Player_Size) * angles(Rad(0), Rad(-76), Rad(0)) * angles(Rad(-8.5 - 6.5 * Sin(sine / 12)), Rad(15), Rad(25)), 0.1)
- RW.C0 = clerp(RW.C0, CF(1.4* Player_Size, 0.4 + 0.08 * Sin(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(25 - 6.5 * Cos(sine / 12)), Rad(-.6), Rad(13 + 6.5 * Sin(sine / 12))), 0.1)
- LW.C0 = clerp(LW.C0, CF(-1.4* Player_Size, 0.4 + 0.08 * Sin(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(25 - 6.5 * Cos(sine / 12)), Rad(-.6), Rad(-13 - 6.5 * Sin(sine / 12))), 0.1)
- end
- end))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement