Package kr.toxicity.model.api.manager
Interface SkinManager
public interface SkinManager
Manages the retrieval and caching of player skins.
This manager handles fetching skin data from various sources (e.g., Mojang, SkinsRestorer) and provides a fallback skin when a profile cannot be resolved.
- Since:
- 1.15.2
-
Method Summary
Modifier and TypeMethodDescription@NotNull CompletableFuture<? extends SkinData> complete(ModelProfile.Uncompleted profile) Asynchronously completes an uncompleted model profile to retrieve its skin data.@NotNull SkinDatafallback()Returns the fallback skin data used when a skin cannot be resolved.voidremoveCache(@NotNull ModelProfile profile) Removes a specific profile from the skin cache.booleanChecks if a skin provider (like SkinsRestorer) is supported and available.
-
Method Details
-
supported
boolean supported()Checks if a skin provider (like SkinsRestorer) is supported and available.- Returns:
- true if supported, false otherwise
- Since:
- 1.15.2
-
fallback
Returns the fallback skin data used when a skin cannot be resolved.- Returns:
- the fallback skin data
- Since:
- 1.15.2
-
complete
@NotNull @NotNull CompletableFuture<? extends SkinData> complete(@NotNull ModelProfile.Uncompleted profile) Asynchronously completes an uncompleted model profile to retrieve its skin data.- Parameters:
profile- the uncompleted profile- Returns:
- a future that completes with the skin data
- Since:
- 1.15.2
-
removeCache
Removes a specific profile from the skin cache.- Parameters:
profile- the profile to remove- Since:
- 1.15.2
-