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.

Dark Physics & Dark A.I. & Dark Dynamix / I got vehicle powersliding and braking to work!

Author
Message
Lucy
17
Years of Service
User Offline
Joined: 19th Apr 2007
Location: Roanoke, VA USA
Posted: 27th Aug 2007 20:00 Edited at: 27th Aug 2007 20:23
YAY! Powersliding and vehicle brakes! Here's my source and media.

Sorry about the messiness of the code and sporadic comments. I'll be cleaning the code up later, I did clearly mark the parts I used to get power sliding and brakes to work though.

Oh and you'll need the DarkPhysics 1.01 update to get this to work. The IDE might forget to highlight the commands, or highlight them improperly (as it does for me), but it compiles fine.

(edit)I forgot to change the help text at the top of the screen that says that spacebar is boost and selfright... There is no self right and space bar is the brake.

Nothing I say is intended to be rude. My autism means that I do not know what is rude and what isn't rude. I apologize if I seem rude. It is not my intention.

Attachments

Login to view attachments
Alquerian
18
Years of Service
User Offline
Joined: 29th Mar 2006
Location: Reno Nevada
Posted: 27th Aug 2007 21:24
This works very nice! good work! It feels very realistic, I really like how your tires catch when you go over a jump too

Visit the Wip!
CJD
18
Years of Service
User Offline
Joined: 15th Mar 2006
Location:
Posted: 28th Aug 2007 17:34
Great! It handles far better than in the original demo

Now if only you could join other rigid bodies to vehicles, me and my friend could make a truck sim!

Your signature has been erased by a mod because it's larger than 600x120
Agent Dink
20
Years of Service
User Offline
Joined: 30th Mar 2004
Location:
Posted: 29th Aug 2007 07:59
This is looking good! I want to see some suspension though



BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 29th Aug 2007 12:03
Nice. I have attached the compiled version for anyone without Dark Physics, it's worth playing with.
I also changed the camera to follow the vehicle.

Attachments

Login to view attachments
Lucy
17
Years of Service
User Offline
Joined: 19th Apr 2007
Location: Roanoke, VA USA
Posted: 29th Aug 2007 20:58
I've been working on a new version that's a bit more realistic, but I'm trying to get DarkShader working for a compiled demo of the new version... Sadly, it seems that Dark Shader is causing DBPro to eat all objects every time the backbuffer is drawn.

Nothing I say is intended to be rude. My autism means that I do not know what is rude and what isn't rude. I apologize if I seem rude. It is not my intention.
NeX the Fairly Fast Ferret
19
Years of Service
User Offline
Joined: 10th Apr 2005
Location: The Fifth Plane of Oblivion
Posted: 29th Aug 2007 23:56
I just get a black screen when running that.


Since the other one was scaring you guys so much...
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 30th Aug 2007 00:34
It takes 30 seconds or so on a Dual Core AMD 4200+. Probably the terrain. You could reduce the resolution of the terrain to speed it up

Lucy
17
Years of Service
User Offline
Joined: 19th Apr 2007
Location: Roanoke, VA USA
Posted: 2nd Sep 2007 16:22 Edited at: 2nd Sep 2007 16:28
The terrain is actually pretty low res, the polies are huge. The terrain is merely stretched out immensely. There's maybe only 45-50k polies on the screen at any one time. Basically, I went for immense terrain, not detailed.

I have a 1.8 ghz Pentium4 dual core (the old school kind, before hyperthreading) in the house and it only takes about 7 seconds to load the test program up. So, there's probably something else going on if it's taking so long for you.

Anyway, here's the latest version. I've commented out the DarkShader stuff for now because i can't seem to fix the problem with it eating objects (which noone gets but me, even with the exact same source).

I made it use momentum instead of velocity for modifying the slipperyness of the tires. It's feels a bit more realistic now, but still not quite right. Namely, it's not behaving properly when you brake during a slide. Other than that, it just needs some more fine tuning.

I invite you to hack away at the settings (they're at the top of the gameloop() function to come up with a better formula. This is just proof of concept. I'm putting it out to let the community help figure out how to make it better

Nothing I say is intended to be rude. My autism means that I do not know what is rude and what isn't rude. I apologize if I seem rude. It is not my intention.

Attachments

Login to view attachments
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 3rd Sep 2007 00:32
I was responding to Nex's issue, I think the loading time is acceptable considering the size of the terrain.

What would be good, with only a small change, is to make your terrain with a road, and hills along each side. It would make it more fun to try and keep the car on the road.

NeX the Fairly Fast Ferret
19
Years of Service
User Offline
Joined: 10th Apr 2005
Location: The Fifth Plane of Oblivion
Posted: 11th Sep 2007 23:11
It runs after 1 minute and 36 seconds.
I know my computer isn't exactly top of the range; it's 5 years old. But Oblivion takes less time to load than that. What, exactly, is the hold up? And why has such a "revolutionary" physics engine produced results that can be easily done with five ground height checks and a little coding? I can't help but feel that the way the wheels are reacting with the terrain is a little Grand Turismo. Too plastic. Too smooth.


Since the other one was scaring you guys so much...
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 11th Sep 2007 23:43
It would take far more than a "little coding".

I believe the delay is Advanced Terrain, and making a huge, huuuge collision map for it.

Login to post a reply

Server time is: 2024-05-04 08:28:21
Your offset time is: 2024-05-04 08:28:21