# \[FLASHCS3\] MC follow cursor in given area

**URL:** https://forum.kirupa.com/t/flashcs3-mc-follow-cursor-in-given-area/286925
**Category:** flash
**Created:** [April 23, 2009, 1:08am UTC](https://forum.kirupa.com/t/flashcs3-mc-follow-cursor-in-given-area/286925 "2009-04-23T01:08:11Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![goalpost95](https://avatars.discourse-cdn.com/v4/letter/g/da6949/32.png) [@goalpost95](https://forum.kirupa.com/u/goalpost95)
#### Post date: [April 23, 2009, 1:08am UTC](https://forum.kirupa.com/t/flashcs3-mc-follow-cursor-in-given-area/286925/1 "2009-04-23T01:08:11Z")

</div>

what i want to happen is have images in a movie clip scroll up and down but i don’t want to have to move the mouse to the top of the page to see the top image

here is my code so far

frame 1:

if (\_root.\_ymouse \> \_root.circle.\_y) {  
\_root.circle.\_y = (\_root.circle.\_y + 10);  
} else {  
\_root.circle.\_y = (\_root.circle.\_y - 10);  
}

frame 2:  
if (\_root.\_ymouse \> \_root.circle.\_y) {  
\_root.circle.\_y = (\_root.circle.\_y + 10);  
} else {  
\_root.circle.\_y = (\_root.circle.\_y - 10);  
}  
gotoAndPlay (1);
