# Could anyone explain this getBounds related code?

**URL:** <https://forum.kirupa.com/t/could-anyone-explain-this-getbounds-related-code/192020>\
**Category:** flash\
**Created:** [June 25, 2006, 3:51am UTC](https://forum.kirupa.com/t/could-anyone-explain-this-getbounds-related-code/192020 "2006-06-25T03:51:15Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![woad](https://avatars.discourse-cdn.com/v4/letter/w/34f0e0/32.png) [@woad](https://forum.kirupa.com/u/woad)\
**Post date:** [June 25, 2006, 3:51am UTC](https://forum.kirupa.com/t/could-anyone-explain-this-getbounds-related-code/192020/1 "2006-06-25T03:51:15Z")

</div>

walls.onEnterFrame = function() {  
with (\_root.circle) {  
if (Key.isDown(Key.DOWN)) {  
\_y += 1;  
}  
if (Key.isDown(Key.UP)) {  
\_y -= 1;  
}  
if (Key.isDown(Key.LEFT)) {  
\_x -= 1;  
}  
if (Key.isDown(Key.RIGHT)) {  
\_x += 1;  
}  
if (this.hitTest(getBounds(\_root).xMax, \_y, true)) {  
\_x -= 1;  
}  
if (this.hitTest(getBounds(\_root).xMin, \_y, true)) {  
\_x += 1;  
}  
if (this.hitTest(\_x, getBounds(\_root).yMax, true)) {  
\_y -= 1;  
}  
if (this.hitTest(\_x, getBounds(\_root).yMin, true)) {  
\_y += 1;  
}  
}  
};

Can anyone explain to me how that all works exactly? Like the !\_root. and the stand-alone \_y, \_x, and \_root? And if you feel empowered try giving the getBounds explanation a shot please.  
I want to break free :jailbreak of my current stupidity on this subject and not stay in my stupid cage :jail:
