Cone-projected particles

I’m trying to make a particle effect that projects particles in a cone that go away from a certain point at a certain angle. I can’t get the spread (cone) to be the same at all different angles. The spread seems to get very narrow the closer it is to a quadrant edge (right angle), and spreads out more in between right angles.


coneAngle = (2*Math.random() - 1) * .5 + particleAngle;

particle_mc.speedX = -Math.cos(coneAngle) * (Math.random()*particleMaxSpeed);
particle_mc.speedY = -Math.sin(coneAngle) * (Math.random()*particleMaxSpeed);

Any tips?