MatchMakingLobby/Lobby/MatchMakers/AbstractDistance.php
private function computeDistances($object, $followers, $distanceComputeCallback)
	{
		$distances = array();
		foreach($followers as $follower)
		{
			if($follower == $object)
				continue;
			$distances[$follower->id] = call_user_func($distanceComputeCallback, $object->data, $follower->data);
		}
		return $distances;
	}
private function computeDistances($object, $followers, $distanceComputeCallback)
	{
		$distances = array();
		foreach($followers as $follower)
		{
			if($follower == $object)
				continue;
			$distances[$follower->id] = call_user_func($distanceComputeCallback, $object->data, $follower->data);
		}
		return $distances;
	}
private function computeDistances ( $ object , $ followers , $ distanceComputeCallback ) { $ distances = array ( ) ; foreach ( $ followers as $ follower ) { if ( $ follower == $ object ) continue ; $ distances [ $ follower -> id ] = call_user_func ( $ distanceComputeCallback , $ object -> data , $ follower -> data ) ; } return $ distances ; }
Compute distance for a player with all his followers
@param string $player
@param string[] $followers
@return float[string]
Compute distance for a player with all his followers