Newton Raycast Vehicle.

Share with us how are you using the powerrrr of the force

Moderator: Alain

Re: Newton Raycast Vehicle.

Postby Julio Jerez » Wed Nov 26, 2008 4:27 pm

Actually I will be interested in see how Master Sury when about implementing ray cast car.

The biggest problems in making a ray cast car is there it can no t be coded as an emerging physics behaviors.
Since tire equations are empirical, and are only define for vehicle moving at some speed, they because very untreatable when implemention car that need to run at low and high speed.

Maybe if I can see the code form both Master K00m, and Master Sury, I can combine the best of both and finally make the ray cast car.
I think that lots of Apprentices will appreciated that.
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Newton Raycast Vehicle.

Postby Sury » Wed Nov 26, 2008 4:46 pm

I will contribute mine.
It's ugly and has DX9 stuff in it. It works on newton 1.53(2), and behaves strange with new versions. Suspension is OK, but userjoint is somehow different.
Give me some time to finish some stuff.
User avatar
Sury
 
Posts: 193
Joined: Sat Aug 14, 2004 5:32 am
Location: Bulgaria

Re: Newton Raycast Vehicle.

Postby Julio Jerez » Wed Nov 26, 2008 5:06 pm

I take it.
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Newton Raycast Vehicle.

Postby Julio Jerez » Thu Nov 27, 2008 9:18 am

Suri if possible, you can send it to me the way it is now, I can figure out. :mrgreen:
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Newton Raycast Vehicle.

Postby Sury » Fri Nov 28, 2008 3:26 pm

Hi,
yesterday i sent you the code i have, along with two messages. I got no response. Did you get it ?
User avatar
Sury
 
Posts: 193
Joined: Sat Aug 14, 2004 5:32 am
Location: Bulgaria

Re: Newton Raycast Vehicle.

Postby Julio Jerez » Fri Nov 28, 2008 4:28 pm

Oh yes I have it, I am looking at it.
Is this the class you are using in you video?
I was tryin to find teh youtive video, but I cna no remember a key war for senrching it.
I think the code is clear, and I cna take teh pieces I nee to complete teh Ray cast Joint in teh engine.
I think it iwll be very aprecisted by many aprentices. Soem are getting impacient already.

coudl you tell me roughfully what teh forceand torque do an dwje teh joint do.
I can see the force and torque apply the suspention and the engine forces, but I do not see what is teh job of the joint.


Than you very much
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Newton Raycast Vehicle.

Postby Sury » Fri Nov 28, 2008 4:43 pm

Yes, that's the exact code i'm using. The code from the video is a bit older.
Probably this is the video, you were referring
http://www.youtube.com/watch?v=bDg9gTROylA

I will try to rip parts of my projects to make a small application, so you see. There are very few imposrtant tricks. The first is, that i'm actually offseting the position where the forces are applied. For a better stability, i'm applying forces not on tire position, but a bit offset to the center of the body, or "outside" the body. Second is I rotate the a matrix according to the front tires, take the right vector and apply LinearRow where they point. No setrowacceleration is used. Suspension damping is based on your sample posted on forums long time ago.
User avatar
Sury
 
Posts: 193
Joined: Sat Aug 14, 2004 5:32 am
Location: Bulgaria

Re: Newton Raycast Vehicle.

Postby Dave Gravel » Fri Nov 28, 2008 5:01 pm

The offseted force apply on a directional point is currently what I use too with the current newton raycast vehicle.
It's working pretty good in general, only on air and with slip situation it need some tweaking.
The major problem that I get currently is when my tire is more big that the normal vehicle shape.
You search a nice physics solution, if you can read this message you're at the good place :wink:
OrionX3D Projects & Demos:
https://orionx3d.sytes.net
https://www.facebook.com/dave.gravel1
https://www.youtube.com/user/EvadLevarg/videos
User avatar
Dave Gravel
 
Posts: 800
Joined: Sat Apr 01, 2006 9:31 pm
Location: Quebec in Canada.

Re: Newton Raycast Vehicle.

Postby agi_shi » Fri Nov 28, 2008 5:48 pm

Just a quick question, are raycast vehicles single bodies? Or are the tires/etc separate bodies? I'm looking to implement vehicles that go correctly through portals, and if the tires/etc were separate bodies, it'd be a bit hard :D
agi_shi
 
Posts: 263
Joined: Fri Aug 17, 2007 6:54 pm

Re: Newton Raycast Vehicle.

Postby Dave Gravel » Fri Nov 28, 2008 6:08 pm

Yes only a body the rest is casted collision shape's.
You search a nice physics solution, if you can read this message you're at the good place :wink:
OrionX3D Projects & Demos:
https://orionx3d.sytes.net
https://www.facebook.com/dave.gravel1
https://www.youtube.com/user/EvadLevarg/videos
User avatar
Dave Gravel
 
Posts: 800
Joined: Sat Apr 01, 2006 9:31 pm
Location: Quebec in Canada.

Re: Newton Raycast Vehicle.

Postby agi_shi » Fri Nov 28, 2008 8:31 pm

Sounds great :D. Being the physics newbie I am, right now I'll just lay back and wait for the ray cast car thing to be finished :D good luck, and it's looking great so far :D
agi_shi
 
Posts: 263
Joined: Fri Aug 17, 2007 6:54 pm

Re: Newton Raycast Vehicle.

Postby TheoLogic » Thu Dec 11, 2008 6:04 am

k00m; could you please tell me how you calculate your torque.
My vehicle is: or very slow, or the tires spin like hell.

Thx!
TheoLogic - Portfolio.
Wiki - Personal wiki pages.
TheoLogic
 
Posts: 35
Joined: Thu Oct 02, 2008 5:27 am

Re: Newton Raycast Vehicle.

Postby Dave Gravel » Thu Dec 11, 2008 6:09 am

I don't use torque at all to make it move, I only use torque to simulate the spinning visual tire effect.
I only apply a directional force at point on the vehicle body.
You search a nice physics solution, if you can read this message you're at the good place :wink:
OrionX3D Projects & Demos:
https://orionx3d.sytes.net
https://www.facebook.com/dave.gravel1
https://www.youtube.com/user/EvadLevarg/videos
User avatar
Dave Gravel
 
Posts: 800
Joined: Sat Apr 01, 2006 9:31 pm
Location: Quebec in Canada.

Re: Newton Raycast Vehicle.

Postby Dave Gravel » Thu Dec 11, 2008 6:09 am

I don't use torque at all to make it move, I only use torque to simulate the spinning visual tire effect.
I only apply a directional force at point on the vehicle body.
You search a nice physics solution, if you can read this message you're at the good place :wink:
OrionX3D Projects & Demos:
https://orionx3d.sytes.net
https://www.facebook.com/dave.gravel1
https://www.youtube.com/user/EvadLevarg/videos
User avatar
Dave Gravel
 
Posts: 800
Joined: Sat Apr 01, 2006 9:31 pm
Location: Quebec in Canada.

Re: Newton Raycast Vehicle.

Postby TheoLogic » Thu Dec 11, 2008 6:23 am

And how do you rotate the vehicle?
TheoLogic - Portfolio.
Wiki - Personal wiki pages.
TheoLogic
 
Posts: 35
Joined: Thu Oct 02, 2008 5:27 am

PreviousNext

Return to User Gallery

Who is online

Users browsing this forum: No registered users and 12 guests