As far as I know, a pixel is a pixel.
You can hardly move a DisplayObject half a pixel, can you?
Still the x and y properties of a DisplayObject allow values with two decimals.
A small test…
addEventListener(Event.ENTER_FRAME, enterFrameHandler);
function enterFrameHandler(e:Event):void {
myDisplayObject.y = Number(myInputBox.text);
trace(myDisplayObject.y);
}
… shows that this happens in steps of five (0, 0.05, 0.1, 0.15, etc.).
Values like for example 0.16 get converted to 0.15.
Also, the object moves 1 pixel as soon as it’s x/y value is .2
You would expect the x and y properties to convert the given numbers to integers, no?
I couldn’t find anything on this subject, neither on google nor on these forums
([SIZE=1]“The following words are either very common, too long, or too short and were not included in your search: x, y”[/SIZE])
Does someone have a clue on the sense behind this?
Thanks.