JubeatPlus 3.9.11
Loading...
Searching...
No Matches
StorePromotion Class Reference

A promoted pack or genre, with its banner artwork and, for a pack, its sample list. More...

#include <StorePromotion.h>

Inheritance diagram for StorePromotion:
Collaboration diagram for StorePromotion:

Instance Methods

(instancetype) - initWithPackInfo:imageURL:sampleURL:
 Builds a pack promotion and picks which of its samples to play.
(instancetype) - initWithGenreIndex:imageURL:
 Builds a genre promotion.
(nullable NSString *) - getSampleURL
 The chosen sample's audio address.
(nullable NSString *) - getSampleName
 The chosen sample's track name.

Properties

NSUInteger genreIndex
 The promoted genre's index.
StorePackInfo * packInfo
 The promoted pack.
NSString * imageURL
 The banner artwork's address, as text.
NSArray * sampleList
 The pack's sample tracks, one dictionary each.

Detailed Description

A promoted pack or genre, with its banner artwork and, for a pack, its sample list.

Method Documentation

◆ getSampleName

- (NSString *) getSampleName

The chosen sample's track name.

Unlike -getSampleURL this one has no nil guard on the sample list; see TYPES_PENDING.md.

Returns
The name.
Ghidra address:
0x1bd9d8
Ghidra address:
0x1bd9d8

◆ getSampleURL

- (NSString *) getSampleURL

The chosen sample's audio address.

Returns
The address, or nil when there is no sample list.
Ghidra address:
0x1bd954
Ghidra address:
0x1bd954

◆ initWithGenreIndex:imageURL:

- (instancetype) initWithGenreIndex: (NSUInteger) genreIndex
imageURL: (nullable NSString *) imageURL 

Builds a genre promotion.

A genre promotion has no samples: both _packInfo and _sampleList are cleared and the slot is set to zero.

Parameters
genreIndexThe promoted genre.
imageURLThe banner artwork's address.
Returns
The initialised promotion.
Ghidra address:
0x1bd88c

◆ initWithPackInfo:imageURL:sampleURL:

- (instancetype) initWithPackInfo: (nullable StorePackInfo *) packInfo
imageURL: (nullable NSString *) imageURL
sampleURL: (nullable NSArray *) sampleURL 

Builds a pack promotion and picks which of its samples to play.

The sample slot is chosen once here, with rand() , and never changes for the promotion's lifetime — so the same track plays every time until the promotion is rebuilt.

Parameters
packInfoThe promoted pack.
imageURLThe banner artwork's address.
sampleURLThe samples. Despite the name this is the sample list, an array of dictionaries, and it is what _sampleList holds.
Returns
The initialised promotion.
Ghidra address:
0x1bd754

Property Documentation

◆ genreIndex

- (NSUInteger) genreIndex
readnonatomicassign

The promoted genre's index.

Zero for a pack promotion.

Ghidra address:
0x1bda50 (getter)

◆ imageURL

- (NSString*) imageURL
readnonatomicassign

The banner artwork's address, as text.

Ghidra address:
0x1bda70 (getter)

◆ packInfo

- (StorePackInfo*) packInfo
readnonatomicassign

The promoted pack.

Nil for a genre promotion.

Ghidra address:
0x1bda60 (getter)

◆ sampleList

- (NSArray*) sampleList
readnonatomicassign

The pack's sample tracks, one dictionary each.

Nil for a genre promotion.

Ghidra address:
0x1bda80 (getter)

The documentation for this class was generated from the following files: