MCPcopy Create free account
hub / github.com/TombEngine/TombEngine / Ray

Method Ray

TombEngine/Scripting/Internal/TEN/Collision/Los.cpp:74–75  ·  view source on GitHub ↗

Create a ray at a specified world position, direction, and distance in a room. @function Ray @tparam Vec3 pos World position. @tparam int roomNumber Origin room number. @tparam Vec3 direction Direction vector. @tparam float dist Maximum distance the ray can travel. @tparam[opt=Collision.IntersectionType.BOX] Collision.IntersectionType hitMoveables Collide with moveables. Disable when not needed or

Source from the content-addressed store, hash-verified

72 // @tparam[opt=false] bool penetrate Continue the ray test after the first hit. Enable this when you need to collect all collision information beyond the first occlusion point.
73 // @treturn Ray A new ray object.
74 Ray::Ray(const Vec3& origin, int roomNumber, const Vec3& dir, float dist) :
75 Ray(origin, roomNumber, dir, dist, ScriptIntersectionType::Box, ScriptIntersectionType::Box, false) { }
76
77 Ray::Ray(const Vec3& origin, int roomNumber, const Vec3& dir, float dist, ScriptIntersectionType hitMoveables) :
78 Ray(origin, roomNumber, dir, dist, hitMoveables, ScriptIntersectionType::Box, false) { }

Callers

nothing calls this directly

Calls 2

TENLogFunction · 0.85
GetLosCollisionFunction · 0.85

Tested by

no test coverage detected