#particle emitters not enabling

1 messages · Page 1 of 1 (latest)

hollow wraith
#

i need SERIOUS help guys, basically my script wont enable particle emitters no matter what i do, if i manually enable it does, but this doesnt seem to work. i can't see whats wrong


function Ability:OnPress(player)
    
    SFX.FireballSound:Play()
    
    local char = player.Character
    if not char then return end

    local arm = char:FindFirstChild("Right Arm") 
    if not arm then return end

    local fireball = VFX.FireballProjectile:Clone()
    fireball.CFrame = arm.CFrame
    fireball.Anchored = false
    fireball.CanCollide = false
    fireball.Parent = char
    




    local weld = Instance.new("Motor6D")
    weld.Part0 = arm
    weld.Part1 = fireball
    weld.Parent = fireball
    

    ACTIVE[player] = {
        Fireball = fireball,
        Weld = weld,
        StartTime = os.clock(),
        LastCharge = 0
    }
    
    EmitCharge(player)
    ACTIVE[player].LastCharge = 1
    
    local projectileAttachment = fireball:FindFirstChild("Projectile")
    if projectileAttachment then
        for _, v in ipairs(projectileAttachment:GetDescendants()) do
            if v:IsA("ParticleEmitter") then
                v.Enabled = true
            end
        end
    end
end

hardy hound
#

could you try adding
print(“particle enabled”)
in your if statement?

#

so i can see where the thing doesn’t work?

hollow wraith
#

i've added some, and they all work.

#

i think the problem might be my module

#

i have to sleep now, i can give you the rbxl if you want to find out