Advertisement
Scriptboy

bernie sandoors

Apr 23rd, 2018
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 26.45 KB | None | 0 0
  1. --[[ World eater Script ]]--
  2. --[[ Declarations ]]--
  3. wait(.0000000000000000000001)
  4. local Player = game:GetService("Players").LocalPlayer
  5. local Character = Player.Character
  6. local Head = Character.Head
  7. local Torso = Character.Torso
  8. local Right_Arm = Character["Right Arm"]
  9. local Right_Leg = Character["Right Leg"]
  10. local Left_Arm = Character["Left Arm"]
  11. local Left_Leg = Character["Left Leg"]
  12. local Humanoid = Character.Humanoid
  13. local Animation = "Idle"
  14. local Mouse = Player:GetMouse()
  15. local LeftShoulder = Torso["Left Shoulder"]
  16. local Left_Hip = Torso["Left Hip"]
  17. local RightShoulder = Torso["Right Shoulder"]
  18. local Right_Hip = Torso["Right Hip"]
  19. local Root = Character.HumanoidRootPart
  20. local RootJoint = Root.RootJoint
  21. local Attacking = false
  22. local CanAttack = true
  23. local Anim = "Idle"
  24. local Combo = 1
  25. local Blocking = false
  26. local MaxDestruction = 1000
  27. local Destruction = 0
  28. local MaxBlock = 100
  29. local Effects = {}
  30. local Color = "Bright yellow"
  31. local Invert = false
  32. local Idle = 0
  33. local Equipped = false
  34. local Running = false
  35. local Unseathed = false
  36. local Shard = "None"
  37.  
  38. Humanoid.MaxHealth = 999999
  39. Humanoid.Health = 999999
  40.  
  41. local WorldEaterTheme = Instance.new("Sound",Character)
  42. WorldEaterTheme.Name = "WorldEaterTheme"
  43. WorldEaterTheme.Looped = true
  44. WorldEaterTheme.SoundId = "http://www.roblox.com/asset?id=400786493"
  45. WorldEaterTheme:Play()
  46.  
  47. Left_Shoulder = Instance.new("Weld", Torso)
  48. Left_Shoulder.Part0 = Torso
  49. Left_Shoulder.Part1 = Left_Arm
  50. Left_Shoulder.Name = "Left Shoulder"
  51. Left_Shoulder.C0 = CFrame.new(-1.5,0,0)
  52.  
  53. Right_Shoulder = Instance.new("Weld", Torso)
  54. Right_Shoulder.Part0 = Torso
  55. Right_Shoulder.Part1 = Right_Arm
  56. Right_Shoulder.Name = "Right Shoulder"
  57. Right_Shoulder.C0 = CFrame.new(1.5,0,0)
  58.  
  59. LeftShoulder.Parent = nil
  60. RightShoulder.Parent = nil
  61. Humanoid.WalkSpeed = 10
  62.  
  63. local RootCFrame = CFrame.fromEulerAnglesXYZ(-1.57,0,3.14)
  64. Necko = CFrame.new(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  65. Necko2 = CFrame.new(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  66. Right_Hip_C1 = CFrame.new(0.5, 1, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  67. Left_Hip_C1 = CFrame.new(-0.5, 1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  68.  
  69.  
  70. Movemment = 1
  71. Walk = 0
  72.  
  73. Animator = Humanoid.Animator
  74. --Animate = Character.Animate
  75.  
  76. Animator.Parent = nil
  77. --Animate.Parent = nil
  78.  
  79. local Services = {
  80.  
  81. SoundService = game:GetService("SoundService");
  82. Players = game:GetService("Players");
  83. Debris = game:GetService("Debris");
  84. Workspace = game:GetService("Workspace");
  85. Lighting = game:GetService("Lighting");
  86. HttpService = game:GetService("HttpService");
  87. InsertService = game:GetService("InsertService");
  88.  
  89. }
  90.  
  91. local ManaBarGUI = Instance.new("ScreenGui", Player.PlayerGui)
  92. ManaBarGUI.Name = "ManaBarGUI"
  93.  
  94. local ManaBarP1 = Instance.new("Frame", ManaBarGUI)
  95. ManaBarP1.Name = "ManaBarPart1"
  96. ManaBarP1.Size = UDim2.new(0,300,0,20)
  97. ManaBarP1.Position = UDim2.new(0,350,0.1,0)
  98. ManaBarP1.BackgroundColor3 = BrickColor.Black().Color
  99.  
  100. local ManaBarP2 = Instance.new("Frame", ManaBarP1)
  101. ManaBarP2.Name = "ManaBarPart2"
  102. ManaBarP2.Size = UDim2.new(0,300,0,20)
  103. ManaBarP2.Position = UDim2.new(0,0,0,0)
  104. ManaBarP2.BackgroundColor3 = BrickColor.new("Black").Color
  105.  
  106. local ManaBarText = Instance.new("TextLabel", ManaBarP1)
  107. ManaBarText.Name = "ManaBarText"
  108. ManaBarText.Size = UDim2.new(0,300,0,20)
  109. ManaBarText.Position = UDim2.new(0,0,-1.5,0)
  110. ManaBarText.TextScaled = true
  111. ManaBarText.Text = "<{[ Destruction ]}> 0 <{[ Destruction ]}>"
  112. ManaBarText.BackgroundTransparency = 1
  113. ManaBarText.TextStrokeTransparency = 0
  114. ManaBarText.TextStrokeColor3 = Color3.new(1,1,1)
  115. ManaBarText.TextColor3 = Color3.new(0,0,0)
  116. ManaBarText.Font = "Garamond"
  117.  
  118. local WorldEaterGui = Instance.new("BillboardGui", Head)
  119. WorldEaterGui.ExtentsOffset = Vector3.new(0,5,0)
  120. WorldEaterGui.Adornee = Head
  121. WorldEaterGui.AlwaysOnTop = true
  122. WorldEaterGui.Enabled = true
  123. WorldEaterGui.Size = UDim2.new(0, 200,0, 50)
  124.  
  125. local WorldEaterText = Instance.new("TextLabel", WorldEaterGui)
  126. WorldEaterText.BackgroundTransparency = 1
  127. WorldEaterText.Font = "Garamond"
  128. WorldEaterText.Size = UDim2.new(0, 200,0, 50)
  129. WorldEaterText.TextStrokeColor3 = BrickColor.Red().Color
  130. WorldEaterText.TextStrokeTransparency = 0
  131. WorldEaterText.TextColor3 = BrickColor.Black().Color
  132. WorldEaterText.TextScaled = true
  133. WorldEaterText.Text = "a wild screamer on aids"
  134.  
  135. --------[[ Mesh Ids ]]--------
  136.  
  137. SpikeMeshId = 1033714
  138. SpikeBallId = 9982590
  139. StarMeshId = 45428961
  140. CrystalMeshId = 9756362
  141.  
  142. --[[ Essential Functions ]]--
  143. function NoOutlines(Part)
  144. Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10
  145. end
  146.  
  147.  
  148. local CreatePart = function(Parent, Name, Color, Size, Material, Transparency, Shape)
  149.  
  150. local Part = Instance.new("Part", Parent)
  151. Part.Name = Name
  152. Part.BrickColor = BrickColor.new(Color)
  153. Part.Size = Size
  154. Part.Material = Material
  155. Part.Transparency = Transparency
  156. Part.Shape = Shape
  157. Part.CanCollide = false
  158. NoOutlines(Part)
  159.  
  160. return Part
  161.  
  162. end
  163.  
  164. local CreateMesh = function(Parent, Scale, Shape)
  165.  
  166.  
  167. local Mesh = Instance.new("BlockMesh", Parent)
  168. Mesh.Scale = Scale
  169.  
  170. return Mesh
  171.  
  172. end
  173.  
  174. local CreateWedge = function(Parent, Name, Color, Size, Material, Transparency)
  175.  
  176. local WedgePart = Instance.new("WedgePart", Parent)
  177. WedgePart.Name = Name
  178. WedgePart.BrickColor = BrickColor.new(Color)
  179. WedgePart.Size = Size
  180. WedgePart.Material = Material
  181. WedgePart.Transparency = Transparency
  182. WedgePart.CanCollide = false
  183. NoOutlines(WedgePart)
  184.  
  185. return WedgePart
  186.  
  187. end
  188.  
  189. local CreateWeld = function(Parent, Cframe, P1 , P0)
  190.  
  191. local Weld = Instance.new("Weld", Parent)
  192. Weld.Part0 = P0
  193. Weld.Part1 = P1
  194. Weld.Name = P0.Name .. "To" .. P1.Name
  195. Weld.C0 = Cframe
  196.  
  197. return Weld
  198.  
  199. end
  200.  
  201. local CreateVelocity = function(Parent,Velocity,Force)
  202.  
  203. local BodyVelocity = Instance.new("BodyVelocity", Parent)
  204. BodyVelocity.Velocity = Velocity
  205. BodyVelocity.MaxForce = Force
  206.  
  207.  
  208.  
  209. return BodyVelocity
  210.  
  211. end
  212.  
  213.  
  214. local CreateCrystal = function(Parent, Name, Color, Size, Material, Transparency, Scale)
  215.  
  216.  
  217. local Part = Instance.new("Part", Parent)
  218. Part.Name = Name
  219. Part.BrickColor = BrickColor.new(Color)
  220. Part.Size = Size
  221. Part.Material = Material
  222. Part.Transparency = Transparency
  223. Part.CanCollide = false
  224. NoOutlines(Part)
  225.  
  226. local Mesh = Instance.new("SpecialMesh", Part)
  227. Mesh.MeshId = "http://www.roblox.com/asset?id=" .. CrystalMeshId
  228. Mesh.Scale = Scale
  229.  
  230. return Mesh and Part
  231.  
  232. end
  233.  
  234. local MakeSFX = function(Parent, Id, Volume, Pitch, Type)
  235.  
  236. local SFX = Instance.new("Sound", Parent)
  237. SFX.SoundId = "http://www.roblox.com/asset?id=" .. Id
  238. SFX.Name = "SFX"
  239. SFX:Play()
  240. SFX.Volume = Volume
  241. SFX.Pitch = Pitch
  242. SFX.PlayOnRemove = true
  243. SFX:Remove()
  244.  
  245. if Type == "Echo" then
  246.  
  247. Instance.new("EchoSoundEffect", SFX)
  248.  
  249. end
  250.  
  251. end
  252.  
  253. local CreateSpike = function(Parent, Name, Color, Size, Material, Transparency, Scale)
  254.  
  255.  
  256. local Part = Instance.new("Part", Parent)
  257. Part.Name = Name
  258. Part.BrickColor = BrickColor.new(Color)
  259. Part.Size = Size
  260. Part.Material = Material
  261. Part.Transparency = Transparency
  262. Part.CanCollide = false
  263. NoOutlines(Part)
  264.  
  265. local Mesh = Instance.new("SpecialMesh", Part)
  266. Mesh.MeshId = "http://www.roblox.com/asset?id=" .. SpikeMeshId
  267. Mesh.Scale = Scale
  268.  
  269. return Mesh and Part
  270.  
  271. end
  272.  
  273. CircleEffect = function(Position, Parent, DSX, DSY, DSZ, SX, SY, SZ, Time, Brickcolor, Material, Transparency)
  274.  
  275. local Part = Instance.new("Part", Parent)
  276. Part.Transparency = Transparency
  277. Part.Name = "CircleEffect"
  278. Part.Size = Vector3.new()
  279. Part.Anchored = true
  280. Part.CanCollide = false
  281. Part.Position = Position
  282. Part.BrickColor = BrickColor.new(Brickcolor)
  283. Part.Material = Material
  284. NoOutlines(Part)
  285.  
  286. local Mesh = Instance.new("SpecialMesh", Part)
  287. Mesh.MeshType = "Sphere"
  288. Mesh.Scale = Vector3.new(DSX, DSY, DSZ)
  289.  
  290. Services.Debris:AddItem(Part, Time)
  291.  
  292.  
  293. table.insert(Effects, {Part, "Circle", Time, SX, SY, SZ})
  294.  
  295.  
  296. end
  297.  
  298. BlockEffect = function(Position, Parent, DSX, DSY, DSZ, SX, SY, SZ, Time, Brickcolor, Material, Transparency)
  299.  
  300. local Part = Instance.new("Part", Parent)
  301. Part.Transparency = Transparency
  302. Part.Name = "BlockEffect"
  303. Part.Size = Vector3.new()
  304. Part.Anchored = true
  305. Part.Position = Position
  306. Part.CanCollide = false
  307. Part.BrickColor = BrickColor.new(Brickcolor)
  308. Part.Material = Material
  309. NoOutlines(Part)
  310.  
  311. local Mesh = Instance.new("BlockMesh", Part)
  312. Mesh.Scale = Vector3.new(DSX, DSY, DSZ)
  313.  
  314. Services.Debris:AddItem(Part, Time)
  315.  
  316. table.insert(Effects, {Part, "Block", Time, SX, SY, SZ})
  317.  
  318.  
  319. end
  320.  
  321. --[[ Damage function ]]--
  322.  
  323.  
  324. function DamageFunction(Hit, Part, Type, HitSFX, Knockback, Min, Max)
  325.  
  326. local HitHumanoid = Hit.Parent.Humanoid
  327.  
  328.  
  329. local Damage = math.random(Min, Max)
  330.  
  331.  
  332. coroutine.resume(coroutine.create(function()
  333. HitHumanoid:TakeDamage(Damage)
  334. end))
  335.  
  336. if Type == "Shrink" then
  337. MakeSFX(Hit.Parent.Torso, 209527235, 1, 1)
  338. for i,v in pairs(Hit.Parent:children()) do
  339. if v:IsA("Part") then
  340. coroutine.resume(coroutine.create(function()
  341. for i = 1,100 do
  342. wait()
  343. v.Size = v.Size - Vector3.new(0.05,0.05,0.05)
  344. v.Transparency = v.Transparency + 0.05
  345.  
  346. end
  347. end))
  348. end
  349. end
  350.  
  351. end
  352.  
  353.  
  354.  
  355. if Type == "Normal" then
  356.  
  357. local Push = CreateVelocity(Hit.Parent.Torso, Torso.CFrame.lookVector * Knockback, Vector3.new(math.huge,math.huge,math.huge))
  358. Services.Debris:AddItem(Push, 0)
  359. DamageLabel(Hit.Parent, Damage, Hit)
  360.  
  361. elseif Type == "Ranged" then
  362. local Push = CreateVelocity(Hit.Parent.Torso, Part.CFrame.lookVector * Knockback, Vector3.new(math.huge,math.huge,math.huge))
  363. Services.Debris:AddItem(Push, 0)
  364. DamageLabel(Hit.Parent, Damage, Hit)
  365.  
  366. elseif Type == "Impale" then
  367.  
  368. local Spike = CreateSpike(Services.Workspace, "D e a t h", "Black", Vector3.new(), "SmoothPlastic", 0, Vector3.new(1,20,1))
  369. Spike.Anchored = true
  370. Spike.Rotation = Vector3.new(math.random(-50,50), 0 , math.random(-50,50))
  371. Spike.Position = Hit.Parent.Torso.Position
  372.  
  373.  
  374. Services.Debris:AddItem(Spike, 30)
  375.  
  376. Hit.Parent:BreakJoints()
  377. Hit.Parent.Torso.Position = Spike.Position + Vector3.new(0,5,0)
  378. Hit.Parent.Torso.Anchored = true
  379.  
  380. MakeSFX(Spike, 306247724, 1,1)
  381. MakeSFX(Hit.Parent.Torso, 209527175, 10,1)
  382. elseif Type == "Knockdown" then
  383.  
  384.  
  385. local Push = CreateVelocity(Hit.Parent.Torso, Part.CFrame.lookVector * Knockback, Vector3.new(math.huge,math.huge,math.huge))
  386. DamageLabel(Hit.Parent, Damage, Hit)
  387. Services.Debris:AddItem(Push, 0.3)
  388.  
  389. coroutine.resume(coroutine.create(function()
  390.  
  391. HitHumanoid.PlatformStand = true
  392. wait(1)
  393. HitHumanoid.PlatformStand = false
  394.  
  395.  
  396. end))
  397. end
  398.  
  399. if HitSFX == "Penetration" then
  400.  
  401. MakeSFX(Hit, 199149269, 1 , 1)
  402.  
  403. elseif HitSFX == "Punch" then
  404.  
  405. MakeSFX(Hit, 278062209, 1 , 1)
  406.  
  407.  
  408.  
  409.  
  410. end
  411. end
  412.  
  413. function DamageLabel(HitCharacter, DamageDealt, Hit)
  414.  
  415. local DamageShowingPart = CreatePart(Services.Workspace, "ShowDamage", "Bright yellow", Vector3.new(0.8,0.8,0.8), "Neon", 1, "Block")
  416. DamageShowingPart.Position = HitCharacter.Head.Position
  417.  
  418. local DamageGui = Instance.new("BillboardGui", DamageShowingPart)
  419. DamageGui.Name = "Damage"
  420. DamageGui.AlwaysOnTop = true
  421. DamageGui.Size = UDim2.new(5, 0, 5, 0)
  422.  
  423. local DamageNumber = Instance.new("TextLabel", DamageGui)
  424. DamageNumber.Size = UDim2.new(1,0,1,0)
  425. if Hit.Parent:FindFirstChild("Head") then
  426. DamageNumber.TextStrokeColor3 = Hit.Parent.Head.BrickColor.Color
  427. DamageNumber.TextColor3 = Hit.BrickColor.Color
  428. end
  429. DamageNumber.TextStrokeTransparency = 0
  430. DamageNumber.BackgroundTransparency = 1
  431. DamageNumber.Font = "SourceSansBold"
  432. DamageNumber.TextScaled = true
  433. DamageNumber.Text = DamageDealt
  434.  
  435. local BodyVelocity = Instance.new("BodyVelocity", DamageShowingPart)
  436. BodyVelocity.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  437. BodyVelocity.Velocity = Vector3.new(0,2,0)
  438.  
  439. Services.Debris:AddItem(DamageShowingPart, 3)
  440.  
  441.  
  442. end
  443.  
  444. function ValidateDamage(Part, Distance ,Min , Max, Type, HitSFX, Knockback)
  445. for _,WorkspaceChildren in pairs(workspace:children()) do
  446.  
  447. local HitHumanoid = WorkspaceChildren:findFirstChild("Humanoid")
  448.  
  449. if HitHumanoid ~= nil then
  450. local Hit = WorkspaceChildren:findFirstChild("Torso")
  451.  
  452. if Hit ~= nil then
  453.  
  454. local Target = Hit.Position - Part.Position
  455.  
  456. local Magnitude = Target.magnitude
  457.  
  458. if Magnitude <= Distance and WorkspaceChildren.Name ~= Player.Name then
  459.  
  460. local HitBlock = Hit.Parent:FindFirstChild("Block")
  461.  
  462. if HitBlock ~= nil and HitBlock:FindFirstChild("BlockDurability") and HitBlock.Value == true then
  463.  
  464. local HitBlock2 = Hit.Parent.Block.BlockDurability
  465.  
  466. if HitBlock2.Value > 15 then
  467.  
  468. local HitN = math.random(1,5)
  469.  
  470. HitBlock2.Value = HitBlock2.Value - 15
  471.  
  472.  
  473. if HitN == 1 then
  474. MakeSFX(Hit ,199148971, 0.5, 1)
  475. end
  476.  
  477. if HitN == 2 then
  478. MakeSFX(Hit ,199149025, 0.5, 1)
  479. end
  480.  
  481. if HitN == 3 then
  482. MakeSFX(Hit ,199149072, 0.5, 1)
  483. end
  484.  
  485. if HitN == 4 then
  486. MakeSFX(Hit ,199149109, 0.5, 1)
  487. end
  488.  
  489. if HitN == 5 then
  490. MakeSFX(Hit ,199149119, 0.5, 1)
  491. end
  492. return
  493. end
  494. end
  495.  
  496. DamageFunction(Hit, Part, Type, HitSFX, Knockback, Min, Max)
  497.  
  498.  
  499.  
  500. end
  501. end
  502. end
  503. end
  504. end
  505.  
  506.  
  507.  
  508. local Cloak = Instance.new("Part", Character)
  509. Cloak.Name = "Cloak"
  510. Cloak.CanCollide = false
  511. Cloak.BrickColor = BrickColor.new("Institutional white")
  512.  
  513. local CloakMesh = Instance.new("SpecialMesh", Cloak)
  514. CloakMesh.MeshId = "http://www.roblox.com/asset?id=431030647"
  515.  
  516. local CloakWeld = CreateWeld(Cloak, CFrame.new(0,0,0) * CFrame.Angles(0,0,0), Head , Cloak, "ArkusToCharacter")
  517.  
  518. for i,v in pairs(Character:children()) do
  519. if v:IsA("Accessory") then
  520. v:Remove()
  521. elseif v:IsA("Shirt") then
  522. v:Remove()
  523. elseif v:IsA("Pants") then
  524. v:Remove()
  525. elseif v:IsA("BodyColors") then
  526.  
  527. Head.BrickColor =BrickColor.new("Really black")
  528. Torso.BrickColor = BrickColor.new("Really black")
  529. Right_Arm.BrickColor = BrickColor.new("Really black")
  530. Right_Leg.BrickColor = BrickColor.new("Really black")
  531. Left_Arm.BrickColor = BrickColor.new("Really black")
  532. Left_Leg.BrickColor = BrickColor.new("Really black")
  533.  
  534. v.HeadColor = BrickColor.new("Really black")
  535. v.TorsoColor = BrickColor.new("Really black")
  536. v.RightArmColor = BrickColor.new("Really black")
  537. v.LeftArmColor = BrickColor.new("Really black")
  538. v.RightLegColor = BrickColor.new("Really black")
  539. v.LeftLegColor = BrickColor.new("Really black")
  540.  
  541. end
  542. end
  543.  
  544.  
  545.  
  546. --[[ CLerp Declarations ]]--
  547.  
  548. function clerp(a,b,t)
  549. local qa = {QuaternionFromCFrame(a)}
  550. local qb = {QuaternionFromCFrame(b)}
  551. local ax, ay, az = a.x, a.y, a.z
  552. local bx, by, bz = b.x, b.y, b.z
  553. local _t = 1-t
  554. return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
  555. end
  556.  
  557. function QuaternionFromCFrame(cf) -- dis one
  558. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  559. local trace = m00 + m11 + m22
  560. if trace > 0 then
  561. local s = math.sqrt(1 + trace)
  562. local recip = 0.5/s
  563. return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
  564. else
  565. local i = 0
  566. if m11 > m00 then
  567. i = 1
  568. end
  569. if m22 > (i == 0 and m00 or m11) then
  570. i = 2
  571. end
  572. if i == 0 then
  573. local s = math.sqrt(m00-m11-m22+1)
  574. local recip = 0.5/s
  575. return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
  576. elseif i == 1 then
  577. local s = math.sqrt(m11-m22-m00+1)
  578. local recip = 0.5/s
  579. return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
  580. elseif i == 2 then
  581. local s = math.sqrt(m22-m00-m11+1)
  582. local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
  583. end
  584. end
  585. end
  586.  
  587. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  588. local xs, ys, zs = x + x, y + y, z + z
  589. local wx, wy, wz = w*xs, w*ys, w*zs
  590. local xx = x*xs
  591. local xy = x*ys
  592. local xz = x*zs
  593. local yy = y*ys
  594. local yz = y*zs
  595. local zz = z*zs
  596. 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))
  597. end
  598.  
  599. function QuaternionSlerp(a, b, t)
  600. local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
  601. local startInterp, finishInterp;
  602. if cosTheta >= 0.0001 then
  603. if (1 - cosTheta) > 0.0001 then
  604. local theta = math.acos(cosTheta)
  605. local invSinTheta = 1/math.sin(theta)
  606. startInterp = math.sin((1-t)*theta)*invSinTheta
  607. finishInterp = math.sin(t*theta)*invSinTheta
  608. else
  609. startInterp = 1-t
  610. finishInterp = t
  611. end
  612. else
  613. if (1+cosTheta) > 0.0001 then
  614. local theta = math.acos(-cosTheta)
  615. local invSinTheta = 1/math.sin(theta)
  616. startInterp = math.sin((t-1)*theta)*invSinTheta
  617. finishInterp = math.sin(t*theta)*invSinTheta
  618. else
  619. startInterp = t-1
  620. finishInterp = t
  621. end
  622. end
  623. 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
  624. end
  625.  
  626. function RayCast(Pos, Dir, Max, Ignore)
  627. return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
  628. end
  629.  
  630.  
  631. function Bars()
  632.  
  633. --[[ Mana Bar ]]--
  634. if Destruction ~= MaxDestruction then
  635.  
  636. Destruction = Destruction + 1
  637.  
  638. end
  639.  
  640. if Destruction >= MaxDestruction then
  641.  
  642. Destruction = Destruction
  643.  
  644. end
  645.  
  646.  
  647. ManaBarText.Text = "<{[ Destruction ]}> <|"..Destruction.."|> <{[ Destruction ]}>"
  648.  
  649. ManaBarP2.Size = UDim2.new(Destruction / Destruction,0,0,20)
  650.  
  651. end
  652. local EyeReference = CreatePart(Character, "Reference", "Dark stone grey", Vector3.new(), "SmoothPlastic", 1, "Block")
  653. local EyeReferenceWeld = CreateWeld(EyeReference, CFrame.new(0.15,-0.1,-0.7), EyeReference, Head)
  654.  
  655. coroutine.resume(coroutine.create(function()
  656.  
  657. while wait(3) do
  658.  
  659.  
  660. CircleEffect(EyeReference.Position, Services.Workspace, 1, 1, 1, 1, 1, 1, 0.5, "Bright red", "Neon", 0.5)
  661.  
  662.  
  663. end
  664.  
  665. end))
  666. --[[ Attacks ]]--
  667.  
  668. function Attack1()
  669. Attacking = true
  670. MakeSFX(EyeReference, 341336274, 1,1)
  671. wait(0.3)
  672. local Reference = CreatePart(Services.Workspace, "Reference", "Dark stone grey", Vector3.new(), "SmoothPlastic", 1, "Block")
  673. local ReferenceWeld = CreateWeld(Reference, CFrame.new(0,0.5,-5), Reference, Root)
  674.  
  675. local Reference2 = CreatePart(Services.Workspace, "Reference", "Dark stone grey", Vector3.new(), "SmoothPlastic", 1, "Block")
  676. local Reference2Weld = CreateWeld(Reference2, CFrame.new(0,0.5,-2), Reference2, Root)
  677.  
  678.  
  679. for i = 1,10 do
  680.  
  681. wait()
  682. RootJoint.C0 = clerp(RootJoint.C0,RootCFrame*CFrame.new(0,0,0)* CFrame.Angles(0,0,-1.6),0.5)
  683. Torso.Neck.C0 = clerp(Torso.Neck.C0,Necko * CFrame.Angles(0,0,1.3),0.2)
  684. Right_Shoulder.C0 = clerp(Right_Shoulder.C0, CFrame.new(1.5, 0.1, 0) * CFrame.Angles(0,0,0.2), 0.3)
  685. Left_Shoulder.C0 = clerp(Left_Shoulder.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(0,0,-1.6), 0.4)
  686. Right_Hip.C0=clerp(Right_Hip.C0,CFrame.new(1,-1,0) * CFrame.Angles(0,1.6,0),0.3)
  687. Left_Hip.C0=clerp(Left_Hip.C0,CFrame.new(-1,-1,0) * CFrame.Angles(0,-1.6,0),0.3)
  688.  
  689. end
  690.  
  691. CircleEffect(Reference2.Position, Services.Workspace, 50, 50, 50, -5, -5, -5, 5, "Bright red", "Neon", 0.5)
  692. wait(0.5)
  693. CircleEffect(Reference2.Position, Services.Workspace, 50, 50, 50, -5, -5, -5, 5, "Bright red", "Neon", 0.5)
  694. wait(0.5)
  695. CircleEffect(Reference2.Position, Services.Workspace, 50, 50, 50, -5, -5, -5, 5, "Bright red", "Neon", 0.5)
  696. wait(0.5)
  697. CircleEffect(Reference2.Position, Services.Workspace, 50, 50, 50, -5, -5, -5, 5, "Bright red", "Neon", 0.5)
  698. wait(0.5)
  699. MakeSFX(Reference, 306247724, 1,1)
  700. CircleEffect(Reference.Position, Services.Workspace, 1, 1, 1, 5, 5, 5, 5, "Bright red", "Neon", 0.5)
  701. ValidateDamage(Reference, 10 ,10 , 14, "Shrink", "Penetration", 5)
  702. Attacking = false
  703. end
  704.  
  705. function Attack2()
  706.  
  707. Attacking = true
  708. Humanoid.WalkSpeed = 0
  709. Humanoid.JumpPower = 0
  710.  
  711.  
  712. for i = 1,25 do
  713. wait()
  714.  
  715. RootJoint.C0 = clerp(RootJoint.C0,RootCFrame*CFrame.new(0,0,0)* CFrame.Angles(-0.5,0,0),0.2)
  716. Torso.Neck.C0 = clerp(Torso.Neck.C0,Necko * CFrame.Angles(-0.5,0,0),0.3)
  717. Right_Shoulder.C0 = clerp(Right_Shoulder.C0, CFrame.new(1, 1, 0) * CFrame.Angles(3.2,0,-0.6), 0.3)
  718. Left_Shoulder.C0 = clerp(Left_Shoulder.C0, CFrame.new(-1, 1, 0) * CFrame.Angles(3.2,0,0.6), 0.3)
  719. Right_Hip.C0=clerp(Right_Hip.C0,CFrame.new(1,-1,0)*CFrame.Angles(0,1.6,-0.3),0.2)
  720. Left_Hip.C0=clerp(Left_Hip.C0,CFrame.new(-1,-1,-0.5)*CFrame.Angles(0,-1.6,0),0.2)
  721.  
  722. end
  723.  
  724. MakeSFX(Torso, 142070127, 1, 1)
  725. ValidateDamage(Torso, 60 ,23, 26, "Knockdown", "Penetration", 15)
  726. local Hit, Position = RayCast(Torso.Position,(CFrame.new(Root.Position,Root.Position - Vector3.new(0,1,0))).lookVector,100,Character)
  727. if Hit ~= nil then
  728. local Reference = CreatePart(Services.Workspace, "Reference", "Dark stone grey", Vector3.new(), "SmoothPlastic", 1, "Block")
  729. Reference.Anchored = true
  730. Reference.CFrame = CFrame.new(Position)
  731.  
  732. CircleEffect(Reference.Position, Services.Workspace, 1, 1, 1, 5, 5, 5, 5, "Bright red", "Neon", 0.5)
  733.  
  734. game:GetService("Debris"):AddItem(Reference,0.1)
  735. for i=1,50 do
  736.  
  737. local Ground = CreatePart(Services.Workspace, "Ground", Hit.BrickColor.Color, Vector3.new(math.random(1,3), math.random(1,3), math.random(1,3)), Hit.Material, 0, "Block")
  738. Ground.Anchored = true
  739. Ground.CanCollide = true
  740. Ground.CFrame = CFrame.new(Position) * CFrame.new(math.random(-30,30), 0, math.random(-30,30)) * CFrame.Angles(math.random(-50,50),math.random(-50,50), math.random(-50,50))
  741.  
  742. game:GetService("Debris"):AddItem(Ground,10)
  743.  
  744. end
  745. end
  746.  
  747. for i = 1,25 do
  748. wait()
  749.  
  750. RootJoint.C0 = clerp(RootJoint.C0,RootCFrame*CFrame.new(0,0,0)* CFrame.Angles(0,0,0),0.5)
  751. Torso.Neck.C0 = clerp(Torso.Neck.C0,Necko * CFrame.Angles(0.5,0,0),0.3)
  752. Right_Shoulder.C0 = clerp(Right_Shoulder.C0, CFrame.new(1.5, 0, 0.1) * CFrame.Angles(-0.2,0,0), 0.3)
  753. Left_Shoulder.C0 = clerp(Left_Shoulder.C0, CFrame.new(-1.5, 0, 0.1) * CFrame.Angles(-0.2,0,0), 0.3)
  754. Right_Hip.C0=clerp(Right_Hip.C0,CFrame.new(1,-1,0)*CFrame.Angles(0,1.6,-0.3),0.2)
  755. Left_Hip.C0=clerp(Left_Hip.C0,CFrame.new(-1,-1,-0.5)*CFrame.Angles(0,-1.6,0),0.2)
  756.  
  757. end
  758.  
  759. Attacking = false
  760. Humanoid.WalkSpeed = 16
  761. Humanoid.JumpPower = 50
  762.  
  763.  
  764.  
  765. end
  766.  
  767.  
  768. function Attack3()
  769. Humanoid.WalkSpeed = 0
  770. Humanoid.JumpPower = 0
  771. Attacking = true
  772. wait(1)
  773. MakeSFX(Torso, 341336274, 1, 1.2)
  774. CircleEffect(Torso.Position, Services.Workspace, 1, 1, 1, 20, 20, 20, 5, "Black", "Neon", 0.5)
  775. wait(1)
  776. MakeSFX(Torso, 341336274, 1, 1.2)
  777. CircleEffect(Torso.Position, Services.Workspace, 1, 1, 1, 20, 20, 20, 5, "Black", "Neon", 0.5)
  778. wait(1)
  779. MakeSFX(Torso, 341336274, 1, 1.2)
  780. CircleEffect(Torso.Position, Services.Workspace, 1, 1, 1, 20, 20, 20, 5, "Black", "Neon", 0.5)
  781. ValidateDamage(Torso, 60 ,0, 0, "Impale", "Penetration", 15)
  782. Humanoid.WalkSpeed = 16
  783. Humanoid.JumpPower = 50
  784. Attacking = false
  785. end
  786.  
  787. Mouse.Button1Down:connect(function()
  788. if not Attacking then
  789. if Combo == 1 then
  790.  
  791. Combo = 2
  792. Attack1()
  793.  
  794.  
  795. elseif Combo == 2 then
  796.  
  797. Attack2()
  798. Combo = 3
  799.  
  800. elseif Combo == 3 then
  801.  
  802. Attack3()
  803. Combo = 1
  804.  
  805. end
  806. end
  807. end)
  808.  
  809. --[[ CLerp Animations ]]--
  810. Change1 = 0
  811. Change2 = 0
  812. Change3 = 0
  813. Change4 = 0
  814.  
  815. while true do
  816. wait()
  817.  
  818. local Torvel = (Root.Velocity*Vector3.new(1,0,1)).magnitude
  819. local Velderp = Root.Velocity.y
  820. HitFloor,PosFloor = RayCast(Root.Position,(CFrame.new(Root.Position,Root.Position - Vector3.new(0,1,0))).lookVector,4,Character)
  821.  
  822. Bars()
  823.  
  824.  
  825. if Torvel < 1 and HitFloor ~= nil and Attacking == false then
  826. Anim = "Idle"
  827.  
  828. RootJoint.C0 = clerp(RootJoint.C0,RootCFrame*CFrame.new(0,0,0)* CFrame.Angles(0,0,0),0.2)
  829. Torso.Neck.C0 = clerp(Torso.Neck.C0,Necko * CFrame.Angles(0,-0.3,0),0.3)
  830. Right_Shoulder.C0 = clerp(Right_Shoulder.C0, CFrame.new(1.5, 0.1, 0) * CFrame.Angles(0,0,0.2), 0.3)
  831. Left_Shoulder.C0 = clerp(Left_Shoulder.C0, CFrame.new(-1.5, 0.1, 0) * CFrame.Angles(0,0,-0.2), 0.3)
  832. Right_Hip.C0=clerp(Right_Hip.C0,CFrame.new(1,-1,0)*CFrame.Angles(0,1.6,0) * CFrame.Angles(-0.1,0,0),0.2)
  833. Left_Hip.C0=clerp(Left_Hip.C0,CFrame.new(-1,-1,0)*CFrame.Angles(0,-1.6,0) * CFrame.Angles(-0.1,0,0),0.2)
  834.  
  835. end
  836.  
  837.  
  838. if 2 < Torvel and Torvel < 22 and HitFloor ~= nil and Attacking == false then
  839. Anim = "Walking"
  840.  
  841. if Invert == false then
  842. Change1 = Change1 + 0.1
  843.  
  844. elseif Invert == true then
  845.  
  846. Change1 = Change1 - 0.1
  847.  
  848. end
  849.  
  850. if Change1 > 0.5 then
  851.  
  852. Invert = true
  853.  
  854. elseif Change1 < -0.5 then
  855.  
  856. Invert = false
  857.  
  858. end
  859.  
  860. if Attacking == false then
  861.  
  862. RootJoint.C0 = clerp(RootJoint.C0,RootCFrame*CFrame.new(0,0,0)* CFrame.Angles(0,0,0),0.2)
  863. Torso.Neck.C0 = clerp(Torso.Neck.C0,Necko * CFrame.Angles(0,-0.3,0),0.3)
  864. Right_Shoulder.C0 = clerp(Right_Shoulder.C0, CFrame.new(1.5, 0, -Change1) * CFrame.Angles(Change1,0,0), 0.3)
  865. Left_Shoulder.C0 = clerp(Left_Shoulder.C0, CFrame.new(-1.5, 0, Change1) * CFrame.Angles(-Change1,0,0), 0.3)
  866. Right_Hip.C0=clerp(Right_Hip.C0,CFrame.new(1,-1,-Change1 / 4)*CFrame.Angles(Change1,1.6,0),0.2)
  867. Left_Hip.C0=clerp(Left_Hip.C0,CFrame.new(-1,-1,Change1 / 4)*CFrame.Angles(-Change1,-1.6,0),0.2)
  868.  
  869. end
  870. end
  871.  
  872. if Root.Velocity.y > 1 and HitFloor == nil and Attacking == false then
  873. Anim = "Jump"
  874.  
  875. RootJoint.C0 = clerp(RootJoint.C0,RootCFrame*CFrame.new(0,0,0)* CFrame.Angles(0,0,0),0.2)
  876. Torso.Neck.C0 = clerp(Torso.Neck.C0,Necko * CFrame.Angles(-0.5,0,0),0.3)
  877. Right_Shoulder.C0 = clerp(Right_Shoulder.C0, CFrame.new(1.5, 0, 0.2) * CFrame.Angles(-0.4,0,0.2), 0.3)
  878. Left_Shoulder.C0 = clerp(Left_Shoulder.C0, CFrame.new(-1.5, 0, 0.2) * CFrame.Angles(-0.4,0,-0.2), 0.3)
  879. Right_Hip.C0=clerp(Right_Hip.C0,CFrame.new(1,-1,-0.2)*CFrame.Angles(-0.2,1.6,0),0.2)
  880. Left_Hip.C0=clerp(Left_Hip.C0,CFrame.new(-1,-1,0)*CFrame.Angles(0,-1.6,0),0.2)
  881.  
  882. end
  883.  
  884. if Root.Velocity.y < -1 and HitFloor == nil and Attacking == false then
  885. Anim = "Fall"
  886.  
  887. RootJoint.C0 = clerp(RootJoint.C0,RootCFrame*CFrame.new(0,0,0)* CFrame.Angles(0,0,0),0.2)
  888. Torso.Neck.C0 = clerp(Torso.Neck.C0,Necko * CFrame.Angles(0.5,0,0),0.3)
  889. Right_Shoulder.C0 = clerp(Right_Shoulder.C0, CFrame.new(1.5, 0, -0.2) * CFrame.Angles(0.4,0,0.2), 0.3)
  890. Left_Shoulder.C0 = clerp(Left_Shoulder.C0, CFrame.new(-1.5, 0, -0.2) * CFrame.Angles(0.4,0,-0.2), 0.3)
  891. Right_Hip.C0=clerp(Right_Hip.C0,CFrame.new(1,-1,-0.2)*CFrame.Angles(-0.2,1.6,0),0.2)
  892. Left_Hip.C0=clerp(Left_Hip.C0,CFrame.new(-1,-1,0)*CFrame.Angles(0,-1.6,0),0.2)
  893.  
  894. end
  895.  
  896.  
  897. if #Effects > 0 then
  898. for E = 1, #Effects do
  899. if Effects[E]~=nil then
  900. local Effect = Effects[E]
  901.  
  902. if Effect ~= nil then
  903.  
  904. local Part = Effect[1]
  905. local Mode = Effect[2]
  906. local Time = Effect[3]
  907. local SizeX = Effect[4]
  908. local SizeY = Effect[5]
  909. local SizeZ = Effect[6]
  910.  
  911. if Effect[1].Transparency <= 1 then
  912. if Effect[2] == "Block" then
  913. Effect[1].CFrame = Effect[1].CFrame * CFrame.Angles(math.random(-50,50),math.random(-50,50),math.random(-50,50))
  914.  
  915. Mesh = Effect[1]:FindFirstChild("Mesh")
  916. if Mesh ~= nil then
  917. Mesh.Scale = Mesh.Scale + Vector3.new(Effect[4],Effect[5],Effect[6])
  918. end
  919.  
  920. elseif Effect[2] == "Circle" then
  921.  
  922. if Effect[1]:FindFirstChild("Mesh") ~= nil then
  923. Mesh=Effect[1].Mesh
  924. Mesh.Scale = Mesh.Scale + Vector3.new(Effect[4],Effect[5],Effect[6])
  925. end
  926.  
  927. Effect[1].Transparency = Effect[1].Transparency + 0.05
  928.  
  929. else
  930.  
  931. Part.Parent=nil
  932.  
  933. table.remove(Effects, E)
  934.  
  935. end
  936. end
  937. end
  938. end
  939. end
  940. end
  941. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement