Advertisement
JasonLion

test lolol

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