Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- print'why sInstitutional white credit when you know it\'s mine?'
- --print'madiik cannot be resisted kthx'
- function clerp(c1,c2,al)
- local com1 = {c1.X,c1.Y,c1.Z,c1:toEulerAnglesXYZ()}
- local com2 = {c2.X,c2.Y,c2.Z,c2:toEulerAnglesXYZ()}
- for i,v in pairs(com1) do
- com1[i] = v+(com2[i]-v)*al
- end
- return CFrame.new(com1[1],com1[2],com1[3]) * CFrame.Angles(select(4,unpack(com1)))
- end
- plr = game:service'Players'.LocalPlayer
- plrgui = plr.PlayerGui
- char = plr.Character
- mouse = plr:GetMouse()
- humanoid = char:findFirstChild("Humanoid")
- torso = char:findFirstChild("Torso")
- head = char.Head
- ra = char:findFirstChild("Right Arm")
- la = char:findFirstChild("Left Arm")
- rl = char:findFirstChild("Right Leg")
- ll = char:findFirstChild("Left Leg")
- rs = torso:findFirstChild("Right Shoulder")
- ls = torso:findFirstChild("Left Shoulder")
- rh = torso:findFirstChild("Right Hip")
- lh = torso:findFirstChild("Left Hip")
- neck = torso:findFirstChild("Neck")
- rj = char:findFirstChild("HumanoidRootPart"):findFirstChild("RootJoint")
- rootpart = char:findFirstChild("HumanoidRootPart")
- camera = workspace.CurrentCamera
- anim = char:findFirstChild("Animate")
- if anim then
- anim:Destroy()
- end
- wait(1)
- local rm = Instance.new("Motor", torso)
- rm.C0 = CFrame.new(1.5, 0.5, 0)
- rm.C1 = CFrame.new(0, 0.5, 0)
- rm.Part0 = torso
- rm.Part1 = ra
- rm.Name = 'Right Shoulder'
- local lm = Instance.new("Motor", torso)
- lm.C0 = CFrame.new(-1.5, 0.5, 0)
- lm.C1 = CFrame.new(0, 0.5, 0)
- lm.Part0 = torso
- lm.Part1 = la
- lm.Name = 'Left Shoulder'
- local rlegm = Instance.new("Motor", torso)
- rlegm.C0 = CFrame.new(0.5, -1, 0)
- rlegm.C1 = CFrame.new(0, 1, 0)
- rlegm.Part0 = torso
- rlegm.Part1 = rl
- local llegm = Instance.new("Motor", torso)
- llegm.C0 = CFrame.new(-0.5, -1, 0)
- llegm.C1 = CFrame.new(0, 1, 0)
- llegm.Part0 = torso
- llegm.Part1 = ll
- rj.C0 = CFrame.new()
- rj.C1 = CFrame.new()
- local speed = 0.3
- local angle = 0
- local anglespeed = 1
- rsc0 = rm.C0
- lsc0 = lm.C0
- llc0 = llegm.C0
- rlc0 = rlegm.C0
- rootc0 = rj.C0
- mouse.KeyDown:connect(function(k)
- if k == "e" then
- fieryhead = not fieryhead
- if fieryhead then
- coroutine.wrap(function()
- while fieryhead and wait() do
- local FireColors = {'Really black', 'Institutional white'}
- local p = Instance.new('Part', char)
- p.BrickColor = BrickColor.new(FireColors[math.random(1,#FireColors)])
- p.FormFactor = 'Custom'
- p.Size = Vector3.new(3, 3, 3)
- p.CanCollide = false
- p.Anchored = true
- p.Locked = true
- Instance.new('PointLight', p).Range = 10
- p.CFrame = head.CFrame * CFrame.new(0, 1, 0) * CFrame.Angles(math.random(0,3),math.random(0,3),math.random(0,3))
- Instance.new('BlockMesh', p)
- coroutine.wrap(function()
- for i = 1, 10 do
- p.Mesh.Scale = p.Mesh.Scale - Vector3.new(.1, .1, .1)
- p.CFrame = p.CFrame * CFrame.new(0, .35, 0)
- wait()
- end
- end)()
- game:service'Debris':AddItem(p, .55)
- end
- end)()
- end
- end
- if k == "r" then
- if Charge1Anim or Attack1Anim then return end
- Charge1Anim = true
- for i = 0, 70 do
- local FireColors = {'Really black', 'Institutional white'}
- local p = Instance.new('Part', char)
- p.BrickColor = BrickColor.new(FireColors[math.random(1,#FireColors)])
- p.FormFactor = 'Custom'
- p.Size = Vector3.new(.8, .8, .8)
- p.CanCollide = false
- p.Anchored = true
- p.Locked = true
- p.CFrame = ra.CFrame * CFrame.new(0, -1, 0) * CFrame.Angles(math.random(0,3),math.random(0,3),math.random(0,3))
- Instance.new('BlockMesh', p)
- coroutine.wrap(function()
- for i = 1, 10 do
- p.Mesh.Scale = p.Mesh.Scale - Vector3.new(.1, .1, .1)
- p.CFrame = p.CFrame * CFrame.new(0, .15, 0)
- wait()
- end
- end)()
- game:service'Debris':AddItem(p, 2)
- wait()
- end
- Charge1Anim = false
- Attack1Anim = true
- wait(.35)
- local ray = Ray.new(ra.CFrame*CFrame.new(0,-1,0).p, ra.CFrame*CFrame.new(0, -150, 0).p)
- local hitz, enz = workspace:FindPartOnRay(ray, char)
- local humanoid = hitz and hitz.Parent and hitz.Parent:findFirstChild("Humanoid")
- if humanoid then
- humanoid:TakeDamage(80)
- end
- local humanoid = hitz and hitz.Parent and hitz.Parent.Parent and hitz.Parent.Parent:findFirstChild("Humanoid")
- if humanoid then
- humanoid:TakeDamage(80)
- end
- --draw the ray
- local distance = (enz - ra.CFrame*CFrame.new(0,-1,0).p).magnitude
- local rayPart = Instance.new("Part", char)
- rayPart.BrickColor = BrickColor.new("Bright red")
- rayPart.Anchored = true
- rayPart.CanCollide = false
- rayPart.Locked = true
- rayPart.TopSurface = 0
- rayPart.BottomSurface = 0
- rayPart.formFactor = 'Custom'
- Instance.new('CylinderMesh', rayPart)
- rayPart.Size = Vector3.new(1, distance, 1)
- rayPart.CFrame = CFrame.new((enz + ra.CFrame*CFrame.new(0,-1,0).p)/2,enz) * CFrame.Angles(math.pi/2, 0, 0)
- for i = 0, 1, .1 do
- rayPart.Transparency = i
- wait()
- end
- rayPart:remove()
- Attack1Anim = false
- end
- if string.byte(k) == 48 then
- humanoid.WalkSpeed = 70
- end
- end)
- mouse.KeyUp:connect(function(k)
- if string.byte(k) == 48 then
- humanoid.WalkSpeed = 24
- end
- end)
- local action = 'None'
- plr.Chatted:connect(function(msg)
- if msg == '/e dance' or msg == '/emote dance' then
- action = 'Dance'
- end
- if msg == '/e bernie' or msg == '/emote bernie' then
- action = 'MovingLikeBernie'
- end
- end)
- local dance_move_wait = 0
- print'madiik cannot be resisted kthx'
- game:service'RunService'.RenderStepped:connect(function()
- rm.MaxVelocity = 0
- lm.MaxVelocity = 0
- rm.DesiredAngle = 0
- rm.CurrentAngle = 0
- lm.DesiredAngle = 0
- lm.CurrentAngle = 0
- angle = (angle % 100) + anglespeed/10
- mvmnt = math.pi * math.sin(math.pi*2/100*(angle*10))
- local rscf = rsc0
- local lscf = lsc0
- local rlcf = rlc0
- local llcf = llc0
- local rjcf = rootc0
- local ray = Ray.new(rootpart.Position, Vector3.new(0, -4.1, 0))
- local hitz, enz = workspace:FindPartOnRay(ray, char)
- for i,object in pairs(char:children()) do
- if object:IsA("Tool") then
- tool = true
- if not debounce then
- for x,value in pairs(object:children()) do
- if value:IsA("StringValue") and value.Name == "toolanim" and value.Value == "Slash" then
- debounce = true
- coroutine.wrap(function()
- slashing = true
- wait(.15)
- slashing = false
- debounce = false
- end)()
- value:Destroy()
- end
- end
- end
- elseif not object:IsA'Tool' then
- tool = false
- end
- end
- if action == 'Dance' then
- anglespeed = 2
- if Vector3.new(torso.Velocity.x, 0, torso.Velocity.z).magnitude < 2 then
- rjcf = rootc0 * CFrame.Angles(math.rad(2), math.sin(angle)*.15, 0)
- lscf = lsc0 * CFrame.new(0, .5 + math.sin(angle)*0.025, 0) * CFrame.Angles(math.pi/1.2-math.cos(angle)*0.4, math.sin(angle)*0.1, -.15 - -math.sin(angle)*0.4)
- rscf = rsc0 * CFrame.new(0, .5 + math.sin(angle)*0.025, 0) * CFrame.Angles(math.pi/1.2+math.cos(angle)*0.4, math.sin(-angle)*0.1, .15 + -math.sin(angle)*0.4)
- rlcf = rlc0 * CFrame.new(0, .3 + math.cos(angle)*.3, -.1) * CFrame.Angles(-math.rad(2), 0, 0)
- llcf = llc0 * CFrame.new(0, .3 - math.cos(angle)*.3, -.1) * CFrame.Angles(-math.rad(2), 0, 0)
- else
- action = 'None'
- end
- elseif action == 'MovingLikeBernie' then
- anglespeed = 1+math.random()
- dance_move_wait = (dance_move_wait%40) + 1/60
- if Vector3.new(torso.Velocity.x, 0, torso.Velocity.z).magnitude < 2 then
- if dance_move_wait <= 20 then
- rjcf = rootc0 * CFrame.new(0, -.2, .6) * CFrame.Angles(math.rad(25)-math.sin(angle)*0.025, math.cos(angle)*.15, 0)
- lscf = lsc0 * CFrame.new(0, math.sin(angle)*0.025, 0) * CFrame.Angles(-math.pi/6 + -math.cos(angle)*0.4, math.sin(angle)*0.1, -.15 - -math.sin(angle)*0.4)
- rscf = rsc0 * CFrame.new(0, math.sin(angle)*0.025, 0) * CFrame.Angles(-math.pi/6 + math.cos(angle)*0.4, math.sin(-angle)*0.1, .15 + -math.sin(angle)*0.4)
- rlcf = rlc0 * CFrame.new(0, 0, -.1) * CFrame.Angles(-math.rad(25)+math.sin(angle)*0.025, -math.cos(angle)*.15, .1)
- llcf = llc0 * CFrame.new(0, 0, -.1) * CFrame.Angles(-math.rad(25)+math.sin(angle)*0.025, -math.cos(angle)*.15, -.1)
- elseif dance_move_wait > 20 then
- rjcf = rootc0 * CFrame.new(0, -.2, -.6) * CFrame.Angles(-math.rad(25)-math.sin(angle)*0.025, math.cos(angle)*.15, 0)
- lscf = lsc0 * CFrame.new(0, math.sin(angle)*0.025, 0) * CFrame.Angles(math.pi/6 + math.cos(angle)*0.4, math.sin(angle)*0.1, -.15 - -math.sin(angle)*0.4)
- rscf = rsc0 * CFrame.new(0, math.sin(angle)*0.025, 0) * CFrame.Angles(math.pi/6 + -math.cos(angle)*0.4, math.sin(-angle)*0.1, .15 + -math.sin(angle)*0.4)
- rlcf = rlc0 * CFrame.new(0, 0, -.1) * CFrame.Angles(math.rad(25)-math.sin(angle)*0.025, -math.cos(angle)*.15, .1)
- llcf = llc0 * CFrame.new(0, 0, -.1) * CFrame.Angles(math.rad(25)-math.sin(angle)*0.025, -math.cos(angle)*.15, -.1)
- end
- else
- action = 'None'
- end
- elseif not hitz and (torso.Velocity.y > 1 or torso.Velocity.y < -1) then
- anglespeed = 3
- rjcf = rootc0 * CFrame.Angles(math.rad(5), 0, 0)
- rscf = rsc0 * CFrame.Angles(math.rad(130) + math.sin(angle)*.8, 0, .15)
- lscf = lsc0 * CFrame.Angles(math.rad(130) + -math.sin(angle)*.8, 0, -.15)
- rlcf = rlc0 * CFrame.new(0, .3 + -math.cos(angle)*.3, -.3 + -math.cos(angle)*.3) * CFrame.Angles(math.pi/14 + -math.sin(angle)*1, 0, 0)
- llcf = llc0 * CFrame.new(0, .3 - -math.cos(angle)*.3, -.3 - -math.cos(angle)*.3) * CFrame.Angles(math.pi/14 + math.sin(angle)*1, 0, 0)
- elseif Vector3.new(torso.Velocity.x, 0, torso.Velocity.z).magnitude < 2 then
- elseif Vector3.new(torso.Velocity.x, 0, torso.Velocity.z).magnitude <= 20 then
- anglespeed = 2
- rjcf = rootc0 * CFrame.new(0, math.abs(math.sin(angle))*.65, 0) * CFrame.Angles(math.rad(10)+math.rad(torso.Velocity.y)*2, 0, 0)
- rscf = rsc0 * CFrame.Angles(math.sin(angle)*1.7, 0, .05)
- lscf = lsc0 * CFrame.Angles(-math.sin(angle)*1.7, 0, -.05)
- rlcf = rlc0 * CFrame.Angles(-math.sin(angle)*1.4, 0, 0)
- llcf = llc0 * CFrame.Angles(math.sin(angle)*1.4, 0, 0)
- elseif Vector3.new(torso.Velocity.x, 0, torso.Velocity.z).magnitude > 20 then
- anglespeed = 2.5
- rjcf = rootc0 * CFrame.new(0, -.3 + math.abs(math.sin(angle))*.65, 0) * CFrame.Angles(-math.rad(10)+math.rad(torso.Velocity.y)*2, 0, 0)
- rscf = rsc0 * CFrame.new(0, math.cos(angle)*.5, math.sin(angle)*.5) * CFrame.Angles(math.cos(angle)*2.8, 0, math.abs(math.sin(angle))*.5)
- lscf = lsc0 * CFrame.new(0, -math.cos(angle)*.5, -math.sin(angle)*.5) * CFrame.Angles(-math.cos(angle)*2.8, 0, -math.abs(math.sin(angle))*.5)
- rlcf = rlc0 * CFrame.new(0, .3 + -math.cos(-angle)*.3, -.2+math.sin(angle)*0.25) * CFrame.Angles(-math.pi/18+math.sin(-angle)*1.4, 0, math.rad(.5))
- llcf = llc0 * CFrame.new(0, .3 - -math.cos(angle)*.3, -.05-math.sin(angle)*0.25) * CFrame.Angles(-math.pi/18+math.sin(angle)*1.4, 0, -math.rad(.5))
- end
- if Charge1Anim then
- rscf = rsc0 * CFrame.new(-.75, 0, .75) * CFrame.Angles(math.pi/4, 0, math.pi/4)
- lscf = lsc0 * CFrame.new(.95, 0, -.45) * CFrame.Angles(math.pi/4, 0, math.pi/3)
- end
- if Attack1Anim then
- rscf = rsc0 * CFrame.Angles(math.pi/2, 0, 0)
- lscf = lsc0 * CFrame.Angles(-math.pi/8, 0, 0)
- end
- if tool then
- rscf = rsc0 * CFrame.Angles(math.pi/2, 0, 0)
- if slashing then
- rscf = rsc0 * CFrame.Angles(-math.pi/12, 0, -.1)
- end
- end
- rm.C0 = clerp(rm.C0,rscf,speed)
- lm.C0 = clerp(lm.C0,lscf,speed)
- rj.C0 = clerp(rj.C0,rjcf,speed)
- rlegm.C0 = clerp(rlegm.C0,rlcf,speed)
- llegm.C0 = clerp(llegm.C0,llcf,speed)
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement