# Swap Depth Hell - p me please!

**URL:** <https://forum.kirupa.com/t/swap-depth-hell-p-me-please/241825>\
**Category:** flash\
**Created:** [October 18, 2007, 2:39pm UTC](https://forum.kirupa.com/t/swap-depth-hell-p-me-please/241825 "2007-10-18T14:39:20Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Hallowed](https://avatars.discourse-cdn.com/v4/letter/h/e47774/32.png) [@Hallowed](https://forum.kirupa.com/u/Hallowed)\
**Post date:** [October 18, 2007, 2:39pm UTC](https://forum.kirupa.com/t/swap-depth-hell-p-me-please/241825/1 "2007-10-18T14:39:20Z")

</div>

Hey all! Good morning.

I am hoping you can help me. I have a project where I have three polaroids overlapping eachother. When the mouse is run over each of them, that one comes to the front. No problem.

But the problem is, I need a way to send them back to their original state. Currently whatever one was the last to be rolled over…will stay when I go to other pages. It just floats in it’s spot. How can I stop this? It’s driving me mad. Here’s the code I was trying:

```auto
on (rollOver){
swapDepths(getNextHighestDepth()); ;
}
on (rollOut){
swapDepths (getNextLowestDepth()); ;
}

```

Any help would be greatly appreciated!
