开发者

1067: Implicit coercion of a value of type void to an unrelated type flash.geom:Matrix

Im confused, I passed a matrix datatype into the this.graphics.beginBitmapFill(); and i get Implici开发者_如何学Ct coercion of a value of type. below is my code.

var theMatrix:Matrix;
            theMatrix = new Matrix();
            this.graphics.beginBitmapFill(tileImage,theMatrix.translate(30,0));
            this.graphics.endFill();

and the followig error sprigs

1067: Implicit coercion of a value of type void to an unrelated type flash.geom:Matrix.


It's normal you are passing to the beginBitmapFill function a parameter theMatrix.translate(30,0) who return nothing (void)

do this instead:

theMatrix.translate(30,0);
this.graphics.beginBitmapFill(tileImage,theMatrix);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