spawn checker

Have a macro idea but not sure where to start? Ask here.

Moderator: MacroQuest Developers

bzt
a lesser mummy
a lesser mummy
Posts: 77
Joined: Fri Oct 10, 2003 3:39 pm

spawn checker

Post by bzt » Fri Apr 30, 2004 3:27 am

is there a simple spawn checker with alert abilty that works with the new MQ2?

User avatar
Fuergrissa
a grimling bloodguard
a grimling bloodguard
Posts: 607
Joined: Mon Dec 08, 2003 3:46 pm
Location: UK

Post by Fuergrissa » Fri Apr 30, 2004 4:39 pm

use the spawnalert Plugin here ---> http://macroquest2.com/phpBB2/viewtopic.php?t=5770

i use it and it is very good, also you can still use other macros as well.

Enjoy

If you dont know how to add plugins it is real easy, trust me.

bzt
a lesser mummy
a lesser mummy
Posts: 77
Joined: Fri Oct 10, 2003 3:39 pm

Post by bzt » Wed May 05, 2004 11:19 pm

well..I tried and tried..I can not figure out how to get a plugin to work..I can compile MQ2 np..but the plugins evade me.


Is there a macro like

Code: Select all

| Spawnchecker macro by wilso132 
| USAGE: /macro spawncheck <spawn_name> <# of times to beep> 
| e.g. /macro spawncheck frenzied 20   will check for something with the 
| name "frenzied" and beep 20 times 

Sub Main 
/declare alertlistno_ global 
/declare spawn_name global 
/declare x global 
/declare num_of_beeps global 
/varset x 0 
/varset alertlistno_ 9 
/varset spawn_name "@Param0" 
/varset num_of_beeps @Param1 

   /echo Going to beep @num_of_beeps times when spawn_name spawns. 
   /alert clear alertlistno_ 
   /alert add alertlistno_ npc radius 10000 "@spawn_name" 
      
    :TOP 
   /if $alert(alertlistno_)==TRUE { 
           /w npc @spawn_name 
           /echo Matches your criteria of @spawn_name 
           /for x 0 to @num_of_beeps 
             /beep 
           /next x 
           /echo spawned at $time(h):$time(m)
   /return 
   } else { 
      /goto :TOP 
   } 
/return 
still around?

User avatar
wilso132
Contributing Member
Contributing Member
Posts: 106
Joined: Thu Oct 17, 2002 11:53 am

Post by wilso132 » Thu May 06, 2004 2:18 am

I can't believe anyone actually used that piece of junk I made, almost ashamed of it compared to what everyone else can do :oops: .

bzt
a lesser mummy
a lesser mummy
Posts: 77
Joined: Fri Oct 10, 2003 3:39 pm

Post by bzt » Thu May 06, 2004 3:12 am

