Invalid item slot 'loot1' on a working looting macro

Need help running MacroQuest2? Ask your questions about how to get things to work on your computer.

Moderator: MacroQuest Developers

luie85
orc pawn
orc pawn
Posts: 10
Joined: Thu Oct 27, 2011 3:23 pm

Invalid item slot 'loot1' on a working looting macro

Post by luie85 » Tue Nov 22, 2011 3:54 pm

After 20111120a patch The common Hunterv1.3 macro looting gets a white "Invalid item slot 'loot1'". I read in the patch notes that corpse.items was fixed.

The error pops up on this line
/shiftkey /itemnotify loot${LootSlot} Rightmouseup

Seems like after the patch the loot boxes are coded different in EQ?
How can I Echo the loot screen slot names?

Something of this sort?
/echo ${corpse.itemslot}

Here is the code.

Code: Select all

Sub LootMob

   /declare LootSlot    int inner  1
   /declare LootCheck   int inner  0
   /declare LootTotal   int inner  0
   
   /face fast
   
   /keypress forward
   /keypress back
   
   /fastdrop on
   /lootn never
   /delay 2s
   /loot
   /delay 2s
   /if (!${Corpse.Items}) {
      /echo NO LOOT! Cheap Bastard!
      /return
   }

   /varset LootTotal ${Corpse.Items}
   /for LootSlot 1 to ${LootTotal}
      /shiftkey /itemnotify loot${LootSlot} Rightmouseup
      /echo ${itemSlot}
      /delay 1s
      /if (${RV_LootAllItems}) {
         /echo Keeping a ${Cursor.Name}... WOOT!
         /autoinventory
         /delay 1s
      } else {
         /for LootCheck 1 to ${RV_LootArray.Size}
            /if (${Cursor.Name.Find[${RV_LootArray[${LootCheck}]}]}) {
               /echo Keeping a ${Cursor.Name}... WOOT!
               /varcalc RV_LootStats[${LootCheck}] ${RV_LootStats[${LootCheck}]}+1
               /autoinventory
               /delay 1s
            }
         /next LootCheck
      }
      /if (${Cursor.ID}) {
         /echo Destroying a ${Cursor.Name}...
         /destroy
         /delay 1s
      }
   /next LootSlot
   
   /notify LootWnd DoneButton leftmouseup
   /delay 2
   
/return 

devNull
a ghoul
a ghoul
Posts: 121
Joined: Sat Mar 06, 2004 3:57 am

Re: Invalid item slot 'loot1' on a working looting macro

Post by devNull » Tue Nov 22, 2011 5:29 pm

/nomodkey /shift /itemnotify ${Corpse.Item[${lootSlot}].InvSlot} leftmouseup

leftmouseup should put it on the cursor, rightmouseup should autoinventory

your code looks like it wants it on the cursor but it has rightmouseup

luie85
orc pawn
orc pawn
Posts: 10
Joined: Thu Oct 27, 2011 3:23 pm

Re: Invalid item slot 'loot1' on a working looting macro

Post by luie85 » Tue Nov 22, 2011 7:28 pm

Ya I changed it to rightclick so it looted stacks but used to work both ways.
with your changed code is just gives

"Invalid item slot 'null'"

devNull
a ghoul
a ghoul
Posts: 121
Joined: Sat Mar 06, 2004 3:57 am

Re: Invalid item slot 'loot1' on a working looting macro

Post by devNull » Tue Nov 22, 2011 10:11 pm

LootSlot instead of lootSlot, typo.

luie85
orc pawn
orc pawn
Posts: 10
Joined: Thu Oct 27, 2011 3:23 pm

Re: Invalid item slot 'loot1' on a working looting macro

Post by luie85 » Tue Nov 22, 2011 11:24 pm

Thanks for your help.

That worked. not sure why that code worked before and now it does not

User avatar
dont_know_at_all
Developer
Developer
Posts: 5450
Joined: Sun Dec 01, 2002 4:15 am
Location: Florida, USA
Contact:

Re: Invalid item slot 'loot1' on a working looting macro

Post by dont_know_at_all » Wed Nov 23, 2011 12:48 am

The inventory window struct changed and hasn't been fix yet..

drrich76
decaying skeleton
decaying skeleton
Posts: 2
Joined: Fri Dec 03, 2010 10:32 am

Re: Invalid item slot 'loot1' on a working looting macro

Post by drrich76 » Tue May 22, 2012 2:33 am

I found this thread looking for an answer to the OP's question about how to echo loot in loot slots. It wasn't answered, although what he was trying to accomplish seems to have been figured out. I eventually fumbled my way to figuring out

Code: Select all

/echo ${Corpse.Item[1].Name}
is the way to do what he literally asked. I'm writing a loot macro that will not loot certain items (nodrop stuff) if needed by other characters but will instead call them to come and loot. If anyone else is looking for something along those lines, hopefully this helps. My main loot macro will have a line similar to this for designated items:

Code: Select all

/if (${Corpse.Item[1].Name.Equal[Bone Chips]}) /bc Othertoon //macro SpecialLoot ${Target}
The current target will be passed as an argument so the other toon knows which corpse to loot. If this ends up working well, I'll post it for general consumption since I haven't seen any loot macros that do this.

Maskoi

Re: Invalid item slot 'loot1' on a working looting macro

Post by Maskoi » Tue May 22, 2012 8:32 am

You might want to check out ninjadvloot.inc file to use or for reference.

viewtopic.php?f=49&t=17101&hilit=ninjaadvloot

drrich76
decaying skeleton
decaying skeleton
Posts: 2
Joined: Fri Dec 03, 2010 10:32 am

Re: Invalid item slot 'loot1' on a working looting macro

Post by drrich76 » Tue May 22, 2012 2:16 pm

Thanks, Maskoi- I'll take a look at it