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.

Code Snippets / DBP Matrixs and NGC 2.03

Author
Message
Lost in Thought
20
Years of Service
User Offline
Joined: 4th Feb 2004
Location: U.S.A. : Douglas, Georgia
Posted: 9th Apr 2005 16:40 Edited at: 9th Apr 2005 16:42
Here is a version of using a DBP 5.8 Matrix and NGC 2.03. You can reposition the matrix *after entering it into the collision system* as much as you want. You can't yet and probably never will be able to quickly edit the matrix's collision data though. So no changing the matrixs without having to reload them. Maybe when v3 is fixed it is something we can look at. The only reason I done this was for bullet calcs on instant bullets. Get ground height is way faster for slow moving objects. I will clean this up and comment better later it is 2:30 a.m. here and I need some sleep.

[stupid swaer filter is blocking my code thought there is no swears in it] will post a .zip.

Attachments

Login to view attachments
Lost in Thought
20
Years of Service
User Offline
Joined: 4th Feb 2004
Location: U.S.A. : Douglas, Georgia
Posted: 10th Apr 2005 16:57 Edited at: 10th Apr 2005 17:03
Here is a neater code with lots of comments and a few extra NGC safetys when using matrixs.

[edit] You will want to lower the values of these variables in that code as I left them extremely high for testing: (I would change them to 20 for running on all systems)

xsegs = 20
zsegs = 20

Attachments

Login to view attachments
TEH_CODERER
20
Years of Service
User Offline
Joined: 12th Nov 2003
Location: Right behind you!
Posted: 12th Apr 2005 20:17
Sounds good but un-neccesary. I don't really understand what it is needed for. You can check for collisions using ground height and you can work out angles of collisions quite easily as well.

[url]andrewneale2004@yahoo.com[/url]
http://www.elbsoftware.tk
Lost in Thought
20
Years of Service
User Offline
Joined: 4th Feb 2004
Location: U.S.A. : Douglas, Georgia
Posted: 13th Apr 2005 09:25 Edited at: 13th Apr 2005 13:59
Quote: "The only reason I done this was for bullet calcs on instant bullets. Get ground height is way faster for slow moving objects."


Yeah I need to edit the example. You need this for fast bullet calcs to stop a bullet from going through the matrix. As I said get ground height is faster for slow moving collisions. I'll post an example of instant bullet collision when I get time.

[edit] Here is a quickly modified version showing get ground height for slow moving collision (player) and instant collision (lazer). You can easily modify the lazer to be a bullet. All you have to do is extract, copy your NGC dll into the folder, compile, and run.

I will be testing this a bit more and probably breaking the matrixs up as well as using sparky's dll to test as it is faster.

Attachments

Login to view attachments

Login to post a reply

Server time is: 2024-05-03 21:49:08
Your offset time is: 2024-05-03 21:49:08