static @NotNull ResourcePackCallback onTerminal(final @NotNull BiConsumer<UUID, Audience> success, final @NotNull BiConsumer<UUID, Audience> failure) {
    return (uuid, status, audience) -> {
      if (status == ResourcePackStatus.SUCCESSFULLY_LOADED) {
        success.accept(uuid, audience);
      } else if (!status.intermediate()) {
        failure.accept(uuid, audience);
      }
    };
  }
Create a pack callback that will only execute the provided functions when the pack application has completed, discarding all intermediate events.

@param success the success callback
@param failure the failure callback
@return the created callback
@since 4.15.0
api/src/main/java/net/kyori/adventure/resource/ResourcePackCallback.java