/trunk
local MRMDebug = false |
local MRM_Zones = {} |
function MountRandomMount:Reseed() |
local mountcount = GetNumCompanions("MOUNT") |
local id |
for j = 1, mountcount do |
local _, creatureName = GetCompanionInfo("MOUNT", j) |
local amount = string.lower(creatureName) |
for i = 1, #MountRandomMount_SavedTable['flying'] do |
if (amount == MountRandomMount_SavedTable['flying'][i][1]) then |
MountRandomMount_SavedTable['flying'][i][2] = j |
end |
end |
for i = 1, #MountRandomMount_SavedTable['ground'] do |
if (amount == MountRandomMount_SavedTable['ground'][i][1]) then |
MountRandomMount_SavedTable['ground'][i][2] = j |
end |
end |
end |
print(L['MRMReseedPrint']) |
end |
function MountRandomMount:MountRandom() |
if (MountRandomMount_SavedTable == nil) |
or ((MountRandomMount_SavedTable['flying'] == nil) and (MountRandomMount_SavedTable['ground'] == nil)) |
end |
if (foundmount == true) then |
local mounttoadd = mntspid |
if listtype == 'CL' then |
local sources, mounts |
for sources, mounts in pairs(MountRandomMount_MountDataList["flying"]) do |
table.foreach(mounts, function(k,v) |
if mntspid == v then |
listtype = 'flying' |
end |
end) |
end |
for sources, mounts in pairs(MountRandomMount_MountDataList["ground"]) do |
table.foreach(mounts, function(k,v) |
if mntspid == v then |
if listtype == 'flying' then |
listtype = 'both' |
else |
listtype = 'ground' |
end |
end |
end) |
end |
end |
if (listtype == 'flying') then |
if (MountRandomMount_SavedTable.randommountlist == nil) or (MountRandomMount_SavedTable['flying'] == nil) or (#MountRandomMount_SavedTable['flying'] == 0) then |
if (ibeg ~= nil) and (iend ~= nil) then |
rest = string.sub(rest2, ibeg+1, (iend -1)) |
end |
if (rest == L['MRMBronzeDrake']) then |
rest = L['MRMBronzeDrakeMount'] |
end |
if (command == L['MRMRandom']) then |
MountRandomMount:MountRandom() |
elseif (command == L['MRMLandOnly']) then |
else |
print(L['MRMNotADruid']) |
end |
elseif (command == L['MRMReseed']) then |
MountRandomMount:Reseed() |
elseif (command == "debug") then |
if MRMDebug then |
MRMDebug = false |
end |
end, |
set = function(info,val) |
local insert = true |
for iSaved, vSaved in pairs(MountRandomMount_SavedTable['ground']) do |
if vSaved == v then |
table.remove(MountRandomMount_SavedTable['ground'], iSaved) |
insert = false |
break |
end |
if MountRandomMount_SavedTable['ground'][v] == nil then |
MountRandomMount_SavedTable['ground'][v] = v |
else |
MountRandomMount_SavedTable['ground'][v] = nil |
end |
if insert then |
table.insert(MountRandomMount_SavedTable['ground'], v) |
end |
end, |
get = function(info) |
for iSaved, vSaved in pairs(MountRandomMount_SavedTable['ground']) do |
if vSaved == v then |
return true |
end |
if MountRandomMount_SavedTable['ground'][v] == nil then |
return false |
else |
return true |
end |
return false |
end |
} |
allmounts[GetSpellInfo(v)] = optionTableMount[GetSpellInfo(v)] |
L['MRMNoMounts'] = "You haven't added any mounts to the list, please use /rdm add [mount name] to do this." |
L['MRMNoLandMounts'] = "You have not added any land mounts to your random list." |
L['MRMNoFlyingMountsLand'] = "You have not added any flying mounts to your random list. Using a Land mount." |
L['MRMBronzeDrake'] = "bronze drake" |
L['MRMBronzeDrakeMountMount'] = "bronze drake mount" |
L['MRMRandom'] = "random" |
L['MRMLandOnly'] = "landonly" |
L['MRMAdd'] = "add" |
L['MRMRemove'] = "remove" |
L['MRMList'] = "list" |
L['MRMGui'] = "gui" |
L['MRMReseed'] = "reseed" |
L['MRMReseedPrint'] = "Mounts have been reseeded." |
L['MRMCatInside'] = "catform" |
L['MRMCommands'] = "MountRandomMount v"..GetAddOnMetadata("MountRandomMount", "Version").."\n use: /rdm -- prints this help\n /rdm add [mount name] (can also shift click from your mount list) -- adds another mount to the random list\n /rdm remove [mount name] (can also shift click from your mount list) --removes a mount from the list\n /rdm list -- lists the mounts to select from\n /rdm gui -- brings up a GUI of your mounts\n /rdm random -- mounts a random mount from your list (using flying in flyable areas and land in nonflyable areas)\n /rdm landonly -- mounts a random land mount from your list\n /rdm catform -- will enable/disable using Cat Form inside and in instances.\n There are a few keybindings option in the Blizzard KeyBindings Menu. One will summon a random mount (fly/land, one will summon a land wherever you are, and one is for class summons.\n " |
L['MRMCommands'] = "MountRandomMount v"..GetAddOnMetadata("MountRandomMount", "Version").."\n use: /rdm -- prints this help\n /rdm add [mount name] (can also shift click from your mount list) -- adds another mount to the random list\n /rdm remove [mount name] (can also shift click from your mount list) --removes a mount from the list\n /rdm list -- lists the mounts to select from\n /rdm gui -- brings up a GUI of your mounts\n /rdm reseed -- if you use more than one computer and you learn a new mount, your list will not work on the other computer, use this to reseed correct mount ID's\n /rdm random -- mounts a random mount from your list (using flying in flyable areas and land in nonflyable areas)\n /rdm landonly -- mounts a random land mount from your list\n /rdm catform -- will enable/disable using Cat Form inside and in instances.\n There are a few keybindings option in the Blizzard KeyBindings Menu. One will summon a random mount (fly/land, one will summon a land wherever you are, and one is for class summons.\n " |
L['MRMNoFlyingMounts'] = "You have not added any flying mounts to your random list." |
L['MRMListTitle'] = "The mounts in your random list are: " |
L['MRMListFlyingTitle'] = "Flying mounts used in Outland/Northrend (except Dalaran/WG): " |
L['MRMNoMounts'] = "You haven't added any mounts to the list, please use /rdm add [mount name] to do this." |
L['MRMNoLandMounts'] = "You have not added any land mounts to your random list." |
L['MRMNoFlyingMountsLand'] = "You have not added any flying mounts to your random list. Using a Land mount." |
L['MRMBronzeDrake'] = "éé é¾" |
L['MRMBronzeDrakeMountMount'] = "éé é¾åº§é¨" |
L['MRMRandom'] = "random" |
L['MRMLandOnly'] = "landonly" |
L['MRMAdd'] = "add" |
L['MRMReseed'] = "reseed" |
L['MRMReseedPrint'] = "Mounts have been reseeded." |
L['MRMCatInside'] = "catform" |
L['MRMCommands'] = "MountRandomMount v"..GetAddOnMetadata("MountRandomMount", "Version").."\n use: /rdm -- prints this help\n /rdm add [mount name] (can also shift click from your mount list) -- adds another mount to the random list\n /rdm remove [mount name] (can also shift click from your mount list) --removes a mount from the list\n /rdm list -- lists the mounts to select from\n /rdm gui -- brings up a GUI of your mounts\n /rdm random -- mounts a random mount from your list (using flying in flyable areas and land in nonflyable areas)\n /rdm landonly -- mounts a random land mount from your list\n /rdm catform -- will enable/disable using Cat Form inside and in instances.\n There are a few keybindings option in the Blizzard KeyBindings Menu. One will summon a random mount (fly/land, one will summon a land wherever you are, and one is for class summons.\n " |
L['MRMCommands'] = "MountRandomMount v"..GetAddOnMetadata("MountRandomMount", "Version").."\n use: /rdm -- prints this help\n /rdm "..L['MRMAdd'].." [mount name] (can also shift click from your mount list) -- adds another mount to the random list\n /rdm "..L['MRMRemove'].." [mount name] (can also shift click from your mount list) --removes a mount from the list\n /rdm "..L['MRMList'].." -- lists the mounts to select from\n /rdm "..L['MRMGui'].." -- brings up a GUI of your mounts\n /rdm "..L['MRMReseed'].." -- if you use more than one computer and you learn a new mount, your list will not work on the other computer, use this to reseed correct mount ID's\n /rdm "..L['MRMRandom'].." -- mounts a random mount from your list (using flying in flyable areas and land in nonflyable areas)\n /rdm "..L['MRMLandOnly'].." -- mounts a random land mount from your list\n /rdm "..L['MRMCatInside'].." -- will enable/disable using Cat Form inside and in instances.\n There are a few keybindings option in the Blizzard KeyBindings Menu. One will summon a random mount (fly/land, one will summon a land wherever you are, and one is for class summons.\n " |
L['MRMNoFlyingMounts'] = "You have not added any flying mounts to your random list." |
L['MRMListTitle'] = "The mounts in your random list are: " |
L['MRMListFlyingTitle'] = "Flying mounts used in Outland/Northrend (except Dalaran/WG): " |
L['MRMNoMounts'] = "ÐÑ Ð½Ðµ добавили ни одного ÑÑанÑпоÑÑа в ÑпиÑок, пожалÑйÑÑа набеÑиÑе /rdm add [Ð¸Ð¼Ñ ÑÑанÑпоÑÑа] ÑÑоб добавиÑÑ." |
L['MRMNoLandMounts'] = "ÐÑ Ð½Ðµ добавили ни одного наземного ÑÑанÑпоÑÑа в ÑпиÑок." |
L['MRMNoFlyingMountsLand'] = "ÐÑ Ð½Ðµ добавили ни одного наземного ÑÑанÑпоÑÑа в ÑпиÑок. ÐÑполÑзÑÑ Ð½Ð°Ð·ÐµÐ¼Ð½Ñй." |
L['MRMBronzeDrake'] = "ÐÑонзовÑй дÑакон" |
L['MRMBronzeDrakeMount'] = "ÐеÑÑ Ð¾Ð²Ð¾Ð¹ бÑонзовÑй дÑакон" |
L['MRMRandom'] = "random" |
L['MRMLandOnly'] = "landonly" |
L['MRMAdd'] = "add" |
L['MRMRemove'] = "remove" |
L['MRMList'] = "list" |
L['MRMGui'] = "gui" |
L['MRMCatInside'] = "catform" |
L['MRMCommands'] = "MountRandomMount v"..GetAddOnMetadata("MountRandomMount", "Version").."\n набеÑиÑе: /rdm -- показаÑÑ ÑÑÑ Ð¿Ð¾Ð´ÑказкÑ\n /rdm add [Ð¸Ð¼Ñ ÑÑанÑпоÑÑа] (Ñакже можно Shift+клик на ÑÑанÑпоÑÑе в ÑпиÑке) -- добавлÑÐµÑ ÑÑанÑпоÑÑ Ð² ÑпиÑок ÑÑанÑпоÑÑа, вÑзÑваемого в ÑлÑÑайном поÑÑдке\n /rdm remove [Ð¸Ð¼Ñ ÑÑанÑпоÑÑа] (Ñакже можно Shift+клик на ÑÑанÑпоÑÑе в ÑпиÑке) -- ÑдалÑÐµÑ ÑÑанÑпоÑÑ Ð¸Ð· ÑпиÑка ÑÑанÑпоÑÑа, вÑзÑваемого в ÑлÑÑайном поÑÑдке\n /rdm list -- показÑÐ²Ð°ÐµÑ ÑпиÑок ÑÑанÑпоÑÑа, вÑзÑваемого в ÑлÑÑайном поÑÑдке\n /rdm gui -- показÑÐ²Ð°ÐµÑ GUI ÑпÑÐ°Ð²Ð»ÐµÐ½Ð¸Ñ ÑпиÑком ваÑего ÑÑанÑпоÑÑа, вÑзÑваемого в ÑлÑÑайном поÑÑдке\n /rdm random -- вÑзÑÐ²Ð°ÐµÑ ÑлÑÑайнÑй ÑÑанÑпоÑÑ Ð¸Ð· ваÑего ÑпиÑка (иÑполÑзÑеÑÑÑ Ð»ÐµÑаÑÑий ÑÑанÑпоÑÑ Ñам где он доÑÑÑпен\n /rdm catform -- ÑазÑеÑаеÑ/запÑеÑÐ°ÐµÑ Ð¸ÑполÑзование Ðблика коÑки в подземелÑÑÑ .\n Ðожно назнаÑиÑÑ Ð½ÐµÑколÑко бÑÑÑÑÑÑ ÐºÐ»Ð°Ð²Ð¸Ñ Ð² Ð¼ÐµÐ½Ñ ÐазнаÑÐµÐ½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñ. Ðдна из Ð½Ð¸Ñ Ð±ÑÐ´ÐµÑ Ð²ÑзÑваÑÑ ÑлÑÑайнÑй ÑÑанÑпоÑÑ (леÑаÑÑий/наземнÑй), дÑÑÐ³Ð°Ñ Ð²ÑÐ·Ð¾Ð²ÐµÑ Ð½Ð°Ð·ÐµÐ¼Ð½Ñй ÑÑанÑпоÑÑ, ÑÑеÑÑÑ Ð²ÑÐ·Ð¾Ð²ÐµÑ ÑÑанÑпоÑÑ Ð²Ð°Ñего клаÑÑа.\n " |
L['MRMReseed'] = "reseed" |
L['MRMReseedPrint'] = "ТÑанÑпоÑÑ Ð¿ÐµÑеÑÑиÑан." |
L['MRMCatInside'] = "Ðблик коÑки" |
L['MRMCommands'] = "MountRandomMount v"..GetAddOnMetadata("MountRandomMount", "Version").."\n набеÑиÑе: /rdm -- показаÑÑ ÑÑÑ Ð¿Ð¾Ð´ÑказкÑ\n /rdm "..L['MRMAdd'].." [Ð¸Ð¼Ñ ÑÑанÑпоÑÑа] (Ñакже можно Shift+клик на ÑÑанÑпоÑÑе в ÑпиÑке) -- добавлÑÐµÑ ÑÑанÑпоÑÑ Ð² ÑпиÑок ÑÑанÑпоÑÑа, вÑзÑваемого в ÑлÑÑайном поÑÑдке\n /rdm "..L['MRMRemove'].." [Ð¸Ð¼Ñ ÑÑанÑпоÑÑа] (Ñакже можно Shift+клик на ÑÑанÑпоÑÑе в ÑпиÑке) -- ÑдалÑÐµÑ ÑÑанÑпоÑÑ Ð¸Ð· ÑпиÑка ÑÑанÑпоÑÑа, вÑзÑваемого в ÑлÑÑайном поÑÑдке\n /rdm "..L['MRMList'].." -- показÑÐ²Ð°ÐµÑ ÑпиÑок ÑÑанÑпоÑÑа, вÑзÑваемого в ÑлÑÑайном поÑÑдке\n /rdm "..L['MRMGui'].." -- показÑÐ²Ð°ÐµÑ GUI ÑпÑÐ°Ð²Ð»ÐµÐ½Ð¸Ñ ÑпиÑком ваÑего ÑÑанÑпоÑÑа, вÑзÑваемого в ÑлÑÑайном поÑÑдке\n /rdm "..L['MRMReseed'].." -- еÑли Ð²Ñ Ð·Ð° дÑÑгим компÑÑÑеÑом и вÑÑÑили новÑй ÑÑанÑпоÑÑ Ð²Ð°Ñ ÑпиÑок не бÑÐ´ÐµÑ ÑабоÑаÑÑ Ð½Ð° дÑÑгом компÑÑÑеÑе. ÐÑполÑзÑйÑе ÑÑÑ ÐºÐ¾Ð¼Ð°Ð½Ð´Ñ Ð´Ð»Ñ ÐºÐ¾ÑÑекÑии ID ÑÑанÑпоÑÑа\n /rdm "..L['MRMRandom'].." -- вÑзÑÐ²Ð°ÐµÑ ÑлÑÑайнÑй ÑÑанÑпоÑÑ Ð¸Ð· ваÑего ÑпиÑка (иÑполÑзÑеÑÑÑ Ð»ÐµÑаÑÑий ÑÑанÑпоÑÑ Ñам где он доÑÑÑпен\n /rdm "..L['MRMCatInside'].." -- ÑазÑеÑаеÑ/запÑеÑÐ°ÐµÑ Ð¸ÑполÑзование Ðблика коÑки в подземелÑÑÑ .\n Ðожно назнаÑиÑÑ Ð½ÐµÑколÑко бÑÑÑÑÑÑ ÐºÐ»Ð°Ð²Ð¸Ñ Ð² Ð¼ÐµÐ½Ñ ÐазнаÑÐµÐ½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñ. Ðдна из Ð½Ð¸Ñ Ð±ÑÐ´ÐµÑ Ð²ÑзÑваÑÑ ÑлÑÑайнÑй ÑÑанÑпоÑÑ (леÑаÑÑий/наземнÑй), дÑÑÐ³Ð°Ñ Ð²ÑÐ·Ð¾Ð²ÐµÑ Ð½Ð°Ð·ÐµÐ¼Ð½Ñй ÑÑанÑпоÑÑ, ÑÑеÑÑÑ Ð²ÑÐ·Ð¾Ð²ÐµÑ ÑÑанÑпоÑÑ Ð²Ð°Ñего клаÑÑа.\n " |
L['MRMNoFlyingMounts'] = "ÐÑ Ð½Ðµ добавили ни одного леÑаÑÑего ÑÑанÑпоÑÑа в ÑпиÑок." |
L['MRMListTitle'] = "ÐÐ°Ñ ÑпиÑок ÑÑанÑпоÑÑа, вÑзÑваемого в ÑлÑÑайном поÑÑдке: " |
L['MRMListFlyingTitle'] = "ÐеÑаÑÑий ÑÑанÑпоÑÑ Ð¸ÑполÑзÑемÑй в ÐапÑеделÑе/ÐоÑдÑколе (кÑоме ÐалаÑана/ÐÐÐ): " |
L['MRMNoMounts'] = "Aucune monture n'a \195\169t\195\169 ajout\195\169 \195\160 votre liste de monture al\195\169atoire." |
L['MRMNoLandMounts'] = "Aucune monture terrestre n'a \195\169t\195\169 ajout\195\169 \195\160 votre liste de monture al\195\169atoire." |
L['MRMNoFlyingMountsLand'] = "Aucune monture volante n'a \195\169t\195\169 ajout\195\169 \195\160 votre liste de monture al\195\169atoire. Utilisation de la monture terrestre." |
L['MRMBronzeDrake'] = "Drake de bronze" |
L['MRMBronzeDrakeMount'] = "R\195\170nes de drake bronze" |
L['MRMRandom'] = "random" |
L['MRMLandOnly'] = "landonly" |
L['MRMAdd'] = "add" |
L['MRMRemove'] = "remove" |
L['MRMList'] = "list" |
L['MRMGui'] = "gui" |
L['MRMReseed'] = "reseed" |
L['MRMKelp'] = "For\195\170t de Varech'thar" |
L['MRMShimExp'] = "\195\137tendues Chatoyantes" |
L['MRMAbysDepth'] = "Profondeurs Abyssales" |
L['MRMReseedPrint'] = "La liste des monture a \195\169t\195\169 r\195\169index\195\169e." |
L['MRMCatInside'] = "catform" |
L['MRMCommands'] = "MountRandomMount v"..GetAddOnMetadata("MountRandomMount", "Version").."\n Faire: /rdm -- Affiche cette aide\n /rdm add [nom de monture] (Vous pouvez shift click depuis la liste des montures) -- Ajoute une autre monture dans la liste\n /rdm remove [nom de monture] (vous pouvez aussi shift click depuis la liste des montures) -- Retire la monture de la liste\n /rdm list -- Liste les monture choisis\n /rdm gui -- Affiche l'interface de selection des montures\n /rdm random -- Invoque une monture al\195\169atoire (utilise une monture volante dans les zones authoris\195\169s ou une monture terrestre sinon)\n /rdm landonly -- Invoque une monture terrestre al\195\169atoire\n /rdm catform -- Active/d\195\169sactive la forme de f\195\169lin en int\195\169rieur et en instances.\n Il y a des racourcis disponible dans l'interface d'affectation des racourcis de blizzard. Un des racourcis permet d'invoquer une monture al\195\169atoire (volante/terrestre), un autre permet d'invoquer une monture terrestre ou que vous soyez, et un autre pour les invoquations de classe.\n " |
L['MRMCommands'] = "MountRandomMount v"..GetAddOnMetadata("MountRandomMount", "Version").."\n Faire: /rdm -- Affiche cette aide\n /rdm add [nom de monture] (Vous pouvez shift click depuis la liste des montures) -- Ajoute une autre monture dans la liste\n /rdm remove [nom de monture] (vous pouvez aussi shift click depuis la liste des montures) -- Retire la monture de la liste\n /rdm list -- Liste les monture choisis\n /rdm gui -- Affiche l'interface de selection des montures\n /rdm reseed -- Si vous utilisez plus qu'un ordinateur et que vous apprenez une nouvelle monture, la liste ne marchera pas sur l'autre oridnateur, a utiliser pour r\195\169indexer correctement la liste des monture\n /rdm random -- Invoque une monture al\195\169atoire (utilise une monture volante dans les zones authoris\195\169s ou une monture terrestre sinon)\n /rdm landonly -- Invoque une monture terrestre al\195\169atoire\n /rdm catform -- Active/d\195\169sactive la forme de f\195\169lin en int\195\169rieur et en instances.\n Il y a des racourcis disponible dans l'interface d'affectation des racourcis de blizzard. Un des racourcis permet d'invoquer une monture al\195\169atoire (volante/terrestre), un autre permet d'invoquer une monture terrestre ou que vous soyez, et un autre pour les invoquations de classe.\n " |
L['MRMNoFlyingMounts'] = "Vous n'avez pas s\195\169lectionn\195\169 de monture volante." |
L['MRMListTitle'] = "Les montures s\195\169lectionn\195\169es sont: " |
L['MRMListFlyingTitle'] = "Monture volante a utilis\195\169 en Outreterre et au Norfendre (Exept\195\169 \195\160 Dalaran et au Joug):" |
L['MRMNoMounts'] = "You haven't added any mounts to the list, please use /rdm add [mount name] to do this." |
L['MRMNoLandMounts'] = "You have not added any land mounts to your random list." |
L['MRMNoFlyingMountsLand'] = "You have not added any flying mounts to your random list. Using a Land mount." |
L['MRMBronzeDrake'] = "Bronzedrache" |
L['MRMBronzeDrakeMount'] = "Bronzefarbener Reitdrache" |
L['MRMRandom'] = "random" |
L['MRMLandOnly'] = "landonly" |
L['MRMAdd'] = "add" |
L['MRMRemove'] = "remove" |
L['MRMList'] = "list" |
L['MRMGui'] = "gui" |
L['MRMReseed'] = "reseed" |
L['MRMReseedPrint'] = "Reittiere neu eingelesen." |
L['MRMCatInside'] = "Katzengestalt" |
L['MRMCommands'] = "German translation, all commands can be found at: http://www.wowinterface.com/downloads/info13679-MountRandomMount.html in english. run /rdm gui for the GUI" |
L['MRMCommands'] = "German translation, all commands can be found at: http://www.wowinterface.com/downloads/info13679-MountRandomMount.html in english. run /rdm gui for the GUI\n /rdm reseed --to reseed mounts" |
L['MRMNoFlyingMounts'] = "Keine Flugtiere in der Liste vorhanden." |
L['MRMListTitle'] = "Folgende Reittiere sind auf der Liste: " |
L['MRMListFlyingTitle'] = "Flugtiere f\195\188r Scherbenwelt/Nordend: " |