Thread Tools Display Modes
10-08-12, 10:17 PM   #1
ssbattousai
A Murloc Raider
Join Date: Oct 2012
Posts: 4
simple rollonloot

Problem

/run rollonloot(rollID,1|2|3);

doesn't work, does anyone have a working macro that 'needs on the loot' rather than clicking on it.

Please no addons and no redirection to sites.

Then also a /run ConfirmLootRoll(rollID, 1|2|3); to complete the macro

Any ideas would be greatly appreciated.

Thank you all!
  Reply With Quote
10-08-12, 10:19 PM   #2
Phanx
Cat.
 
Phanx's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2006
Posts: 5,617
Is that your actual macro? Lua (the programming language WoW's interface uses) is case-sensitive, so "rollonloot" is not the same as "RollOnLoot".
__________________
Retired author of too many addons.
Message me if you're interested in taking over one of my addons.
Don’t message me about addon bugs or programming questions.
  Reply With Quote
10-08-12, 10:29 PM   #3
ssbattousai
A Murloc Raider
Join Date: Oct 2012
Posts: 4
Originally Posted by Phanx View Post
Is that your actual macro? Lua (the programming language WoW's interface uses) is case-sensitive, so "rollonloot" is not the same as "RollOnLoot".
Yep, sorry I was writing it off the top of my head, here is the correct question

/script RollOnLoot(1, 2);
/script ConfirmLootRoll(1, 2);

I want that to work, any ideas?
  Reply With Quote
10-08-12, 11:56 PM   #4
Torhal
A Pyroguard Emberseer
 
Torhal's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2008
Posts: 1,196
You can't make that work in a macro. Macros execute in order, without any wait between commands. You would need to have an AddOn which listens for the CONFIRM_LOOT_ROLL event, at which point your ConFirmLootRoll(id) would be executed.
__________________
Whenever someone says "pls" because it's shorter than "please", I say "no" because it's shorter than "yes".

Author of NPCScan and many other AddOns.
  Reply With Quote
10-09-12, 10:07 AM   #5
Sharparam
A Flamescale Wyrmkin
 
Sharparam's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2011
Posts: 102
Might be a possible with a macro such as this:
lua Code:
  1. /run local f=CreateFrame"Frame"f:SetScript("OnEvent",function(s,e,i,r)ConfirmLootRoll(i,r)s:UnregisterEvent(e)s:SetScript("OnEvent",nil)end)f:RegisterEvent"CONFIRM_LOOT_ROLL"RollOnLoot(1,2)

This could have unintended side-effects though since the script confirms the first CONFIRM_LOOT_ROLL event, which *should* be the RollOnLoot executed right after frame creation, but it *might* not be.

Then I'm not sure about performance of creating a new frame every time the macro is called.
  Reply With Quote
10-09-12, 10:35 AM   #6
SDPhantom
A Pyroguard Emberseer
 
SDPhantom's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 2,313
You can modify the code to store the frame in a global and check for the global before trying to create the frame. something like the following.
Lua Code:
  1. /run local f=CRF or CreateFrame("Frame","CRF")f:SetScript("OnEvent",function(s,e,i,r)ConfirmLootRoll(i,r)s:UnregisterEvent(e)s:SetScript("OnEvent",nil)end)f:RegisterEvent"CONFIRM_LOOT_ROLL"RollOnLoot(1,2)
__________________
WoWInterface AddOns
"All I want is a pretty girl, a decent meal, and the right to shoot lightning at fools."
-Anders (Dragon Age: Origins - Awakening)
  Reply With Quote
10-09-12, 01:57 PM   #7
ssbattousai
A Murloc Raider
Join Date: Oct 2012
Posts: 4
Hmm doesn't really seem to work, any auto need/greed/disenchant and auto confirmloot addons that's easy to use then?

The problem is I have to reinstall the addons on 3-4 different computers, even with curse client.

Last edited by ssbattousai : 10-09-12 at 02:29 PM.
  Reply With Quote
10-09-12, 03:15 PM   #8
Sharparam
A Flamescale Wyrmkin
 
Sharparam's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2011
Posts: 102
Originally Posted by ssbattousai View Post
Hmm doesn't really seem to work, any auto need/greed/disenchant and auto confirmloot addons that's easy to use then?

The problem is I have to reinstall the addons on 3-4 different computers, even with curse client.
There probably are, but what exactly do you want it to do? Roll need/greed/DE every time, or a different roll type depending on the item?

The former could easily be achieved, the second would need some more work.
  Reply With Quote
10-09-12, 05:07 PM   #9
ssbattousai
A Murloc Raider
Join Date: Oct 2012
Posts: 4
Originally Posted by F16Gaming View Post
There probably are, but what exactly do you want it to do? Roll need/greed/DE every time, or a different roll type depending on the item?

The former could easily be achieved, the second would need some more work.
Yes, Every time, like a crazy needy greedy person
  Reply With Quote
10-09-12, 09:56 PM   #10
Dridzt
A Pyroguard Emberseer
 
Dridzt's Avatar
AddOn Author - Click to view addons
Join Date: Nov 2005
Posts: 1,359
Most addons of the kind take care to turn the auto-roll functionality off while in a group or offer specific rules for when to roll on what.

Rolling need on everything that can be needed looks like a very good way to ruin the reputation of any addon.
(I'm guessing you don't care about yours or you wouldn't request this)
  Reply With Quote
10-09-12, 10:34 PM   #11
Phanx
Cat.
 
Phanx's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2006
Posts: 5,617
The Confirm Loot Roll addon may be of interest. It will automatically confirm whatever kind of roll you do. You would still need to click need/greed/disenchant, or use a macro to run RollOnLoot with the appropriate values.

If you want something that will roll automatically on certain item types, you could try PassLoot, but you would need to set it up to roll how you want.

If you want something that will unconditionally roll Need on everything, you could probably configure PassLoot to do that, but I don't think anyone here (myself included) will help you configure it, or write any code to do this for you, since this is not the kind of behavior anyone appreciates in a group.
__________________
Retired author of too many addons.
Message me if you're interested in taking over one of my addons.
Don’t message me about addon bugs or programming questions.
  Reply With Quote

WoWInterface » AddOns, Compilations, Macros » Macro Help » simple rollonloot

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off