Outerra forum
Anteworld - Outerra Game => Modding: Importer, Tools & Utilities => JavaScript development => Topic started by: zzz on September 19, 2016, 06:55:18 pm
-
In the world interface, what are the purposes and arguments of find_object, find_object2, find_object_mesh, and find_object_point?
Putting in random values returns me the ECEF positions of objects when the camera is within their bounding box. Was wondering if I could use it to get the positions of all objects in a scene.
-
These take parameters that define a single ray, and return the object hit by it. Getting the positions of all objects would be likely too expensive, but sometimes it is used, for example for line-of-sight computation. Usually you'd spread it over several frames though.
-
These take parameters that define a single ray, and return the object hit by it. Getting the positions of all objects would be likely too expensive, but sometimes it is used, for example for line-of-sight computation. Usually you'd spread it over several frames though.
$world.nearest_objects(pos/*ECEF*/, radius/*radius of the sphere within which a search will be*/)
?
alternatively an easier solution.