(self, entity_positions)
Move camera toward its target poses.
Move camera toward its target poses.
Move camera toward its target poses .
def after_step(self, entity_positions):
    """Move camera toward its target poses."""
    target_pose = self._get_target_camera_pose(entity_positions)
    cur_pose = self._camera.get_pose()
    smoothing_update_speed = self._smoothing_update_speed
    filtered_pose = [
        target_val * smoothing_update_speed + \
        current_val * (1 - smoothing_update_speed)
        for target_val, current_val in zip(target_pose, cur_pose)
    ]
    self._camera.set_pose(*filtered_pose)
def after_step ( self , entity_positions ) : target_pose = self . _get_target_camera_pose ( entity_positions ) cur_pose = self . _camera . get_pose ( ) smoothing_update_speed = self . _smoothing_update_speed filtered_pose = [ target_val * smoothing_update_speed + current_val * ( 1 - smoothing_update_speed ) for target_val , current_val in zip ( target_pose , cur_pose ) ] self . _camera . set_pose ( * filtered_pose )