# Follow the mouse from a fixed point

**URL:** <https://forum.kirupa.com/t/follow-the-mouse-from-a-fixed-point/262719>\
**Category:** flash\
**Created:** [June 9, 2008, 2:13pm UTC](https://forum.kirupa.com/t/follow-the-mouse-from-a-fixed-point/262719 "2008-06-09T14:13:34Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![jonnyby\_007](https://avatars.discourse-cdn.com/v4/letter/j/7ba0ec/32.png) [@jonnyby\_007](https://forum.kirupa.com/u/jonnyby_007)\
**Post date:** [June 9, 2008, 2:13pm UTC](https://forum.kirupa.com/t/follow-the-mouse-from-a-fixed-point/262719/1 "2008-06-09T14:13:34Z")

</div>

Hi - I am trying to make a character in Flash move his arm as you move the mouse across the file. In other words I want to have one point of an image fixed in place (his shoulder) but the other end moving to where the mouse is (preferably with a second joint as his elbow). Does anyone know of any tutorials I could use?

Thanks for any help you can give!

---

<div class="post-metadata">

**Author:** ![randomagain](https://avatars.discourse-cdn.com/v4/letter/r/35a633/32.png) [@randomagain](https://forum.kirupa.com/u/randomagain)\
**Post date:** [June 9, 2008, 3:37pm UTC](https://forum.kirupa.com/t/follow-the-mouse-from-a-fixed-point/262719/2 "2008-06-09T15:37:09Z")

</div>

straight forward static arms turning towards the mouse would be easy

having a joint and making it seem real… I guess you would have to add a weight to the elbow so the hand would move towards the mouse but the elbow would not then I guess depending on how far the mouse is the less weight on the elbow

_shrugs_

---

<div class="post-metadata">

**Author:** ![jonnyby\_007](https://avatars.discourse-cdn.com/v4/letter/j/7ba0ec/32.png) [@jonnyby\_007](https://forum.kirupa.com/u/jonnyby_007)\
**Post date:** [June 10, 2008, 8:51am UTC](https://forum.kirupa.com/t/follow-the-mouse-from-a-fixed-point/262719/3 "2008-06-10T08:51:40Z")

</div>

Okay I think the straight forward would be okay for now - no joint, just the hand following the direction of the mouse. Is there a tutorial available for such a thing?

Thanks for your help!

---

<div class="post-metadata">

**Author:** ![randomagain](https://avatars.discourse-cdn.com/v4/letter/r/35a633/32.png) [@randomagain](https://forum.kirupa.com/u/randomagain)\
**Post date:** [June 10, 2008, 9:35am UTC](https://forum.kirupa.com/t/follow-the-mouse-from-a-fixed-point/262719/4 "2008-06-10T09:35:04Z")

</div>

there are lots of examples “googley eyes” “follow mouse” “mouse trails”

search the forums, the main page of this site

> **[GoToAndLearn - Photography & Photo Editing](https://gotoandlearn.com)**
>
> GoToAndLearn - Photography & Photo Editing

> **[DEWA89 Slot Online: Banyak Pilihan Game Gacor Berinovatif](https://joobi.co/)**
>
> Dewa89 situs penyedia slot gacor provider terbaik dengan game online terlengkap. daftar dan mainkan rasakan sensasi yang berinovatif memberikan kemudahan x500.

> circle.onMouseMove = function(){  
> var \_\_x = \_xmouse - this.\_x ;  
> var \_\_y = \_ymouse - this.\_y ;  
> var angle = Math.atan2(\_\_y, \_\_x) \* 180 / Math.PI  
> this.\_rotation=angle  
> }

---

<div class="post-metadata">

**Author:** ![jonnyby\_007](https://avatars.discourse-cdn.com/v4/letter/j/7ba0ec/32.png) [@jonnyby\_007](https://forum.kirupa.com/u/jonnyby_007)\
**Post date:** [June 10, 2008, 10:41am UTC](https://forum.kirupa.com/t/follow-the-mouse-from-a-fixed-point/262719/5 "2008-06-10T10:41:24Z")

</div>

Great thanks randomagain I will go searching!
