# Zoom in movieclip

**URL:** <https://forum.kirupa.com/t/zoom-in-movieclip/167351>\
**Category:** Uncategorized\
**Created:** [October 27, 2005, 12:58pm UTC](https://forum.kirupa.com/t/zoom-in-movieclip/167351 "2005-10-27T12:58:57Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![manga](https://avatars.discourse-cdn.com/v4/letter/m/6bbea6/32.png) [@manga](https://forum.kirupa.com/u/manga)\
**Post date:** [October 27, 2005, 12:58pm UTC](https://forum.kirupa.com/t/zoom-in-movieclip/167351/1 "2005-10-27T12:58:57Z")

</div>

hey again 🙂

i have a 1 movieclip names OBJ inside 1 movieclip named map

the map = 1000 x 1000 \_x=0 , \_y=0;

the OBJ movieclip = 100x100 \_x=100 , \_y=200; inside the map movieclip…

now… i scale the map to 20 %

on the stage…

now i when i click the OBJ movieclip inside the map movieclip

i want the map movieclip to \_xscale and \_yscale to 100%

but i want the OBJ movieclip to be position \_x=0 \_y=0 global to the stage?

so this doesnt work:

inside the map:  
on(Press){  
this.pt = {x:this.OBJ.\_x, y:this.OBJ.\_y};

this.onEnterFrame=function(){  
if (this.\_xscale\<=98) {  
this.\_xscale +=(100-this.\_xscale)/4;  
} else {  
this.\_xscale = 100;  
togar[0]=1;  
}  
if (this.\_yscale\<=98) {  
this.\_yscale +=(100-this.\_yscale)/4;  
} else {  
this.\_yscale = 100;  
togar[1]=1;  
}  
this.localToGlobal(this.pt)  
this.\_x=(this.\_x-pt.x) + pt.x  
this.\_y=(this.\_y-pt.y) +pt.y  
}

}

how can i scale and position the map moviexclip so the OBJ is global to x:0,y:0 on the stage and 100%

?
