Skip to content

Liquid Glass and Apple Music touches for the Spotify iOS app. A GPL-3.0 fork of spoti.pw 0.21.1.

C

fix: crossfade and AutoMix reach the player under Spoof Premium (#127)

My-Name-Is-Jeff690858585ad3
diff --git a/docs/tweaks.md b/docs/tweaks.md
index da403cc2..4d4575b0 100644
--- a/docs/tweaks.md
+++ b/docs/tweaks.md
@@ -80,7 +80,9 @@ Shared:
AdBlock/ EeveeSpotify's ad blocking: the ad and upsell services silenced (AdServices.x), ad components out of the
Hub JSON (AdHubs.x) and the feeds (Feeds.m), Premium pop-ups dropped (AdPopups.x), and the responses
rewritten on the way in (AdNetwork.x, Premium.m over the protobuf walker in Protobuf.m), with crossfade
- and automix switched on in the player core and crossfade's switch kept in step with its slider (Crossfade.x).
+ and automix switched on in the player core, the core and Settings both kept on the audio.crossfade
+ prefs rather than the account's Playback Settings, and crossfade's switch kept in step with its
+ slider (Crossfade.x).
With Spoof Premium on, RadioModes.m enables shuffle and repeat for radio/autoplay in either look:
only restrictions made entirely of radio, endless_context and autoplay are allowed.
Raw reason sets remain intact when Spotify copies its state. Positive radio evidence survives
diff --git a/tweak/Sources/Shared/AdBlock/Premium.m b/tweak/Sources/Shared/AdBlock/Premium.m
index 88bda479..77fccbeb 100644
--- a/tweak/Sources/Shared/AdBlock/Premium.m
+++ b/tweak/Sources/Shared/AdBlock/Premium.m
@@ -109,8 +109,13 @@ static const SGRule rules[] = {
// Premium account's sets both off (compared on 2026-10-09: the other core-ads values are the same for both).
{"core-ads", "enable_state_fetch_system", SGRuleForce, NO, NULL},
{"core-ad-detection", "use_ad_placements_beta", SGRuleForce, NO, NULL},
+ // The Settings page and the core each choose between the old audio.crossfade prefs and the account's Playback
+ // Settings. Both are kept on the old prefs, which the Settings page and AutoMix write; with the core's flag on, the
+ // core reads the account's settings and every write misses (issue #62).
{"ios-feature-settings", "use_playback_settings_crossfade", SGRuleForce, NO, NULL},
{"ios-feature-settings", "use_playback_settings_gapless", SGRuleForce, NO, NULL},
+ {"playback-settings", "use_playback_settings_crossfade", SGRuleForce, NO, NULL},
+ {"playback-settings", "use_playback_settings_gapless", SGRuleForce, NO, NULL},
{NULL, "enable_common_capping", SGRuleRemove, NO, NULL},
{NULL, "enable_pns_common_capping", SGRuleRemove, NO, NULL},
{NULL, "enable_pick_and_shuffle_common_capping", SGRuleRemove, NO, NULL},
@@ -365,9 +370,6 @@ static const SGRule rules[] = {
// Smart shuffle stays on in a Jam, as on Premium.
{"ios-system-smartshuffle", "allow_smart_shuffle_in_jams", SGRuleForce, YES, NULL},
{"core-player", "disable_smart_shuffle_when_in_jam", SGRuleForce, NO, NULL},
- // Automix: blended transitions between songs, off for Free.
- {"core-automix", "automix_enabled", SGRuleForce, YES, NULL},
- {"ios-feature-settings", "automix_enabled", SGRuleForce, YES, NULL},
};
static const size_t ruleCount = sizeof(rules) / sizeof(rules[0]);
@@ -392,6 +394,8 @@ static void setValue(NSMutableArray<SGPBField *> *value, SGPBField *replacement)
// Free account in this country is told, to set beside a Premium one when ads still play. Names and values only;
// replaced by each fetch.
static void keepLiveConfiguration(NSArray<SGPBField *> *fields) {
+ static BOOL loggedCrossfadeFlag;
+ NSString *crossfadeFlag = nil;
NSMutableString *text = [NSMutableString string];
for (SGPBField *field in fields) {
NSArray<SGPBField *> *value = field.number == 3 && field.wire == 2 ? SGPBParse(field.payload) : nil;
@@ -401,7 +405,14 @@ static void keepLiveConfiguration(NSArray<SGPBField *> *fields) {
if (SGPBFirst(value, 3)) shown = SGPBFirst(SGPBParse(SGPBFirst(value, 3).payload), 1).varint ? @"true" : @"false";
else if (SGPBFirst(value, 4)) shown = @(SGPBFirst(SGPBParse(SGPBFirst(value, 4).payload), 1).varint).stringValue;
else if (SGPBFirst(value, 5)) shown = SGPBText(SGPBFirst(SGPBParse(SGPBFirst(value, 5).payload), 1)) ?: @"";
- [text appendFormat:@"%@.%@ = %@\n", SGPBText(SGPBFirst(parts, 1)) ?: @"", SGPBText(SGPBFirst(parts, 2)) ?: @"", shown];
+ NSString *scope = SGPBText(SGPBFirst(parts, 1)) ?: @"", *name = SGPBText(SGPBFirst(parts, 2)) ?: @"";
+ if (!loggedCrossfadeFlag && [scope isEqualToString:@"playback-settings"] && [name isEqualToString:@"use_playback_settings_crossfade"]) crossfadeFlag = shown;
+ [text appendFormat:@"%@.%@ = %@\n", scope, name, shown];
+ }
+ // The core flag behind issue #62, as the server sent it, once a launch; live-config.txt shows a fetch without it.
+ if (crossfadeFlag) {
+ loggedCrossfadeFlag = YES;
+ SGLog(@"premium: server sent playback-settings.use_playback_settings_crossfade = %@", crossfadeFlag);
}
NSURL *caches = [NSFileManager.defaultManager URLsForDirectory:NSCachesDirectory inDomains:NSUserDomainMask].firstObject;
NSURL *folder = [caches URLByAppendingPathComponent:@"Vitrine" isDirectory:YES];