Code Snippets / Perfect Newton Car Physics |
| Author | Message | ||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
Well, maybe almost perfect see attachment file. use WASD and mouse for Camera, use Arrow Keys for car and SPACE key for brakes. use F12 key for debug info. All the font images and Truck object is free to use, as long as you give me credits. I have few more cars to work with this if you need, just ask nicely and i may consider. Aaaand i need comments on, if this car is perfect? or almost perfect? |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
By the way, i have to tell you this is not all about newton vehicle, indeed its about whole newton, most of the code, you dont need just to run the car around, however i shared the code as a whole so you can do more than cars. even there are no REMS in the code, buoyancy, collisions are already set for immediate usage. |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
attached is another car model (LandRover - PathFinder) extract the files in the "carModels" directory. use the following variables for driving code: + Code Snippet use the following for the creation code in levels.DBA: + Code Snippet EDIT: Bug Fix; Correct the below part in the Main.Dba at Sub NewtonVehicleDrive + Code Snippet |
||
| Back to top |
|||
|
Sven B
User Joined: Wed Jan 5th 2005 Location: Belgium |
Sorry man, but this doesn't work with DBC. We can't use globals... |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
This is for DBPro, with Newton Physics wrapper 1.32 by walaber and kjelle. http://walaber.com |
||
| Back to top |
|||
|
Movey
User Joined: Wed Apr 13th 2005 Location: Cyberspace |
Car performs well.Very impressed. Have you tried it with advanced terrain? |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
no comments so far, and i need some to improve this ( i dont even have a driving licence |
||
| Back to top |
|||
|
TEH_CODERER
User ![]() Joined: Wed Nov 12th 2003 Location: Right behind you! |
I'll take a look when I get home. The example that came with Newton was pretty hopeless and hard to control. |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
Sure it works with advanced terrain perfectly, its fun to jump around |
||
| Back to top |
|||
|
Kjelle69
User Joined: Thu Aug 5th 2004 Location: Sweden 150 km north of arctic circle |
Very nice app !! This can really be something good ! The demo that came with newton is not supposed to be driveable, rather show what is possible and trig your own imagination, just like Cucumber apparently did ! I guess you spend some time tuning the vehicle right ? Great work ! -==The tame birds yearn, the wild ones dare to fly.==- http://Mtec.hostname.nu |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
Thanks Kjelle69, you are the man i found a way to make realistic cars the easy way, and yes Kjelle after wasting a full day tuning the car..and still needs some more as i said its 99% yet. ill post many cars for you to try tonight. |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
Here is a Bmw Serie6 to try out Variables for driving code: + Code Snippet use the following for the creation code in levels.DBA: + Code Snippet |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
Here is a Chevrolet Van to try out Variables for driving code: + Code Snippet use the following for the creation code in levels.DBA: + Code Snippet |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
Well, can anybody spare some web space to load new cars and example games made with this? |
||
| Back to top |
|||
|
Cellbloc Studios
User Joined: Mon Mar 15th 2004 Location: Atlanta, GA |
I can host the web space if you can tell me what's wrong with this line: 72:NDB_NewtonUpdateTires nVehicleJoint -This...is my boomstick! |
||
| Back to top |
|||
|
ALPHA ZERO PRODUCTIONS
User Joined: Sun Sep 28th 2003 Location: Mom ! I forgot where we live ! |
it doesn't work 4 me. Web designer for hire. $5-50 dollars per page For more info please e-mail me. ![]() |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
CellBloc: Because you dont have wrapper 1.32 (the newest one) Alpha: Because you dont have whether dbp 5.8 or newton wrapper 1.32 |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
As i dont have a place to upload huge files, ill try to explain some little stuff here. for first person camera without the need for ezrotate, the easiest way is editing the car mesh and adding a limb forexample a small box, to where the drivers eyes should be and adding the following code somewhere in the loop: (you have to define gameCamera variable) + Code Snippet for making a speed-o-meter, load the attached image outside of the loop as follows: + Code Snippet and loop it as follows: + Code Snippet Comments or questions please. |
||
| Back to top |
|||
|
Cellbloc Studios
User Joined: Mon Mar 15th 2004 Location: Atlanta, GA |
Yeap. Forgot I got a new Alienware notebook and out of all the things I didn't install, Newton was the one. This really is a nice piece of work you got here. My only disappointment is that I cannot "roll" the truck, and I can tell you from personal experience that it is "quite" easy to do with a truck. I will fool around with the acceleration to see if I can get it to roll. A promise is a promise. Please email me at quoteland [at] cellbloc [punto] com and I will email you the FTP info. [EDIT] Nevermind. I got it to roll. I did it the "Atlanta" way. Drive too fast, turn right hard, panic, turn left hard. Worked like a charm! -This...is my boomstick! |
||
| Back to top |
|||
|
Google Ad
AdBot Joined: Aug 26th 2002 Location: Everywhere |
|||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
increase the tires = 4 for the Ford and you will roll even without steering:p try the Pathfinder, for race style |
||
| Back to top |
|||
|
Cellbloc Studios
User Joined: Mon Mar 15th 2004 Location: Atlanta, GA |
Thanks! I sent the info to the email you have displayed. Let me know if you got it. -This...is my boomstick! |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
cellbloc, ive uploaded the files into the account you gave me, but i couldnt find the adress for it |
||
| Back to top |
|||
|
Cellbloc Studios
User Joined: Mon Mar 15th 2004 Location: Atlanta, GA |
http://www.cellbloc.com/CuCuMBeR/ Case Sensitive! Same goes for your filename. You had "Driver.rar" and in your HTML you had "driver.rar". I went ahead and fix it for you. Ah, the magic of unix..... -This...is my boomstick! |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
okay then, you can find in the following zip a cool driving sort of thing with all cars available above. http://www.cellbloc.com/CuCuMBeR/Drive.rar press C key to cycle through cameras(doesnt work for all cars) use arrow keys and space to control car wasd keys and mouse for free camera |
||
| Back to top |
|||
|
Cellbloc Studios
User Joined: Mon Mar 15th 2004 Location: Atlanta, GA |
CuCuMBer: Can you post an example of the car(s) working with the Advanced Terrain plugin please? -This...is my boomstick! |
||
| Back to top |
|||
|
Baggers
User ![]() Joined: Mon May 31st 2004 Location: Yonder over dem dere hills |
|
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
CellBloc: Change level.dba as follows, you already have the media if you downloaded the last file; + Code Snippet Baggers: its already so easy to implement new cars, all you have to do is making your own 3d car, making the collision bod file and put them in the appropriate folder. if you examine the code, you have to change the menu only then. about the track, building tracks is easy with 3dmax, all you have to do is loft a spline through another spline, and then paint it. |
||
| Back to top |
|||
|
Cellbloc Studios
User Joined: Mon Mar 15th 2004 Location: Atlanta, GA |
Slient Crash. I will look into it. (and yes I have the plugin installed because it works with the example that comes with the Advance Terrain) [EDIT] I take that back. It *ONLY* crashes on Land Rover (figures, first one I try). The other three work fine. -This...is my boomstick! |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
Thats strange,does it give an error code? |
||
| Back to top |
|||
|
Cellbloc Studios
User Joined: Mon Mar 15th 2004 Location: Atlanta, GA |
Nope, silent crash. I will try and use the "debugger" in a little bit and see if I can locate the issue. -This...is my boomstick! |
||
| Back to top |
|||
|
Professor
User ![]() Joined: Thu Oct 7th 2004 Location: USA |
CuCuMBeR, Can you post a exe file for the ones (Including myself) that dont have dbpro? Sorry if this has been brought up before i dont realy have time to read through all of this.. Sounds great though hope i can try it some time! ![]() Prodigy Games : Comunity FPS : 3ds Artist : Uvw Mapper http://forum.thegamecreators.com/?m=forum_view&t=41284&b=8 |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
Unfortunately, i cant because im on 56k modem. But maybe some other nice guy would do it for you. |
||
| Back to top |
|||
|
Professor
User ![]() Joined: Thu Oct 7th 2004 Location: USA |
Oh ok ![]() Prodigy Games : Comunity FPS : 3ds Artist : Uvw Mapper http://forum.thegamecreators.com/?m=forum_view&t=41284&b=8 |
||
| Back to top |
|||
|
Cellbloc Studios
User Joined: Mon Mar 15th 2004 Location: Atlanta, GA |
HAHAHAHA, I'm on a 14.4k! -This...is my boomstick! |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
Sorry to bump this up, but i was wondering if anybody managed or atleast try to make a computer controlled car on this scene? |
||
| Back to top |
|||
|
Cellbloc Studios
User Joined: Mon Mar 15th 2004 Location: Atlanta, GA |
I have one. It drives to waypoints. -This...is my boomstick! |
||
| Back to top |
|||
|
CuCuMBeR
User Joined: Sat Jan 11th 2003 Location: Turkey |
can i see it? |
||
| Back to top |
|||
|
Olli
User Joined: Fri Mar 11th 2005 Location: Finland |
Have anyone tried to make a vehicle with more than 4 wheels? I'm trying to make a militar vehicle with 8 turning wheels (2 in the front turning the opposite way related to 2 in the back). Any help would be more than welcome... Olli |
||
| Back to top |
|||
|
RaceGT
User Joined: Mon Aug 15th 2005 Location: Cyberspace |
Great demo, i found i could indeed roll the truck by driving it very far away and gathering speed, twitching to the right then hard left...I rolled it. But I'm having a problem with the Newton wrapper, in that I just installed the DB 5.8 upgrade (on a fresh install of DB Pro), and the Newton plugin 1.32, both the first time I've installed either one, so they're both fresh. But each of the demos in Newton 1.32 crashes on exit, as well as this good driving demo here. I'm very impressed with Newton and would like to get started (try) using it, and started looking at the demos, but I noticed each app using Newton crashes after quitting the program, causing an "illegal operation" dialog. I suspect it would be somewhere in the "NewtonDestroy" area since this might be global to all the apps, but can anyone confirm this? I can run the demos and see how they work fine, but each crashes after the program is ended. I figured since Kjelle was involved on this thread he might be able to shed some light on the subject since I'm still waiting for approval at the Newton forums, and haven't been able to post about it yet. I was very impressed with 'demo02' in the demos, the falling shapes and throwing them around. Very impressive! The way they interact could be exactly what I need in a program I'm developing, and I was hoping to start with demo02 and start tinkering towards my needs, but the crash on each exit made me have to pause. I still love it, just don't know if I'll be able to use it if it's just crashing all the time. If I can get it to work without crashing every time I'd be happy, I could probably use it as-is with what I've seen so far. However, I would like to see this project go as far as to be the best physics implementation possible! It's already way more than I would have expected, I just need to get this kink worked out before I can start working with it. http://www.geocities.com/crmnlelmnt/ |
||
| Back to top |
|||
Sorry, but it has been so long since anyone replied to this Thread that it has been automatically locked.
You may read it but not reply.
You may read it but not reply.
Forum Search
Enter a word or phrase to search our Forum for:
|
|











