Help with viewports

BlitzMax Forums/BlitzMax Beginners Area/Help with viewports

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Hi all,

I was hoping that someone could help me with viewports, it's just not clicking with me.

I can understand the sample that comes with blitzmax, but when i come to trying to expand on it for my own needs i can't get things to work right.

What i want is to have a gameplay area of any given size, and a viewport (say 800*600 in size) centered around the player, so that when the user moves the player ship the view port remains centered and the background scrolls accordingly.

Any clues/example code for this would be greatly appreciated.

Cheers
Charlie