drawing on top of tile

Started by
0 comments, last by Zakwayda 17 years, 4 months ago
Hey... I am making a 2D racing game and so far its going ok, I have drawna track, which is based on a 2D array, and have a car moving around the track... The next stage i am looking to implement is to have little boxes of ammo scattered around the track, that when the car drives through increases the cars ammo count, and then the box of ammo disapears.. I'm having real trouble implementing thsi is opengl... My thinking was that when im searching through the 2D array and drawing the track tiles, if i come across the number 7, which i have assigned to mean 'piece of track with ammo on it', then i would draw the track tile as normal, and then draw a small box in the centre of the track tile.. However, when i tried to do this it seemed to jsut mess up the entire track.. If any one could hepl me id be greatful, thanks very much
Advertisement
It's kind of hard to guess what the problem is from your description, so you might post some code (such as where you render the ammo item).

This topic is closed to new replies.

Advertisement