Game Development Community

Fixed) Beta 1.1: getIsPointInObject() not working?

by Jason McIntosh · in Torque Game Builder · 02/16/2006 (7:37 am) · 9 replies

Calls to getIsPointInObject() seem to always returns false under beta1.1.

This is why my GUI code stopped working when I switched from alpha2, where it worked fine. I didn't change my GUI code at all between those versions. I tried space-delimited and comma-separated calling methods, but neither works. My debug output reports the corrdinates are within the object. Also, with debug panel/bounding boxes turned on, it's clear that the mouse is inside the objects.

Were there any changes made that could cause this?

Edit: This is under Mac OSX 10.3. Unconfirmed on Windows.

#1
02/19/2006 (7:26 am)
Just wanted to add that I ran the exact same TorqueScript code but swapped the alpha2 and beta1.1 executables. The beta1.1 did not work, while the alpha2 worked fine. So there must be a change there somewhere, right? Hmm, I guess I'll write my own function in script to work around this.
#2
06/05/2006 (1:53 pm)
This is verified to not work on PC or Mac. Could someone please verify that this function isn't working in a current version of TGB? I switched to the alpha3 from alpha2 and it quit working. Everything else seems to be working such that I might be able to use RC1 if this was working. (I can work around it in script, but maybe I found a bug?)

Any replies appreciated! :)
#3
06/05/2006 (3:56 pm)
I think it should work in RC1. This function has problems with counter-clockwise collision polygons. RC1 changes CC polys to clockwise automatically. You can find a alpha3 t2dPhysics.cc with this fix applied here. Password is "polyfix". Maybe that resolves your problem (if your polys are defined CC).
#4
06/06/2006 (6:23 am)
I do not define custom polys on these objects (just uses defaults), but I'll give this fix a try. Thanks for your help, yet again! :)
#5
06/07/2006 (3:50 pm)
@Michael: Is there a thread regarding this bug? I searched but didn't find it. I'm interested in verifying that the fix was applied to RC1. (I can't get alpha2 to compile with VC Express, so I'm gonna try to get RC1 working since it compiled flawlessly.)
#6
06/08/2006 (2:34 am)
There have been numerous issues with pickPoint() / getIsPointInObject() / the mouse callbacks lately. It is hard to tell if you have discovered a new bug if you do not verify this in the latest version.

But if you use only default polys then this particular bug fix will not help you anyway, I fear.
#7
06/08/2006 (6:16 am)
Well I dropped the RC1 .exe into the directory and it ran fine, with the exception that the getIsPointInObject() functionality does not work. Seems like evidence that something is amiss with RC1, too?
#8
06/08/2006 (6:56 am)
Well, I guess so ;) Maybe if you try RC2 which should be out today...
#9
06/17/2006 (8:52 am)
This appears to be fixed in RC3. Great work!! :)