it worked, I used it..I miss it :(

User avatar
Fuergrissa
a grimling bloodguard
a grimling bloodguard
Posts: 607
Joined: Mon Dec 08, 2003 3:46 pm
Location: UK

Post by Fuergrissa » Thu May 06, 2004 4:19 am

well..I tried and tried..I can not figure out how to get a plugin to work..I can compile MQ2 np..but the plugins evade me.
You really need to use the Spawnalert plugin, it will allow you to run other macros at the same time and will work for every zone you use.
go to this link:
http://macroquest2.com/phpBB2/viewtopic.php?t=5770

Lets assume your using VC6 AND your MQ-Latest.Zip is unpacked into c:\mq2

open a dos prompt and make sure your prompt reads
c:\mq2

type mkplugin MQ2Spawnalert
copy and paste the code Titled
MQ2SpawnAlert.cpp
into the file c:\mq2\mq2spawnalert\mq2spawnalert.cpp

now open the macroquest2.dsw file with vc6 and look under the heading "Projects", at the bottom choose "Insert Project into Workspace" and find your Mq2spawnalert folder you will have only one file to choose from to insert, dont forget to make Mq2Main the active project by right clicking and choosing "Make Active Project".
ok do your builds as normal and in your release folder you will now have the plugin. download the zip at the top pf the post mentioned above and extract the mq2spawnalert.ini file and place it in your release folder and once ingame from any chat window type: /plugin mq2spawnalert

there are instructions on how to add and remove spawns in the above mentioned post.
The plugin will allways remain loaded once loaded. dont forget to redo all this when you get a new release if you allways do a fresh rebuild like i do.

If you get any probs just repost here. if you use VSnet as your compiler maybe someone else can just redo the vsnet bits as i dont use it.

Good Luck.
Last edited by Fuergrissa on Thu May 06, 2004 2:00 pm, edited 1 time in total.

kasodo
a lesser mummy
a lesser mummy
Posts: 64
Joined: Fri Feb 13, 2004 9:41 am

Spawn Checker

Post by kasodo » Thu May 06, 2004 12:52 pm

Changed the code at work UNTESTED.... Post any problems here ill try and fix it.

Code: Select all

| Spawnchecker macro by wilso132 
| USAGE: /macro spawncheck <spawn_name> <# of times to beep> 
| e.g. /macro spawncheck frenzied 20   will check for something with the 
| name "frenzied" and beep 20 times 
| MQ2 Data enabled by kasodo

Sub Main 
/declare spawn_name outer 
/declare x int outer 
/declare num_of_beeps int outer 
/varset x 0 
/varset spawn_name ${Param0} 
/varset num_of_beeps ${Param1} 

   /echo Going to beep ${num_of_beeps} times when spawn_name spawns. 
      
    :TOP 
   if (${NearestSpawn[npc radius 10000 ${spawn_name}]}) { 
           /w npc ${spawn_name} 
           /echo Matches your criteria of ${spawn_name} 
           /for x 0 to ${num_of_beeps} 
             /beep 
           /next x 
           /echo spawned at ${Time} 
   /return 
   } else { 
      /goto :TOP 
   } 
/return
<Oid> You know whats sad
<Oid> here soon, lax will log in
<Oid> and go "You fucking idiots!"
* Lax has joined #macroquest
* ChanServ sets mode: +o Lax
...
<Lax> you fucking idiots!

bzt
a lesser mummy
a lesser mummy
Posts: 77
Joined: Fri Oct 10, 2003 3:39 pm

Post by bzt » Thu May 06, 2004 1:57 pm

thanks to both of you...

I could not get the mkplugin command to work at all kept saying wasnt a valid command..but..in the zip file there was a dsw file that I used to compile the plugin..then went from there..the plugin loaded up in eq, so it must be working.

thanks again


lol spoke too soon..the plugin just drops me to the server select creen if any mob on that list is up in the zone..


But I do appreciate your help.
Last edited by bzt on Thu May 06, 2004 2:12 pm, edited 1 time in total.

User avatar
Fuergrissa
a grimling bloodguard
a grimling bloodguard
Posts: 607
Joined: Mon Dec 08, 2003 3:46 pm
Location: UK

Post by Fuergrissa » Thu May 06, 2004 2:03 pm

yeah that was my fault with a typo I was in EQ mode and told you to do a /mkplugin when in actuall fact we should have been in DOS mode and just typed mkplugin

bzt
a lesser mummy
a lesser mummy
Posts: 77
Joined: Fri Oct 10, 2003 3:39 pm

Post by bzt » Thu May 06, 2004 2:32 pm

Ok..forgive me but I can not get this thing to work the way it should.

I am using windows XP wit SP1, MS Visual c++ 6 with the latest updates. The latest release is d:/mq ( shortened the name for ease)

I go to start, run, cmd.exe.. Type cd d:\mq well, ill just copy and paste..
C:\Documents and Settings\mynamehere>cd d:\mq

C:\Documents and Settings\mynamehere>
[/quote]

Oid
a snow griffon
a snow griffon
Posts: 416
Joined: Thu Oct 17, 2002 3:26 am
Contact:

Post by Oid » Fri May 07, 2004 6:06 am

Code: Select all

Sub Main
:loop
/tar ${Param0}
/if (${Target.ID}) /beep
/goto :loop
/return
Last edited by Oid on Fri May 07, 2004 6:19 am, edited 1 time in total.
Smokey the Lax says only you can prevent reproduction.

Oid
a snow griffon
a snow griffon
Posts: 416
Joined: Thu Oct 17, 2002 3:26 am
Contact:

Post by Oid » Fri May 07, 2004 6:10 am

I dont like that version.....

Code: Select all

Sub Main 
:loop 
/keypress esc
/tar ${Param0} 
/if (${Target.ID}) /goto :loop2
/delay 30s
/goto :loop 

:loop2
/beep
/goto :loop2
/return
Smokey the Lax says only you can prevent reproduction.

bzt
a lesser mummy
a lesser mummy
Posts: 77
Joined: Fri Oct 10, 2003 3:39 pm

Post by bzt » Thu May 13, 2004 9:01 pm

I am still unable to get a plugin to work..anyone willing to help me? I know I must be doing something wrong, but I can not get the DOS commands to work to even start to compile the dang thing.

Thanks!

Preocts
a snow griffon
a snow griffon
Posts: 312
Joined: Thu Jan 29, 2004 1:02 pm

Post by Preocts » Thu May 13, 2004 9:43 pm

:? Why are you trying to compile in DOS if you are using VC++?

bzt
a lesser mummy
a lesser mummy
Posts: 77
Joined: Fri Oct 10, 2003 3:39 pm

Post by bzt » Thu May 13, 2004 11:07 pm

was trying to follow your directions :P
open a dos prompt and make sure your prompt reads
c:\mq2
but for the life of me cd wont work :evil:

This is what it looks like when I try
C:\Documents and Settings\mynamehere>cd d:\mq

C:\Documents and Settings\mynamehere>