This is supposed to shoot out a sphere a "Potato Thrower" but it does nothing.
local sp=script.Parent local head=sp:WaitForChild("Head") function shootpotato() local fireball=Instance.new("Part") potato.name="Effect" potato.BrickColor=BrickColor.new("Bright Yellow") potato.Shape="Ball" potato.Size=Vector3(2,2,2) potato.canCollide=false potato.CFrame=head.CFrame potato.Velocity=head.CFrame.lookVector*50 potato.TopSurface("Smooth") potato.BottomSurface("Smooth") potato.Parent=game.Workspace end while true do wait(2) shootpotato() end
local sp=script.Parent local head=sp:WaitForChild("Head") function shootpotato() local fireball=Instance.new("potato") potato.name="Effect" potato.BrickColor=BrickColor.new("Bright Yellow") potato.Shape="Ball" potato.Size=Vector3(2,2,2) potato.canCollide=false potato.CFrame=head.CFrame potato.Velocity=head.CFrame.lookVector*50 potato.TopSurface("Smooth") potato.BottomSurface("Smooth") potato.Parent=game.Workspace end while true do wait(2) shootpotato() end
This may be wrong, but you are creating a "Part" but trying to change a property of "potato". There may be another problem as you are not defining the location of "potato" and maybe "Effect" has something to do with it. If I'm wrong, just say.
local sp=script.Parent local head=sp:WaitForChild("Head") function shootpotato() local fireball=Instance.new("Part") potato.name="Effect" potato.BrickColor=BrickColor.new("Bright Yellow") potato.Shape="Ball" potato.Size=Vector3(2,2,2) potato.canCollide=false potato.CFrame=head.CFrame potato.Velocity=head.CFrame.lookVector*50 potato.TopSurface("Smooth") potato.BottomSurface("Smooth") potato.Parent=game.Workspace end while true do wait(2) shootpotato() end
Your problem here is, You didn't Define what Potato is, so:
local sp = script.Parent local head = sp:WaitForChild("Head") function shootpotato() local potato = Instance.new("Part") potato.name = "Effect" potato.BrickColor = BrickColor.new("Bright Yellow") potato.Shape = "Ball" potato.Size = Vector3(2,2,2) potato.canCollide = false potato.CFrame = head.CFrame potato.Velocity = head.CFrame.lookVector*50 potato.TopSurface = ("Smooth") potato.BottomSurface = ("Smooth") potato.Parent = game.Workspace end while true do wait(2) shootpotato() end