Spawn Detector

Post your completed (working) macros here. Only for macros using MQ2Data syntax!

Moderator: MacroQuest Developers

User avatar
Canadian_Cowgirl
a bunny
Posts: 245
Joined: Sat May 13, 2006 1:43 pm

Spawn Detector

Post by Canadian_Cowgirl » Tue Mar 11, 2008 2:21 pm

DKAA, as usual, did the hardwork for me. But since this uses a command I hadn't seen used before - figured a refresh for the memory of the community .

Code: Select all

#turbo

Sub Main

:loop 
/if (${Spawn[a snow bunny].ID}) { 
     /exec "C:\Spawn.MP3" bg 
     /tell name WOOT! It's UP!
     /beep 
     /endm 
      } 
/delay 5s 
/goto :loop

/return
I suppose the enthusiastic could make the Spawn target a variable you enter at the start of the macro.. but I'm lazy :)

-C_CG.
Agripa: Isn't there a rule about never getting into a fight with a Canadian when tech support is on the line?

toomanynames
a grimling bloodguard
a grimling bloodguard
Posts: 1844
Joined: Mon Apr 11, 2005 11:10 am

Post by toomanynames » Tue Mar 11, 2008 2:46 pm

Is there a syntax available for "/exec"
[quote="DKAA"]You cant. Only the server knows.[/quote]

optix
orc pawn
orc pawn
Posts: 29
Joined: Sun Jan 27, 2008 12:37 pm

Post by optix » Tue Mar 11, 2008 4:05 pm

Code: Select all

#turbo

Sub Main

/declare CharName string outer NAMEHERE
/declare SpawnWait string outer a snow bunny

:loop
/if (${Spawn[${SpawnWait}].ID}) {
     /exec "C:\Spawn.MP3" bg
     /tell ${CharName} WOOT! It's UP!
     /beep
     /endm
      }
/delay 5s
/goto :loop

/return 
Yes /exec is an EQ command, not a MQ command I believe.

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 » Tue Mar 11, 2008 4:11 pm

/exec is an MQ command; /system is an EQ command.

/exec [application] [fg | bg]

application can be mapped via the [Application Paths] section of MacroQuest.ini