0

Hi

I am making a 2D adventure/rpg game in vb.net. At the moment, the character in the game moves around a game map, and initiates battle with any enemies he comes across.

The problem is that I want the terrain on the battle map to change according to the terrain on the game map. So if the character fights in water, the battle map is in water and if he fights on land, the battle map is on land. The crash collision as I know it works on squares. But the map I am using, like all maps, is not polygonal. Does anyone know how I could make the character detect whether he is on water or land, and the battle map changes accordingly?

Thankyou

2
Contributors
3
Replies
4
Views
8 Years
Discussion Span
Last Post by martonx
0

You should store your characters position in a 2D array. It is independent from terrain type, you have to store and check only the positions after every movement.
If two character positions are the same then a collision appear.

0

You choose the array. Your array could be the pixels of the screen, or the bitmaps of the map, or anything.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.