WoW:API GetPetFoodTypes

Revision as of 18:07, 31 October 2006 by WoWWiki>Bull3t
local PetFoodList = {GetPetFoodTypes()};

Returns

Returns a list with strings.

Possible strings

  • Meat
  • Fish
  • Fruit
  • Fungus
  • Bread
  • Cheese

Example

To print every string from the list into the default chatframe.

if(PetFoodList[1] ~= nil)then
    local index, j;
    for index, j in PetFoodList do
        if (PetFoodList[index] ~= nil) then	
            DEFAULT_CHAT_FRAME:AddMessage(PetFoodList[index]);
        end
    end
end