I'm not sure that I can use either for what I need, but thanks for searching. I think I may have to make an invisible entity at the point and use the StartTouch hook in the brush entity.
Untested but should work.
shared.lua
[lua]_R["Entity"].IsInsideEntity = function(self, ent)
local origin = self:LocalToWorld(self:OBBCenter())
local entnearest = ent:NearestPoint(origin)
return entnearest:Distance(self:NearestPoint(entnearest)) == 0
end[/lua]
in your brush entity or whatever.
[lua]if someentity:IsInsideEntity(self) then
--whatever
end[/lua]
Sorry, you need to Log In to post a reply to this thread.