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.

DLL Talk / NGC problems

Author
Message
Mandalore
19
Years of Service
User Offline
Joined: 18th Jul 2004
Location: USA
Posted: 23rd Jan 2005 15:35
I (along with some friends from school) am making an interactive virtual tour of a medieval castle for a unit project. If I don't get it working in DarkBASIC Pro, we're going to be forced to use 3drad (if any of you have ever used it you know how much it sucks). The only real problem is collision, and I've been trying to use Nuclear Glory (since the time for each student to explore is limited, I figure the demo will work for now); however; I'm running in to problems that I can't figure out

1: Collision only works about a quarter of the time. I run in to certain parts of the castle model, but right through others.

2: I seem to be running in to invisible walls in places... What the heck?

I'm pretty sure I've done everything correctly. I removed the second object from the demo and it loads and works, but only sparsely. I really need help, lest I be forced to defile myself with 3drad.

I'd like to buy NGC because my final course project will be something along the lines of a video game of sorts, and Nuclear Glory would make things alot easier... But it won't freakin' work!

Anyhow, if anyone could help me out here I'd appreciate it.

In Soviet Russia, thread locks YOU!
Lost in Thought
20
Years of Service
User Offline
Joined: 4th Feb 2004
Location: U.S.A. : Douglas, Georgia
Posted: 23rd Jan 2005 19:26 Edited at: 23rd Jan 2005 19:26
Well with no code and not knowing what version of NGC you are using it will be hard to help. The only thing I can think of right off is you are scaling the objects with DBP's native scale object command instead of the SetObjScalePRO command in NGC. Also if you are using version 3 make sure all 3 values in every SetObjRadiusPRO command are the same size and turn off the octree system as it is bugged.

Basically with NGC (all versions) you have a certain layout that works with almost any code. It is formatted like this.

delcare constants for making NGC easier to read
turn sync on and set sync rate
start collision system (StartCollisionPRO)
start debug mode (if developing)
if version 3 set exclusive mode for replacement commands (i use 0)
define the constants for your collision types (player, world, etc.)
setup how you want your objects to collide (SetCollisionsPro)
load your objects
set objects to a collision type (CollisionTypePRO)
set your objects size, radius, gravity, rotation and anything else affecting object
start your main loop
move, rotate objects
update the collision system (RunCollisionPRO())
update the camera to players position
use sync to show changes
end your loop

always follow this order and all should be well.

Mandalore
19
Years of Service
User Offline
Joined: 18th Jul 2004
Location: USA
Posted: 24th Jan 2005 04:36
Sorry about not including the code, I was really tired last nigth and wanted to get something off before I went to bed. Anyhow, here it is... It's more or less the same code from the "old demo" of version 2.03.

As a side note, it's not my object being able to fit through doors and stuff. I just randomly run in to invisible walls in the middle of large, open areas in the castle. Otherwise, there's basically no collision at all and I can go straight through jsut about everything (except for the afore mentioned invisible walls).

In Soviet Russia, thread locks YOU!
Lost in Thought
20
Years of Service
User Offline
Joined: 4th Feb 2004
Location: U.S.A. : Douglas, Georgia
Posted: 24th Jan 2005 08:35
Yeah NGC V2.03 sometimes has trouble with rotating objects at certain angles as well. I have had problems rotating to 65 degrees perfectly while 60 failed and so on. If it's not the rotation fault I don't know. The code seems ok.

Mandalore
19
Years of Service
User Offline
Joined: 18th Jul 2004
Location: USA
Posted: 24th Jan 2005 11:58
I have located the problem! Because DarkBASIC Pro is being really stupid, I can't use .3ds files in any of my projects (help with this would be great too). Anyhow, the issue is that when I use 3d exploration to make my .3ds in to .x, the stupid thing rotates the model 90 degrees on the x axis. So when I try to rotate the object, it rotates the visable object but for some reason keeps the collision at it's original place. That's why the collision doesn't work in some places an I run in to invisible walls in others. So can anyone suggest a good .3ds to .x converter or tell me why I can't use .3ds in my projects?

P.S. I have the latest NG now and my code remains the same as before.

Furry apes will get you...
Etienne
20
Years of Service
User Offline
Joined: 17th Jan 2004
Location: Paris
Posted: 10th Feb 2005 11:46 Edited at: 10th Feb 2005 11:51
Deep exploration is the best to me i tried alot believe me ... this should be overwritten again and again until they rewrite the load objects (and i agree with the 3DS to X issue , had the same prob and posted alot around)

I know this is your thread : the NG issue was solved so i'm just asking something : when using ellipse to poly , is it required to load objects ? cause right now i try to test the command on a regular coded box and it makes the ellypse object pass through it .

A pixel is nothing , lots of can be all

Login to post a reply

Server time is: 2024-04-23 20:08:12
Your offset time is: 2024-04-23 20:08:12