# Moving around a game board

**URL:** <https://forum.kirupa.com/t/moving-around-a-game-board/155612>\
**Category:** programming\
**Created:** [July 19, 2005, 5:39am UTC](https://forum.kirupa.com/t/moving-around-a-game-board/155612 "2005-07-19T05:39:42Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![marty177](https://avatars.discourse-cdn.com/v4/letter/m/e8c25b/32.png) [@marty177](https://forum.kirupa.com/u/marty177)\
**Post date:** [July 19, 2005, 5:39am UTC](https://forum.kirupa.com/t/moving-around-a-game-board/155612/1 "2005-07-19T05:39:42Z")

</div>

Hi,

I have two questions I was hoping to get some help with. I’m trying create a board game like the classic ‘Cluedo’ game. Pretty bold but exciting challenge. There are some major parts of the game I really cannot think of the best way to do it.

Firstly, the board is a essentially simple grid of square tiles. Part of the game involves the player rolling a die, the moving there pieces up to that number of times. They can only move up, down, left and right (no diagonals). Now I really don’t know the best way to do this. I had the idea the player could click adjacent tiles and then finally press a ‘move’ button, but it just seems messy.

Lastly, the player has to enter a room through a door. That is, they have to move to a certain tile to enter the room. How could you have a condition that allows the player to enter the room, only if they are on the tile with at least one move left?

I am sorry if that is not clear enough. I’ve added a .swf so that you might be able to look at the ‘floor plan’.

Thanks for taking the time.

Marty
