local StarterGui = game:GetService("StarterGui") local FartButton = StarterGui:WaitForChild("FartButton") local character = script.Parent local KillAnim = script:WaitForChild("FartAnim") local Torso = script.Parent:WaitForChild("LowerTorso") local UserInputService = game:GetService("UserInputService") local emitter = Torso:WaitForChild("ParticleEmitter") local humanoid = character:WaitForChild("Humanoid") local KillAnimTrack = humanoid.Animator:LoadAnimation(KillAnim) local sound = script:WaitForChild("FartSound") local Head = script.Parent:WaitForChild("Head") local Neutral = Head:WaitForChild("face") local Grit = Head:WaitForChild("face2") local ReplicatedStorage = game:GetService("ReplicatedStorage") local Fart = ReplicatedStorage:WaitForChild("Fart") local FartVal = Fart.Value while true do if FartVal == true then print("Fart was Pressed!") Neutral.Transparency = 1 Grit.Transparency = 0 emitter.Rate = 8 humanoid.JumpPower = 200 humanoid.WalkSpeed = 34 KillAnimTrack:Play() sound:Play() wait(2) humanoid.WalkSpeed = 16 humanoid.JumpPower = 50 emitter.Rate = 0 Neutral.Transparency = 0 Grit.Transparency = 1 end end
I was wondering if i could get some help with this.
(I've also tried using ":GetPropertyChangedSignal" and it still doesn't work.)
you cant put FartVal as a variable...
u kinda have to do if Fart.Value == true then ....
It seems that "GetPropertyChangedSignal" worked for this, i was just doing it wrong.
local StarterGui = game:GetService("StarterGui") local character = script.Parent local KillAnim = script:WaitForChild("FartAnim") local Torso = script.Parent:WaitForChild("LowerTorso") local UserInputService = game:GetService("UserInputService") local emitter = Torso:WaitForChild("ParticleEmitter") local humanoid = character:WaitForChild("Humanoid") local KillAnimTrack = humanoid.Animator:LoadAnimation(KillAnim) local sound = script:WaitForChild("FartSound") local Head = script.Parent:WaitForChild("Head") local Neutral = Head:WaitForChild("face") local Grit = Head:WaitForChild("face2") local ReplicatedStorage = game:GetService("ReplicatedStorage") local Fart = ReplicatedStorage:WaitForChild("Fart") Fart:GetPropertyChangedSignal("Value"):Connect(function() if Fart.Value == true then Fart.Value = false Neutral.Transparency = 1 Grit.Transparency = 0 emitter.Rate = 8 humanoid.JumpPower = 200 humanoid.WalkSpeed = 34 KillAnimTrack:Play() sound:Play() wait(2) humanoid.WalkSpeed = 16 humanoid.JumpPower = 50 emitter.Rate = 0 Neutral.Transparency = 0 Grit.Transparency = 1 end end)