Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / 3D game with 2D Icon Commands. Notice a slow down - Why?

Author
Message
Leeorg
21
Years of Service
User Offline
Joined: 5th Jul 2005
Location:
Posted: 5th Jul 2005 08:46
Apologies if this has cropped up before, I have tried looking for a similar post.
My Query is this:
I have created a 3D board game that relies on 2D Icons to be selected by the mouse for options. The game runs at a good FPS before these icons are displayed. Afterwards the FPS falls right off. I have had 3 sprites on screen before I added the icons (keys were used to select options before - no sprites then) and no slow down was noticed. My total sprite count is now 6 on the screen at any one time and all sprites are hidden when the 3D action is happening (camera rotating around a table while dice are rolled.)
Any ideas why adding a couple of extra sprites can slow things down - even when hidden off screen?
Link102
21
Years of Service
User Offline
Joined: 1st Dec 2004
Location: On your head, weeeeee!
Posted: 5th Jul 2005 09:14 Edited at: 5th Jul 2005 09:14
I don't know why darkbasic isn't verry fast with sprites, but I do know a work-around.

Use plains that are pointed at the camera (be carefull, the point command puts the side of a plain towards the camera), then texure and ghost it.

please reply

Your signature has been erased by a mod because he was in the mood for it
Leeorg
21
Years of Service
User Offline
Joined: 5th Jul 2005
Location:
Posted: 6th Jul 2005 05:46
Found a solution!
I set up my sprites i.e. Sprite A,X,Y,C and then set them using SET SPRITE A,0,0 which turned transparency and backsave off. And then hid them all. From then on, I only needed to use Show Sprite and Hide Sprite and this has sped the whole game back to its usual speed.

Login to post a reply

Server time is: 2026-07-10 02:47:08
Your offset time is: 2026-07-10 02:47:08