Hi !
Featured games (90)
games approved by the League of Dukes
Games in Showcase (777)
Games in Android Showcase (231)
games submitted by our members
Games in WIP (856)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Problem with Collision  (Read 3074 times)
0 Members and 1 Guest are viewing this topic.
Offline akito

Junior Newbie

« Posted 2007-04-26 07:47:45 »

Hello everybody!

I have a problem with collision in java3D.

I use WakeupOnCollisionEntry. It's ok if an object collides an other.

But if an object collides with a series of other objects, only the first collision is detected...

I have found a message which explain that impossible :

How can I do to have a good collision with more that two object?

Thank you!
Offline akito

Junior Newbie

« Reply #1 - Posted 2007-04-26 08:47:09 »

So, I have found this website :

But there aren't explicit example..

Somebody have use this website to implement collision? Can you show me an example to collide more than two object?

Thank you
Offline submitter

Senior Newbie

« Reply #2 - Posted 2007-04-26 10:57:42 »

I'm pretty new to Java3D myself and I found WakuponCollisionEntry was just way too slow to respond. It actually reports a collision once it has already occured. What you want in most cases is to be able to know beforehand whether a collision is about to occur so you can take the appropriate action immediately once it does occur. For this you need to use something called picking. The tutorial that you have linked to is good for understanding so make sure you understand what picking is all about. Also read the Sun Java3D tutorial on picking. And this is also very good:

Check this out for quite a good implementation:

Hope this helps.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Jeff

JGO Coder

Got any cats?

« Reply #3 - Posted 2007-04-27 16:53:08 »

You can use projected pick rays for simple collision prediction.

For real, modern game quality collision detection, you need to write a WakeOnFrame(0) behavior that has all the collision detection and correction logic.

This is is a non-trivial task.  Any really good book on writing 3D apps like FPSs though should have articles on it, as does the Oriely book on game physics.

Got a question about Java and game programming?  Just new to the Java Game Development Community?  Try my FAQ.  Its likely you'll learn something!
Offline akito

Junior Newbie

« Reply #4 - Posted 2007-04-28 09:44:30 »


Thank you very much for your answer!

I will test it on monday and I will tell you if have problems.

Thank you!
Pages: [1]
  ignore  |  Print  

hadezbladez (336 views)
2018-11-16 13:46:03

hadezbladez (180 views)
2018-11-16 13:41:33

hadezbladez (336 views)
2018-11-16 13:35:35

hadezbladez (83 views)
2018-11-16 13:32:03

EgonOlsen (2177 views)
2018-06-10 19:43:48

EgonOlsen (2205 views)
2018-06-10 19:43:44

EgonOlsen (1378 views)
2018-06-10 19:43:20

DesertCoockie (2011 views)
2018-05-13 18:23:11

nelsongames (1655 views)
2018-04-24 18:15:36

nelsongames (2300 views)
2018-04-24 18:14:32
Deployment and Packaging
by mudlee
2018-08-22 18:09:50

Java Gaming Resources
by gouessej
2018-08-22 08:19:41

Deployment and Packaging
by gouessej
2018-08-22 08:04:08

Deployment and Packaging
by gouessej
2018-08-22 08:03:45

Deployment and Packaging
by philfrei
2018-08-20 02:33:38

Deployment and Packaging
by philfrei
2018-08-20 02:29:55

Deployment and Packaging
by philfrei
2018-08-19 23:56:20

Deployment and Packaging
by philfrei
2018-08-19 23:54:46 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!