A forum for you to dump all the macros you create, allowing users to use, modify, and comment on your work.
Moderator: MacroQuest Developers
-
bob_the_builder
- a hill giant

- Posts: 275
- Joined: Tue Jul 22, 2003 1:22 pm
Post
by bob_the_builder » Sun Apr 25, 2004 10:05 pm
Code: Select all
| Loot.mac
| By LordGiddion and AP50
| Edited by Bob_the_builder
| 4/27/04
| /mac loot <# items to leave on corpse>
| /mac loot 0 <will loot all items>
| If no paramter given will auto leave 1 item for res
|
Sub main
/declare LootTotal global
/declare LootSlot global
/declare LootLeft global
:CheckParam
/if (!${Defined[Param0]}) {
/varset LootLeft "1"
/echo Using default LootLeft of @LootLeft
/echo Useage: /mac loot <# items to leave on corpse>
/echo Useage: /mac loot 0 <Loots all items>
} else {
/varset LootLeft @LootLeft
}
:CheckMyCorpse
/target mycorpse
/corpse
/loot
/delay 2s
:CheckIfCorpseNear
/if (!${Corpse.Items}) {
/popup NO CORPSE TO LOOT
/endmacro
}
:SetLootTotal
/varset LootTotal "${Math.Calc[${Corpse.Items}-@LootLeft].Int}"
|/echo Total to Loot: @LootTotal
/popup LOOTING ALL BUT @LootLeft ITEMS
:MainLoop
/for LootSlot 1 to @LootTotal
|/echo loot slot: @LootSlot
/itemnotify loot@LootSlot rightmouseup
/delay 1s
/next LootSlot
:DoneLooting
/delay 1s
/notify LootWnd DoneButton leftmouseup
/popup DONE LOOTING
/endmacro
A stand alone corpse looter with ability to leave items on corpse
/macro loot <# items to leave on corpse>
Bob
Last edited by
bob_the_builder on Tue Apr 27, 2004 9:48 pm, edited 4 times in total.
-
Space-Boy
- a hill giant

- Posts: 242
- Joined: Wed Dec 04, 2002 12:53 pm
-
Contact:
Post
by Space-Boy » Tue Apr 27, 2004 8:18 pm
would be really nice if it worked =) no errors just doesnt loot anything lol
You have gotten better at Carpal Tunnel! (247)
-
bob_the_builder
- a hill giant

- Posts: 275
- Joined: Tue Jul 22, 2003 1:22 pm
Post
by bob_the_builder » Tue Apr 27, 2004 8:42 pm
Oops, I had left the cursor check in there and forgot that the items don't really go to cursor. Removed the line. All working now )
Bob
-
LordGiddion
- a snow griffon

- Posts: 352
- Joined: Sat Sep 13, 2003 6:12 pm
-
Contact:
Post
by LordGiddion » Tue Apr 27, 2004 9:01 pm
You might want
Code: Select all
/if (${Corpse.ID}) /goto :DoneLooting
This way the macro will stop if your inventory is full and it can't keep looting. Though then you might want the concluding popup to check the Cursor value too, display done if !${Corpse.ID} and an error popup otherwise.
-
bob_the_builder
- a hill giant

- Posts: 275
- Joined: Tue Jul 22, 2003 1:22 pm
Post
by bob_the_builder » Tue Apr 27, 2004 9:42 pm
Just added some robustness to leave items on corpse incase needing res.
Thanks LordGiddion, let me review what you said and add it in to next post
Think i might change it to just /mac loot needres and not. Seems easier then thinking baout how many items left.. /shrug
I need to go play EQ for awhile. Thanks a ton LordGiddion.
Bob_sees_dead_people
-
JWWQ
- a lesser mummy

- Posts: 30
- Joined: Sat Jun 19, 2004 4:58 pm
Post
by JWWQ » Tue Jul 06, 2004 4:59 pm
Try this.
I did this at work without any testing, so someone check it out and let me know.
Code: Select all
| Loot.mac
| By LordGiddion and AP50
| Edited by Bob_the_builder
| 4/27/04
| Edited by JWWQ
| 6/6/04
| took out a few old '@'s. Did all this at work so have not tested this.
| /mac loot <;# items to leave on corpse>;
| /mac loot 0 <;will loot all items>;
| If no paramter given will auto leave ${LootLeft} item for res
|
Sub main
/declare LootTotal global
/declare LootSlot global
/declare LootLeft global
:CheckParam
/if (!${Defined[Param0]}) {
/varset LootLeft "0"
/echo Using default LootLeft of ${LootLeft}
/echo Useage: /mac loot <; # items to leave on corpse >;
/echo Useage: /mac loot 0 <; Loots all items >;
} else {
/varset LootLeft ${LootLeft}
}
:CheckMyCorpse
/target mycorpse
/corpse
/loot
/delay 2s
:CheckIfCorpseNear
/if (!${Corpse.Items}) {
/popup NO CORPSE TO LOOT
/endmacro
}
:SetLootTotal
/varset LootTotal "${Math.Calc[${Corpse.Items}-${LootLeft}].Int}"
/echo Total to Loot: ${LootTotal}
/popup LOOTING ALL BUT ${LootLeft} ITEMS
:MainLoop
/for LootSlot 1 to ${LootTotal}
/echo loot slot: ${LootSlot}
/itemnotify loot${LootSlot} rightmouseup
/delay 2
/next LootSlot
:DoneLooting
/delay 1s
/notify LootWnd DoneButton leftmouseup
/popup DONE LOOTING
/endmacro
-
JWWQ
- a lesser mummy

- Posts: 30
- Joined: Sat Jun 19, 2004 4:58 pm
Post
by JWWQ » Wed Jul 07, 2004 11:10 am
tried it out last night and It is having trouble parsing the calc command. Took out the parenthasese and it still has trouble with the LootTotal being an integer.
any gurus?