Alice Community

Alice Community (http://www.alice.org/community/index.php)
-   Suggestion Box (http://www.alice.org/community/forumdisplay.php?f=26)
-   -   Age-old collision question (http://www.alice.org/community/showthread.php?t=10676)

jrrTolkien 06-26-2014 11:03 PM

Age-old collision question
 
I know that everyone wants this, but do you think it's at all likely that there will ever be collision detection in Alice? :(

-Jrr

fourbros 06-27-2014 09:24 PM

I hope so.

I really hope so.

I REALLY REALLY hope so.

But seriously, I don't think that there ever will be. And isn't making the collision detection yourself part of the fun?

MrMoke 06-28-2014 11:04 AM

Exactly!
 
It's always been the best challenge for me, and also gives a deeper understanding of how important the center of objects are when figuring out the distances and directions of the bounce methods.

It's always better to [U]BE[/U] a programmer, than ask one to do something for you!

jrrTolkien 07-03-2014 12:44 PM

If only...
 
Well yeah, but that's [B]HARDER[/B]. :rolleyes: Anyway, Alice itself doesn't allow to make proper collision detection. :mad: The best you can really do is "if object is within threshold of" and that doesn't work with flat or square objects. And of course, I currently know hardly anything about Java, or I'd just try to edit the code itself. :o That's my next goal. To learn more Java. :D

-jrr

beachbum111111 07-03-2014 04:37 PM

I know if you make arrow keys control the camera it gives the camera real collision detection. It would be nice if this option wasn't so limited though.

jrrTolkien 07-05-2014 04:29 PM

Even that doesn't work
 
Yeah I noticed that, but if you move it into a corner, you can go through it.

chickentree 07-08-2014 12:41 PM

[QUOTE=jrrTolkien;54613]Well yeah, but that's [B]HARDER[/B]. :rolleyes: Anyway, Alice itself doesn't allow to make proper collision detection. :mad: The best you can really do is "if object is within threshold of" and that doesn't work with flat or square objects. And of course, I currently know hardly anything about Java, or I'd just try to edit the code itself. :o That's my next goal. To learn more Java. :D

-jrr[/QUOTE]

I've had some luck with using a second object. For instance, If I have an aircraft carrier to land on, I might create a half cylinder, align its flat side to the carrier deck and set it's vehicle to the carrier. Then, since the half cylinder is upside down, check if whatever is landing is below the half cylinder ( that is the same as above the carrier's flight deck.)
Its not elegant but it works.

Mark


All times are GMT -5. The time now is 06:15 AM.

Copyright ©2018, Carnegie Mellon University
Alice 2.x 1999-2012, Alice 3.x 2008-2012, Carnegie Mellon University. All rights reserved.