# What is wrong with this piece of.... code

**URL:** <https://forum.kirupa.com/t/what-is-wrong-with-this-piece-of-code/183988>\
**Category:** Uncategorized\
**Created:** [March 31, 2006, 7:33pm UTC](https://forum.kirupa.com/t/what-is-wrong-with-this-piece-of-code/183988 "2006-03-31T19:33:22Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Leo75](https://avatars.discourse-cdn.com/v4/letter/l/779978/32.png) [@Leo75](https://forum.kirupa.com/u/Leo75)\
**Post date:** [March 31, 2006, 7:33pm UTC](https://forum.kirupa.com/t/what-is-wrong-with-this-piece-of-code/183988/1 "2006-03-31T19:33:22Z")

</div>

Hi there!  
I am having some problems with my code no idea if it is logical or what is it. For some reason, when i move or access the buttons on a vertical motion, gives me the wrong coordinates. While with horizontal movement its ok.  
I cracked my head and i could find why. :sen:  
Trying to do a BattleShip game.

HELP!

The file is attached. Download it, and c what i am talking about.  
Cheers!  
Leo.
