# Sensing the speed of the mouse

**URL:** <https://forum.kirupa.com/t/sensing-the-speed-of-the-mouse/303880>\
**Category:** Uncategorized\
**Created:** [January 28, 2010, 5:23pm UTC](https://forum.kirupa.com/t/sensing-the-speed-of-the-mouse/303880 "2010-01-28T17:23:18Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![m2244](https://avatars.discourse-cdn.com/v4/letter/m/ac91a4/32.png) [@m2244](https://forum.kirupa.com/u/m2244)\
**Post date:** [January 28, 2010, 5:23pm UTC](https://forum.kirupa.com/t/sensing-the-speed-of-the-mouse/303880/1 "2010-01-28T17:23:18Z")

</div>

Hello,

I am going to work on a game for my kids. Mot sure if it is a good idea for a game but it is an opportunity to learn more AS3. Anyway, Is there a way to run a function after the mouse has moved a certain speed for a certain amount of time? As if you were shaking somehting and then it explodes. Is there a way to even sense the speed of the mouse or would it be better to sense the number of times the mouse changes direction?

Any advice would be appreciated.
