im making a baldr (dont ask its just an addon on another game) which explodes when hitting a non character entity, but instead it explodes right after being shot
https://gyazo.com/832c3f4c990512f003899535bf097d98
here is the script that's supposed to trigger explosions
elseif (not hit:FindFirstChild("Hit")) then
script.Disabled = true
for i = 1, 25 do
local w = script.Parent.CFrame
script.Parent.Rotation = Vector3.new(math.random(-180 , 180), math.random(-180, 180), math.random(-180, 180))
script.Parent.Transparency = script.Parent.Transparency + 0.05
script.Parent.Size = script.Parent.Size + Vector3.new(0.1, 0.1, 0.1)
script.Parent.CFrame = w --just realized something : because of this line, the explosion doesnt rotate lol
script.Parent.Anchored = true
wait(0.05)
end
wait(2)
script.Parent:Destroy()
end
above elseif is the part of the script that triggers when hitting a character which is the part that works fine.
can you help me? (gif at top)
also, for the 'elseif (not hit:FindFirstChild("Hit")) then' i tried hit.Name ~= "Bullet", hit.Name == not "Bullet", hit.Name == not script.Parent.Name etc. none worked.
WORKS ONLINE | SOLVED

2 comments
Slower the delay at least, or spread.
do you mean slower firerate?