Page 1 of 1

StaticTriangleGroup backside triangle cull

Posted: Sat Jun 28, 2008 5:37 pm
by Semei
Is it possible to not collide with backside facing triangles using StaticTriangleGroup? If yes, how that could be done? Thanks in advance

Re: StaticTriangleGroup backside triangle cull

Posted: Sat Jun 28, 2008 8:14 pm
by Zukarakox
Easily... no.

If you REALLY want to do it... you could raycast agaisnt the triangles from the object multiple times from all of its verticies going in the velocity's direction. (note: the actual triangles, not the StaticTriangleGroup, it returns null entities) Then check the order of the verticies (if they are facing, or not facing the object), and then add it to NonCollidableEntities of the object thats going to collide....

That would 'work' but it would probably have a very large amount of bugs as well as be extremly slow.

Re: StaticTriangleGroup backside triangle cull

Posted: Sat Jun 28, 2008 8:38 pm
by Norbo
Things similar to this may eventually be allowed, possibly in v0.6.0 or v0.7.0 when the detection system is more open to special case situations.

Right now, the triangles are just generally flat objects with nothing special about one side versus the other.