I am creating a flash game for iPhone using Flash CS5. Everything runs smoothly when creating the SWF via Ctrl+Enter. But when I am attaching the .p12 and provisioning profile files and publish the FLA to generate the .ipa there is an error thrown by the compiler that is:
"Incorrect number of arguments, Expected no more than 0"
private static function closestVertexOnOBB(p:Vector,r:RectangleParticle):Vector
{
var d:Vector = p.minus(r.samp);
var q:Vector= new Vector(r.samp.x, r.samp.y);
for (var i:int = 0; i < 2; i++)
{
var dist:Number = d.dot(r.axes[i]);
if (dist >= 0) dist = r.extents[i];
else if (dist < 0) dist = -r.extents[i];
q.plusEquals(r.axes[i].mult(dist));
}
return q;
}