So I'm trying to change the position so it glides across, like a cannon but the cannon is at a weird angle so I can't make the brick go in a straight line.
I thought of doing a for i loop, but I can't figure out how to set it up
(Sorry if the title is misleading/bad, couldn't think of anything else)
if canfire == true then
while true do
local bullet = Instance.new("Part", workspace)
bullet.CFrame = CFrame.new(524.021, 72.038, -120.748)-- * CFrame.Angles(0, 50, 0) this line might also cause it to error
bullet.Name = "Bullet"
bullet.Anchored = false
bullet.CanCollide = false
bullet.TopSurface = "Smooth"
bullet.BottomSurface = "Smooth"
bullet.Size = Vector3.new(1.5, 1.5, 1.5)
-- bullet.Transparency = 1
bullet.Position = Vector3.new(524.021, 72.038, -120.748)
v = Instance.new("BodyVelocity", bullet)
v.velocity = bullet.CFrame.new(0, 30, 0) -- errors
v.maxForce = Vector3.new(math.huge, math.huge, math.huge)
wait(4)
end
(not the full code)
error:
20:34:03.818 - new is not a valid member of CoordinateFrame 20:34:03.820 - Script 'Workspace.Level1.FireballShooter.Script', Line 25 20:34:03.821 - Stack End
(line 25 is line 14 in here)
I know how to use CFrame, but I guess I forgot something.
Thanks

4 comments
error on line 14 "Expected Identifier, got '='
also I already had an end for the while true loop do. Like I said that isn't the full code :P
Ah figured it out. I was doing something wrong with another piece of line.
lol ok