Advertisement
TheSkibidiOne1

GAROU JJS SCRIPT TEST 1

Feb 10th, 2025
53
0
Never
1
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 20.77 KB | None | 0 0
  1. -- yk the deal bud
  2. local Players = game:GetService("Players")
  3. local ReplicatedStorage = game:GetService("ReplicatedStorage")
  4.  
  5. -- Skill Names
  6. local skillOne = game.Players.LocalPlayer.PlayerGui.Main.Moveset['Cursed Strikes'].ItemName
  7. local skillTwo = game.Players.LocalPlayer.PlayerGui.Main.Moveset['Crushing Blow'].ItemName
  8. local skillThree = game.Players.LocalPlayer.PlayerGui.Main.Moveset['Divergent Fist'].ItemName
  9. local skillFour = game.Players.LocalPlayer.PlayerGui.Main.Moveset['Manji Kick'].ItemName
  10. local ultTitle = game.Players.LocalPlayer.PlayerGui.Main.Ultimate.Title
  11.  
  12. -- Set skill names
  13. skillOne.Text = "Flowing Water"
  14. skillTwo.Text = "Lethal Whirlwind Stream
  15. skillThree.Text = "Hunters Grasp"
  16. skillFour.Text = "Preys Peril"
  17. ultTitle.Text = "Rampage"
  18.  
  19. -- Skill 1 --
  20.  
  21. -- Animation references
  22. local Ravage = ReplicatedStorage.Animations.Itadori.CursedStrike
  23. local RavageStart = ReplicatedStorage.Animations.Heian.Cleave
  24. local RavageMid = ReplicatedStorage.Animations.Choso.WingKing
  25.  
  26. -- VFX references (add your VFX paths here)
  27. local VFX_TEMPLATES = {
  28. groundWave = game.ReplicatedStorage.Utils.Gojo.HollowPurple.Blue.Mid,
  29. }
  30.  
  31. -- Animation storage
  32. local loadedAnimations = {}
  33. local activeVFX = {}
  34.  
  35. -- Prevent multiple triggers
  36. local isAnimationSequenceActive = false
  37.  
  38. -- Function to create VFX
  39. local function createVFX(vfxName, character)
  40. if not VFX_TEMPLATES[vfxName] then
  41. warn("VFX template not found:", vfxName)
  42. return nil
  43. end
  44.  
  45. local hrp = character:WaitForChild("HumanoidRootPart")
  46. local vfx = VFX_TEMPLATES[vfxName]:Clone()
  47. vfx.Parent = hrp
  48. activeVFX[vfxName] = vfx
  49.  
  50. return vfx
  51. end
  52.  
  53. -- Function to play VFX
  54. local function playVFX(vfxName, particleAmount)
  55. local vfx = activeVFX[vfxName]
  56. if not vfx then return end
  57.  
  58. for _, child in ipairs(vfx:GetChildren()) do
  59. child.Color = ColorSequence.new(Color3.new(1, 1, 1))
  60. if child:IsA("ParticleEmitter") then
  61. child:Emit(particleAmount or 15)
  62. child.Enabled = true
  63. end
  64. end
  65. end
  66.  
  67. -- Function to stop VFX
  68. local function stopVFX(vfxName)
  69. local vfx = activeVFX[vfxName]
  70. if not vfx then return end
  71.  
  72. for _, child in ipairs(vfx:GetChildren()) do
  73. if child:IsA("ParticleEmitter") then
  74. child.Enabled = false
  75. end
  76. end
  77. end
  78.  
  79. -- Function to cleanup VFX
  80. local function cleanupVFX(vfxName)
  81. local vfx = activeVFX[vfxName]
  82. if vfx then
  83. vfx:Destroy()
  84. activeVFX[vfxName] = nil
  85. end
  86. end
  87.  
  88. -- Function to load animation
  89. local function loadAnimation(animId, character)
  90. local humanoid = character:FindFirstChildOfClass("Humanoid")
  91. if not humanoid then return nil end
  92.  
  93. local animation = Instance.new("Animation")
  94. animation.AnimationId = animId
  95.  
  96. return humanoid:LoadAnimation(animation)
  97. end
  98.  
  99. -- Function to play animation sequence
  100. local function playAnimationSequence(player)
  101. if isAnimationSequenceActive then return end
  102. isAnimationSequenceActive = true
  103.  
  104. local character = player.Character
  105. if not character then return end
  106.  
  107. -- Load animations if not already loaded
  108. if not loadedAnimations.roughEnergy then
  109. loadedAnimations.RavageStart = loadAnimation(RavageStart.AnimationId, character)
  110. loadedAnimations.RavageMid = loadAnimation(RavageMid.AnimationId, character)
  111. end
  112.  
  113. -- Stop any existing animations
  114. for _, track in pairs(character:FindFirstChildOfClass("Humanoid"):GetPlayingAnimationTracks()) do
  115. track:Stop()
  116. end
  117.  
  118. -- Create VFX instances
  119. createVFX("groundWave", character)
  120.  
  121. -- Custom sequence
  122. task.spawn(function()
  123. loadedAnimations.RavageStart:Play()
  124. task.wait(0.2)
  125. playVFX("groundWave", 10)
  126.  
  127. task.wait(0.2)
  128. loadedAnimations.RavageStart:Stop()
  129. loadedAnimations.RavageMid:Play()
  130. stopVFX("groundWave")
  131.  
  132. task.wait(2)
  133. loadedAnimations.RavageMid:Stop()
  134.  
  135. -- Cleanup
  136. task.wait(0.5)
  137. cleanupVFX("groundWave")
  138.  
  139. isAnimationSequenceActive = false
  140. end)
  141. end
  142.  
  143. -- Event handler for animation played
  144. local function onAnimationPlayed(animationTrack)
  145. if animationTrack.Animation.AnimationId == Ravage.AnimationId then
  146. playAnimationSequence(Players.LocalPlayer)
  147. end
  148. end
  149.  
  150. -- Set up character connections
  151. local function setupCharacter(character)
  152. -- Clear old animations
  153. loadedAnimations = {}
  154.  
  155. -- Clear old VFX
  156. for name, vfx in pairs(activeVFX) do
  157. vfx:Destroy()
  158. end
  159. activeVFX = {}
  160.  
  161. local humanoid = character:WaitForChild("Humanoid")
  162. humanoid.AnimationPlayed:Connect(onAnimationPlayed)
  163. end
  164.  
  165. -- Connect to local player's character
  166. local player = Players.LocalPlayer
  167. setupCharacter(player.Character or player.CharacterAdded:Wait())
  168. player.CharacterAdded:Connect(setupCharacter)
  169.  
  170. -- Skill 2 --
  171.  
  172. -- Animation references
  173. local crushingBlowANIM = ReplicatedStorage.Animations.Itadori.CrushingBlow
  174. local roughEnergyANIM = ReplicatedStorage.Animations.Choso.BloodEdge
  175.  
  176. -- VFX references (add your VFX paths here)
  177. local VFX_TEMPLATES = {
  178. groundWave = game:GetService("ReplicatedStorage").Utils.Megumi.Mahoraga.Parry.Scream,
  179. }
  180.  
  181. -- Animation storage
  182. local loadedAnimations = {}
  183. local activeVFX = {}
  184.  
  185. -- Prevent multiple triggers
  186. local isAnimationSequenceActive = false
  187.  
  188. -- Function to create VFX
  189. local function createVFX(vfxName, character)
  190. if not VFX_TEMPLATES[vfxName] then
  191. warn("VFX template not found:", vfxName)
  192. return nil
  193. end
  194.  
  195. local hrp = character:WaitForChild("HumanoidRootPart")
  196. local vfx = VFX_TEMPLATES[vfxName]:Clone()
  197. vfx.Parent = hrp
  198. activeVFX[vfxName] = vfx
  199.  
  200. return vfx
  201. end
  202.  
  203. -- Function to play VFX
  204. local function playVFX(vfxName, particleAmount)
  205. local vfx = activeVFX[vfxName]
  206. if not vfx then return end
  207.  
  208. for _, child in ipairs(vfx:GetChildren()) do
  209. if child:IsA("ParticleEmitter") then
  210. child:Emit(particleAmount or 15)
  211. child.Enabled = true
  212. end
  213. end
  214. end
  215.  
  216. -- Function to stop VFX
  217. local function stopVFX(vfxName)
  218. local vfx = activeVFX[vfxName]
  219. if not vfx then return end
  220.  
  221. for _, child in ipairs(vfx:GetChildren()) do
  222. if child:IsA("ParticleEmitter") then
  223. child.Enabled = false
  224. end
  225. end
  226. end
  227.  
  228. -- Function to cleanup VFX
  229. local function cleanupVFX(vfxName)
  230. local vfx = activeVFX[vfxName]
  231. if vfx then
  232. vfx:Destroy()
  233. activeVFX[vfxName] = nil
  234. end
  235. end
  236.  
  237. -- Function to load animation
  238. local function loadAnimation(animId, character)
  239. local humanoid = character:FindFirstChildOfClass("Humanoid")
  240. if not humanoid then return nil end
  241.  
  242. local animation = Instance.new("Animation")
  243. animation.AnimationId = animId
  244.  
  245. return humanoid:LoadAnimation(animation)
  246. end
  247.  
  248. -- Function to play animation sequence
  249. local function playAnimationSequence(player)
  250. if isAnimationSequenceActive then return end
  251. isAnimationSequenceActive = true
  252.  
  253. local character = player.Character
  254. if not character then return end
  255.  
  256. -- Load animations if not already loaded
  257. if not loadedAnimations.roughEnergy then
  258. loadedAnimations.roughEnergy = loadAnimation(roughEnergyANIM.AnimationId, character)
  259. end
  260.  
  261. -- Stop any existing animations
  262. for _, track in pairs(character:FindFirstChildOfClass("Humanoid"):GetPlayingAnimationTracks()) do
  263. track:Stop()
  264. end
  265.  
  266. -- Create VFX instances
  267. createVFX("groundWave", character)
  268.  
  269. -- Custom sequence
  270. task.spawn(function()
  271. loadedAnimations.roughEnergy:Play()
  272. task.wait(0.2)
  273. playVFX("groundWave", 15)
  274.  
  275. task.wait(0.5)
  276. loadedAnimations.roughEnergy:Stop()
  277. stopVFX("groundWave")
  278.  
  279. -- Cleanup
  280. task.wait(0.5)
  281. cleanupVFX("groundWave")
  282.  
  283. isAnimationSequenceActive = false
  284. end)
  285. end
  286.  
  287. -- Event handler for animation played
  288. local function onAnimationPlayed(animationTrack)
  289. if animationTrack.Animation.AnimationId == crushingBlowANIM.AnimationId then
  290. playAnimationSequence(Players.LocalPlayer)
  291. end
  292. end
  293.  
  294. -- Set up character connections
  295. local function setupCharacter(character)
  296. -- Clear old animations
  297. loadedAnimations = {}
  298.  
  299. -- Clear old VFX
  300. for name, vfx in pairs(activeVFX) do
  301. vfx:Destroy()
  302. end
  303. activeVFX = {}
  304.  
  305. local humanoid = character:WaitForChild("Humanoid")
  306. humanoid.AnimationPlayed:Connect(onAnimationPlayed)
  307. end
  308.  
  309. -- Connect to local player's character
  310. local player = Players.LocalPlayer
  311. setupCharacter(player.Character or player.CharacterAdded:Wait())
  312. player.CharacterAdded:Connect(setupCharacter)
  313.  
  314. -- Skill 3 --
  315.  
  316. -- Animation references
  317. local divergentFist1 = ReplicatedStorage.Animations.Itadori.Variants.DivergentFist1
  318. local roughEnergyANIM = ReplicatedStorage.Animations.Todo.PebbleThrow
  319.  
  320.  
  321. -- VFX references (add your VFX paths here)
  322. local VFX_TEMPLATES = {
  323. groundWave = game.ReplicatedStorage.Utils.Mahito.Worms.WormLaunch.groundwaveing,
  324. }
  325.  
  326. -- Animation storage
  327. local loadedAnimations = {}
  328. local activeVFX = {}
  329.  
  330. -- Prevent multiple triggers
  331. local isAnimationSequenceActive = false
  332.  
  333. -- Function to create VFX
  334. local function createVFX(vfxName, character)
  335. if not VFX_TEMPLATES[vfxName] then
  336. warn("VFX template not found:", vfxName)
  337. return nil
  338. end
  339.  
  340. local hrp = character:WaitForChild("HumanoidRootPart")
  341. local vfx = VFX_TEMPLATES[vfxName]:Clone()
  342. vfx.Parent = hrp
  343. activeVFX[vfxName] = vfx
  344.  
  345. return vfx
  346. end
  347.  
  348. -- Function to play VFX
  349. local function playVFX(vfxName, particleAmount)
  350. local vfx = activeVFX[vfxName]
  351. if not vfx then return end
  352.  
  353. for _, child in ipairs(vfx:GetChildren()) do
  354. child.Color = ColorSequence.new(Color3.new(1, 0, 0))
  355. if child:IsA("ParticleEmitter") then
  356. child:Emit(particleAmount or 15)
  357. child.Enabled = true
  358. end
  359. end
  360. end
  361.  
  362. -- Function to stop VFX
  363. local function stopVFX(vfxName)
  364. local vfx = activeVFX[vfxName]
  365. if not vfx then return end
  366.  
  367. for _, child in ipairs(vfx:GetChildren()) do
  368. if child:IsA("ParticleEmitter") then
  369. child.Enabled = false
  370. end
  371. end
  372. end
  373.  
  374. -- Function to cleanup VFX
  375. local function cleanupVFX(vfxName)
  376. local vfx = activeVFX[vfxName]
  377. if vfx then
  378. vfx:Destroy()
  379. activeVFX[vfxName] = nil
  380. end
  381. end
  382.  
  383. -- Function to load animation
  384. local function loadAnimation(animId, character)
  385. local humanoid = character:FindFirstChildOfClass("Humanoid")
  386. if not humanoid then return nil end
  387.  
  388. local animation = Instance.new("Animation")
  389. animation.AnimationId = animId
  390.  
  391. return humanoid:LoadAnimation(animation)
  392. end
  393.  
  394. -- Function to play animation sequence
  395. local function playAnimationSequence(player)
  396. if isAnimationSequenceActive then return end
  397. isAnimationSequenceActive = true
  398.  
  399. local character = player.Character
  400. if not character then return end
  401.  
  402. -- Load animations if not already loaded
  403. if not loadedAnimations.roughEnergy then
  404. loadedAnimations.roughEnergy = loadAnimation(roughEnergyANIM.AnimationId, character)
  405. end
  406.  
  407. -- Stop any existing animations
  408. for _, track in pairs(character:FindFirstChildOfClass("Humanoid"):GetPlayingAnimationTracks()) do
  409. track:Stop()
  410. end
  411.  
  412. -- Create VFX instances
  413. createVFX("groundWave", character)
  414.  
  415. -- Custom sequence
  416. task.spawn(function()
  417. loadedAnimations.roughEnergy:Play()
  418. task.wait(0.2)
  419. playVFX("groundWave", 1)
  420.  
  421. task.wait(0.5)
  422. loadedAnimations.roughEnergy:Stop()
  423. stopVFX("groundWave")
  424.  
  425. -- Cleanup
  426. task.wait(0.5)
  427. cleanupVFX("groundWave")
  428.  
  429. isAnimationSequenceActive = false
  430. end)
  431. end
  432.  
  433. -- Event handler for animation played
  434. local function onAnimationPlayed(animationTrack)
  435. if animationTrack.Animation.AnimationId == divergentFist1.AnimationId then
  436. playAnimationSequence(Players.LocalPlayer)
  437. end
  438. end
  439.  
  440. -- Set up character connections
  441. local function setupCharacter(character)
  442. -- Clear old animations
  443. loadedAnimations = {}
  444.  
  445. -- Clear old VFX
  446. for name, vfx in pairs(activeVFX) do
  447. vfx:Destroy()
  448. end
  449. activeVFX = {}
  450.  
  451. local humanoid = character:WaitForChild("Humanoid")
  452. humanoid.AnimationPlayed:Connect(onAnimationPlayed)
  453. end
  454.  
  455. -- Connect to local player's character
  456. local player = Players.LocalPlayer
  457. setupCharacter(player.Character or player.CharacterAdded:Wait())
  458. player.CharacterAdded:Connect(setupCharacter)
  459.  
  460. -- Skill 4 --
  461.  
  462. -- Animation references
  463. local divergentFist2 = ReplicatedStorage.Animations.Itadori.ManjiKick
  464. local KJCounterANIM = ReplicatedStorage.Animations.Hakari.Luckyvolley
  465.  
  466.  
  467. -- VFX references (add your VFX paths here)
  468. local VFX_TEMPLATES = {
  469. groundWave = game:GetService("ReplicatedStorage").Utils.Damage.Explode.Head.Attachment,
  470. }
  471.  
  472. -- Animation storage
  473. local loadedAnimations = {}
  474. local activeVFX = {}
  475.  
  476. -- Prevent multiple triggers
  477. local isAnimationSequenceActive = false
  478.  
  479. -- Function to create VFX
  480. local function createVFX(vfxName, character)
  481. if not VFX_TEMPLATES[vfxName] then
  482. warn("VFX template not found:", vfxName)
  483. return nil
  484. end
  485.  
  486. local hrp = character:WaitForChild("HumanoidRootPart")
  487. local vfx = VFX_TEMPLATES[vfxName]:Clone()
  488. vfx.Parent = hrp
  489. activeVFX[vfxName] = vfx
  490.  
  491. return vfx
  492. end
  493.  
  494. -- Function to play VFX
  495. local function playVFX(vfxName, particleAmount)
  496. local vfx = activeVFX[vfxName]
  497. if not vfx then return end
  498.  
  499. for _, child in ipairs(vfx:GetChildren()) do
  500. child.Color = ColorSequence.new(Color3.new(1, 0, 0))
  501. if child:IsA("ParticleEmitter") then
  502. child:Emit(particleAmount or 15)
  503. child.Enabled = true
  504. end
  505. end
  506. end
  507.  
  508. -- Function to stop VFX
  509. local function stopVFX(vfxName)
  510. local vfx = activeVFX[vfxName]
  511. if not vfx then return end
  512.  
  513. for _, child in ipairs(vfx:GetChildren()) do
  514. if child:IsA("ParticleEmitter") then
  515. child.Enabled = false
  516. end
  517. end
  518. end
  519.  
  520. -- Function to cleanup VFX
  521. local function cleanupVFX(vfxName)
  522. local vfx = activeVFX[vfxName]
  523. if vfx then
  524. vfx:Destroy()
  525. activeVFX[vfxName] = nil
  526. end
  527. end
  528.  
  529. -- Function to load animation
  530. local function loadAnimation(animId, character)
  531. local humanoid = character:FindFirstChildOfClass("Humanoid")
  532. if not humanoid then return nil end
  533.  
  534. local animation = Instance.new("Animation")
  535. animation.AnimationId = animId
  536.  
  537. return humanoid:LoadAnimation(animation)
  538. end
  539.  
  540. -- Function to play animation sequence
  541. local function playAnimationSequence(player)
  542. if isAnimationSequenceActive then return end
  543. isAnimationSequenceActive = true
  544.  
  545. local character = player.Character
  546. if not character then return end
  547.  
  548. -- Load animations if not already loaded
  549. if not loadedAnimations.roughEnergy then
  550. loadedAnimations.roughEnergy = loadAnimation(KJCounterANIM.AnimationId, character)
  551. end
  552.  
  553. -- Stop any existing animations
  554. for _, track in pairs(character:FindFirstChildOfClass("Humanoid"):GetPlayingAnimationTracks()) do
  555. track:Stop()
  556. end
  557.  
  558. -- Create VFX instances
  559. createVFX("groundWave", character)
  560.  
  561. -- Custom sequence
  562. task.spawn(function()
  563. loadedAnimations.roughEnergy:Play()
  564. task.wait(0.2)
  565. playVFX("groundWave", 1)
  566.  
  567. task.wait(0.3)
  568. loadedAnimations.roughEnergy:Stop()
  569. stopVFX("groundWave")
  570.  
  571. -- Cleanup
  572. task.wait(0.5)
  573. cleanupVFX("groundWave")
  574.  
  575. isAnimationSequenceActive = false
  576. end)
  577. end
  578.  
  579. -- Event handler for animation played
  580. local function onAnimationPlayed(animationTrack)
  581. if animationTrack.Animation.AnimationId == divergentFist2.AnimationId then
  582. playAnimationSequence(Players.LocalPlayer)
  583. end
  584. end
  585.  
  586. -- Set up character connections
  587. local function setupCharacter(character)
  588. -- Clear old animations
  589. loadedAnimations = {}
  590.  
  591. -- Clear old VFX
  592. for name, vfx in pairs(activeVFX) do
  593. vfx:Destroy()
  594. end
  595. activeVFX = {}
  596.  
  597. local humanoid = character:WaitForChild("Humanoid")
  598. humanoid.AnimationPlayed:Connect(onAnimationPlayed)
  599. end
  600.  
  601. -- Connect to local player's character
  602. local player = Players.LocalPlayer
  603. setupCharacter(player.Character or player.CharacterAdded:Wait())
  604. player.CharacterAdded:Connect(setupCharacter)
  605.  
  606. -- Ult --
  607.  
  608. -- Animation references
  609. local KJUltBase = ReplicatedStorage.Animations.Itadori.Ultimate
  610. local KJUltANIM = ReplicatedStorage.Animations.Heian.Dismantle.WCS
  611.  
  612.  
  613. -- VFX references (add your VFX paths here)
  614. local VFX_TEMPLATES = {
  615. groundWave = game:GetService("ReplicatedStorage").Utils.Heian.Sweep.Attachment,
  616. }
  617.  
  618. -- Animation storage
  619. local loadedAnimations = {}
  620. local activeVFX = {}
  621.  
  622. -- Prevent multiple triggers
  623. local isAnimationSequenceActive = false
  624.  
  625. -- Function to create VFX
  626. local function createVFX(vfxName, character)
  627. if not VFX_TEMPLATES[vfxName] then
  628. warn("VFX template not found:", vfxName)
  629. return nil
  630. end
  631.  
  632. local hrp = character:WaitForChild("HumanoidRootPart")
  633. local vfx = VFX_TEMPLATES[vfxName]:Clone()
  634. vfx.Parent = hrp
  635. activeVFX[vfxName] = vfx
  636.  
  637. return vfx
  638. end
  639.  
  640. -- Function to play VFX
  641. local function playVFX(vfxName, particleAmount)
  642. local vfx = activeVFX[vfxName]
  643. if not vfx then return end
  644.  
  645. for _, child in ipairs(vfx:GetChildren()) do
  646. child.Color = ColorSequence.new(Color3.new(1, 0, 0))
  647. if child:IsA("ParticleEmitter") then
  648. child:Emit(particleAmount or 15)
  649. child.Enabled = true
  650. end
  651. end
  652. end
  653.  
  654. -- Function to stop VFX
  655. local function stopVFX(vfxName)
  656. local vfx = activeVFX[vfxName]
  657. if not vfx then return end
  658.  
  659. for _, child in ipairs(vfx:GetChildren()) do
  660. if child:IsA("ParticleEmitter") then
  661. child.Enabled = false
  662. end
  663. end
  664. end
  665.  
  666. -- Function to cleanup VFX
  667. local function cleanupVFX(vfxName)
  668. local vfx = activeVFX[vfxName]
  669. if vfx then
  670. vfx:Destroy()
  671. activeVFX[vfxName] = nil
  672. end
  673. end
  674.  
  675. -- Function to load animation
  676. local function loadAnimation(animId, character)
  677. local humanoid = character:FindFirstChildOfClass("Humanoid")
  678. if not humanoid then return nil end
  679.  
  680. local animation = Instance.new("Animation")
  681. animation.AnimationId = animId
  682.  
  683. return humanoid:LoadAnimation(animation)
  684. end
  685.  
  686. -- Function to play animation sequence
  687. local function playAnimationSequence(player)
  688. if isAnimationSequenceActive then return end
  689. isAnimationSequenceActive = true
  690.  
  691. local character = player.Character
  692. if not character then return end
  693.  
  694. -- Load animations if not already loaded
  695. if not loadedAnimations.roughEnergy then
  696. loadedAnimations.roughEnergy = loadAnimation(KJUltANIM.AnimationId, character)
  697. end
  698.  
  699. -- Stop any existing animations
  700. for _, track in pairs(character:FindFirstChildOfClass("Humanoid"):GetPlayingAnimationTracks()) do
  701. track:Stop()
  702. end
  703.  
  704. -- Create VFX instances
  705. createVFX("groundWave", character)
  706.  
  707. -- Custom sequence
  708. task.spawn(function()
  709. loadedAnimations.roughEnergy:Play()
  710. task.wait(0.2)
  711. playVFX("groundWave", 1)
  712.  
  713. task.wait(0.3)
  714. loadedAnimations.roughEnergy:Stop()
  715. stopVFX("groundWave")
  716.  
  717. -- Cleanup
  718. task.wait(0.5)
  719. cleanupVFX("groundWave")
  720.  
  721. isAnimationSequenceActive = false
  722. end)
  723. end
  724.  
  725. -- Event handler for animation played
  726. local function onAnimationPlayed(animationTrack)
  727. if animationTrack.Animation.AnimationId == KJUltBase.AnimationId then
  728. playAnimationSequence(Players.LocalPlayer)
  729. end
  730. end
  731.  
  732. -- Set up character connections
  733. local function setupCharacter(character)
  734. -- Clear old animations
  735. loadedAnimations = {}
  736.  
  737. -- Clear old VFX
  738. for name, vfx in pairs(activeVFX) do
  739. vfx:Destroy()
  740. end
  741. activeVFX = {}
  742.  
  743. local humanoid = character:WaitForChild("Humanoid")
  744. humanoid.AnimationPlayed:Connect(onAnimationPlayed)
  745. end
  746.  
  747. -- Connect to local player's character
  748. local player = Players.LocalPlayer
  749. setupCharacter(player.Character or player.CharacterAdded:Wait())
  750. player.CharacterAdded:Connect(setupCharacter)
Advertisement
Comments
Add Comment
Please, Sign In to add comment
Advertisement