Also habe ich es gelöst - mein Problem war, dass ich nicht wusste, wie man mit NSNumbers richtig mathematisiert wurde - ich wusste nicht, dass ich danach suchte, deshalb habe ich es nicht darum gefragt. Hier ist der Code, den ich entwickelt habe, um die Länge eines Albums auf Ihrem Gerät zu berechnen:
- (void)fullAlbumLength
{
for (int i=0; i < songsAlbumList.count; i++)
{
if (addLength == NULL) // addLength and addLengthNew are NSNumber variables
{
addLength = [[self.albumTracksList objectAtIndex:i] valueForProperty: @"playbackDuration"];
}
else
{
addLengthNew = [[self.albumTracksList objectAtIndex:i] valueForProperty: @"playbackDuration"];
addLength = [NSNumber numberWithFloat:([addLength floatValue] + [addLengthNew floatValue])];
}
}
fullminutes = floor([addLength floatValue] / 60); // fullminutes is an int
fullseconds = trunc([addLength floatValue] - fullminutes * 60); // fullseconds is an int
fullLength.text = [NSString stringWithFormat:@"%02d:%02d", fullminutes, fullseconds];
}
Hoffe das ist hilfreich für jemand anderen da draußen.