forums

TNT Basic Forums > Programming Q&A
Hint for faster games
< Last Thread     Next Thread >
Author
Thread        Post A Reply

10-31-2003 00:00

Posted by:
-wyvern

Location:
Bedroom

Find more posts by -wyvern

Just something I discovered: Sprites that overlap sprites (particlarly large sprites) can take a long time to draw. Try to use paste image instead, it makes your game much faster. Don't know if this is any help, but feel free to submit other ideas for optimising code.

10-31-2003 00:07

Posted by:
Leorik The Creator

Location:
Montréal,Québec(canada)

Find more posts by Leorik The Creator

yes thats what im using true its better ...

10-31-2003 07:15

Posted by:
Miles

Location:
Australia

Click Here to Email Miles   Find more posts by Miles

Paste Image? Then how would the sprite move etc?

10-31-2003 14:08

Posted by:
-wyvern

Location:
Bedroom

Find more posts by -wyvern

What you would do is to use another canvas, say canvas 2 which is specially reserved, and a viewport to canvas 0. You would then have your large sprite do whatever it wanted to do and then paste itself into the background, then turn it off before drawing. Repeat the process for the next frame. It might be a bit complicated for sprites that have to move rapidly, I mainly meant it for things like fancy moving background images to menus. you'll see when you download my game, should I ever chance to finish it.

-wyvern, still alive after sixteen birthdays.

11-01-2003 06:07

Posted by:
eekaydee

Location:
CA, USA

Click Here to Email eekaydee   Find more posts by eekaydee

Yeah, it's no good for me in my current game because I've written so much already, but it might come in handy for anything in the future. Thanks for the tip.

Yeah, I'm alive after 16 birthdays too!

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.