Having a problem with my script executing. It’s not doing anything, nor is it outputting errors?
Good Day Everyone, Today I want to say something and then when I say something it should light the person on fire. (Will Show a GIF). I want it to have a cooldown and I'm adding extra particles and stuff.
https://gyazo.com/15307aa42d8f11c5c7d38d91bf4a6807
The issue is it won't work. I'm not sure whether I'm spamming something or anything with my code but, any help is greatly appreciated. The animations on my person won't even play. I'm guessing it's something wrong with my if-then statements but still.
I've tried to ask my friends, but they don't know as well. Any help is much appreciated. I will post my Local and Server Scripts below.
After that, you should include more details if you have any. Try to make your topic as descriptive as possible, so that it's easier for people to help you!
Local Script
01 | local Player = game:GetService( 'Players' ).LocalPlayer |
02 | local Mouse = Player:GetMouse() |
03 | local Replicated = game:GetService( 'ReplicatedStorage' ) |
04 | local Char = Player.Character |
06 | local AllowBurn = false |
09 | Player.Chatted:Connect( function (message) |
10 | if message = = Spell then |
15 | Mouse.Button 1 Down:Connect( function () |
16 | if AllowBurn and not Debounce then |
18 | local hum = Mouse.Target.Parent:FindFirstChild( 'Humanoid' ) |
20 | Replicated:FindFirstChild( 'Ignis' ):FireServer(hum, 4456612982 ) |
Server Script
01 | game:FindFirstChild( 'ReplicatedStorage' ):FindFirstChild( 'Ignis' ).OnServerEvent:Connect( function (plr,hum,animationID) |
03 | local Replicated = game:GetService( 'ReplicatedStorage' ) |
05 | if (Player.Character:FindFirstChild( "HumanoidRootPart" ).Position - hum.Parent:FindFirstChild( "HumanoidRootPart" ).Position).magnitude < = Radius then |
07 | local Fire 1 = Replicated.FireParticles:FindFirstChild( 'Fire' ) |
08 | local Fire 2 = Replicated.FireParticles:FindFirstChild( 'Fire2' ) |
09 | local FireCore = Replicated.FireParticles:FindFirstChild( 'FireCore' ) |
11 | local animation = Instance.new( "Animation" ) |
14 | local loadedAnimation = game.Workspace [ Player.Name ] .Humanoid:LoadAnimation(animation) |
15 | loadedAnimation:Play() |
17 | local fire = Fire 1 :Clone() |
18 | fire.Parent = hum.Parent:FindFirstChild( 'LeftHand' ) |
20 | local fire 2 = Fire 2 :Clone() |
21 | fire 2. Parent = hum.Parent:FindFirstChild( 'LeftHand' ) |
23 | local firec = FireCore:Clone() |
24 | firec.Parent = hum.Parent:FindFirstChild( 'LeftHand' ) |
27 | local fire = Fire 1 :Clone() |
28 | fire.Parent = hum.Parent:FindFirstChild( 'RightHand' ) |
30 | local fire 2 = Fire 2 :Clone() |
31 | fire 2. Parent = hum.Parent:FindFirstChild( 'RightHand' ) |
33 | local firec = FireCore:Clone() |
34 | firec.Parent = hum.Parent:FindFirstChild( 'RightHand' ) |
38 | local fire = Fire 1 :Clone() |
39 | fire.Parent = hum.Parent:FindFirstChild( 'LeftHand' ) |
41 | local fire 2 = Fire 2 :Clone() |
42 | fire 2. Parent = hum.Parent:FindFirstChild( 'LeftHand' ) |
44 | local firec = FireCore:Clone() |
45 | firec.Parent = hum.Parent:FindFirstChild( 'LeftHand' ) |
48 | local fire = Fire 1 :Clone() |
49 | fire.Parent = hum.Parent:FindFirstChild( 'LowerTorso' ) |
51 | local fire 2 = Fire 2 :Clone() |
52 | fire 2. Parent = hum.Parent:FindFirstChild( 'LowerTorso' ) |
54 | local firec = FireCore:Clone() |
55 | firec.Parent = hum.Parent:FindFirstChild( 'LowerTorso' ) |
59 | local fire = Fire 1 :Clone() |
60 | fire.Parent = hum.Parent:FindFirstChild( 'LeftFoot' ) |
62 | local fire 2 = Fire 2 :Clone() |
63 | fire 2. Parent = hum.Parent:FindFirstChild( 'LeftFoot' ) |
65 | local firec = FireCore:Clone() |
66 | firec.Parent = hum.Parent:FindFirstChild( 'LeftFoot' ) |
70 | local fire = Fire 1 :Clone() |
71 | fire.Parent = hum.Parent:FindFirstChild( 'RightFoot' ) |
73 | local fire 2 = Fire 2 :Clone() |
74 | fire 2. Parent = hum.Parent:FindFirstChild( 'RightFoot' ) |
76 | local firec = FireCore:Clone() |
77 | firec.Parent = hum.Parent:FindFirstChild( 'RightFoot' ) |