The Util package contains several components that may be needed in other parts of the application. The most important of these is the custom logging system, which is used by all other modules.
FastDistanceComparison
Distance calculation involves the taking of a square root, making it computationally expensive. While this is usually not a problem on modern machines, we sometimes need to perform large numbers of distance comparisons during experiments, i.e. when checking whether a certain location in the environment has been reached. To reduce computational load in these situations it is advantageous to compare the squared distances of points in questions, to avoid the square root call (also see here: https://docs.unity3d.com/ScriptReference/Vector3-sqrMagnitude.html). We provide such a comparison based on squared distances in a simple static class. The user can perform fast checks of the squared distance between points, as well as make use of a helper function with a boolean return value, which checks whether a point B is within a certain radius of a point A.
FindInterfaces
This static class can be used to find all class instances which implement a specific interface that are currently present in a given unity scene. For an example usecase see the custom logging system, where it is used to find all instances of ILoggable in the scene to hook them up with a logging manager.
SimplePlayerMover
An instance of this class can be attached to a gameobject that should serve as the player's avatar. It provides the minimal functionalities required to restrict player movement to specified translational and rotational velocities.
Assets
We have created a number of simple 3D models, which can be used to create simple virtual environments. Go here for an overview of the provided Assets.