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 Professional Discussion / Objects leaving image "residue"

Author
Message
CALL ME B3AST
15
Years of Service
User Offline
Joined: 18th Oct 2010
Location: UNITED STATES
Posted: 30th Nov 2010 21:07
This is pretty much my first game in DBPro. I'm currently working on a 3D pong-like game, but my walls are "smearing" across the screen with and without textures on the walls. I'm not sure if it's my computer or not. You will need to dummy up a background image on line 10 or rem it out. Otherwise I have rem'ed out anything that would not load if you just slapped the code into your IDE and compiled/ran it. I have attached an image below to better explain this. Thanks in advanced for even viewing.





Forgive me for sometimes I am such a noob.
Indicium
18
Years of Service
User Offline
Joined: 26th May 2008
Location:
Posted: 30th Nov 2010 22:37
You have no sync on command, and you use the backdrop off command, which I believe disables screen clearing.. why?

CALL ME B3AST
15
Years of Service
User Offline
Joined: 18th Oct 2010
Location: UNITED STATES
Posted: 30th Nov 2010 22:59
For some reason when I use the sync on command I just get a black window like a command prompt with no text. Also about 1 out of 10 times I compile and run code with the sync on command no matter what sync rate it crashes the compiler and I have to reinstall. Dunno what that's about...but I have tried this code on other PC's with backdrop on/off and sync on/off. Yet I still get the same result, unless I turn the backdrop on, the backdrop loses it's image and I'm back to the default blue background.

Forgive me for sometimes I am such a noob.
Van B
Moderator
23
Years of Service
User Offline
Joined: 8th Oct 2002
Location: Sunnyvale
Posted: 1st Dec 2010 12:55
Quote: "
`Create Background
load bitmap "C:\Users\Mitchell\Desktop\Extreme Pong\Textures\background.jpg",0
set current bitmap 0
"


All this is doing is loading that image as the screen, bitmap 0 - but then as soon as you draw over it, it will be lost. I suggest loading that image as an IMAGE, then texture the backdrop with it, like TEXTURE BACKDROP Img.

If I was you, I'd do that, then add your sync on, and see how it goes from there. Don't dismiss the sync on, and persevere with any display issues you get.

Health, Ammo, and bacon and eggs!
CALL ME B3AST
15
Years of Service
User Offline
Joined: 18th Oct 2010
Location: UNITED STATES
Posted: 1st Dec 2010 16:21
TEXTURE BACKDROP Img worked! I just didn't ever try to compile/run with that command because the IDE doesn't color it blue. Weird...but anyway thanks!

Forgive me for sometimes I am such a noob.

Login to post a reply

Server time is: 2026-07-21 13:38:44
Your offset time is: 2026-07-21 13:38:44