DistanceCheck

Description

A static utility class that provides a single method for getting the closest object, provided its given a target to find the distance from and a list of objects to find the distance to.

Public methods

static T GetClosestObject<T>(Transform target, IEnumerable<T> objects)

  • checks distance between the given target and all objects in the list and assigns the current and returns the value of T

  • this method and class have a concrete use in the grab point assignment part of InteractionHand

Last updated