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 / Darkbasicpro & dark physics

Author
Message
Justice
19
Years of Service
User Offline
Joined: 22nd Jun 2004
Location:
Posted: 23rd Nov 2014 12:43
Hi, (sorry if this is the wrong forum, but I tend to get some great advice here )

I have just bought Darkphysics and I have been trying out all the demos. (all work great)

I have changed a simple program of mine which creates a random maze and I walk around the maze. I had collision detection in it but I have removed it all. (I had used NGC collision which worked great)

I'm not testing for collision yet with dark physics. I just created a box and tried to move it around.
When that works I was going to add the collision.

When I run my program I get the error :

DARK BASIC PRO HAS STOPPED WORKING

Does anyone know why ?

This is driving me insane !!!

Attachments

Login to view attachments
Justice
19
Years of Service
User Offline
Joined: 22nd Jun 2004
Location:
Posted: 23rd Nov 2014 13:09 Edited at: 23rd Nov 2014 16:44
Partly solved my problem.

I didn't have the command phy start at the start of my program.

runs ok now apart that when I try to move the object tries to move down instead of the direction im pointing.

any ideas ?

Attachments

Login to view attachments
Virtual Nomad
Moderator
18
Years of Service
User Offline
Joined: 14th Dec 2005
Location: SF Bay Area, USA
Posted: 23rd Nov 2014 22:34 Edited at: 23rd Nov 2014 22:42
it looks like you're starting the player "beneath the ground"; its "falling" from the on-set, not "moving down". start the player up a little higher or make adjustments to the character controller to fix it.

meanwhile, try replacing sync 30 with sync 0 and increasing the player move speed; the player is moving/updating so slowly, it's hardly noticible.

and, while you're in there, remove camera 1 (which you've created); (the default) camera (0) is already working for you.

beyond that, consider:

replacing your player rotation with:
yrotate object 2,wrapvalue(object angle y(2)+mousemovex())

and, moving phy start up higher (still) in the code, per the examples/suggested usage.
Justice
19
Years of Service
User Offline
Joined: 22nd Jun 2004
Location:
Posted: 23rd Nov 2014 23:39
Thx for the help.

I worked out the problem in the end.

It was the player speed (as you suggested). I increased it (a lot) and it works fine.

thank you again for replying.

Login to post a reply

Server time is: 2024-03-28 08:32:31
Your offset time is: 2024-03-28 08:32:31