autolooting problem

Help section from before the user variable changes that broke all macros

Moderator: MacroQuest Developers

rogue
decaying skeleton
decaying skeleton
Posts: 5
Joined: Wed Aug 27, 2003 1:33 pm

autolooting problem

Post by rogue » Mon Sep 15, 2003 5:32 pm

Before the recent patch I had a macro which had an auto looting component modified slightly from one of the macros in the macro depot, but now its stopped working.

The loot part of the macro is

Code: Select all

sub event_Loot 
   /target "corpse" 
   /delay 1s 
   /loot
   /if $target()=="FALSE" /return 
   /goto :doneloot 
 
   :doneloot 
   /cleanup 
   /varset LootSlot 0 
/return
But now instead of looting it says 'there are no '' around here' and 'you must first target a corpse to loot'.

Can anyone fix? :) Or does anyone have a working looting macro which will either loot the coin off the corpse as soon as it dies, or loot the coin and any items? :)

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

Post by dont_know_at_all » Mon Sep 15, 2003 6:27 pm

Use the force, Luke.












PS Force == search

malum
decaying skeleton
decaying skeleton
Posts: 4
Joined: Tue Sep 16, 2003 7:52 am

Post by malum » Wed Sep 17, 2003 3:48 am

Hello,

I have tried a few different loot scripts that I found using search, but none seem to work currently I am using hunter.mac with the loot routine following the message - hunter.mac does everything BUT loot properly.

I am using the default UI and have tried it in EQ and EQW with both the mouse locked and unlocked.

Any ideas?

Malum


Code: Select all

sub LootMob 
   /loot 
   /delay 10s 
   :lootloop 
   /if n $LootSlot==0 /click left loot2 
   /if n $LootSlot==1 /click left loot3 
   /if n $LootSlot==2 /click left loot4 
   /if n $LootSlot==3 /click left loot5 
   /if n $LootSlot==4 /click left loot6 
   /if n $LootSlot==5 /click left loot7 
   /if n $LootSlot==6 /click left loot8 
   /if n $LootSlot==7 /click left loot9 
   /if n $LootSlot==8 /click left loot10 
   /if n $LootSlot==9 /goto :doneloot 
   /delay 1s 
   /if "$cursor()"!="TRUE" /goto :doneloot 
   :lootChecker 
   /if "$cursor(name)"~~"$a(1,$CheckLoot)" { 
      /delay 1s 
      /click left auto 
      /varadd LootSlot 1 
      /goto :lootloop 
   } 
   /varadd CheckLoot 1 
   /if "$cursor()"=="TRUE" { 
      /if n $CheckLoot<$LootTotal /goto :lootchecker 
   } 
   /if "$cursor()"=="TRUE" { 
      /delay 1s 
      /click left destroy 
      /delay 1s 
   } 
   /varadd LootSlot 1 
   /varset CheckLoot 0 
   /goto :lootloop  
   :doneloot 
   /varset LootSlot 0 
/return
edit: Valerian likes code brackets.

User avatar
grimjack
Macro Author
Macro Author
Posts: 525
Joined: Thu Nov 07, 2002 6:51 am
Contact:

Old code

Post by grimjack » Wed Sep 17, 2003 6:51 am

malum wrote:Hello,

sub LootMob
/loot
/delay 10s
:lootloop
/if n $LootSlot==0 /click left loot2
/if n $LootSlot==1 /click left loot3
/if n $LootSlot==2 /click left loot4
/if n $LootSlot==3 /click left loot5
/if n $LootSlot==4 /click left loot6
/if n $LootSlot==5 /click left loot7
/if n $LootSlot==6 /click left loot8
/if n $LootSlot==7 /click left loot9
/if n $LootSlot==8 /click left loot10
/if n $LootSlot==9 /goto :doneloot
/delay 1s
/if "$cursor()"!="TRUE" /goto :doneloot
:lootChecker
/if "$cursor(name)"~~"$a(1,$CheckLoot)" {
/delay 1s
/click left auto
/varadd LootSlot 1
/goto :lootloop
}
/varadd CheckLoot 1
/if "$cursor()"=="TRUE" {
/if n $CheckLoot<$LootTotal /goto :lootchecker
}
/if "$cursor()"=="TRUE" {
/delay 1s
/click left destroy
/delay 1s
}
/varadd LootSlot 1
/varset CheckLoot 0
/goto :lootloop
:doneloot
/varset LootSlot 0
/return
This is a VERY old version of the loot code. Some of the syntax for doing /click on a corpse has changed since when that was posted. I would suggest using the loot sub that is in the first post in the thread. I usualy update the original post to the newest code.

You can find the date it was last edited at the bottom of the post.
Last edited by grimjack on Tue Aug 05, 2003 5:51 am; edited 10 times in total
If you see a fix posted that is before that date, most likely it's not something you want to use.

Thanks
GrimJack


Code: Select all

sub LootMob
   /loot
   /delay 2s
   :lootloop
   /if n $LootSlot>=9 /goto :doneloot
   /click left corpse $LootSlot
   /delay 1s
   /if "$cursor()"!="TRUE" /goto :doneloot
   :lootChecker
   /if "$cursor(name)"~~"$a(1,$CheckLoot)" {
      /delay 1s
      /click left auto
      /delay 1s
      /varadd LootSlot 1
      /goto :lootloop
   }
   /varadd CheckLoot 1
   /if "$cursor()"=="TRUE" {
      /if n $CheckLoot<$LootTotal /goto :lootchecker
   }
   /if "$cursor()"=="TRUE" {
      /delay 1s
      /click left destroy
      /delay 1s
   }
   /varadd LootSlot 1
   /varset CheckLoot 0
   /goto :lootloop 
   :doneloot
   /varset LootSlot 0
/return 
When they come to me, they're in trouble, or they want some. I bust people out of prison, hunt down vampires, fight alien gods -- All the fun jobs people are too squeamish or too polite to do themselves.

Call me a mercenary. Call me an assassin. Call me a villain. I am all that and more.

My name's John Gaunt, but out on the streets of Cynosure, I am called...
GrimJack