Please or Register to create posts and topics.

Detecting if a point is inside a solid

Page 1 of 2Next

I was wondering how I would detect if a point is inside a solid physics entity or brush, or physics clip, or such.
Thank You,
Sound Logic

Bit vague, can you explain what you're trying to do so we can tell you the best thing to do?

What kind of point? A point entity?
All I can think of is using a trigger that has a filter.

?????????????????????????????TWP Releases | My Workshop

I am trying to setup a catapult cube that when placed upside-down it will detect the floor and launch itself. However I need to detect solid brushes for this.
Thank you,
Sound logic

Like I said, use a trigger with a filter of a block that is parented to the cube. When the (invisible) brush touches the trigger it will fire the catapult.

?????????????????????????????TWP Releases | My Workshop

You would get issues where when the cube is rolling on the floor it would also activate the trigger. You could perhaps use a timer to activate the catapult after say 0.5 seconds. If the block leaves the trigger then you could deactivate the timer.

Kasc wrote:
You would get issues where when the cube is rolling on the floor it would also activate the trigger.

A cube rolling? Seems as if havok has some problem, lol.

Portal 1.5 http://www.moddb.com/mods/portal-15
yohoat9 wrote:
Kasc wrote:
You would get issues where when the cube is rolling on the floor it would also activate the trigger.

A cube rolling? Seems as if havok has some problem, lol.

;)

Rolling is actually just rotation + translation, which is certainly possible for a cube.

I fail to see the proposed problem with the cube rolling, since that should activate the trigger. However, I am confused as how I use a filter to detect solid brushes. What settings would I use for the filter?

EDIT: I have been looking at the wiki, and would the class 'solid' work with the filter class?

The class is the entity type, IE prop_weighted_cube. You would want to use filter_activator_name since this is a special cube with a unique name, and not all weighted cubes.

[Important Threads] Forum Rules | Welcome to the new Thinking With Portals
Please do not Private Message me for assistance. Post a thread if you have questions or concerns.
If you need to contact the staff privately, contact the Global Moderators via Discord.
Page 1 of 2Next