Log in

View Full Version : Macro or script to queue for a BG?



HTeam
10-23-2009, 02:02 AM
re: http://www.wowwiki.com/API_JoinBattlefield

So I'm looking at JoinBattlefield() and it appears to work on the currently selected battleground. Anyone know of a way to queue for a battleground without opening and selecting a specific battleground. I've been reading through the code for Preform AV Enabler and it appears to require selecting a battleground before it can be called.

This is where I'm a bit fuzzy, can the battleground form be manipulated, hidden, selected, etc. through script such that I can push one button and queue for the bg of choice?

In particular, I'm looking to queue for the 2 bg's that I have the fewest marks with, so I can save up marks for the "For Greater Honor" quest as a way of going past the honor cap. Currently I can do this part easily enough and I have a macro that just prints which bg's I need.

I don't need working code, just if anyone has a better idea of where to look, or knows of a mod that does something similar. I'd have sword that Preform AV Enabler didn't require an open form, but if it doesn't I'm not sure how the code accomplishes that.

Ualaa
10-23-2009, 04:05 PM
Not sure how you could queue without opening the window.
I typically queue as a group, so only one toon has to open the window.

All of my toons have this on a bind:

/script AcceptBattlefieldPort(1,1)
/script LeaveBattlefield()

When I have the window open, saying the battlefield is ready, one press and they join.
Until I've finished loading the BG, I can spam away with impunity for others to join without leaving.

At the end, with the score sheet up, the same macro has me leave.

HTeam
10-25-2009, 06:13 AM
AutoBG is an addon that will do what I want.

/autobg marks -- queues for the bg with the lowest mark total
/autobg daily -- toggles queuing for the bg daily first if you have that quest

Can turn on specific bg's or not.
It will also auto-leave a bg as well.
Can toggle whether to queue as a group or not.

Very nice, I just keep playing and don't bother with open that window, selecting the tab, selecting the bg (after doing the same to find my marks).

Also a good example of manipulating a hidden window.