TNT Basic Forums > Programming Q&A
Arrow scrolling and map scrolling
< Last Thread     Next Thread >
Thread        Post A Reply

09-21-2002 21:32

Posted by:

Click Here to Email Mark   Find more posts by Mark

I am curently tring to make a overhead first person shooter and after downloading TNT Basic 1.1, I had a look at the scrolling examples and decided to adapt it to my game. However, I already have a simple sprite movement system that uses arrow keys to move the character around the screen, but do I need to get rid of one as they look like they do simmilar tasks, but without the arrow key sprite movement, will my charcter be still in the centre of the screen for the entire game with the scenery moving around it? Not what I want!
Any help or ideas much appreciated.

09-22-2002 23:44

Posted by:

Find more posts by Mathew

Your player won't stay in the middle until you specify it to the computer. TNT has nothing already decided ( wich is good! ) such having a hero sprite.

You could use:

Xmap=X-320 >>>320 is half of 640<<<<
Ymap=Y-240 >>>240 is half of 480<<<<
set viewport offset 1,Xmap,Ymap

if you use that, you will have to use a larger canvas so that your viewport doesn't scroll out of it. If you need more help, tell me your e-mail adress and I'll send you and example.

09-23-2002 14:57

Posted by:

Click Here to Email Mark   Find more posts by Mark


i already worked pout that bit myself while experimenting with it, but thanks for the advice.

All times are GMT        Post A Reply

Forum Jump:
< Last Thread     Next Thread >

< Contact Us - TNT Basic >

Powered by: vBulletin Lite Version 1.0.1 Lite
Copyright © Jelsoft Enterprises Limited 2000.