# Sprite scaling, strange behaviour, where is the limit?

**URL:** https://forum.kirupa.com/t/sprite-scaling-strange-behaviour-where-is-the-limit/268590
**Category:** Uncategorized
**Created:** [August 15, 2008, 3:43pm UTC](https://forum.kirupa.com/t/sprite-scaling-strange-behaviour-where-is-the-limit/268590 "2008-08-15T15:43:40Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Yikulju](https://avatars.discourse-cdn.com/v4/letter/y/e68b1a/32.png) [@Yikulju](https://forum.kirupa.com/u/Yikulju)
#### Post date: [August 15, 2008, 3:43pm UTC](https://forum.kirupa.com/t/sprite-scaling-strange-behaviour-where-is-the-limit/268590/1 "2008-08-15T15:43:40Z")

</div>

Hi,

I’ve found that sprite scaling works strangely when I use quite small or big numbers.

Here is a code which works under a limit but above that the scaling just stops

there are two rectangles, a big and a small in the big.  
at the beginning it scales and then it just stops.

```
        var spr1:Sprite = new Sprite();
        var spr2:Sprite = new Sprite();
        
        spr1.graphics.clear();
        spr1.graphics.beginFill(0xff0000);
        spr1.graphics.drawRect(-150,-150, 300, 300);
        spr1.graphics.endFill();
        
        
        spr2.graphics.clear();
        spr2.graphics.beginFill(0x00ff00);
        spr2.graphics.drawRect(-20, -20, 40, 40);
        spr2.graphics.endFill();
        
        spr2.scaleX = 0.0001;
        spr2.scaleY = 0.0001;
        
        spr1.addChild(spr2);
        
        addChild(spr1);
        
        addEventListener(Event.ENTER_FRAME, function(event:Event)
        {
            spr1.scaleX += 1000;
            spr1.scaleY += 1000;

        });

```

do you know why?  
or I missed something?

thanks in advance  
Viktor
