fix: 复用皮肤站逻辑并稳定玩家头像

This commit is contained in:
2026-09-14 23:06:03 +08:00
parent 2a1dfa3c42
commit 0b30fc96a0
17 changed files with 1063 additions and 138 deletions

View File

@ -551,6 +551,13 @@ pub async fn get_available_skins() -> crate::Result<Vec<Skin>> {
Ok(available_skins)
}
/// Gets the bundled skin catalogue without requiring a selected Minecraft
/// credential. This is used by external account providers that manage their
/// own player profiles while reusing the launcher's native skin picker.
pub fn get_default_skins() -> Vec<Skin> {
assets::DEFAULT_SKINS.iter().cloned().collect()
}
/// Adds or updates a skin in the app database and equips it for the current profile.
/// Bundled default skins are only persisted when they have an associated cape.
#[tracing::instrument(skip(texture_blob))]