StarzoZero

roblox fe sans attempt #7

Jan 13th, 2019
205
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 51.57 KB | None | 0 0
  1. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  2. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  3. do
  4. print("FE Compatibility code by iPxter")
  5. script.Parent = Player.Character
  6.  
  7. --RemoteEvent for communicating
  8. local Event = Instance.new("RemoteEvent")
  9. Event.Name = "UserInput_Event"
  10.  
  11. --Fake event to make stuff like Mouse.KeyDown work
  12. local function fakeEvent()
  13. local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
  14. t.connect = t.Connect
  15. return t
  16. end
  17.  
  18. --Creating fake input objects with fake variables
  19. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  20. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  21. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  22. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  23. end}
  24. --Merged 2 functions into one by checking amount of arguments
  25. CAS.UnbindAction = CAS.BindAction
  26.  
  27. --This function will trigger the events that have been :Connect()'ed
  28. local function te(self,ev,...)
  29. local t = m[ev]
  30. if t and t._fakeEvent and t.Function then
  31. t.Function(...)
  32. end
  33. end
  34. m.TrigEvent = te
  35. UIS.TrigEvent = te
  36.  
  37. Event.OnServerEvent:Connect(function(plr,io)
  38. if plr~=Player then return end
  39. if io.isMouse then
  40. m.Target = io.Target
  41. m.Hit = io.Hit
  42. else
  43. local b = io.UserInputState == Enum.UserInputState.Begin
  44. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  45. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  46. end
  47. for _,t in pairs(CAS.Actions) do
  48. for _,k in pairs(t.Keys) do
  49. if k==io.KeyCode then
  50. t.Function(t.Name,io.UserInputState,io)
  51. end
  52. end
  53. end
  54. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  55. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  56. end
  57. end)
  58. Event.Parent = NLS([==[
  59. local Player = game:GetService("Players").LocalPlayer
  60. local Event = script:WaitForChild("UserInput_Event")
  61.  
  62. local UIS = game:GetService("UserInputService")
  63. local input = function(io,a)
  64. if a then return end
  65. --Since InputObject is a client-side instance, we create and pass table instead
  66. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
  67. end
  68. UIS.InputBegan:Connect(input)
  69. UIS.InputEnded:Connect(input)
  70.  
  71. local Mouse = Player:GetMouse()
  72. local h,t
  73. --Give the server mouse data 30 times every second, but only if the values changed
  74. --If player is not moving their mouse, client won't fire events
  75. while wait(1/30) do
  76. if h~=Mouse.Hit or t~=Mouse.Target then
  77. h,t=Mouse.Hit,Mouse.Target
  78. Event:FireServer({isMouse=true,Target=t,Hit=h})
  79. end
  80. end]==],Player.Character)
  81. Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
  82. end
  83.  
  84. -- BurnLegion strikes again!
  85. -- wongxd, this is why you DON'T goto Voidacity's
  86. -- SLPM has been absent, so I've taken it upon myself to make something
  87.  
  88. --------------------------------------------------------
  89.  
  90. pls = game:GetService'Players'
  91. rs = game:GetService'RunService'
  92. uinps = game:GetService'UserInputService'
  93. lp = owner
  94. c = lp.Character
  95. human = c.Humanoid
  96. human.MaxHealth = 50
  97. wait()
  98. human.Health = 50
  99. c.Health:Destroy()
  100.  
  101. --------------------------------------------------------
  102.  
  103. Debounces = {
  104. AnimationCycles = 0;
  105. FPS = 0;
  106. scalingDamage = false;
  107. damageLevel = 0;
  108. attackNumber = 0;
  109. isAttacking = false;
  110. isMoving = false;
  111. isSprinting = false;
  112. isBoosting = false;
  113. isPassive = false;
  114. isTyping = false;
  115. }
  116.  
  117. --------------------------------------------------------
  118.  
  119. numLerp = function(start, goal, alpha)
  120. return(((goal - start) * alpha) + start)
  121. end
  122.  
  123. CFrameZero = function()
  124. return CFrame.new(Vector3.new())
  125. end
  126.  
  127. rad = function(value)
  128. return math.rad(value)
  129. end
  130.  
  131. CFAngles = function(Vector)
  132. return CFrame.Angles(rad(Vector.x),rad(Vector.y),rad(Vector.z))
  133. end
  134.  
  135. --------------------------------------------------------
  136.  
  137. AnimStat = {
  138. lerpSpeed = .2;
  139. lerpSpeed2 = .35;
  140. lerpTween = 0;
  141. }
  142.  
  143. Joints = {
  144. c.HumanoidRootPart.RootJoint;
  145. c.Torso.Neck;
  146. c.Torso['Left Shoulder'];
  147. c.Torso['Right Shoulder'];
  148. c.Torso['Left Hip'];
  149. c.Torso['Right Hip'];
  150. }
  151.  
  152. JointTargets = {
  153. CFrameZero();
  154. CFrameZero();
  155. CFrameZero();
  156. CFrameZero();
  157. CFrameZero();
  158. CFrameZero();
  159. }
  160.  
  161. --------------------------------------------------------
  162.  
  163. BodyColors = {
  164. HeadColor = BrickColor.new("Institutional white");
  165. LeftArmColor = BrickColor.new("Institutional white");
  166. RightArmColor = BrickColor.new("Institutional white");
  167. LeftLegColor = BrickColor.new("Institutional white");
  168. RightLegColor = BrickColor.new("Institutional white");
  169. TorsoColor = BrickColor.new("Mid gray");
  170. }
  171.  
  172. Customs = {
  173. Face = "http://www.roblox.com/asset/?id=8560915";
  174. Shirt = "http://www.roblox.com/asset/?id=334781688";
  175. Pants = "http://www.roblox.com/asset/?id=335237283";
  176. }
  177.  
  178. --------------------------------------------------------
  179.  
  180. prepareCharacter = function()
  181. local transPoints = {
  182. NumberSequenceKeypoint.new(0,.819,.0375),
  183. NumberSequenceKeypoint.new(.207,.594,.0187),
  184. NumberSequenceKeypoint.new(.4,.55,.031),
  185. NumberSequenceKeypoint.new(.57,.619,.05),
  186. NumberSequenceKeypoint.new(.76,.8,.0375),
  187. NumberSequenceKeypoint.new(1,1,0),
  188. }
  189. local sizePoints = {
  190. NumberSequenceKeypoint.new(0,.687,0),
  191. NumberSequenceKeypoint.new(.111,.875,0),
  192. NumberSequenceKeypoint.new(.327,1.19,0),
  193. NumberSequenceKeypoint.new(.646,1.56,0),
  194. NumberSequenceKeypoint.new(.805,1.37,0),
  195. NumberSequenceKeypoint.new(.905,1.06,0),
  196. NumberSequenceKeypoint.new(.968,.938,0),
  197. NumberSequenceKeypoint.new(.984,1.13,0),
  198. NumberSequenceKeypoint.new(1,1.62,0),
  199. }
  200. local Size = NumberSequence.new(sizePoints)
  201. local Transparency = NumberSequence.new(transPoints)
  202. rayModel = Instance.new("Model",c)
  203. efxBlock = Instance.new("Part",c)
  204. efxBlock.BrickColor = BrickColor.new("Cyan")
  205. efxBlock.Material = "Neon"
  206. efxBlock.FormFactor = "Custom"
  207. efxBlock.Transparency = .3
  208. efxBlock.Size = Vector3.new(.3,.3,.3)
  209. local mesh = Instance.new("SpecialMesh",efxBlock)
  210. mesh.MeshType = Enum.MeshType.Sphere
  211. mesh.Scale = Vector3.new(1,1,1)
  212. light = Instance.new("PointLight",c.Head)
  213. light.Range = 10
  214. light.Color = Color3.new(0,200/255,1)
  215. light.Shadows = false
  216. local particles = Instance.new("ParticleEmitter",efxBlock)
  217. particles.Color = ColorSequence.new(Color3.new(0,0,225/255),Color3.new(20/255,190/255,205/255))
  218. particles.LightEmission = .95
  219. particles.Size = Size
  220. particles.Name = "Fire"
  221. particles.Transparency = Transparency
  222. particles.LockedToPart = true
  223. particles.VelocityInheritance = .5
  224. particles.LockedToPart = true
  225. particles.Rate = 70
  226. particles.Texture = "rbxassetid://56561915"
  227. particles.Lifetime = NumberRange.new(2,2)
  228. particles.RotSpeed = NumberRange.new(100,100)
  229. particles.Speed = NumberRange.new(7,7)
  230. script.Parent = efxBlock
  231. fire = particles
  232. local offset = Vector3.new(-0.11, .23, -0.5)
  233. local weld = Instance.new("Weld",c.Head)
  234. weld.Part0 = c.Head
  235. weld.Part1 = efxBlock
  236. weld.C0 = CFrame.new(offset) * CFrame.Angles(math.rad(-40),math.rad(10),math.rad(40))
  237. efxBlock.Parent = c
  238. local music = Instance.new("Sound",c)
  239. music.SoundId = "rbxassetid://316012176"
  240. music.Looped = true
  241. music.Volume = 0
  242. fight = music
  243. local music2 = Instance.new("Sound",c)
  244. music2.SoundId = "rbxassetid://316014309"
  245. music2.Looped = true
  246. music2.Volume = 0
  247. sans = music2
  248. pointGyro = Instance.new("BodyGyro",c.HumanoidRootPart)
  249. pointGyro.P = 1e7
  250. pointGyro.D = 1e3
  251. pointGyro.MaxTorque = Vector3.new(0,1e7,0)
  252. animator = c.Humanoid:FindFirstChild("Animator")
  253. if animator then
  254. animator:Destroy()
  255. end
  256. c.Torso.roblox:Destroy()
  257. for i,v in pairs (c.Head:children()) do
  258. if v.ClassName == "Sound" then
  259. v:Destroy()
  260. end
  261. end
  262. for i = 1,#Joints do
  263. Joints[i].C1 = CFrame.new(Vector3.new())
  264. end
  265. human.WalkSpeed = 0
  266. human.JumpPower = 0
  267. end
  268.  
  269. uinps.InputBegan:connect(function(InputObject)
  270. if InputObject.KeyCode == Enum.KeyCode.K and Debounces.isTyping == false then
  271. Debounces.isPassive = not Debounces.isPassive
  272. end
  273. end)
  274.  
  275. setJointCFrames = function(table)
  276. for i = 1,#table do
  277. JointTargets[i] = table[i]
  278. end
  279. AnimationCycles = 0
  280. end
  281.  
  282. setLerp = function(speed)
  283. AnimStat.lerpSpeed = speed
  284. end
  285.  
  286. setTween = function(tween)
  287. AnimStat.lerpTween = tween
  288. end
  289.  
  290. takeDamage = function(position,damage,distance,platformStand)
  291. for i,v in pairs (pls:children()) do
  292. if v.ClassName == "Player" and v:FindFirstChild("Character") then
  293. local torso = v.Character:FindFirstChild("Torso")
  294. if torso and (torso.Position - position).magnitude < distance then
  295. v.Character.Humanoid:TakeDamage(damage)
  296. if platformStand == true then
  297. v.Character.PlatformStand = platformStand
  298. end
  299. end
  300. end
  301. end
  302. end
  303.  
  304. --------------------------------------------------------
  305.  
  306. prepareCharacter()
  307.  
  308. --------------------------------------------------------
  309.  
  310. spawn(function()
  311. local sine = 0
  312. while wait() do
  313. pointGyro.CFrame = CFrame.new(Vector3.new(),(mouse.Hit.p - c.HumanoidRootPart.CFrame.p).unit * 100)
  314. if Debounces.isAttacking == false and Debounces.isMoving == false and Debounces.isBoosting == false then
  315. setLerp(.1)
  316. if Debounces.isPassive == true then
  317. setJointCFrames({
  318. CFrame.new(Vector3.new(0, -0.901 + math.sin(tick() * 1.5)/45, 0)) * CFAngles(Vector3.new(-22.001, 0, 0));
  319. CFrame.new(Vector3.new(-0.001, 1.52 + math.sin(tick() * -1.5)/35, math.sin(tick() * 1.5)/35)) * CFAngles(Vector3.new(-10.861 + math.sin((-tick() + 2) * 1.5) * 5, 13.765, -1.658));
  320. CFrame.new(Vector3.new(-1.5, -0.1 + math.sin(tick() * 1.5)/15, -0.801)) * CFAngles(Vector3.new(44.999, 0, 0));
  321. CFrame.new(Vector3.new(1.7, 0.2 + math.sin(tick() * 1.5)/15, 0.199)) * CFAngles(Vector3.new(-15.001, -15.001, 15));
  322. CFrame.new(Vector3.new(-0.7, -1.8, 0.6)) * CFAngles(Vector3.new(-59.511, 3.84, 0.489));
  323. CFrame.new(Vector3.new(0.5, -1, -0.801)) * CFAngles(Vector3.new(14.999, -15, -0.001));
  324. })
  325. else
  326. setJointCFrames({
  327. CFrame.new(Vector3.new(0, 0 + math.sin(tick() * 1.5)/25, 0)) * CFAngles(Vector3.new(0, 0, 0));
  328. CFrame.new(Vector3.new(0, 1.5 + math.sin(tick() * -1.5)/35, math.sin(tick() * 1.5)/35)) * CFAngles(Vector3.new(1.554 + math.sin((-tick() + 2) * 1.5) * 5, -0.001, -0.001));
  329. CFrame.new(Vector3.new(-1.06, -0.03 + math.sin(tick() * 1.5)/25, 0.449)) * CFAngles(Vector3.new(-29.511, 0, 29.51));
  330. CFrame.new(Vector3.new(1.059, -0.031 + math.sin(tick() * 1.5)/25, 0.449)) * CFAngles(Vector3.new(-29.511, -3.842, -29.511));
  331. CFrame.new(Vector3.new(-0.49, -2, -0.05/1.5)) * CFAngles(Vector3.new(0, 8.885, 0));
  332. CFrame.new(Vector3.new(0.49, -2, -0.05/1.5)) * CFAngles(Vector3.new(-0.001, -8.886, 0));
  333. })
  334. end
  335. elseif Debounces.isAttacking == false and Debounces.isMoving == true and Debounces.isBoosting == false then
  336. sine = sine + math.rad(12)
  337. human.WalkSpeed = 15
  338. setLerp(.15)
  339. setJointCFrames({
  340. CFrame.new(Vector3.new(0, 0, 0)) * CFAngles(Vector3.new(0, math.sin(sine) * -2.5, 0));
  341. CFrame.new(Vector3.new(0, 1.499, -0.04)) * CFAngles(Vector3.new(-5.676, -0.001 - math.sin(sine) * 3, -0.001));
  342. CFrame.new(Vector3.new(-1.97, 0 + math.sin(sine + .5)/20, 0.1 + math.sin(-sine)/2)/1.3) * CFAngles(Vector3.new(-5 + math.sin(sine) * 23, 0, 0));
  343. CFrame.new(Vector3.new(1.97, 0 - math.sin(sine + .5)/20, 0.1 + math.sin(sine)/2)/1.3) * CFAngles(Vector3.new(-5 + math.sin(-sine) * 23, 0, 0));
  344. CFrame.new(Vector3.new(-0.5, -1.93 - math.cos(sine)/8.7, 0.2 + math.sin(sine)/2)) * CFAngles(Vector3.new(-15 + math.sin(-sine) * 30, 0, 0));
  345. CFrame.new(Vector3.new(0.5, -1.93 + math.cos(sine)/8.7, 0.2 + math.sin(-sine)/2)) * CFAngles(Vector3.new(-15 + math.sin(sine) * 30, 0, 0));
  346. })
  347. end
  348. if Debounces.scalingDamage == true then
  349. takeDamage(c.HumanoidRootPart.Position,Debounces.damageLevel,8,true)
  350. end
  351. end
  352. end)
  353.  
  354. human.Changed:connect(function(prop)
  355. if prop == "MoveDirection" then
  356. if human.MoveDirection.magnitude > .02 then
  357. Debounces.isMoving = true
  358. else
  359. Debounces.isMoving = false
  360. end
  361. end
  362. end)
  363.  
  364. uinps.InputBegan:connect(function(InputObject)
  365. if InputObject.KeyCode == Enum.KeyCode.A and Debounces.isAttacking == false and Debounces.isSprinting == true and Debounces.isBoosting == false and Debounces.isPassive == true and Debounces.isTyping == false then
  366. Debounces.isBoosting = true
  367. Debounces.damageLevel = 10
  368. Debounces.scalingDamage = true
  369. local vel = Instance.new("BodyVelocity",c.HumanoidRootPart)
  370. setLerp(.15)
  371. setJointCFrames({
  372. CFrame.new(Vector3.new(0, -0.901, 0)) * CFAngles(Vector3.new(-22.001, 0, 20));
  373. CFrame.new(Vector3.new(-0.001, 1.52, 0)) * CFAngles(Vector3.new(-10.372, 28.758, -1.837));
  374. CFrame.new(Vector3.new(-0.7, -0.2, -0.801)) * CFAngles(Vector3.new(45, 0, 45));
  375. CFrame.new(Vector3.new(1.7, 0.2, 0.199)) * CFAngles(Vector3.new(-15.001, -15.001, 45));
  376. CFrame.new(Vector3.new(-0.3, -2, 0.2)) * CFAngles(Vector3.new(-11.283, -17.801, 19.495));
  377. CFrame.new(Vector3.new(0.9, -2, -0.201)) * CFAngles(Vector3.new(15, -15, 29.999));
  378. })
  379. local boostSpeed = 250
  380. local efx = Instance.new("Sound",c.Head)
  381. efx.SoundId = "rbxassetid://200632875"
  382. efx.Pitch = math.random(1100,1300)/1000
  383. efx.Volume = .5
  384. efx:Play()
  385. spawn(function()
  386. wait(5)
  387. efx:Destroy()
  388. end)
  389. vel.Velocity = (c.HumanoidRootPart.Position - c.HumanoidRootPart.CFrame:toWorldSpace(CFrame.new(1,0,0)).p).unit * boostSpeed
  390. vel.P = 1e3
  391. vel.MaxForce = Vector3.new(math.huge,0,math.huge)
  392. wait(.15)
  393. vel.P = 1000
  394. vel.MaxForce = Vector3.new(3000,0,3000)
  395. vel.Velocity = Vector3.new()
  396. wait(.3)
  397. setLerp(.3)
  398. setJointCFrames({
  399. CFrame.new(Vector3.new(0, -0.901, 0)) * CFAngles(Vector3.new(-22.001, 0, 13));
  400. CFrame.new(Vector3.new(-0.001, 1.52, 0)) * CFAngles(Vector3.new(-30.239, 42.47, 11.879));
  401. CFrame.new(Vector3.new(-1.9, -0.2, -0.401)) * CFAngles(Vector3.new(44.999, 0, -45));
  402. CFrame.new(Vector3.new(1.5, 0.4, 0.599)) * CFAngles(Vector3.new(-62.058, -21.088, -15.383));
  403. CFrame.new(Vector3.new(-0.7, -1.8, 0.6)) * CFAngles(Vector3.new(-59.239, -26.158, -14.457));
  404. CFrame.new(Vector3.new(0.5, -1, -0.801)) * CFAngles(Vector3.new(-0.505, -14.478, -18.968));
  405. })
  406. wait(.2)
  407. vel:Destroy()
  408. Debounces.damageLevel = 0
  409. Debounces.scalingDamage = false
  410. Debounces.isBoosting = false
  411. end
  412. end)
  413.  
  414. uinps.InputBegan:connect(function(InputObject)
  415. if InputObject.KeyCode == Enum.KeyCode.D and Debounces.isAttacking == false and Debounces.isSprinting == true and Debounces.isBoosting == false and Debounces.isPassive == true and Debounces.isTyping == false then
  416. Debounces.isBoosting = true
  417. Debounces.damageLevel = 10
  418. Debounces.scalingDamage = true
  419. local vel = Instance.new("BodyVelocity",c.HumanoidRootPart)
  420. setLerp(.15)
  421. setJointCFrames({
  422. CFrame.new(Vector3.new(0, -0.901, 0)) * CFAngles(Vector3.new(-22.001, 0, -15));
  423. CFrame.new(Vector3.new(-0.001, 1.52, 0)) * CFAngles(Vector3.new(-13.603, -45.662, -6.645));
  424. CFrame.new(Vector3.new(-1.9, 0, -0.201)) * CFAngles(Vector3.new(31.935, -7.436, -60.853));
  425. CFrame.new(Vector3.new(1.9, 0, 0.399)) * CFAngles(Vector3.new(-3.644, -23.448, 59.102));
  426. CFrame.new(Vector3.new(-1.1, -1.8, 0)) * CFAngles(Vector3.new(-3.616, -11.936, -29.566));
  427. CFrame.new(Vector3.new(0.1, -1.6, -0.601)) * CFAngles(Vector3.new(1.943, -7.181, -32.528));
  428. })
  429. local boostSpeed = 250
  430. local efx = Instance.new("Sound",c.Head)
  431. efx.SoundId = "rbxassetid://200632875"
  432. efx.Pitch = math.random(1100,1300)/1000
  433. efx.Volume = .5
  434. efx:Play()
  435. spawn(function()
  436. wait(5)
  437. efx:Destroy()
  438. end)
  439. vel.Velocity = (c.HumanoidRootPart.Position - c.HumanoidRootPart.CFrame:toWorldSpace(CFrame.new(-1,0,0)).p).unit * boostSpeed
  440. vel.P = 1e3
  441. vel.MaxForce = Vector3.new(math.huge,0,math.huge)
  442. wait(.15)
  443. vel.P = 1000
  444. vel.MaxForce = Vector3.new(3000,0,3000)
  445. vel.Velocity = Vector3.new()
  446. wait(.3)
  447. setLerp(.3)
  448. setJointCFrames({
  449. CFrame.new(Vector3.new(0, -0.901, 0)) * CFAngles(Vector3.new(-22.001, 0, -13));
  450. CFrame.new(Vector3.new(-0.001, 1.52, 0)) * CFAngles(Vector3.new(-12.936, -46.206, -2.327));
  451. CFrame.new(Vector3.new(-1.9, 0.2, -0.201)) * CFAngles(Vector3.new(45, 0, -60));
  452. CFrame.new(Vector3.new(1.7, 0, -0.401)) * CFAngles(Vector3.new(14.035, -5.69, 35.342));
  453. CFrame.new(Vector3.new(-0.3, -1.8, 0.6)) * CFAngles(Vector3.new(-55.479, -10.612, 15.729));
  454. CFrame.new(Vector3.new(0.5, -1, -0.801)) * CFAngles(Vector3.new(14.999, -15, 14.999));
  455. })
  456. wait(.2)
  457. vel:Destroy()
  458. Debounces.damageLevel = 0
  459. Debounces.scalingDamage = false
  460. Debounces.isBoosting = false
  461. end
  462. end)
  463.  
  464. uinps.InputBegan:connect(function(InputObject)
  465. if InputObject.KeyCode == Enum.KeyCode.W and Debounces.isAttacking == false and Debounces.isSprinting == true and Debounces.isBoosting == false and Debounces.isPassive == true and Debounces.isTyping == false then
  466. Debounces.isBoosting = true
  467. Debounces.damageLevel = 10
  468. Debounces.scalingDamage = true
  469. local vel = Instance.new("BodyVelocity",c.HumanoidRootPart)
  470. setLerp(.15)
  471. setJointCFrames({
  472. CFrame.new(Vector3.new(0, -0.901, 0)) * CFAngles(Vector3.new(-40.001, 0, 5));
  473. CFrame.new(Vector3.new(-0.001, 1.429, 0.2)) * CFAngles(Vector3.new(25.141, -8.347, 0.878));
  474. CFrame.new(Vector3.new(-1.5, 0, .101)) * CFAngles(Vector3.new(14.999, -0.001, 0));
  475. CFrame.new(Vector3.new(1.7, 0.199, -0.401)) * CFAngles(Vector3.new(28.08, -0.358, 21.087));
  476. CFrame.new(Vector3.new(-0.5, -1.8, 0.6)) * CFAngles(Vector3.new(-29.448, 3.57, -1.5));
  477. CFrame.new(Vector3.new(0.499, -1.6, -0.401)) * CFAngles(Vector3.new(-0.505, -14.478, -3.968));
  478. })
  479. local boostSpeed = 250
  480. local efx = Instance.new("Sound",c.Head)
  481. efx.SoundId = "rbxassetid://200632875"
  482. efx.Pitch = math.random(1100,1300)/1000
  483. efx.Volume = .5
  484. efx:Play()
  485. spawn(function()
  486. wait(5)
  487. efx:Destroy()
  488. end)
  489. vel.Velocity = (c.HumanoidRootPart.Position - c.HumanoidRootPart.CFrame:toWorldSpace(CFrame.new(0,0,1)).p).unit * boostSpeed
  490. vel.P = 1e3
  491. vel.MaxForce = Vector3.new(math.huge,0,math.huge)
  492. wait(.15)
  493. vel.P = 1000
  494. vel.MaxForce = Vector3.new(3000,0,3000)
  495. vel.Velocity = Vector3.new()
  496. wait(.3)
  497. setLerp(.3)
  498. setJointCFrames({
  499. CFrame.new(Vector3.new(0, -0.901, 0)) * CFAngles(Vector3.new(-22.001, 40, -13));
  500. CFrame.new(Vector3.new(-0.001, 1.52, 0)) * CFAngles(Vector3.new(-12.936, -46.206, -2.327));
  501. CFrame.new(Vector3.new(-1.9, 0.2, -0.201)) * CFAngles(Vector3.new(45, 0, -60));
  502. CFrame.new(Vector3.new(1.7, 0, -0.401)) * CFAngles(Vector3.new(14.035, -5.69, 35.342));
  503. CFrame.new(Vector3.new(-0.3, -1.8, 0.6)) * CFAngles(Vector3.new(-55.479, -10.612, 15.729));
  504. CFrame.new(Vector3.new(0.5, -1, -0.801)) * CFAngles(Vector3.new(14.999, -15, 14.999));
  505. })
  506. wait(.2)
  507. vel:Destroy()
  508. Debounces.damageLevel = 0
  509. Debounces.scalingDamage = false
  510. Debounces.isBoosting = false
  511. end
  512. end)
  513.  
  514. uinps.InputBegan:connect(function(InputObject)
  515. if InputObject.KeyCode == Enum.KeyCode.S and Debounces.isAttacking == false and Debounces.isSprinting == true and Debounces.isBoosting == false and Debounces.isPassive == true and Debounces.isTyping == false then
  516. Debounces.isBoosting = true
  517. Debounces.damageLevel = 10
  518. Debounces.scalingDamage = true
  519. local vel = Instance.new("BodyVelocity",c.HumanoidRootPart)
  520. setLerp(.15)
  521. setJointCFrames({
  522. CFrame.new(Vector3.new(0, -.3, 0)) * CFAngles(Vector3.new(15, 0, 0));
  523. CFrame.new(Vector3.new(-0.001, 1.52, -0.03)) * CFAngles(Vector3.new(-5.298, -1.305, -4.093));
  524. CFrame.new(Vector3.new(-1.7, 0, -0.201)) * CFAngles(Vector3.new(12.112, -6.562, -16.939));
  525. CFrame.new(Vector3.new(1.7, 0, -0.201)) * CFAngles(Vector3.new(8.817, 8.378, 20.465));
  526. CFrame.new(Vector3.new(-0.7, -1.8, 0.2)) * CFAngles(Vector3.new(-14.432, 3.06, -2.373));
  527. CFrame.new(Vector3.new(0.5, -1.8, -0.201)) * CFAngles(Vector3.new(-0.505, -14.478, -3.968));
  528. })
  529. local boostSpeed = 150
  530. local boostSpeed = 250
  531. local efx = Instance.new("Sound",c.Head)
  532. efx.SoundId = "rbxassetid://200632875"
  533. efx.Pitch = math.random(1100,1300)/1000
  534. efx.Volume = .5
  535. efx:Play()
  536. spawn(function()
  537. wait(5)
  538. efx:Destroy()
  539. end)
  540. vel.Velocity = (c.HumanoidRootPart.Position - c.HumanoidRootPart.CFrame:toWorldSpace(CFrame.new(0,0,-1)).p).unit * boostSpeed
  541. vel.P = 1e3
  542. vel.MaxForce = Vector3.new(math.huge,0,math.huge)
  543. wait(.15)
  544. vel.P = 1000
  545. vel.MaxForce = Vector3.new(3000,0,3000)
  546. vel.Velocity = Vector3.new()
  547. wait(.3)
  548. setLerp(.3)
  549. setJointCFrames({
  550. CFrame.new(Vector3.new(0, -.5, 0)) * CFAngles(Vector3.new(4, 0, 0));
  551. CFrame.new(Vector3.new(-0.001, 1.52, -0.03)) * CFAngles(Vector3.new(-20.081, 28.752, 3.598));
  552. CFrame.new(Vector3.new(-1.7, 0.2, -0.601)) * CFAngles(Vector3.new(59.51, -3.841, -14.511));
  553. CFrame.new(Vector3.new(1.7, 0.2, 0.399)) * CFAngles(Vector3.new(-47.597, -13.104, 17.887));
  554. CFrame.new(Vector3.new(-0.7, -1.4, 0.2)) * CFAngles(Vector3.new(-44.477, 3.836, -0.524));
  555. CFrame.new(Vector3.new(0.5, -1.4, -0.601)) * CFAngles(Vector3.new(-15.868, -12.953, -7.631));
  556. })
  557. wait(.2)
  558. vel:Destroy()
  559. Debounces.damageLevel = 0
  560. Debounces.scalingDamage = false
  561. Debounces.isBoosting = false
  562. end
  563. end)
  564.  
  565. uinps.InputBegan:connect(function(InputObject)
  566. if InputObject.KeyCode == Enum.KeyCode.Q and Debounces.isAttacking == false and Debounces.isSprinting == false and Debounces.isPassive == true and Debounces.isTyping == false then
  567. local isLooping = true
  568. uinps.InputEnded:connect(function(InputObject2)
  569. if InputObject2.KeyCode == Enum.KeyCode.Q then
  570. isLooping = false
  571. end
  572. end)
  573. while true do
  574. if isLooping == false then
  575. break
  576. end
  577. Debounces.attackNumber = Debounces.attackNumber + 1
  578. local aimPos = mouse.Hit.p
  579. local head = Instance.new("Part",c)
  580. head.Size = Vector3.new(12,.2,12)
  581. head.CanCollide = false
  582. head.Anchored = true
  583. head.Transparency = 1
  584. for i = 1,2 do
  585. local decal = Instance.new("Decal",head)
  586. decal.Texture = "rbxassetid://323497117"
  587. if i == 1 then
  588. decal.Face = Enum.NormalId.Top
  589. else
  590. decal.Face = Enum.NormalId.Bottom
  591. end
  592. end
  593. if Debounces.attackNumber%2 == 1 then
  594. head.CFrame = CFrame.new(c.Torso.CFrame:toWorldSpace(CFrame.new(8,8,.5)).p,aimPos)
  595. else
  596. head.CFrame = CFrame.new(c.Torso.CFrame:toWorldSpace(CFrame.new(-8,8,.5)).p,aimPos)
  597. end
  598. spawn(function()
  599. local timer = 0
  600. while rs.Stepped:wait() do
  601. if timer >= 1.55 then
  602. break
  603. end
  604. head.CFrame = head.CFrame * CFrame.Angles(0,0,math.rad(timer * 25/(Debounces.FPS/60)))
  605. timer = timer + 1/30/(Debounces.FPS/60)
  606. end
  607. head.CFrame = CFrame.new(head.CFrame.p,aimPos)
  608. local ray = Ray.new(head.CFrame.p,(aimPos - head.CFrame.p).unit * 999)
  609. local hit, pos = workspace:FindPartOnRay(ray,c)
  610. local dis = (head.CFrame.p - pos).magnitude
  611. local rayPart = Instance.new("Part",rayModel)
  612. rayPart.Material = "Neon"
  613. rayPart.FormFactor = "Custom"
  614. rayPart.BrickColor = BrickColor.new(1,1,1)
  615. rayPart.Anchored = true
  616. rayPart.CanCollide = false
  617. rayPart.Size = Vector3.new(7,7,dis + 400)
  618. local rayCFrame = CFrame.new(head.CFrame.p + (aimPos - head.CFrame.p).unit * (dis/2 + 200),head.CFrame.p + (aimPos - head.CFrame.p).unit * dis * 2)
  619. rayPart.CFrame = rayCFrame
  620. head:Destroy()
  621. end)
  622. wait()
  623. local s = Instance.new("Sound",head)
  624. s.Volume = 1
  625. s.SoundId = "rbxassetid://332223043"
  626. s:Play()
  627. wait(.04)
  628. end
  629. end
  630. end)
  631.  
  632. uinps.InputBegan:connect(function(InputObj)
  633. if InputObj.KeyCode == Enum.KeyCode.E and Debounces.isAttacking == false and Debounces.isSprinting == false and Debounces.isPassive == true and Debounces.isTyping == false then
  634. Debounces.isAttacking = true
  635. local aimPos = c.HumanoidRootPart.CFrame:toWorldSpace(CFrame.new(0,0,-999)).p
  636. local head = Instance.new("Part",c)
  637. head.Size = Vector3.new(18,.2,18)
  638. head.CanCollide = false
  639. head.Anchored = true
  640. head.CFrame = CFrame.new(c.HumanoidRootPart.CFrame:toWorldSpace(CFrame.new(0,0,-9)).p,aimPos)
  641. head.Transparency = 1
  642. for i = 1,2 do
  643. local decal = Instance.new("Decal",head)
  644. decal.Texture = "rbxassetid://323497117"
  645. if i == 1 then
  646. decal.Face = Enum.NormalId.Top
  647. else
  648. decal.Face = Enum.NormalId.Bottom
  649. end
  650. end
  651. setLerp(.1)
  652. setJointCFrames({
  653. CFrame.new(Vector3.new(0, 0, 0)) * CFAngles(Vector3.new(0, 0, 0));
  654. CFrame.new(Vector3.new(0, 1.499, -0.09)) * CFAngles(Vector3.new(-11.676, -0.001, -0.001));
  655. CFrame.new(Vector3.new(-1.7, 0, 0)) * CFAngles(Vector3.new(-12.808, -28.88, -21.502));
  656. CFrame.new(Vector3.new(1.699, 1.2, 0.599)) * CFAngles(Vector3.new(-146.606, 16.571, 13.928));
  657. CFrame.new(Vector3.new(-0.501, -1.601, 0.6)) * CFAngles(Vector3.new(-60, 0, -0.001));
  658. CFrame.new(Vector3.new(0.5, -1.4, -0.4)) * CFAngles(Vector3.new(-15.001, -15.001, 0));
  659. })
  660. spawn(function()
  661. local timer = 0
  662. while rs.Stepped:wait() do
  663. if timer >= 1.55/.8 then
  664. break
  665. end
  666. head.CFrame = head.CFrame * CFrame.Angles(0,0,math.rad(timer * 25/(Debounces.FPS/60)))
  667. timer = timer + 1/30/(Debounces.FPS/60)
  668. end
  669. head.CFrame = CFrame.new(head.CFrame.p,aimPos)
  670. local ray = Ray.new(head.CFrame.p,(aimPos - head.CFrame.p).unit * 999)
  671. local hit, pos = workspace:FindPartOnRay(ray,c)
  672. local dis = (head.CFrame.p - pos).magnitude
  673. local rayPart = Instance.new("Part",rayModel)
  674. rayPart.Material = "Neon"
  675. rayPart.FormFactor = "Custom"
  676. rayPart.Name = "Punch"
  677. rayPart.BrickColor = BrickColor.new(1,1,1)
  678. rayPart.Anchored = true
  679. rayPart.CanCollide = false
  680. rayPart.Size = Vector3.new(28,28,dis + 400)
  681. local rayCFrame = CFrame.new(head.CFrame.p + (aimPos - head.CFrame.p).unit * (dis/2 + 200),head.CFrame.p + (aimPos - head.CFrame.p).unit * dis * 2)
  682. rayPart.CFrame = rayCFrame
  683. head:Destroy()
  684. end)
  685. wait()
  686. local s = Instance.new("Sound",head)
  687. s.Volume = 1
  688. s.SoundId = "rbxassetid://332223043"
  689. s.Pitch = .8
  690. s:Play()
  691. wait(.75)
  692. setLerp(.17)
  693. setJointCFrames({
  694. CFrame.new(Vector3.new(0, -.5, 0)) * CFAngles(Vector3.new(-20, 15, 0));
  695. CFrame.new(Vector3.new(0, 1.499, -0.09)) * CFAngles(Vector3.new(-11.676, 14.999, -0.001));
  696. CFrame.new(Vector3.new(-1.7, 0, 0.2)) * CFAngles(Vector3.new(-33.928, -4.374, -38.76));
  697. CFrame.new(Vector3.new(1.499, 0.4, -0.601)) * CFAngles(Vector3.new(74.335, 25.091, -6.155));
  698. CFrame.new(Vector3.new(-0.501, -1.601, 0.6)) * CFAngles(Vector3.new(-45, 0, -0.001));
  699. CFrame.new(Vector3.new(0.5, -1.8, -0.4)) * CFAngles(Vector3.new(-15, -15, 0));
  700. })
  701. wait(.5)
  702. Debounces.isAttacking = false
  703. end
  704. end)
  705.  
  706. reflect = function(d,n)
  707. local i, n = -1 * d.unit, n.unit
  708. local dot = n:Dot(i)
  709. return 2*dot*n - i
  710. end
  711.  
  712. makeReflectionBeam = function(pos,look,isCrit)
  713. local ray = Ray.new(pos,look)
  714. local hit,hitpos,norm = workspace:FindPartOnRay(ray,c)
  715. local e = Instance.new("Part",rayModel)
  716. e.Anchored = true
  717. e.CanCollide = false
  718. e.BrickColor = BrickColor.new("White")
  719. e.Material = "Neon"
  720. e.FormFactor = "Custom"
  721. e.Size = Vector3.new(6,6,(pos - hitpos).magnitude)
  722. if isCrit == true then
  723. e.Size = Vector3.new(16,16,(pos - hitpos).magnitude)
  724. e.Name = "Punch"
  725. end
  726. e.CFrame = CFrame.new(pos + (hitpos - pos)/2, pos)
  727. local e = Instance.new("Sound",c)
  728. if isCrit == true then
  729. e.Volume = .5
  730. else
  731. e.Volume = .3
  732. e.Pitch = 1.5
  733. end
  734. e.SoundId = "rbxassetid://200632875"
  735. e:Play()
  736. spawn(function()
  737. wait(6)
  738. e:Destroy()
  739. end)
  740. wait(.05)
  741. if hit ~= nil then
  742. newDir = reflect(look.unit,norm,isCrit)
  743. makeReflectionBeam(hitpos,newDir * 999,isCrit)
  744. end
  745. end
  746.  
  747. uinps.InputBegan:connect(function(InputObject)
  748. if InputObject.KeyCode == Enum.KeyCode.Q and Debounces.isAttacking == false and Debounces.isSprinting == true and Debounces.isPassive == true and Debounces.isTyping == false then
  749. local isLooping = true
  750. uinps.InputEnded:connect(function(InputObject2)
  751. if InputObject2.KeyCode == Enum.KeyCode.Q then
  752. isLooping = false
  753. end
  754. end)
  755. while true do
  756. if isLooping == false then
  757. break
  758. end
  759. Debounces.attackNumber = Debounces.attackNumber + 1
  760. local aimPos = mouse.Hit.p
  761. local head = Instance.new("Part",c)
  762. head.Size = Vector3.new(12,.2,12)
  763. head.CanCollide = false
  764. head.Anchored = true
  765. head.Transparency = 1
  766. for i = 1,2 do
  767. local decal = Instance.new("Decal",head)
  768. decal.Texture = "rbxassetid://323497117"
  769. if i == 1 then
  770. decal.Face = Enum.NormalId.Top
  771. else
  772. decal.Face = Enum.NormalId.Bottom
  773. end
  774. end
  775. if Debounces.attackNumber%2 == 1 then
  776. head.CFrame = CFrame.new(c.Torso.CFrame:toWorldSpace(CFrame.new(8,8,.5)).p,aimPos)
  777. else
  778. head.CFrame = CFrame.new(c.Torso.CFrame:toWorldSpace(CFrame.new(-8,8,.5)).p,aimPos)
  779. end
  780. spawn(function()
  781. local timer = 0
  782. while rs.Stepped:wait() do
  783. if timer >= 1.55 then
  784. break
  785. end
  786. head.CFrame = head.CFrame * CFrame.Angles(0,0,math.rad(timer * 25/(Debounces.FPS/60)))
  787. timer = timer + 1/30/(Debounces.FPS/60)
  788. end
  789. head.CFrame = CFrame.new(head.CFrame.p,aimPos)
  790. head:Destroy()
  791. makeReflectionBeam(head.CFrame.p,(head.CFrame.p - aimPos).unit * -999,false)
  792. end)
  793.  
  794. wait()
  795. local s = Instance.new("Sound",head)
  796. s.Volume = 1
  797. s.SoundId = "rbxassetid://332223043"
  798. s.Pitch = 1.02
  799. s:Play()
  800. wait(.2)
  801. end
  802. end
  803. end)
  804.  
  805. uinps.InputBegan:connect(function(InputObj)
  806. if InputObj.KeyCode == Enum.KeyCode.E and Debounces.isAttacking == false and Debounces.isSprinting == true and Debounces.isPassive == true and Debounces.isTyping == false then
  807. Debounces.isAttacking = true
  808. local aimPos = c.HumanoidRootPart.CFrame:toWorldSpace(CFrame.new(0,0,-999)).p
  809. local head = Instance.new("Part",c)
  810. head.Size = Vector3.new(18,.2,18)
  811. head.CanCollide = false
  812. head.Anchored = true
  813. head.CFrame = CFrame.new(c.HumanoidRootPart.CFrame:toWorldSpace(CFrame.new(0,0,-9)).p,aimPos)
  814. head.Transparency = 1
  815. for i = 1,2 do
  816. local decal = Instance.new("Decal",head)
  817. decal.Texture = "rbxassetid://323497117"
  818. if i == 1 then
  819. decal.Face = Enum.NormalId.Top
  820. else
  821. decal.Face = Enum.NormalId.Bottom
  822. end
  823. end
  824. setLerp(.1)
  825. setJointCFrames({
  826. CFrame.new(Vector3.new(0, 0, 0)) * CFAngles(Vector3.new(0, 0, 0));
  827. CFrame.new(Vector3.new(0, 1.499, -0.09)) * CFAngles(Vector3.new(-11.676, -0.001, -0.001));
  828. CFrame.new(Vector3.new(-1.7, 0, 0)) * CFAngles(Vector3.new(-12.808, -28.88, -21.502));
  829. CFrame.new(Vector3.new(1.699, 1.2, 0.599)) * CFAngles(Vector3.new(-146.606, 16.571, 13.928));
  830. CFrame.new(Vector3.new(-0.501, -1.601, 0.6)) * CFAngles(Vector3.new(-60, 0, -0.001));
  831. CFrame.new(Vector3.new(0.5, -1.4, -0.4)) * CFAngles(Vector3.new(-15.001, -15.001, 0));
  832. })
  833. spawn(function()
  834. local timer = 0
  835. while rs.Stepped:wait() do
  836. if timer >= 1.55/.8 then
  837. break
  838. end
  839. head.CFrame = head.CFrame * CFrame.Angles(0,0,math.rad(timer * 25/(Debounces.FPS/60)))
  840. timer = timer + 1/30/(Debounces.FPS/60)
  841. end
  842. head.CFrame = CFrame.new(head.CFrame.p,aimPos)
  843. head:Destroy()
  844. makeReflectionBeam(head.CFrame.p,(head.CFrame.p - aimPos).unit * -999,true)
  845. end)
  846. wait()
  847. local s = Instance.new("Sound",head)
  848. s.Volume = 2
  849. s.SoundId = "rbxassetid://332223043"
  850. s.Pitch = .8
  851. s:Play()
  852. wait(.75)
  853. setLerp(.17)
  854. setJointCFrames({
  855. CFrame.new(Vector3.new(0, -.5, 0)) * CFAngles(Vector3.new(-20, 15, 0));
  856. CFrame.new(Vector3.new(0, 1.499, -0.09)) * CFAngles(Vector3.new(-11.676, 14.999, -0.001));
  857. CFrame.new(Vector3.new(-1.7, 0, 0.2)) * CFAngles(Vector3.new(-33.928, -4.374, -38.76));
  858. CFrame.new(Vector3.new(1.499, 0.4, -0.601)) * CFAngles(Vector3.new(74.335, 25.091, -6.155));
  859. CFrame.new(Vector3.new(-0.501, -1.601, 0.6)) * CFAngles(Vector3.new(-45, 0, -0.001));
  860. CFrame.new(Vector3.new(0.5, -1.8, -0.4)) * CFAngles(Vector3.new(-15, -15, 0));
  861. })
  862. wait(.5)
  863. Debounces.isAttacking = false
  864. end
  865. end)
  866.  
  867. uinps.InputBegan:connect(function(InputObj)
  868. if InputObj.KeyCode == Enum.KeyCode.Slash then
  869. local finishEvent = nil
  870. Debounces.isTyping = true
  871. finishEvent = uinps.InputBegan:connect(function(InputObj)
  872. if InputObj.KeyCode == Enum.KeyCode.Return or InputObj.UserInputType == Enum.UserInputType.MouseButton1 then
  873. Debounces.isTyping = false
  874. finishEvent:disconnect()
  875. end
  876. end)
  877. end
  878. end)
  879.  
  880. uinps.InputBegan:connect(function(InputObj)
  881. if InputObj.KeyCode == Enum.KeyCode.LeftShift then
  882. Debounces.isSprinting = true
  883. end
  884. end)
  885.  
  886. uinps.InputEnded:connect(function(InputObj)
  887. if InputObj.KeyCode == Enum.KeyCode.LeftShift then
  888. Debounces.isSprinting = false
  889. end
  890. end)
  891.  
  892. rs.Stepped:connect(function()
  893. Debounces.FPS = 1/rs.Stepped:wait()
  894. local FPSLerp = AnimStat.lerpSpeed/(Debounces.FPS/60)
  895. if Debounces.isPassive == false then
  896. fire.Enabled = false
  897. light.Range = 0
  898. fight:Pause()
  899. sans:Resume()
  900. efxBlock.Transparency = 1
  901. else
  902. fire.Enabled = true
  903. light.Range = 10
  904. fight:Resume()
  905. sans:Pause()
  906. efxBlock.Transparency = 0
  907. end
  908. for i,v in pairs (rayModel:children()) do
  909. if v.Transparency >= 1 then
  910. v:Destroy()
  911. else
  912. v.CanCollide = true
  913. local parts = v:GetTouchingParts()
  914. v.CanCollide = false
  915. for i = 1,#parts do
  916. if parts[i].Parent:FindFirstChild("Humanoid") and parts[i].Parent ~= c and v.Name ~= "Punch" then
  917. parts[i].Parent.Humanoid:TakeDamage(.5/(Debounces.FPS/60))
  918. elseif parts[i].Parent:FindFirstChild("Humanoid") and parts[i].Parent ~= c and v.Name == "Punch" then
  919. parts[i].Parent.Humanoid:TakeDamage(3.1/(Debounces.FPS/60))
  920. end
  921. end
  922. v.Size = v.Size + Vector3.new(1/(Debounces.FPS/60),1/(Debounces.FPS/60),0)
  923. v.Transparency = v.Transparency + .05/(Debounces.FPS/60)
  924. end
  925. end
  926. for i = 1,#Joints do
  927. Joints[i].C0 = Joints[i].C0:lerp(JointTargets[i], FPSLerp)
  928. end
  929. local sineval = math.sin(tick() * 2) * 3
  930. fire.Acceleration = Vector3.new(sineval,1,sineval)
  931. light.Brightness = math.sin(math.cos(tick() * 2) * 1.5)
  932. end)
Add Comment
Please, Sign In to add comment