Skip to content

Using the Library

Island Games edited this page Dec 3, 2021 · 1 revision

bool Bartender_StartBartender(char* encryptionKey, char* gameID, bool isUsingVita2D)

This function initializes the library. This should be called at the start of your program.

Parameters

Type Name Description
char* encryptionKey The password that was set in the Mixologist app for the trophy pack.
char* gameID The game ID that was set in the Mixologist app for the trophy pack.

Return
If the function returns true then the Bartender app has started and is functioning correctly. If it returns false then something went wrong.

bool Bartender_UnlockTrophy(int trophyID)

This function unlocks the trophy with the associated ID. You can see the ID number for each trophy in the upper right corner of the Mixologist app. Note: Vita Island Ice Tea trophies cannot be unlocked with this function. Since those trophies require that all previous trophies have been unlocked before unlocking, this check runs internally after each trophy unlock.

Parameters

Type Name Description
int trophyID The ID number of the trophy that you would like to unlock.

Return
If a trophy has been unlocked it will return true, otherwise, it will return false.

bool Bartender_CheckIfTrophyHasBeenUnlocked(int trophyNumber)

This function checks if a trophy has been unlocked. This feature is not necessary to run when unlocking a trophy using the Bartender_UnlockTrophy function, since this function runs a check during the unlock process. However, if you are doing some sort of internal trophy viewer such as in "Spy Chameleon", you can use this function to decide which trophies you would like to display.

Parameters

Type Name Description
int trophyID The ID number of the trophy that you would like to check the status for.

Return
The unlocked status of the trophy.

trophy Bartender_GetTrophyInfo(int trophyID)

Returns the trophy with the selected ID. If you are not using Vita2D, you can use this function to obtain information about the trophy to generate your own pop-up notification.

Parameters

Type Name Description
int trophyID The ID number of the trophy that you would like to obtain trophy information for.

Return
A trophy and all of its information, except for the Unlock Key.

std::string Bartender_GetTrophyImageDirectory()

Returns the path of the ".png" file that contains all of the trophy images.

Return
Returns the path of the ".png" file which contains all of the trophy images.