World of Warcraft Forever API · C_StableInfo.md, for your AI
C_StableInfo
17 functions, 5 events, 2 tables, as Blizzard documents them for Forever 1.60.1 (70959).
Making an addon with an AI? Tell it: Read https://wowaddons.gg/agents.md, then make me a World of Warcraft Forever addon that …, try it with me in the game, and publish it. It checks every call against this API before you try it in the game, then publishes it here. How it works.
Functions
C_StableInfo.BuyStableSlot
C_StableInfo.BuyStableSlot()
C_StableInfo.ClosePetStables
C_StableInfo.ClosePetStables()
C_StableInfo.GetActivePetList
activePets = C_StableInfo.GetActivePetList()
Returns
activePets | PetInfo[] |
|---|
C_StableInfo.GetAvailablePetSpecInfos
petSpecInfos = C_StableInfo.GetAvailablePetSpecInfos()
Returns
petSpecInfos | PetSpecInfo[] |
|---|
C_StableInfo.GetNextStableSlotCost
cost = C_StableInfo.GetNextStableSlotCost()
Returns
cost | number |
|---|
C_StableInfo.GetNumActivePets
numActivePets = C_StableInfo.GetNumActivePets()
Returns
numActivePets | number |
|---|
C_StableInfo.GetNumStablePets
numStablePets = C_StableInfo.GetNumStablePets()
Returns
numStablePets | number |
|---|
C_StableInfo.GetNumStableSlots
numSlots = C_StableInfo.GetNumStableSlots()
Returns
numSlots | number |
|---|
C_StableInfo.GetStablePetFoodTypes
foodTypes = C_StableInfo.GetStablePetFoodTypes(index)
Arguments
index | luaIndex |
|---|
Returns
foodTypes | string[] |
|---|
C_StableInfo.GetStablePetInfo
petInfo = C_StableInfo.GetStablePetInfo(index)
Arguments
index | luaIndex |
|---|
Returns
petInfo | PetInfo may be nil |
|---|
C_StableInfo.GetStabledPetList
stabledPets = C_StableInfo.GetStabledPetList()
Returns
stabledPets | PetInfo[] |
|---|
C_StableInfo.IsAtStableMaster
isAtStableMaster = C_StableInfo.IsAtStableMaster()
Returns
isAtStableMaster | bool |
|---|
C_StableInfo.IsBonusPetSlotAvailable
isAvailable = C_StableInfo.IsBonusPetSlotAvailable()
Returns
isAvailable | bool |
|---|
C_StableInfo.IsPetFavorite
isFavorite = C_StableInfo.IsPetFavorite(slot)
Arguments
slot | luaIndex |
|---|
Returns
isFavorite | bool |
|---|
C_StableInfo.PickupStablePet
C_StableInfo.PickupStablePet(index)
Arguments
index | luaIndex |
|---|
C_StableInfo.SetPetFavorite
C_StableInfo.SetPetFavorite(slot, isFavorite)
Arguments
slot | luaIndex | |
|---|---|---|
isFavorite | bool |
C_StableInfo.SetPetSlot
C_StableInfo.SetPetSlot(index, slot)
Arguments
index | luaIndex | |
|---|---|---|
slot | luaIndex |
Events
PET_INFO_UPDATE
No payload.
PET_STABLE_CLOSED
No payload.
PET_STABLE_FAVORITES_UPDATED
No payload.
PET_STABLE_SHOW
No payload.
PET_STABLE_UPDATE
No payload.
Tables
PetInfo structure
slotID | number | |
|---|---|---|
icon | fileID | |
name | string | |
level | number | |
familyName | string | |
specialization | string | |
type | string | |
petAbilities | number[] | |
specAbilities | number[] | |
displayID | number | |
isFavorite | bool | |
isExotic | bool | |
uiModelSceneID | number default 718 | |
petNumber | number | |
creatureID | number | |
specID | number | |
loyaltyLevel | number | |
loyaltyName | string | |
happinessLevel | number | |
experience | number | |
experienceNeeded | number |
PetSpecInfo structure
specID | number | |
|---|---|---|
specIndex | luaIndex | |
specializationName | string |