C_PetJournal
namespaceavailable in: camelotStatus in wowlua
80 functions: 2 implemented, 3 recorded, 75 guessed. 15 events, 3 of them fired by the emulator on its own.
Functions
| function | what it does | status |
|---|---|---|
CagePetByID | Puts the pet into a cage.not in Blizzard's documentation | guessed |
ClearFanfare | Marks a newly collected pet's fanfare as seen, by pet GUID. Blizzard's pet journal calls it after the pet's unwrap animation finishes. · by wowluanot in Blizzard's documentation | guessed |
ClearHoveredBattlePet | Clears the battle pet marked as hovered. · by wowlua() | guessed |
ClearRecentFanfares | Clears the recent pet fanfares. Blizzard's pet journal calls it when it hides. · by wowluanot in Blizzard's documentation | guessed |
ClearSearchFilter | Clears the search box in the pet journal.() | guessed |
DismissSummonedPet | Dismisses the given companion pet if it is summoned. · by wowlua(petID: string) | guessed |
FindPetIDByName | Returns pet species and GUID by pet name.not in Blizzard's documentation | guessed |
GetBattlePetLink | Returns a battle pet link.not in Blizzard's documentation | guessed |
GetDisplayIDByIndex | Returns one of a pet species' display IDs, or nil when there is none at that index. · by wowlua(speciesID: number, index: number): number? | guessed |
GetDisplayProbabilityByIndex | Returns the chance that a pet species appears with one of its displays, or nil when there is none at that index. · by wowlua(speciesID: number, index: number): number? | guessed |
GetNonBattlePetLinkByIndex | Returns a chat link for a companion pet that cannot battle, given its index in the pet journal. · by wowlua(index: number): string | guessed |
GetNumCollectedInfo | Returns the number of collected battle pets of a particular species.not in Blizzard's documentation | guessed |
GetNumDisplays | Returns how many displays (appearances) a pet species has, or nil for an unknown species. · by wowlua(speciesID: number): number? | guessed |
GetNumPetSources | Returns information about the number of pet sources.not in Blizzard's documentation | recorded |
GetNumPetTypes | Returns information about the number of pet types.not in Blizzard's documentation | guessed |
GetNumPets | Returns information about the number of battle pets.not in Blizzard's documentation | implemented |
GetNumPetsInJournal | Returns how many pets of the creature the player has collected and the most they can have. · by wowlua(creatureID: number): (number, number) | guessed |
GetNumPetsNeedingFanfare | Returns how many collected pets still have an unopened fanfare. Blizzard's collections micro button shows an alert when the number goes up. · by wowluanot in Blizzard's documentation | implemented |
GetOwnedBattlePetString | Returns a formatted string how many of a battle pet species the player has collected.not in Blizzard's documentation | guessed |
GetOwnedPetIDs | Returns the GUIDs of all pets the player owns. · by wowlua(): string[] | guessed |
GetPetAbilityInfo | Returns information about a battle pet ability.(abilityID: number): (string?, number?, number?) | guessed |
GetPetAbilityList | Returns pet battle abilities available to a particular battle pet species.not in Blizzard's documentation | guessed |
GetPetAbilityListTable | Returns a pet species' abilities with the levels at which they are learned, or nil for an unknown species. · by wowlua(speciesID: number): PetAbilityLevelInfo[]? | guessed |
GetPetCooldownByGUID | Returns the cooldown associated with summoning a battle pet companion.not in Blizzard's documentation | guessed |
GetPetInfoByIndex | Returns information about a battle pet.not in Blizzard's documentation | recorded |
GetPetInfoByItemID | Retrieves information about the battle pet species taught by the specified item.not in Blizzard's documentation | guessed |
GetPetInfoByPetID | Returns information about a battle pet.not in Blizzard's documentation | guessed |
GetPetInfoBySpeciesID | Returns information about a pet species.not in Blizzard's documentation | guessed |
GetPetInfoTableByPetID | Returns information about an owned pet, or nil when there is no such pet. · by wowlua(petID: string): PetJournalPetInfo? | guessed |
GetPetInfoTableBySpeciesID | Returns information about a pet species, or nil for an unknown species. · by wowlua(speciesID: number): PetJournalPetInfo? | guessed |
GetPetLoadOutInfo | Returns information about a slot in your battle pet team.(slot: number): (string?, number?, number?, number?, boolean?) | guessed |
GetPetModelSceneInfoBySpeciesID | Returns the model scene IDs used to show a pet species: one for the pet card and one for the loadout. · by wowluanot in Blizzard's documentation | guessed |
GetPetSortParameter | Returns the index of the currently active sort parameter.not in Blizzard's documentation | guessed |
GetPetStats | Returns the stats of a collected battle pet.not in Blizzard's documentation | guessed |
GetPetSummonInfo | Returns whether a pet can be summoned, the error that prevents it, and the error's text. · by wowlua(battlePetGUID: string): (boolean, PetJournalError, string) | guessed |
GetPetTeamAverageLevel | Returns the average level of pets in your battle pet team.not in Blizzard's documentation | guessed |
GetSearchFilter | Returns the text the pet journal is filtered by. · by wowlua(): string | guessed |
GetSummonBattlePetCooldown | Returns the cooldown of summoning a battle pet as start time, duration and whether it is enabled, the values CooldownFrame_Set takes. · by wowluanot in Blizzard's documentation | recorded |
GetSummonRandomFavoritePetGUID | Returns the GUID used for summoning a random favorite pet. · by wowluanot in Blizzard's documentation | guessed |
GetSummonedPetGUID | Returns information about a battle pet.not in Blizzard's documentation | guessed |
HasFavoritePets | Whether the player has marked any pet as a favorite. · by wowlua(): boolean | guessed |
IsCurrentlySummoned | Whether the given pet is summoned. · by wowlua(petID: string): boolean | guessed |
IsFilterChecked | Returns true if the selected filter is checked.not in Blizzard's documentation | guessed |
IsFindBattleEnabled | Returns whether the player can queue for PvP pet battles.not in Blizzard's documentation | guessed |
IsJournalReadOnly | Returns whether the pet journal can only be viewed, not changed. · by wowluanot in Blizzard's documentation | guessed |
IsJournalUnlocked | Returns whether the player can change the pet journal, such as the battle pet loadout. Blizzard's journal shows its loadout as read only (PET_JOURNAL_READONLY_TEXT) when this is false. · by wowluanot in Blizzard's documentation | guessed |
IsPetSourceChecked | Returns true if the pet source is checked.not in Blizzard's documentation | guessed |
IsPetTypeChecked | Returns true if the pet type is checked.not in Blizzard's documentation | guessed |
IsUsingDefaultFilters | Whether the pet journal uses its default filters. · by wowlua(): boolean | guessed |
PetCanBeReleased | Returns true if you can release the pet.not in Blizzard's documentation | guessed |
PetIsCapturable | Returns whether a battle pet in your collection is capturable (i.e. a wild pet).not in Blizzard's documentation | guessed |
PetIsFavorite | Returns true if the collected battle pet is favorited.not in Blizzard's documentation | guessed |
PetIsHurt | Returns whether the specified battle pet is injured and unable to participate in battles.not in Blizzard's documentation | guessed |
PetIsLockedForConvert | Returns whether a pet, by GUID, is locked because it is being converted. Blizzard's pet menu leaves out the summon option for such pets. · by wowluanot in Blizzard's documentation | guessed |
PetIsRevoked | Returns whether or not the pet is revoked.not in Blizzard's documentation | guessed |
PetIsSlotted | Returns whether a battle pet in your collection is part of your current battle pet team.not in Blizzard's documentation | guessed |
PetIsSummonable | Returns true if you can summon this pet.(battlePetGUID: string): boolean | guessed |
PetIsTradable | Returns whether or not a pet from the Pet Journal is tradable.not in Blizzard's documentation | guessed |
PetIsUsable | Returns whether the player can use a pet, by GUID. · by wowluanot in Blizzard's documentation | guessed |
PetNeedsFanfare | Returns whether a newly collected pet, by GUID, still has its fanfare to show. Blizzard's pet journal shows it wrapped until it is opened. · by wowluanot in Blizzard's documentation | guessed |
PetUsesRandomDisplay | Whether a pet species appears with a random display when summoned, or nil for an unknown species. · by wowlua(speciesID: number): boolean? | guessed |
PickupPet | Places a battle pet onto the mouse cursor.not in Blizzard's documentation | guessed |
PickupSummonRandomPet | Puts the summon random pet action on the cursor, to place on an action bar. Blizzard's pet journal calls it when its random pet button is dragged. · by wowluanot in Blizzard's documentation | guessed |
ReleasePetByID | Releases the pet.not in Blizzard's documentation | guessed |
SetAbility | Selects a battle pet ability to make available in battle.not in Blizzard's documentation | guessed |
SetAllPetSourcesChecked | Sets or clears all the pet sources in the filter menu.not in Blizzard's documentation | guessed |
SetAllPetTypesChecked | Sets or clears all the pet types in the filter menu.not in Blizzard's documentation | guessed |
SetCustomName | Sets a custom name for the pet.not in Blizzard's documentation | guessed |
SetDefaultFilters | Resets the pet journal's filters to their defaults. · by wowlua() | guessed |
SetFavorite | Sets (or clears) the pet as a favorite.not in Blizzard's documentation | guessed |
SetFilterChecked | Sets the filters in the filter menu.not in Blizzard's documentation | guessed |
SetHoveredBattlePet | Marks a battle pet as hovered. · by wowlua(battlePetGUID: string) | guessed |
SetPetLoadOutInfo | Places the specified pet into a battle pet slot.not in Blizzard's documentation | guessed |
SetPetSortParameter | Changes the battle pet ordering in the pet journal.not in Blizzard's documentation | guessed |
SetPetSourceChecked | Sets the pet source in the filter menu.not in Blizzard's documentation | guessed |
SetPetTypeFilter | Sets the pet type in the filter menu.not in Blizzard's documentation | guessed |
SetSearchFilter | Sets the search filter in the pet journal.(filterText: string) | guessed |
SpellTargetBattlePet | Casts the pending targeted spell on a battle pet in the pet journal. · by wowlua(battlePetGUID: string) | guessed |
SummonPetByGUID | Summons (or dismisses) a pet.not in Blizzard's documentation | guessed |
SummonRandomPet | Summons a random battle pet companion.not in Blizzard's documentation | guessed |
"by wowlua": no one documents this function, so wowlua wrote the description from its name, signature and behaviour.
Events
| event | payload | fired by the emulator |
|---|---|---|
BATTLEPET_FORCE_NAME_DECLENSION | name: string, battlePetGUID: string | not implemented |
COMPANION_LEARNED | no payload | not implemented |
COMPANION_UNLEARNED | no payload | not implemented |
COMPANION_UPDATE | companionType: string? | not implemented |
NEW_PET_ADDED | battlePetGUID: string | not implemented |
PET_JOURNAL_AUTO_SLOTTED_PET | slotIndex: number, battlePetGUID: string | not implemented |
PET_JOURNAL_CAGE_FAILED | no payload | not implemented |
PET_JOURNAL_LIST_UPDATE | no payload | implemented |
PET_JOURNAL_NEW_BATTLE_SLOT | no payload | not implemented |
PET_JOURNAL_PETS_HEALED | no payload | not implemented |
PET_JOURNAL_PET_DELETED | battlePetGUID: string | not implemented |
PET_JOURNAL_PET_RESTORED | battlePetGUID: string | not implemented |
PET_JOURNAL_PET_REVOKED | battlePetGUID: string | not implemented |
PET_JOURNAL_TRAP_LEVEL_SET | trapLevel: number | implemented |
UPDATE_SUMMONPETS_ACTION | no payload | implemented |
An event the emulator doesn't fire on its own can still be fired from a test: mock.fireEvent("BATTLEPET_FORCE_NAME_DECLENSION").
Structures
PetAbilityLevelInfo· abilityID, levelPetJournalPetInfo· speciesID, customName?, petLevel?, xp?, maxXP?, displayID?, isFavorite?, icon, petType, creatureID, name?, sourceText, description, isWild?, canBattle, tradable, unique, obtainable, canAttachToDecor, creatureModelScale?
sources
Signatures, events and structures: Blizzard's API documentation (Blizzard_APIDocumentationGenerated) (PetJournalInfo system, camelot 1.60.1). Descriptions: warcraft.wiki.gg's API pages, by its contributors, CC BY-SA 4.0 ↗; written by wowlua where no documentation describes the entry.