Advertisement
Pukaciu

editing script

Jul 27th, 2017
114
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 42.68 KB | None | 0 0
  1. local Player = game:GetService("Players").LocalPlayer
  2. local Character = Player.Character
  3. local Mouse = Player:GetMouse()
  4. local Camera = game:GetService("Workspace").CurrentCamera
  5. local Humanoid = Character:findFirstChild("Humanoid")
  6. local Torso = Character.Torso
  7. local PlayerGui = Player.PlayerGui
  8. local Torso = Character:findFirstChild("Torso")
  9. local Head = Character:findFirstChild("Head")
  10. local RootPart = Character:findFirstChild("HumanoidRootPart")
  11. local Root = RootPart.RootJoint
  12. local Sides = {"Left","Right"}
  13. local Arms = {Character["Left Arm"],Character["Right Arm"]}
  14. local Legs = {Character["Left Leg"],Character["Right Leg"]}
  15.  
  16. local Bits = {}
  17. local Disposables = {}
  18. local Discs = {}
  19.  
  20. local DiscSpin = 0
  21. local Spread = 1.25
  22. local RateTop = 1
  23. local RateBot = 1
  24. local Distance = 0.5
  25. local ExtendTop = 1
  26. local ExtendBot = 1
  27. local CurrentFrame = 1
  28. local Lift = 0
  29. local Accel = 1
  30. local TurnAngle = 0
  31. local rofTop = 1
  32. local rofBot = 1
  33. local Flutter = 0
  34.  
  35. local Front = false
  36. local Back = false
  37. local Left = false
  38. local Right = false
  39. local AddSub = false
  40. local ChargeHeld = false
  41. local BoostHeld = false
  42. local BeamHeld = false
  43. local AbsDefHeld = false
  44. local ExtendGrowthTop = false
  45. local ExtendGrowthBot = false
  46. local UpdateAnim = true
  47.  
  48.  
  49. local CurrentAnimation = "Idle"
  50. local LastAnimation = "Idle"
  51. local MobilityType = "Float"
  52. local ColorGlobe = "Lime green"
  53. local ColorBlades = "Dark blue"
  54. local xmove,zmove
  55.  
  56. local LastBeam = tick()
  57.  
  58. if Torso then
  59. for _,v in pairs(Torso:children()) do
  60. if v:IsA("BodyGyro") or v:IsA("BodyVelocity") then
  61. v:Destroy();
  62. end
  63. end
  64. end
  65.  
  66. local Energy = {}
  67. local TotalEnergy = 9999
  68. local CurrentEnergy = 9999
  69.  
  70. pcall(function()
  71. PlayerGui.EnergyMeter:Destroy()
  72. end)
  73. if Player.Name == "modFrost" then
  74. ColorGlobe = "Bright orange"
  75. end
  76.  
  77. local FlapSound = Instance.new("Sound", Torso)
  78. FlapSound.Name = "Flap"
  79. FlapSound.SoundId = "http://www.roblox.com/asset/?id=257002377"
  80. FlapSound.Volume = 1
  81.  
  82. local EnergyMeter = Instance.new("ScreenGui", PlayerGui)
  83. EnergyMeter.Name = "EnergyMeter"
  84. local Bar = Instance.new("Frame", EnergyMeter)
  85. Bar.Size = UDim2.new(0,200,0,10)
  86. Bar.Position = UDim2.new(1,-205,1,-15)
  87. Bar.BorderSizePixel = 0
  88. Bar.BackgroundColor = BrickColor.new("Really black")
  89. Bar.BackgroundTransparency = 0.5
  90. local Text = Instance.new("TextLabel", Bar)
  91. Text.Text = "Energy"
  92. Text.TextColor = BrickColor.new("Black")
  93. Text.BackgroundTransparency = 1
  94. Text.Size = UDim2.new(1,0,1,0)
  95. Text.Position = UDim2.new(0,0,-1,-10)
  96. Text.TextXAlignment = "Left"
  97. Text.FontSize = "Size12"
  98. local EnergyFill = Instance.new("Frame", Bar)
  99. EnergyFill.Size = UDim2.new(0,0,1,-5)
  100. EnergyFill.Position = UDim2.new(0,2.5,0,2.5)
  101. EnergyFill.BorderSizePixel = 0
  102. EnergyFill.BackgroundColor = BrickColor.new(Really red)
  103. EnergyFill.BackgroundTransparency = 0.25
  104.  
  105. local ChargeMeter = Instance.new("ScreenGui", PlayerGui)
  106. ChargeMeter.Name = "EnergyMeter"
  107. local ChargeBar = Instance.new("Frame", ChargeMeter)
  108. ChargeBar.Size = UDim2.new(0,200,0,10)
  109. ChargeBar.Position = UDim2.new(0.5,-102.5,0.8,-5)
  110. ChargeBar.BorderSizePixel = 0
  111. ChargeBar.BackgroundColor = BrickColor.new("Really black")
  112. ChargeBar.BackgroundTransparency = 0.5
  113. local ChargeFill = Instance.new("Frame", ChargeBar)
  114. ChargeFill.Size = UDim2.new(0,0,1,-5)
  115. ChargeFill.Position = UDim2.new(0,2.5,0,2.5)
  116. ChargeFill.BorderSizePixel = 0
  117. ChargeFill.BackgroundColor = BrickColor.new("Bright yellow ")
  118. ChargeFill.BackgroundTransparency = 0.25
  119. ChargeBar.Visible = false
  120.  
  121. local function _Part(Parent,canc,anc,tr,ref,mat,color,size, meshtype, scale)
  122. local part = Instance.new("Part", Parent)
  123. part.Transparency = tr
  124. part.Anchored = anc
  125. part.TopSurface = 10
  126. part.BottomSurface = 10
  127. part.LeftSurface = 10
  128. part.RightSurface = 10
  129. part.FrontSurface = 10
  130. part.BackSurface = 10
  131. part.Locked = true
  132. part.formFactor = 3
  133. part.Reflectance = ref
  134. part.Material = mat
  135. part.CanCollide = canc
  136. part.Size = Vector3.new(size[1],size[2],size[3])
  137. part.BrickColor = BrickColor.new(color)
  138. local mesh
  139. if meshtype == "BlockMesh" then
  140. mesh = Instance.new("BlockMesh", part)
  141. elseif meshtype == "CylinderMesh" then
  142. mesh = Instance.new("CylinderMesh", part)
  143. else
  144. mesh = Instance.new("SpecialMesh", part)
  145. mesh.MeshType = meshtype
  146. end
  147. mesh.Name = "Mesh"
  148. mesh.Scale = Vector3.new(scale[1],scale[2],scale[3])
  149. return part
  150. end
  151.  
  152. local function _Weld(Parent, p0, c1, c0)
  153. local weld = Instance.new("Motor", Parent)
  154. weld.Part1 = Parent
  155. weld.Part0 = p0
  156. weld.C1 = c1
  157. weld.C0 = c0
  158. weld.Name = "Weld"
  159. return weld
  160. end
  161.  
  162. local Main = Character:findFirstChild("Main") or Instance.new("Model", Character)
  163. Main.Name = "Main"
  164. Main:ClearAllChildren()
  165.  
  166. pcall(function() Character["Head"]["face"]:Destroy() end)
  167.  
  168. for _,Hat in pairs(Character:GetChildren()) do
  169. if Hat:IsA("Accoutrement") then
  170. Hat:Destroy()
  171. end
  172. end
  173.  
  174. for _,Part in pairs(Character:GetChildren()) do
  175. if Part:IsA("BasePart") then
  176. Part.Transparency = 1
  177. end
  178. end
  179.  
  180. local function GenF(Part, Cframe, Color)
  181. local A = _Part(Main,false,false,0,0,"SmoothPlastic",Color,{0.05,0.5,0.05},"BlockMesh",{1,1,0.5})
  182. _Weld(A, Part, CFrame.new(), Cframe)
  183. local B = _Part(Main,false,false,0,0,"SmoothPlastic",Color,{0.2,0.2,0.3},"BlockMesh",{1,0.5,1})
  184. _Weld(B, A, CFrame.new(), CFrame.new(0,-0.2,0.2))
  185. local C = _Part(Main,false,false,0,0,"SmoothPlastic",Color,{0.2,0.2,0.2},"BlockMesh",{1,0.5,1})
  186. _Weld(C, A, CFrame.new(), CFrame.new(0,-0.025,0.15))
  187. end
  188.  
  189. local Down = _Part(Main,false,false,1,1,"SmoothPlastic","Black",{1,1,1},"Brick",{1,1,1})
  190. _Weld(Down, Torso, CFrame.Angles(math.rad(90),0,0), CFrame.new())
  191.  
  192. local AnchorPart = _Part(Main,false,false,0.1,0,"Granite",ColorGlobe,{0.8,0.8,0.8},"Sphere",{1,1,1})
  193. _Weld(AnchorPart, Character["Right Arm"], CFrame.new(0,1.5,0), CFrame.new())
  194.  
  195. local AnchorPart2 = _Part(Main,false,false,0.1,0,"Granite",ColorGlobe,{0.8,0.8,0.8},"Sphere",{1,1,1})
  196. _Weld(AnchorPart2, Character["Left Arm"], CFrame.new(0,1.5,0), CFrame.new())
  197.  
  198. local AnchorPart3 = _Part(Main,false,false,0.1,0,"Granite",ColorGlobe,{0.8,0.8,0.8},"Sphere",{1,1,1})
  199. _Weld(AnchorPart3, Character["Right Leg"], CFrame.new(0,1.5,0), CFrame.new())
  200.  
  201. local AnchorPart4 = _Part(Main,false,false,0.1,0,"Granite",ColorGlobe,{0.8,0.8,0.8},"Sphere",{1,1,1})
  202. _Weld(AnchorPart4, Character["Left Leg"], CFrame.new(0,1.5,0), CFrame.new())
  203.  
  204. --Back
  205.  
  206. local AnchorPart5 = _Part(Main,false,false,0.1,0,"Granite",ColorGlobe,{0.6,0.6,0.6},"Sphere",{1,1,1})
  207. _Weld(AnchorPart5, Character.Torso, CFrame.new(0.75,-0.5,-1), CFrame.new())
  208.  
  209. local AnchorPart6 = _Part(Main,false,false,0.1,0,"Granite",ColorGlobe,{0.6,0.6,0.6},"Sphere",{1,1,1})
  210. _Weld(AnchorPart6, Character.Torso, CFrame.new(-0.75,-0.5,-1), CFrame.new())
  211.  
  212. local AnchorPart7 = _Part(Main,false,false,0.1,0,"Granite",ColorGlobe,{0.4,0.4,0.4},"Sphere",{1,1,1})
  213. _Weld(AnchorPart7, Character.Torso, CFrame.new(0.5,0.25,-0.8), CFrame.new())
  214.  
  215. local AnchorPart8 = _Part(Main,false,false,0.1,0,"Granite",ColorGlobe,{0.4,0.4,0.4},"Sphere",{1,1,1})
  216. _Weld(AnchorPart8, Character.Torso, CFrame.new(-0.5,0.25,-0.8), CFrame.new())
  217.  
  218. local WingLeft = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,2,1},"Wedge",{1,1,1})
  219. local WingLeftMain = _Weld(WingLeft, AnchorPart5, CFrame.new(), CFrame.new())
  220. local WingLeftP1 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,2,1},"Wedge",{1,1,1})
  221. _Weld(WingLeftP1, WingLeft, CFrame.new(0,-2,0) * CFrame.Angles(math.rad(180),0,0), CFrame.new())
  222. local WingLeftD = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{0.25,1.8*2,0.45*2})
  223. WingLeftD.Mesh.MeshId = "rbxassetid://9756362"
  224. _Weld(WingLeftD, WingLeft, CFrame.new(0,1,-0.25) * CFrame.Angles(math.rad(-15),0,0), CFrame.new())
  225. table.insert(Bits, {Side = true; Weld = WingLeftMain; Series = 0;Type = "Wing"})
  226.  
  227. local WingRight = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,2,1},"Wedge",{1,1,1})
  228. local WingRightMain = _Weld(WingRight, AnchorPart6, CFrame.new(), CFrame.new())
  229. local WingRightP1 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,2,1},"Wedge",{1,1,1})
  230. _Weld(WingRightP1, WingRight, CFrame.new(0,-2,0) * CFrame.Angles(math.rad(180),0,0), CFrame.new())
  231. local WingRightD = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{0.25,1.8*2,0.45*2})
  232. WingRightD.Mesh.MeshId = "rbxassetid://9756362"
  233. _Weld(WingRightD, WingRight, CFrame.new(0,1,-0.25) * CFrame.Angles(math.rad(-15),0,0), CFrame.new())
  234. table.insert(Bits, {Side = false; Weld = WingRightMain; Series = 0;Type = "Wing"})
  235.  
  236. local WingLeftLower = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1.5,0.5},"Wedge",{1,1,1})
  237. local WingLeftLowerMain = _Weld(WingLeftLower, AnchorPart7, CFrame.new(), CFrame.new())
  238. local WingLeftLowerP1 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1.5,0.5},"Wedge",{1,1,1})
  239. _Weld(WingLeftLowerP1, WingLeftLower, CFrame.new(0,-1.5,0) * CFrame.Angles(math.rad(180),0,0), CFrame.new())
  240. local WingLeftLowerD = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{0.25,2.8,0.45})
  241. WingLeftLowerD.Mesh.MeshId = "rbxassetid://9756362"
  242. _Weld(WingLeftLowerD, WingLeftLower, CFrame.new(0,0.75,-0.15) * CFrame.Angles(math.rad(-10),0,0), CFrame.new())
  243. table.insert(Bits, {Side = true; Weld = WingLeftLowerMain; Series = 0;Type = "WingLow"})
  244.  
  245. local WingRightLower = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1.5,0.5},"Wedge",{1,1,1})
  246. local WingRightLowerMain = _Weld(WingRightLower, AnchorPart8, CFrame.new(), CFrame.new())
  247. local WingRightLowerP1 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1.5,0.5},"Wedge",{1,1,1})
  248. _Weld(WingRightLowerP1, WingRightLower, CFrame.new(0,-1.5,0) * CFrame.Angles(math.rad(180),0,0), CFrame.new())
  249. local WingRightLowerD = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{0.25,2.8,0.45})
  250. WingRightLowerD.Mesh.MeshId = "rbxassetid://9756362"
  251. _Weld(WingRightLowerD, WingRightLower, CFrame.new(0,0.75,-0.15) * CFrame.Angles(math.rad(-10),0,0), CFrame.new())
  252. table.insert(Bits, {Side = false; Weld = WingRightLowerMain; Series = 0;Type = "WingLow"})
  253.  
  254. for i = 1, 6, 1 do
  255. local TriP1 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1,0.5},"Wedge",{1,1,1})
  256. local Main = _Weld(TriP1, AnchorPart, CFrame.new(), CFrame.new())
  257. local TriP2 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1,0.5},"Wedge",{1,1,1})
  258. _Weld(TriP2, TriP1, CFrame.new(0,-1,0) * CFrame.Angles(math.rad(180),0,0), CFrame.new())
  259. local DiamondB = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{0.25,1.8,0.45})
  260. DiamondB.Mesh.MeshId = "rbxassetid://9756362"
  261. _Weld(DiamondB, TriP1, CFrame.new(0,0.5,-0.125) * CFrame.Angles(math.rad(-15),0,0),CFrame.new())
  262. table.insert(Bits, {Side = false; Weld = Main; Series = i;Type = "Top"})
  263. end
  264.  
  265. for i = 1, 6, 1 do
  266. local TriP1 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1,0.5},"Wedge",{1,1,1})
  267. local Main = _Weld(TriP1, AnchorPart2, CFrame.new(), CFrame.new())
  268. local TriP2 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1,0.5},"Wedge",{1,1,1})
  269. _Weld(TriP2, TriP1, CFrame.new(0,-1,0) * CFrame.Angles(math.rad(180),0,0), CFrame.new())
  270. local DiamondB = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{0.25,1.8,0.45})
  271. DiamondB.Mesh.MeshId = "rbxassetid://9756362"
  272. _Weld(DiamondB, TriP1, CFrame.new(0,0.5,-0.125) * CFrame.Angles(math.rad(-15),0,0),CFrame.new())
  273. table.insert(Bits, {Side = true; Weld = Main; Series = i;Type = "Top"})
  274. end
  275.  
  276. for i = 1, 6, 1 do
  277. local TriP1 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1,0.5},"Wedge",{1,1,1})
  278. local Main = _Weld(TriP1, AnchorPart3, CFrame.new(), CFrame.new())
  279. local TriP2 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1,0.5},"Wedge",{1,1,1})
  280. _Weld(TriP2, TriP1, CFrame.new(0,-1,0) * CFrame.Angles(math.rad(180),0,0), CFrame.new())
  281. local DiamondB = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{0.25,1.8,0.45})
  282. DiamondB.Mesh.MeshId = "rbxassetid://9756362"
  283. _Weld(DiamondB, TriP1, CFrame.new(0,0.5,-0.125) * CFrame.Angles(math.rad(-15),0,0),CFrame.new())
  284. table.insert(Bits, {Side = false; Weld = Main; Series = i;Type = "Bot"})
  285. end
  286.  
  287. for i = 1, 6, 1 do
  288. local TriP1 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1,0.5},"Wedge",{1,1,1})
  289. local Main = _Weld(TriP1, AnchorPart4, CFrame.new(), CFrame.new())
  290. local TriP2 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.2,1,0.5},"Wedge",{1,1,1})
  291. _Weld(TriP2, TriP1, CFrame.new(0,-1,0) * CFrame.Angles(math.rad(180),0,0), CFrame.new())
  292. local DiamondB = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{0.25,1.8,0.45})
  293. DiamondB.Mesh.MeshId = "rbxassetid://9756362"
  294. _Weld(DiamondB, TriP1, CFrame.new(0,0.5,-0.125) * CFrame.Angles(math.rad(-15),0,0),CFrame.new())
  295. table.insert(Bits, {Side = true; Weld = Main; Series = i;Type = "Bot"})
  296. end
  297.  
  298. --[[local WingAnchor = _Part(Main,false,false,1,0,"SmoothPlastic",ColorBlades,{1,1,1},"BlockMesh",{1,1,1})
  299. _Weld(WingAnchor, Character.Torso, CFrame.new(0.5,-0.5,-1), CFrame.new())
  300. local LengthWing1 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.3,1.5,0.3},"BlockMesh",{1,1,1})
  301. _Weld(LengthWing1, WingAnchor, CFrame.new(0.5,-0.55,0.35) * CFrame.Angles(math.rad(290),math.rad(45),0), CFrame.new())
  302. local WingAnchor2 = _Part(Main,false,false,1,0,"SmoothPlastic",ColorBlades,{1,1,1},"BlockMesh",{1,1,1})
  303. _Weld(WingAnchor2, LengthWing1, CFrame.new(0,-0.75,0), CFrame.new())
  304. local LengthWing2 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.3,1.5,0.3},"BlockMesh",{1,1,1})
  305. _Weld(LengthWing2, WingAnchor2, CFrame.new(0,-0.6,0) * CFrame.Angles(math.rad(350),0,0), CFrame.new())
  306. local WingAnchor3 = _Part(Main,false,false,1,0,"SmoothPlastic",ColorBlades,{1,1,1},"BlockMesh",{1,1,1})
  307. _Weld(WingAnchor3, LengthWing2, CFrame.new(0,-0.75,0), CFrame.new())
  308. local LengthWing3 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.3,1.5,0.3},"BlockMesh",{1,1,1})
  309. _Weld(LengthWing3, WingAnchor3, CFrame.new(0,-0.6,0) * CFrame.Angles(math.rad(-10),0,0), CFrame.new())
  310. local WingAnchor4 = _Part(Main,false,false,1,0,"SmoothPlastic",ColorBlades,{1,1,1},"BlockMesh",{1,1,1})
  311. _Weld(WingAnchor4, LengthWing3, CFrame.new(0,-0.75,0), CFrame.new())
  312. local LengthWing4 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{0.3,1.5,0.3},"BlockMesh",{1,1,1})
  313. _Weld(LengthWing4, WingAnchor4, CFrame.new(0,-0.6,0) * CFrame.Angles(math.rad(-15),0,0), CFrame.new())
  314. ]]-- Scrapped for now...
  315.  
  316. --[[Body]]--
  317.  
  318. local BHead = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"Head",{1.25,1.25,1.25})
  319. _Weld(BHead,Head,CFrame.new(),CFrame.new())
  320. local BHelm = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{1,1,1})
  321. BHelm.Mesh.MeshId = "rbxassetid://17438747"
  322. _Weld(BHelm,BHead,CFrame.new(0,-0.2,0),CFrame.new())
  323. local BHelm2 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"FileMesh",{0.95,0.97,0.95})
  324. BHelm2.Mesh.MeshId = "rbxassetid://17438747"
  325. _Weld(BHelm2,BHelm,CFrame.new(0,0,-0.02),CFrame.new())
  326. local EyeL = _Part(Main,false,false,0,0,"Neon",ColorGlobe,{1,1,1},"Sphere",{0.25,0.075,0.075})
  327. _Weld(EyeL,Head,CFrame.new(0.2,0.25,0.55)*CFrame.Angles(0,math.rad(40),0),CFrame.new())
  328. local EyeR = _Part(Main,false,false,0,0,"Neon",ColorGlobe,{1,1,1},"Sphere",{0.25,0.075,0.075})
  329. _Weld(EyeR,Head,CFrame.new(-0.2,0.25,0.55)*CFrame.Angles(0,math.rad(-40),0),CFrame.new())
  330. local Mouth = _Part(Main,false,false,0,0,"Neon",ColorGlobe,{1,1,1},"Sphere",{0.25,0.075,0.075})
  331. _Weld(Mouth,Head,CFrame.new(0,0.45,0.53),CFrame.new())
  332. local BTorso = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"FileMesh",{1,0.4,1})
  333. BTorso.Mesh.MeshId = "rbxasset://fonts\\torso.mesh"
  334. _Weld(BTorso,Torso,CFrame.new(0,-0.45,0),CFrame.new())
  335. local BTorso2 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"FileMesh",{0.85,0.6,0.85})
  336. BTorso2.Mesh.MeshId = "rbxasset://fonts\\torso.mesh"
  337. _Weld(BTorso2,BTorso,CFrame.new(0,0.8,0),CFrame.new())
  338. local BTorsoCore = _Part(Main,false,false,0,0,"Neon",ColorGlobe,{1,1,1},"Sphere",{0.5,0.5,0.5})
  339. _Weld(BTorsoCore, Torso, CFrame.new(0,-0.5,0.4),CFrame.new())
  340. local BTorsoCoreDisc = _Part(Main,false,false,0,0,"SmoothPlastic","Medium stone grey",{1,1,1},"FileMesh",{0.525,0.525,0.2})
  341. BTorsoCoreDisc.Mesh.MeshId = "rbxassetid://3270017"
  342. _Weld(BTorsoCoreDisc, BTorsoCore, CFrame.new(0,0,0.1),CFrame.new())
  343. local BNeck = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"Head",{0.8,1,0.8})
  344. _Weld(BNeck,Head,CFrame.new(0,0.8,0),CFrame.new())
  345.  
  346. for i=1,3 do
  347. local BTorsoAb = _Part(Main,false,false,0,0,"SmoothPlastic","Medium stone grey",{1,1,1},"FileMesh",{0.2,0.075,0.2})
  348. BTorsoAb.Mesh.MeshId = "rbxasset://fonts\\torso.mesh"
  349. _Weld(BTorsoAb, Torso, CFrame.new(-0.5,-0.3 + 0.3*i,0.35)*CFrame.Angles(0,0,math.rad(15)),CFrame.new())
  350. end
  351. for i=1,3 do
  352. local BTorsoAb = _Part(Main,false,false,0,0,"SmoothPlastic","Medium stone grey",{1,1,1},"FileMesh",{0.2,0.075,0.2})
  353. BTorsoAb.Mesh.MeshId = "rbxasset://fonts\\torso.mesh"
  354. _Weld(BTorsoAb, Torso, CFrame.new(0.5,-0.3 + 0.3*i,0.35)*CFrame.Angles(0,0,math.rad(-15)),CFrame.new())
  355. end
  356.  
  357. local function Arm(bool)
  358. local Limb, Offset
  359. if bool then
  360. Limb = Character["Left Arm"]
  361. Offset = 0.52
  362. else
  363. Limb = Character["Right Arm"]
  364. Offset = -0.52
  365. end
  366.  
  367. local ShldrL = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"FileMesh",{1,0.35,1})
  368. ShldrL.Mesh.MeshId = "rbxasset://fonts\\rightarm.mesh"
  369. _Weld(ShldrL,Limb,CFrame.new(0,-0.6,0),CFrame.new())
  370. local ShldrL2 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"FileMesh",{0.85,0.5,0.85})
  371. ShldrL2.Mesh.MeshId = "rbxasset://fonts\\rightarm.mesh"
  372. _Weld(ShldrL2,Limb,CFrame.new(0,0.2,0),CFrame.new())
  373. local ShldrL3 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"FileMesh",{0.75,0.2,0.75})
  374. ShldrL3.Mesh.MeshId = "rbxasset://fonts\\rightarm.mesh"
  375. _Weld(ShldrL3,Limb,CFrame.new(0,0.85,0),CFrame.new())
  376. local ShldrL4 = _Part(Main,false,false,0,0,"SmoothPlastic","Really black",{1,1,1},"FileMesh",{0.5,0.05,0.5})
  377. ShldrL4.Mesh.MeshId = "rbxasset://fonts\\rightarm.mesh"
  378. _Weld(ShldrL4,ShldrL3,CFrame.new(0,0.16,0),CFrame.new())
  379. --X Pat--
  380. local ShldrLD = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{1.1,0.03,1.35})
  381. ShldrLD.Mesh.MeshId = "rbxasset://fonts\\rightarm.mesh"
  382. _Weld(ShldrLD,Limb,CFrame.new(0,0,0),CFrame.Angles(math.rad(45),0,0))
  383. local ShldrLD2 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{1.1,0.03,1.35})
  384. ShldrLD2.Mesh.MeshId = "rbxasset://fonts\\rightarm.mesh"
  385. _Weld(ShldrLD2,Limb,CFrame.new(0,0,0),CFrame.Angles(math.rad(-45),0,0))
  386. local ShldrLDB = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{1.35,0.03,1.1})
  387. ShldrLDB.Mesh.MeshId = "rbxasset://fonts\\rightarm.mesh"
  388. _Weld(ShldrLDB,Limb,CFrame.new(0,0,0),CFrame.Angles(0,0,math.rad(45)))
  389. local ShldrLD2B = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{1.35,0.03,1.1})
  390. ShldrLD2B.Mesh.MeshId = "rbxasset://fonts\\rightarm.mesh"
  391. _Weld(ShldrLD2B,Limb,CFrame.new(0,0,0),CFrame.Angles(0,0,math.rad(-45)))
  392.  
  393. local Disc = _Part(Main,false,false,0,0,"SmoothPlastic",ColorGlobe,{1,1,1},"FileMesh",{0.55,0.55,0.55})
  394. Disc.Mesh.MeshId = "rbxassetid://47260990"
  395. _Weld(Disc, ShldrL, CFrame.new(0,0,Offset),CFrame.Angles(0,math.rad(90),0))
  396. --3270017
  397. local DiscC = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"FileMesh",{0.55,0.55,0.1})
  398. DiscC.Mesh.MeshId = "rbxassetid://3270017"
  399. _Weld(DiscC, Disc, CFrame.new(),CFrame.new())
  400.  
  401. table.insert(Discs, Disc)
  402. end
  403.  
  404. local function Leg(bool)
  405. local Limb, Offset
  406. if bool then
  407. Limb = Character["Left Leg"]
  408. Offset = 0.5
  409. else
  410. Limb = Character["Right Leg"]
  411. Offset = -0.5
  412. end
  413. local LegL = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"FileMesh",{0.95,0.35,0.95})
  414. LegL.Mesh.MeshId = "rbxasset://fonts\\leftleg.mesh"
  415. _Weld(LegL,Limb,CFrame.new(0,-0.7,0),CFrame.new())
  416. local LegL2 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"FileMesh",{0.85,0.5,0.85})
  417. LegL2.Mesh.MeshId = "rbxasset://fonts\\leftleg.mesh"
  418. _Weld(LegL2,Limb,CFrame.new(0,0.15,0),CFrame.new())
  419. local LegL3 = _Part(Main,false,false,0,0,"SmoothPlastic",ColorBlades,{1,1,1},"FileMesh",{0.75,0.2,0.75})
  420. LegL3.Mesh.MeshId = "rbxasset://fonts\\leftleg.mesh"
  421. _Weld(LegL3,Limb,CFrame.new(0,0.85,0),CFrame.new())
  422. local LegL4 = _Part(Main,false,false,0,0,"SmoothPlastic","Really black",{1,1,1},"FileMesh",{0.5,0.05,0.5})
  423. LegL4.Mesh.MeshId = "rbxasset://fonts\\leftleg.mesh"
  424. _Weld(LegL4,LegL3,CFrame.new(0,0.16,0),CFrame.new())
  425. local LegL5 = _Part(Main,false,false,0,0,"SmoothPlastic","Medium stone grey",{1,1,1},"FileMesh",{0.9,0.2,0.9})
  426. LegL5.Mesh.MeshId = "rbxasset://fonts\\leftleg.mesh"
  427. _Weld(LegL5,LegL2,CFrame.new(0,0,0),CFrame.new())
  428.  
  429. local MiniRocket = _Part(Main,false,false,0,0,"SmoothPlastic","Medium stone grey",{1,1,1},"FileMesh",{0.2,0.2,0.2})
  430. MiniRocket.Mesh.MeshId = "rbxasset://fonts\\leftleg.mesh"
  431. _Weld(MiniRocket,LegL5,CFrame.new(Offset,0,0),CFrame.new())
  432. local MiniRocket2 = _Part(Main,false,false,0,0,"SmoothPlastic","Really black",{1,1,1},"BlockMesh",{0.125,0.1,0.125})
  433. _Weld(MiniRocket2,LegL5,CFrame.new(Offset,0.16,0),CFrame.new())
  434. end
  435.  
  436. Arm(true)
  437. Arm(false)
  438. Leg(true)
  439. Leg(false)
  440.  
  441. --Spin Disc 22768172
  442. --[[Done]]--
  443.  
  444. local Welds = {
  445. ArmW = {
  446. Left = Instance.new("Weld",Character);
  447. Right = Instance.new("Weld",Main);
  448. };
  449. LegW = {
  450. Left = Instance.new("Weld",Main);
  451. Right = Instance.new("Weld",Main);
  452. };
  453. HeadW = {
  454. Middle = Instance.new("Weld",Main);
  455. };
  456. }
  457. local RWelds = {
  458. ArmW = {
  459. Left = Torso["Left Shoulder"];
  460. Right = Torso["Right Shoulder"];
  461. };
  462. LegW = {
  463. Left = Torso["Left Hip"];
  464. Right = Torso["Right Hip"];
  465. };
  466. HeadW = {
  467. Middle = Torso["Neck"];
  468. };
  469. }
  470.  
  471. local LA,RA = Welds.ArmW.Left,Welds.ArmW.Right
  472. local LL,LR = Welds.LegW.Left,Welds.LegW.Right
  473. local HD = Welds.HeadW.Middle
  474. local LAD = CFrame.new(-1.5,0.5,0)
  475. local RAD = CFrame.new(1.5,0.5,0)
  476. local HDD = CFrame.new(0,-1.5,0)
  477. local LLD = CFrame.new(0.5,2,0)
  478. local RLD = CFrame.new(-0.5,2,0)
  479. local RootD = CFrame.Angles(-1.57,0,-3.15)
  480. Welds.ArmW.Left.C1,Welds.ArmW.Left.C0,Welds.ArmW.Left.Part0 = CFrame.new(0, 0.5, 0),CFrame.new(-1.5, 0.5, 0),Torso
  481. Welds.ArmW.Right.C1,Welds.ArmW.Right.C0,Welds.ArmW.Right.Part0 = CFrame.new(0, 0.5, 0),CFrame.new(1.5, 0.5, 0),Torso
  482. Welds.LegW.Left.C1,Welds.LegW.Left.Part0 = LLD,Torso
  483. Welds.LegW.Right.C1,Welds.LegW.Right.Part0 = RLD,Torso
  484. Welds.HeadW.Middle.C1,Welds.HeadW.Middle.Part0 = HDD,Torso
  485.  
  486. local CurrentLeftArm = LAD
  487. local CurrentRightArm = RAD
  488. local CurrentLeftLeg = LLD
  489. local CurrentRightLeg = RLD
  490.  
  491. local function lerp(a, b, c)
  492. return a+(b-a)*c
  493. end
  494.  
  495. local function AnimLerp(c1, c2, al)
  496. local com1 = {c1.X,c1.Y,c1.Z,c1:toEulerAnglesXYZ()}
  497. local com2 = {c2.X,c2.Y,c2.Z,c2:toEulerAnglesXYZ()}
  498. for i,v in pairs(com1) do
  499. com1[i] = lerp(v,com2[i],al)
  500. end
  501. return CFrame.new(com1[1],com1[2],com1[3]) * CFrame.Angles(select(4,unpack(com1)))
  502. end
  503.  
  504. local _Arm = function(side,tf)
  505. local Arm = nil
  506. local Weld = nil
  507. local RWeld = nil
  508. for _,S in pairs(Sides) do
  509. if side:lower() == S:lower() then
  510. for _,A in pairs(Arms) do
  511. if A.Name:lower():find(side:lower()) then
  512. Arm = A
  513. Weld = Welds.ArmW[S]
  514. RWeld = RWelds.ArmW[S]
  515. end
  516. end
  517. end
  518. end
  519. if Arm and Weld and RWeld then
  520. if tf then
  521. Weld.Part1 = Arm
  522. RWeld.Part1 = nil
  523. elseif not tf then
  524. Weld.Part1 = nil
  525. RWeld.Part1 = Arm
  526. else
  527. print("Error")
  528. end
  529. end
  530. end
  531.  
  532. local _Leg = function(side,tf)
  533. local Leg = nil
  534. local Weld = nil
  535. local RWeld = nil
  536. for _,S in pairs(Sides) do
  537. if side:lower() == S:lower() then
  538. for _,A in pairs(Legs) do
  539. if A.Name:lower():find(side:lower()) then
  540. Leg = A
  541. Weld = Welds.LegW[S]
  542. RWeld = RWelds.LegW[S]
  543. end
  544. end
  545. end
  546. end
  547. if Leg and Weld and RWeld then
  548. if tf then
  549. Weld.Part1 = Leg
  550. RWeld.Part1 = nil
  551. elseif not tf then
  552. Weld.Part1 = nil
  553. RWeld.Part1 = Leg
  554. else
  555. print("Error")
  556. end
  557. end
  558. end
  559.  
  560. local _Head = function(tf)
  561. local Head = nil
  562. local Weld = nil
  563. local RWeld = nil
  564. Head = Character["Head"]
  565. Weld = Welds.HeadW.Middle
  566. RWeld = RWelds.HeadW.Middle
  567. if Head and Weld and RWeld then
  568. if tf then
  569. Weld.Part1 = Head
  570. RWeld.Part1 = nil
  571. elseif not tf then
  572. Weld.Part1 = nil
  573. RWeld.Part1 = Head
  574. else
  575. print("Error")
  576. end
  577. end
  578. end
  579.  
  580. pcall(function()
  581. Character.Animate.Disabled = true
  582. end)
  583. if Humanoid then
  584. Humanoid.PlatformStand = true
  585. end
  586. pcall(function()
  587. Torso.Velocity = Variables.Momentum
  588. end)
  589.  
  590. local Rotate = Instance.new("BodyGyro",Torso)
  591. Rotate.P = 10^6
  592. Rotate.maxTorque = Vector3.new(Rotate.P,Rotate.P,Rotate.P)
  593. Rotate.cframe = Torso.CFrame
  594.  
  595. local Move = Instance.new("BodyPosition",Torso)
  596. Move.maxForce = Vector3.new(1,1,1)*(10^6)
  597. Move.position = Torso.CFrame.p
  598.  
  599. local function LaserBeam()
  600. UpdateAnim = false
  601. CurrentAnimation = "DisableHandAnim"
  602. rofTop = 6
  603. for i=0,1,0.1 do
  604. RA.C0 = AnimLerp(CurrentRightArm, RAD * CFrame.Angles(math.rad(75),0,math.rad(-20)), i)
  605. LA.C0 = AnimLerp(CurrentLeftArm, LAD * CFrame.Angles(math.rad(75),0,math.rad(20)), i)
  606. wait()
  607. end
  608.  
  609. ChargeBar.Visible = true;
  610.  
  611. local Charge = 0
  612. local Downt = _Part(Main,false,true,0,0,"Neon",ColorGlobe,{1,1,1},"Sphere",{1,1,1})
  613. local Effect = Instance.new("ParticleEmitter", Downt)
  614. Effect.Texture = "rbxassetid://283631720"
  615. Effect.VelocitySpread = 0
  616. Effect.Acceleration = Vector3.new(0,0,0)
  617. Effect.Color = ColorSequence.new(Downt.BrickColor.Color,Downt.BrickColor.Color)
  618. Effect.Speed = NumberRange.new(0)
  619. Effect.Lifetime = NumberRange.new(1,1)
  620. Effect.Rate = 60
  621. Effect.Transparency = NumberSequence.new(0.5,0.8)
  622. Effect.Rotation = NumberRange.new(1,2)
  623.  
  624. while BeamHeld do
  625. Charge = Charge + 1
  626. CurrentEnergy = CurrentEnergy - 1.5
  627. Downt.Mesh.Scale = Downt.Mesh.Scale + Vector3.new(0.02,0.02,0.02)
  628. Downt.CFrame = RootPart.CFrame + (RootPart.CFrame.lookVector * 4)
  629. Effect.Size = NumberSequence.new(Downt.Mesh.Scale.X)
  630. ChargeFill.Size = UDim2.new(Charge/100,-5,1,-5)
  631. wait()
  632. if Charge >= 100 or CurrentEnergy <= 0 then
  633. CurrentEnergy = CurrentEnergy <= 0 and 0 or CurrentEnergy
  634. break
  635. end
  636. end
  637.  
  638. Downt.Anchored = false
  639. Downt.Size = Downt.Mesh.Scale
  640. Downt.Mesh.Scale = Vector3.new(1,1,1)
  641.  
  642. local Velocity = Instance.new("BodyVelocity", Downt)
  643. Velocity.maxForce = Vector3.new(1e7,1e7,1e7)
  644. Velocity.P = 1e7
  645. Velocity.Velocity = (Mouse.Hit.p - Downt.CFrame.p)
  646. --[[
  647. --CurrentEnergy = CurrentEnergy <= 0 and 0 or CurrentEnergy - (1.5*Charge)
  648. local Face = Torso.CFrame.lookVector
  649. local Ray = Ray.new(Downt.CFrame.p, (Mouse.Hit.p - Downt.CFrame.p).unit*750)
  650. local Object,Pos = game:GetService("Workspace"):findPartOnRay(Ray, Character)
  651. local Distance = (Pos - Downt.CFrame.p).magnitude
  652. local DrawRay = _Part(Main,false,true,0,0,"Neon",ColorGlobe,{1,1,1},"Cylinder",{Distance,Downt.Mesh.Scale.X,Downt.Mesh.Scale.X})
  653. DrawRay.CFrame = CFrame.new(Pos, Downt.CFrame.p) * CFrame.new(0,0,-Distance/2) * CFrame.Angles(0,math.rad(270),0)
  654.  
  655. local ExplodePart = _Part(Main,false,true,0,0,"Neon",ColorGlobe,{1,1,1},"Sphere",{1,1,1})
  656. ExplodePart.CFrame = CFrame.new(Pos.X,Pos.Y,Pos.Z)
  657.  
  658. local Ignore = {}
  659.  
  660. ExplodePart.Touched:connect(function(Object)
  661. if Object.Parent and Object.Parent:IsA("Model") then
  662. local Model = Object.Parent
  663. if Model:findFirstChild("Humanoid") and not Ignore[Model.Name] and Model.Name ~= Character.Name then
  664. Ignore[Model.Name] = true;
  665. local Humanoid = Model:findFirstChild("Humanoid")
  666. Humanoid:TakeDamage(0.75*Charge)
  667. end
  668. end
  669. end)
  670.  
  671. for i=0,1,0.1 do
  672. wait()
  673. DrawRay.Transparency = i
  674. Downt.Transparency = i
  675. ExplodePart.Size = ExplodePart.Size + Vector3.new(0.04*Charge,0.04*Charge,0.04*Charge)
  676. ExplodePart.CFrame = CFrame.new(Pos.X,Pos.Y,Pos.Z)
  677. ExplodePart.Transparency = i
  678. end
  679. Effect:Destroy()
  680. game:GetService("Debris"):AddItem(DrawRay, 1)
  681. game:GetService("Debris"):AddItem(ExplodePart, 1)]]
  682. game:GetService("Debris"):AddItem(Downt, 10)
  683. UpdateAnim = true
  684. ChargeBar.Visible = false
  685. LastBeam = tick()
  686. end
  687.  
  688. local function AbsoluteDefence()
  689. UpdateAnim = false
  690.  
  691. while AbsDefHeld do
  692.  
  693. wait()
  694. end
  695.  
  696.  
  697. UpdateAnim = true
  698. end
  699.  
  700. local function ThrowBlades()
  701. --[[local Thrown = {}
  702. for i,Bit in pairs(Bits) do
  703. if Bit.Type == "Top" then
  704. table.insert(Thrown, {Side = Bit.Side; Weld = Bit.Weld; Series = Bit.Series; Type = Bit.Type})
  705. table.remove(Bits, i)
  706. end
  707. end
  708. ]]-- *Construction*
  709. end
  710.  
  711. Mouse.KeyDown:connect(function(Key)
  712. if Key == "w" then
  713. Front = true
  714. end
  715. if Key == "a" then
  716. Left = true
  717. end
  718. if Key == "s" then
  719. Back = true
  720. end
  721. if Key == "q" then
  722. BoostHeld = not BoostHeld
  723. if BoostHeld then
  724. Accel = 3
  725. else
  726. Accel = 1
  727. end
  728. end
  729. if Key == "d" then
  730. Right = true
  731. end
  732. if Key:byte() == 50 then
  733. if MobilityType == "Float" then
  734. MobilityType = "Fly"
  735. elseif MobilityType == "Fly" then
  736. MobilityType = "Ground"
  737. elseif MobilityType == "Ground" then
  738. MobilityType = "Float"
  739. end
  740. end
  741. if Key == "h" then
  742. if CurrentEnergy <= 0 then
  743. return
  744. end
  745. AbsDefHeld = true
  746. AbsoluteDefence()
  747. end
  748. if Key == "f" then
  749. if CurrentEnergy <= 0 or tick()-LastBeam <= 1 then
  750. return
  751. end
  752. BeamHeld = true
  753. LaserBeam()
  754. end
  755. if Key == "q" then
  756. ThrowBlades()
  757. end
  758. while BoostHeld do
  759. wait()
  760. CurrentEnergy = CurrentEnergy <= 0 and 0 or CurrentEnergy - 0.5
  761. if CurrentEnergy <= 0 then
  762. break
  763. end
  764. end
  765. if Key == "g" then
  766. ChargeHeld = true
  767. UpdateAnim = false
  768. CurrentAnimation = "DisableHandAnim"
  769. rofTop = 15
  770. for i=0,1,0.1 do
  771. wait()
  772. AnchorPart.Weld.C1 = AnimLerp(AnchorPart.Weld.C1, CFrame.new(0,3,0), i)
  773. AnchorPart2.Weld.C1 = AnimLerp(AnchorPart2.Weld.C1, CFrame.new(0,3,0), i)
  774. RA.C0 = AnimLerp(RA.C0, RAD * CFrame.Angles(math.rad(160),0,math.rad(10)), i)
  775. LA.C0 = AnimLerp(LA.C0, LAD * CFrame.Angles(math.rad(160),0,math.rad(-10)), i)
  776. end
  777.  
  778. while ChargeHeld do
  779. wait()
  780. local NRG = _Part(Main,false,true,0,0,"SmoothPlastic",ColorGlobe,{0.2,0.2,0.2},"Sphere",{1,1,1})
  781. NRG.CFrame = AnchorPart.CFrame * CFrame.new(math.random(-2.5,2.5),math.random(-2.5,2.5),math.random(-2.5,2.5))
  782. local NRGB = _Part(Main,false,true,0,0,"SmoothPlastic",ColorGlobe,{0.2,0.2,0.2},"Sphere",{1,1,1})
  783. NRGB.CFrame = AnchorPart2.CFrame * CFrame.new(math.random(-2.5,2.5),math.random(-2.5,2.5),math.random(-2.5,2.5))
  784. table.insert(Energy, NRG)
  785. table.insert(Energy, NRGB)
  786. for i,nrg in pairs(Energy) do
  787. nrg.Transparency = nrg.Transparency + 0.05
  788. nrg.Mesh.Scale = nrg.Mesh.Scale + Vector3.new(0.1,0.1,0.1)
  789. nrg.CFrame = CFrame.new(nrg.CFrame.p, AnchorPart.CFrame.p) * CFrame.Angles(0,0,-math.pi/2)
  790. if nrg.Transparency >= 1 then
  791. table.remove(Energy, i)
  792. nrg:Destroy()
  793. end
  794. end
  795. CurrentEnergy = CurrentEnergy >= TotalEnergy and TotalEnergy or CurrentEnergy + 10
  796. end
  797.  
  798. for i=0,1,0.1 do
  799. wait()
  800. AnchorPart.Weld.C1 = AnimLerp(AnchorPart.Weld.C1, CFrame.new(0,1.5,0), i)
  801. AnchorPart2.Weld.C1 = AnimLerp(AnchorPart2.Weld.C1, CFrame.new(0,1.5,0), i)
  802. for x,nrg in pairs(Energy) do
  803. nrg.Transparency = nrg.Transparency + 0.15
  804. nrg.Mesh.Scale = nrg.Mesh.Scale + Vector3.new(0.2,0.2,0.2)
  805. nrg.CFrame = CFrame.new(nrg.CFrame.p, AnchorPart.CFrame.p) * CFrame.Angles(0,0,-math.pi/2)
  806. if nrg.Transparency >= 1 then
  807. table.remove(Energy, x)
  808. nrg:Destroy()
  809. end
  810. end
  811. end
  812. UpdateAnim = true
  813. end
  814. end)
  815.  
  816. Mouse.KeyUp:connect(function(Key)
  817. if Key == "w" then
  818. Front = false
  819. end
  820. if Key == "a" then
  821. Left = false
  822. end
  823. if Key == "s" then
  824. Back = false
  825. end
  826. if Key == "d" then
  827. Right = false
  828. end
  829. if Key == "f" then
  830. BeamHeld = false
  831. end
  832. if Key == "h" then
  833. AbsDefHeld = false
  834. end
  835. if Key == "g" then
  836. ChargeHeld = false
  837. end
  838. if Key == "0" then
  839. BoostHeld = false
  840. end
  841. end)
  842.  
  843. _Arm("Left", true)
  844. _Arm("Right", true)
  845. _Leg("Left", true)
  846. _Leg("Right", true)
  847. _Head(true)
  848.  
  849. game:GetService("RunService").Stepped:connect(function()
  850. EnergyFill.Size = UDim2.new(CurrentEnergy/TotalEnergy,-5,1,-5)
  851. RateTop = RateTop + rofTop
  852. if RateTop >= 360 then
  853. RateTop = 1
  854. end
  855.  
  856. RateBot = RateBot + rofBot
  857. if RateBot >= 360 then
  858. RateBot = 1
  859. end
  860.  
  861.  
  862. if AddSub == false then
  863. CurrentFrame = CurrentFrame + 0.01
  864. if CurrentFrame >= 1 then
  865. AddSub = true
  866. end
  867. elseif AddSub == true then
  868. CurrentFrame = CurrentFrame - 0.01
  869. if CurrentFrame <= 0 then
  870. AddSub = false
  871. end
  872. end
  873.  
  874. DiscSpin = DiscSpin + 0.1
  875. for _,Disc in pairs(Discs) do
  876. Disc.Weld.C0 = CFrame.Angles(0,math.rad(90),DiscSpin)
  877. end
  878.  
  879. if ExtendGrowthTop == false and CurrentAnimation == "Idle" then
  880. ExtendTop = ExtendTop + 1/2
  881. if ExtendTop >= 25 then
  882. ExtendGrowthTop = true
  883. end
  884. elseif ExtendGrowthTop == true and CurrentAnimation == "Idle" then
  885. ExtendTop = ExtendTop - 1/2
  886. if ExtendTop <= -10 then
  887. ExtendGrowthTop = false
  888. end
  889. elseif CurrentAnimation == "Forward" or CurrentAnimation == "Backward" or CurrentAnimation == "SwivelRight" or CurrentAnimation == "SwivelLeft" then
  890. ExtendTop = ExtendTop >= 40 and 40 or ExtendTop + 2
  891. elseif CurrentAnimation == "DisableHandAnim" then
  892. ExtendTop = ExtendTop >= 50 and 50 or ExtendTop + 2
  893. end
  894.  
  895. if ExtendGrowthBot == false and (CurrentAnimation == "Idle" or CurrentAnimation == "DisableHandAnim") then
  896. ExtendBot = ExtendBot + 1/2
  897. if ExtendBot >= 25 then
  898. ExtendGrowthBot = true
  899. end
  900. elseif ExtendGrowthBot == true and (CurrentAnimation == "Idle" or CurrentAnimation == "DisableHandAnim") then
  901. ExtendBot = ExtendBot - 1/2
  902. if ExtendBot <= -10 then
  903. ExtendGrowthBot = false
  904. end
  905. elseif CurrentAnimation == "Forward" or CurrentAnimation == "Backward" or CurrentAnimation == "SwivelRight" or CurrentAnimation == "SwivelLeft" then
  906. ExtendBot = ExtendBot >= 40 and 40 or ExtendBot + 2
  907. end
  908.  
  909. if Front and not Back then
  910. xmove = 3
  911. if UpdateAnim then
  912. CurrentAnimation = "Forward"
  913. end
  914. elseif Back and not Front then
  915. xmove = -3
  916. if UpdateAnim then
  917. CurrentAnimation = "Backward"
  918. end
  919. else
  920. xmove = 0
  921. if UpdateAnim then
  922. CurrentAnimation = "Idle"
  923. end
  924. end
  925.  
  926. if Left and not Right then
  927. if xmove == 0 and UpdateAnim then
  928. CurrentAnimation = "SwivelLeft"
  929. end
  930. ymove = 3
  931. elseif Right and not Left then
  932. if xmove == 0 and UpdateAnim then
  933. CurrentAnimation = "SwivelRight"
  934. end
  935. ymove = -3
  936. else
  937. ymove = 0
  938. if xmove == 0 and UpdateAnim then
  939. CurrentAnimation = "Idle"
  940. end
  941. end
  942.  
  943. if LastAnimation ~= CurrentAnimation then
  944. CurrentFrame = 0
  945. AddSub = false
  946. end
  947.  
  948. for _,Info in pairs(Bits) do
  949. local Side = Info.Side
  950. local Series = Info.Series
  951. local Weld = Info.Weld
  952. local Type = Info.Type
  953. local Extend = 1
  954. local MyRate = 1
  955.  
  956. if Type == "Top" then
  957. Extend = ExtendTop
  958. MyRate = RateTop + 30
  959. elseif Type == "Bot" then
  960. Extend = ExtendBot
  961. MyRate = RateBot
  962. else
  963.  
  964. end
  965.  
  966. if CurrentAnimation == "Idle" or CurrentAnimation == "DisableHandAnim" then
  967. if Type == "Wing" or Type == "WingLow" then
  968. if Type == "WingLow" then
  969. Weld.C1 = AnimLerp(Weld.C1, CFrame.new(Side == true and -0.5 or 0.5,1.65,0.5) * CFrame.Angles(math.rad(65 + Lift*3),math.rad((Side == true and 30 + Lift*2 or -30 - Lift*2)),0), CurrentFrame)
  970. else
  971. Weld.C1 = AnimLerp(Weld.C1, CFrame.new(0,1.8,0.5) * CFrame.Angles(math.rad(65 + Lift*3),math.rad((Side == true and 30 + Lift*2 or -30 - Lift*2)),0), CurrentFrame)
  972. end
  973. else
  974. Weld.C1 = CFrame.new(0,0,Spread) * CFrame.Angles(math.rad(-Extend),math.rad(60*Series + (Side == true and -MyRate or MyRate)),0) * CFrame.new(0,Distance,0)
  975. end
  976. elseif CurrentAnimation == "Forward" or CurrentAnimation == "Backward" then
  977. if Type == "Wing" or Type == "WingLow" then
  978. if Type == "WingLow" then
  979. Weld.C1 = AnimLerp(Weld.C1, CFrame.new(Side == true and -0.5 or 0.5,1.65,0.5) * CFrame.Angles(math.rad(65 + Lift*10),math.rad((Side == true and 30 + Lift*2 or -30 - Lift*2)),0), CurrentFrame)
  980. else
  981. Weld.C1 = AnimLerp(Weld.C1, CFrame.new(0,1.8,0.5) * CFrame.Angles(math.rad(65 + Lift*10),math.rad((Side == true and 30 + Lift*2 or -30 - Lift*2)),0), CurrentFrame)
  982. end
  983. else
  984. Weld.C1 = CFrame.new(0,0,Spread) * CFrame.Angles(math.rad(-Extend),math.rad(60*Series + (Side == true and -MyRate or MyRate)),0) * CFrame.new(0,Distance,0)
  985. end
  986. elseif CurrentAnimation == "SwivelLeft" then
  987. if Type == "Wing" or Type == "WingLow" then
  988. if Type == "WingLow" then
  989. Weld.C1 = AnimLerp(Weld.C1, CFrame.new(Side == true and -0.5 or 0.5,1.65,0.5) * CFrame.Angles(math.rad(65 + Lift*3),math.rad((Side == true and 50 or -10)),0), CurrentFrame)
  990. else
  991. Weld.C1 = AnimLerp(Weld.C1, CFrame.new(0,1.8,0.5) * CFrame.Angles(math.rad(65 + Lift*3),math.rad((Side == true and 50 or -10)),0), CurrentFrame)
  992. end
  993. else
  994. Weld.C1 = CFrame.new(0,0,Spread) * CFrame.Angles(math.rad(-Extend),math.rad(60*Series + (Side == true and -MyRate or MyRate)),0) * CFrame.new(0,Distance,0)
  995. end
  996. elseif CurrentAnimation == "SwivelRight" then
  997. if Type == "Wing" or Type == "WingLow" then
  998. if Type == "WingLow" then
  999. Weld.C1 = AnimLerp(Weld.C1, CFrame.new(Side == true and -0.5 or 0.5,1.65,0.5) * CFrame.Angles(math.rad(65 + Lift*3),math.rad((Side == true and 10 or -50)),0), CurrentFrame)
  1000. else
  1001. Weld.C1 = AnimLerp(Weld.C1, CFrame.new(0,1.8,0.5) * CFrame.Angles(math.rad(65 + Lift*3),math.rad((Side == true and 10 or -50)),0), CurrentFrame)
  1002. end
  1003. else
  1004. Weld.C1 = CFrame.new(0,0,Spread) * CFrame.Angles(math.rad(-Extend),math.rad(60*Series + (Side == true and -MyRate or MyRate)),0) * CFrame.new(0,Distance,0)
  1005. end
  1006. else
  1007. Weld.C1 = CFrame.new(0,0,Spread) * CFrame.Angles(math.rad(-Extend),math.rad(60*Series + (Side == true and -MyRate or MyRate)),0) * CFrame.new(0,Distance,0)
  1008. end
  1009. end
  1010.  
  1011. TurnAngle = TurnAngle + ymove
  1012.  
  1013. Rotate.cframe = CFrame.new()*CFrame.Angles(0,math.rad(TurnAngle),0)
  1014.  
  1015. local Ray = Ray.new(Torso.CFrame.p,Down.CFrame.lookVector*15)
  1016. local Part,Pos = game:GetService("Workspace"):findPartOnRay(Ray,Character)
  1017. local Distance = (Pos - Torso.CFrame.p).magnitude
  1018. local Face = Torso.CFrame.lookVector
  1019.  
  1020. if Part and Pos then
  1021. local sides = Enum.NormalId:GetEnumItems();
  1022. local default = Vector3.new(0,1,0)
  1023. for i,v in pairs(sides) do
  1024. sides[i] = Vector3.FromNormalId(v)
  1025. end
  1026. if Part:IsA("Part") then
  1027. if Part.Shape.Name == "Ball" then
  1028. sides = {}
  1029. default = Part.CFrame:vectorToObjectSpace(Pos-Part.Position).unit
  1030. elseif Part.Shape.Name == "Cylinder" then
  1031. sides = {Vector3.new(1,0,0),Vector3.new(-1,0,0)}
  1032. default = (Part.CFrame:vectorToObjectSpace(Pos-Part.Position)*Vector3.new(0,1,1)).unit
  1033. end
  1034. elseif Part:IsA("WedgePart") then
  1035. sides = {Vector3.new(1,0,0),Vector3.new(-1,0,0),Vector3.new(0,-1,0),Vector3.new(0,0,-1)}
  1036. default = Vector3.new(0,1,-Part.Size.Y/Part.Size.Z).unit
  1037. end
  1038. local obs,siz,sidevector = Part.CFrame:pointToObjectSpace(Pos),Part.Size/2
  1039. for i,v in pairs(sides) do
  1040. if (obs*v/(siz*v+Vector3.new(1,1,1)*1e-7)):isClose(v,.01) then
  1041. sidevector = v
  1042. break
  1043. end
  1044. end
  1045. if not sidevector then sidevector = default end
  1046. if sidevector then
  1047. local cf = CFrame.new(Pos,Pos+Part.CFrame:vectorToWorldSpace(sidevector)) * CFrame.Angles(-math.pi/2,0,0)
  1048. Move.position = Vector3.new(cf.X,cf.Y + 6 + Lift,cf.Z) + Vector3.new(Face.X,0,Face.Z)*Accel*xmove
  1049. Move.maxForce = Vector3.new(1e7,1e7,1e7)
  1050. end
  1051. else
  1052. Move.maxForce = Vector3.new(1e7,0,1e7)
  1053. Move.position = Vector3.new(Torso.CFrame.X,Torso.CFrame.Y,Torso.CFrame.Z) + Vector3.new(Face.X,0,Face.Z)*Accel*xmove
  1054. end
  1055.  
  1056. CurrentLeftArm = LA.C0
  1057. CurrentRightArm = RA.C0
  1058. CurrentRightLeg = LR.C1
  1059. CurrentLeftLeg = LL.C1
  1060.  
  1061. if math.floor(Lift+0.5) == 3 then
  1062. --FlapSound:Play()
  1063. end
  1064.  
  1065. if CurrentAnimation == "Idle" then
  1066. rofTop = 1
  1067. rofBot = 1
  1068. RA.C0 = AnimLerp(CurrentRightArm, RAD * CFrame.Angles(math.rad(0),0,math.rad(25 + Lift*2)), CurrentFrame)
  1069. LA.C0 = AnimLerp(CurrentLeftArm, LAD * CFrame.Angles(math.rad(0),0,math.rad(-25 - Lift*2)), CurrentFrame)
  1070. LR.C1 = AnimLerp(CurrentRightLeg, RLD * CFrame.Angles(0,0,math.rad(-7.5 + Lift)), CurrentFrame)
  1071. LL.C1 = AnimLerp(CurrentLeftLeg, LLD * CFrame.Angles(0,0,math.rad(7.5 - Lift)), CurrentFrame)
  1072. elseif CurrentAnimation == "Forward" then
  1073. rofTop = 6
  1074. rofBot = 6
  1075. RA.C0 = AnimLerp(CurrentRightArm, RAD * CFrame.Angles(math.rad(-15),0,math.rad(30)), CurrentFrame)
  1076. LA.C0 = AnimLerp(CurrentLeftArm, LAD * CFrame.Angles(math.rad(-15),0,math.rad(-30)), CurrentFrame)
  1077. LR.C1 = AnimLerp(CurrentRightLeg, RLD * CFrame.Angles(math.rad(15),0,math.rad(-7.5)), CurrentFrame)
  1078. LL.C1 = AnimLerp(CurrentLeftLeg, LLD * CFrame.Angles(math.rad(15),0,math.rad(7.5)), CurrentFrame)
  1079. elseif CurrentAnimation == "Backward" then
  1080. rotTop = -6
  1081. rofBot = -6
  1082. RA.C0 = AnimLerp(CurrentRightArm, RAD * CFrame.Angles(math.rad(15),0,math.rad(20)), CurrentFrame)
  1083. LA.C0 = AnimLerp(CurrentLeftArm, LAD * CFrame.Angles(math.rad(15),0,math.rad(-20)), CurrentFrame)
  1084. LR.C1 = AnimLerp(CurrentRightLeg, RLD * CFrame.Angles(math.rad(-15),0,math.rad(-7.5)), CurrentFrame)
  1085. LL.C1 = AnimLerp(CurrentLeftLeg, LLD * CFrame.Angles(math.rad(-15),0,math.rad(7.5)), CurrentFrame)
  1086. elseif CurrentAnimation == "SwivelLeft" then
  1087. rofTop = 3
  1088. rofBot = 3
  1089. RA.C0 = AnimLerp(CurrentRightArm, RAD * CFrame.Angles(math.rad(15),0,math.rad(25)), CurrentFrame)
  1090. LA.C0 = AnimLerp(CurrentLeftArm, LAD * CFrame.Angles(math.rad(-15),0,math.rad(-25)), CurrentFrame)
  1091. LR.C1 = AnimLerp(CurrentRightLeg, RLD * CFrame.Angles(math.rad(-10),0,math.rad(-7.5)), CurrentFrame)
  1092. LL.C1 = AnimLerp(CurrentLeftLeg, LLD * CFrame.Angles(math.rad(10),0,math.rad(7.5)), CurrentFrame)
  1093. elseif CurrentAnimation == "SwivelRight" then
  1094. rofTop = -3
  1095. rofBot = -3
  1096. RA.C0 = AnimLerp(CurrentRightArm, RAD * CFrame.Angles(math.rad(-15),0,math.rad(25)), CurrentFrame)
  1097. LA.C0 = AnimLerp(CurrentLeftArm, LAD * CFrame.Angles(math.rad(15),0,math.rad(-25)), CurrentFrame)
  1098. LR.C1 = AnimLerp(CurrentRightLeg, RLD * CFrame.Angles(math.rad(10),0,math.rad(-7.5)), CurrentFrame)
  1099. LL.C1 = AnimLerp(CurrentLeftLeg, LLD * CFrame.Angles(math.rad(-10),0,math.rad(7.5)), CurrentFrame)
  1100. elseif CurrentAnimation == "DisableHandAnim" then
  1101. rofBot = 1
  1102. LR.C1 = AnimLerp(CurrentRightLeg, RLD * CFrame.Angles(0,0,math.rad(-7.5)), CurrentFrame)
  1103. LL.C1 = AnimLerp(CurrentLeftLeg, LLD * CFrame.Angles(0,0,math.rad(7.5)), CurrentFrame)
  1104. end
  1105.  
  1106. LastAnimation = CurrentAnimation
  1107. end)
  1108.  
  1109. while true do
  1110. for i = 0,10,0.1 do
  1111. Lift = Lift + (math.sin(math.pi*2/10*i)*0.1)
  1112. wait(0.02)
  1113. end
  1114. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement