Quantcast
Download
(5 Kb)
Download
Updated: 10-18-15 05:49 AM
Pictures
File Info
Compatibility:
Minor patch (6.2.3)
Updated:10-18-15 05:49 AM
Created:11-15-12 09:09 AM
Downloads:1,185
Favorites:0
MD5:

MountRndCat

Version: 1.0-2015101801
by: gmarco [More]

MountRndCat

This is a tiny addon that let you define custom categories and then random summon a mount from them.

To use the addon you FIRST need to rename the file categories-sample.lua to categories.lua in the addon directory and edit it with the names of your favorite mounts.

If you modify the categories.lua file while the game client is active you have to reload the game interface with command:

/reload

Usage:

Create a macro like this to summon your mounts:


/mrc [btn:2] category2; [swimming] category3; [mod:shift] category4; [mod:alt] favorites!; all!

or simply use the command from the cli, i.e.:


/mrc - This help
/mrc category - Summon a random mount from your 'category' list
/mrc favorites! - Summon a random mount from your favorite list
/mrc all! - Summon a random mount

The categories are shared on all characters on the same account.


Here is a categories.lua suitable for alliance players (english client):


Lua Code:
  1. MyCatMount_mrc = {
  2.    
  3.     flying = {
  4.         "Swift Green Gryphon",
  5.         "Swift Blue Gryphon",
  6.         "Swift Red Gryphon",
  7.     },
  8.    
  9.     ground = {
  10.         "Swift Mistsaber",
  11.         "Swift Moonsaber",
  12.       },
  13.    
  14.     repair = {
  15.         "Traveler's Tundra Mammoth",
  16.         "Grand Expedition Yak",
  17.     },
  18.    
  19.     funny = {
  20.         "Azure Water Strider",
  21.         "Sea Turtle",
  22.    
  23.     },
  24.    
  25.     combo = {
  26.         "Sandstone Drake",
  27.         "Mekgineer's Chopper",
  28.     },
  29.    
  30.    
  31.    -- add your custom categories here
  32. }

N.B. Please remember to backup your custom categories.lua before updating.

-- I also whish to thanks SDPhantom and Phanx for their help, code and suggestions that help me so much in understanding and writing my first addon.

v1.0-2015101801
- fixed a bug where a mount with the same name but with 2 ids can't be summoned (thanks to Phanx for the input and ideas)
- add the default category " favorites! " which randomly summon a mount from the favorites.
Basically it is the same of the "Summon Random Favorite Mount" spell, but I need it to use in a macro.
To do it you can also use a simple:

C_MountJournal.Summon(0)

but I found it acts more as a switch than a summon.
So you press once it summon a random favorite you press twice it dismiss.
I have to check it better.

- add the default category " all! " which randomly summon a mount
- fix the code to prevent to summon the active mount

v1.0-2015062401
- bump toc for 6.2

v1.0-2015022501
- bump toc 6.1

v1.0-2014101501
- bump toc for 6.0.x
- migrate to C_MountJournal API

v1.0-2013091001
- bump toc for 5.4

v1.0-2013052101
- bump toc for 5.3

v1.0-2013030401
- bump toc

v0.8-201211192047
- Fix an error if categories.lua is missing
- Change the "mounts" name to "MyCatMount_mrc" to prevent problem with other addons.

This implies that if you modified a categories.lua in a previous version you have to change the first line

from: mounts = {

to: MyCatMount_mrc = {

or check one of the sample provided. I am really sorry about it guys, but I am learning :-)


-- 201211180810 - v.0.7
- Cosmetic only - not released

-- 201211170837 - v.0.6
- Some text changes
- Repackaged to prevent the overwrite of file "categories.lua"
Optional Files (0)


Archived Files (8)
File Name
Version
Size
Author
Date
1.0-2015062401
4kB
gmarco
06-24-15 12:53 AM
1.0-2015022501
4kB
gmarco
02-25-15 12:16 AM
1.0-2014101501
4kB
gmarco
10-16-14 10:09 AM
1.0-2013091001
5kB
gmarco
09-10-13 10:02 AM
1.0-2013052101
5kB
gmarco
05-21-13 01:30 PM
1.0-2013030401
4kB
gmarco
03-05-13 11:28 AM
0.8
4kB
gmarco
11-19-12 01:57 PM
0.6
4kB
gmarco
11-17-12 01:47 AM


There have been no comments posted to this file.
Be the first to add one.



Category Jump: