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.

Newcomers DBPro Corner / First stab at 3D - Any advice on a couple of glitches please?

Author
Message
Melael Darkfury
20
Years of Service
User Offline
Joined: 29th Mar 2004
Location: UK
Posted: 4th Apr 2004 17:58
Just trying my first 3D and I have the following problems. Feel free to ignore them if you are busy, it just seemed if someone had hit these before they could point me in the right direction.

1) I wanted to try and add a second (fixed) camera viewing a part of my BSP map. When I do this, I get all sorts of green blobs corrupting the second camera view. If I change my default BSP camera to the second camera, that one looks fine but the main (mobile) camera then has the green blotches. Is it only possible to have one camera with a BSP map? Or maybe I am doing something silly.

2) Using the 'control camera using arrowkeys' I sometimes fall through floors or hit 'invisible' lumps in my example BSP map (just using a Quake3 Arena map to try a few things). Is this likely to be something I could prevent when creating my own BSP maps, or do I need to do some clever coding to stop falling through floors etc?

3) I tried to code PageUp and PageDown keys to pitch the camera, but when I use them they seem to snap the camera to face in a particular direction (imagine North). Also when I stop pressing the pitch up or down key, the view snaps back to centred, but if I press the key again it continues to pitch up from the position I last was in, like it had saved the position even after the view sanpped back to horizontal. Is this a limitation of using the auto-arrowkeys to move the camera or again am I doing something silly?

4) I have been using IF statements to check if the camera is in a specific location so that I could play some atmospheric sounds, would I be better doing this with some sort of invisible 'box' that I could check collision against or is there another/better way? I know it needs some work anyway, as it is currently possible to exit the area where the atmospheric sound plays without stopping the atmospheric sound, i.e. my nested IF's need some work

Any advice welcome.
Penfold
20
Years of Service
User Offline
Joined: 3rd Dec 2003
Location: RED postbox houses of parliment
Posted: 5th Apr 2004 00:06
All I can say is this... I'm still pretty green around the gill swith 3d myself..

You can try a couple of things

Option 1.

start your program from scratch I know this may sound like a pain but it may help you in the long run.
do each part 1 step at a time. I advise you to use a matrix rather than importing a seperate landscape until you have all your major bugs fixed.
Get your matrix up and running and get your camera or object running around freely first. don't worry about music or any other extra stuff until you get the core done. It only gets in the way when your searching your code for a problem
then include your music sounds and bits and pieces.

Option 2.
Take the part of the code your having problems with and detach it from your main code and just try to get that chunk to work on its own.. this may be a problem with your code as its very intergrated but you can give it a try..

anyway theres my two peneth..lol

'Ooh 'eck chief'...'crumbs'
Melael Darkfury
20
Years of Service
User Offline
Joined: 29th Mar 2004
Location: UK
Posted: 5th Apr 2004 13:55
Thanks for the reply. I have attached a much smaller bit of code which demonstrates a main camera which is movable round a BSP map, with a smaller camera looking at one spot in the top right corner. The smaller camera still has the green corruption problem.

The camera pitch change snapping me to face another direction, I read here was a known bug with Dark Basic and should be fixed in the next release (v6?).

Incidently, is there a way for me to tell how high above 'ground' my camera or main character (object) is within a BSP map? If so I could perhaps prevent at least some of my falling through the floor problems by reducing my height, by my height above ground, rather than doing a reposition of the camera making y=y-0.3 for example which I think sometimes dropped me below ground level. If that makes any sense.

Cheers,
indi
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 5th Apr 2004 14:07
here is an example for multiple camera usage.
feel free to pull it apart.
the green screen is the 2nd cameras default colour.




fall down seven times, stand up eight
Melael Darkfury
20
Years of Service
User Offline
Joined: 29th Mar 2004
Location: UK
Posted: 5th Apr 2004 17:02
Thanks I will take a look. I am wondering if the problem is related to the usage of a BSP map however, if I change the active BSP camera to be the static one it looks fine but the main camera has the green corruption.
Melael Darkfury
20
Years of Service
User Offline
Joined: 29th Mar 2004
Location: UK
Posted: 6th Apr 2004 18:07
Yeah your code works fine for me, so I guess its either a BSP issue or something silly I am doing.

Anyone else used multiple cameras on BSP maps?
indi
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 7th Apr 2004 10:05
color backdrop commands will alter the alternative cameras backgrounds.
fiddle with it and it may become apparant what is going on.


fall down seven times, stand up eight
Melael Darkfury
20
Years of Service
User Offline
Joined: 29th Mar 2004
Location: UK
Posted: 7th Apr 2004 14:43
Thanks for the reply.

Yeah if I fiddle with the backdrop color, it changes the color that shows up when some shapes are not drawn. As I am overlaying the small camera over the fullscreen output of the main camera, I can even get the missing shapes from the small camera to be transparent and show output from behind.

I will try adding a second camera to the tutorial with the alien squid things. Maybe its a problem with my BSP.

Thanks again for trying to help.

Login to post a reply

Server time is: 2024-11-26 12:18:27
Your offset time is: 2024-11-26 12:18:27