may i have some help please

Need help with a macro you are writing? Ask here!

Moderator: MacroQuest Developers

Kenneth00016
decaying skeleton
decaying skeleton
Posts: 1
Joined: Tue Aug 03, 2004 4:13 pm

may i have some help please

Post by Kenneth00016 » Tue Aug 03, 2004 4:19 pm

Hail there i been trying to get this chant kite macro to work but im a total noob
I just got Macroquest a week ago and i got no idea on how to use it really, well i been trying to get this kite to work in PoV but everytime i try to run it i get errors and alot of them if anybody could help me and if anybody is intersted in teaching me how to do this i would be a happy man thanks in advance

error are like
Rubber x and y and so on i get
"Name already in use"

here is the macro

#turbo
#chat tell

Sub Main
/zapvars

| These variables are related to movement and AI control.
/declare RubberX 1234 global
/declare RubberY 1234 global
/varset RubberX 40 @Param1
/varset RubberY 100 @Param0

| These variables are related to song-twisting.
/declare SongTimer timer 6
/declare Songs array 1234
/declare CurSong global 1
/declare PrevSong global 2
/declare nSongs global 3
/declare EachSong local 5



| This block of code checks for proper arguments and echos error or initialization messages.
/if $defined(Param6)==false {
/echo Usage: /mac Diamond <Y> <X> <North> <South> <East> <West> <Song list>
/echo <Y> -- Y-coordinate of the center point.
/echo <X> -- X-coordinate of the center point.
/echo <North> -- Maximum distance north of the center point to travel.
/echo <South> -- Maximum distance south of the center point to travel.
/echo <East> -- Maximum distance east of the center point to travel.
/echo <West> -- Maximum distance west of the center point to travel.
/echo <Song list> -- List of songs to be sung, include Selo's if needed.
/endm
}



| This block of code sorts out the list of songs to be twisted while running.
/varset nSongs $strlen(@Param6)
/for EachSong 1 to @nSongs
/varset Songs(@EachSong) $mid($calc(@EachSong-1),1,@Param6)
/echo Song @EachSong: $char(1,@Songs(@EachSong))
/next EachSong
/varset Songs(@EachSong) $mid($calc(@EachSong-1),1,@Param6)
/echo Song @EachSong: $char(2,@Songs(@EachSong))
/next EachSong
/varset Songs(@EachSong) $mid($calc(@EachSong-1),1,@Param6)
/echo Song @EachSong: $char(3,@Songs(@EachSong))
/varset CurSong 1
/call Event_Timer
/echo Running a diamond path with center at @RubberY, @RubberX and chant-kiting mobs.



| The main loop, this iterates unless some AI warning is reached.
/sendkey down up
:ChantLoop

| Face the correct corner of the diamond, given character's current position.
/if (n $char 300 <@RubberX && n $char -400 >@RubberY) /face fast loc @RubberY,$calc(@RubberX-@Param4)
/look -90
/if (n $char 500 <@RubberX && n $char -300 <@RubberY) /face fast loc $calc(@RubberY-@Param3),@RubberX
/look -90
/if (n $char 700 >@RubberX && n $char -500 <@RubberY) /face fast loc @RubberY,$calc(@RubberX+@Param5)
/look -90
/if (n $char 200 >@RubberX && n $char -200 >@RubberY) /face fast loc $calc(@RubberY+@Param2),@RubberX
/look -90

| Sing songs.
/doevents
/if $char(casting)==FALSE {
/varset CurSong @PrevSong
/call Event_Timer
}

| Get a new target if the current one is no good.
/if n $target(id)==0 /call GetTarget
/if $target(name)~~"corpse" /call GetTarget
/if $target(type)=="PC" /call GetTarget

/goto :ChantLoop

/return

Sub Event_Timer(TimerName)
/delay 2
/stopsong
/cast @Songs(@CurSong)
/varset PrevSong @CurSong
/varset SongTimer 30
/varadd CurSong 1
/if n @CurSong>@nSongs /varset CurSong 1
/return

Sub GetTarget
/if n $searchspawn(npc,radius:200)>0 /target npc radius 200
/if n $target(level)>66 /press esc
/if n $target(range)>200 /press esc
/return




sorry but im a total noob at this so any help woyld be lovely :)

eqjoe
a grimling bloodguard
a grimling bloodguard
Posts: 984
Joined: Sat Sep 28, 2002 12:26 pm

Post by eqjoe » Tue Aug 03, 2004 4:27 pm

Search and read before posting noob. WTF?

User avatar
Cr4zyb4rd
Plugins Czar
Posts: 1449
Joined: Tue Jul 20, 2004 11:46 am

Post by Cr4zyb4rd » Tue Aug 03, 2004 4:39 pm

-Consider reading the manual.
-Consider posting in the correct forum. You want help with a macro...think carefully now, where should you post?
-When posting code, please consider using code markup (there's even a cute little button you can click on when you enter your post to make this easier)

The macro you posted looks ancient. It's using syntax that MQ hasn't supported for a while now, and isn't a very good place to start if you're tying to learn. It won't work at all without MAJOR modifications. I suggest you look in the Macro Depot or Snippets forums for something a little bit more recent to get you started. If you got this from something that was inside of the MQ2 zip, some dev needs to be shot for even keeping these around, as myself and others have offered elsewhere to update anything in there that needs updating. :)

ownagejoo
orc pawn
orc pawn
Posts: 26
Joined: Mon Jul 19, 2004 4:12 pm

Post by ownagejoo » Tue Aug 03, 2004 6:30 pm

Read this topic as -- Hi I found out about this on a certain website, I read enough of the manual to get it running, I don't know SHIT about it, now I come here and ask people how to make things work???


OH first rule RTFM
second there is a search function up top use that
third spend more than 15mins trying to get things to work.
oh yeah RTFM

NOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOB

OAJ

User avatar
Kambic
a lesser mummy
a lesser mummy
Posts: 74
Joined: Fri May 28, 2004 11:48 am

Post by Kambic » Wed Aug 04, 2004 12:05 am

You need to change all of the < and > instances to < and > respectively.

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 » Wed Aug 04, 2004 12:16 am

Kambic wrote:You need to change all of the < and > instances to < and > respectively.
You got this macro running by doing that?

Mimatas
a hill giant
a hill giant
Posts: 262
Joined: Wed Mar 10, 2004 4:22 pm

Post by Mimatas » Wed Aug 04, 2004 12:34 am

DKAA: It's a start.

My recommendation: Find a better macro in the Macros 3.0 area... or if you're really ambitious, read the sticky posts in the macro 3.0 area and try to convert it to the new params.

As things are.. that won't run without a serious overhaul.

eqjoe
a grimling bloodguard
a grimling bloodguard
Posts: 984
Joined: Sat Sep 28, 2002 12:26 pm

Post by eqjoe » Thu Aug 05, 2004 4:11 pm

gah.... rash of noobs floating in from RPGexpert and they want it all to work with no effort on thier part. Instant answers with no effort on thier part. Instant afk plat making macros spoon fed and oh ya... they want it with no effort on thier part.

I am still waiting for todays "someone compile MQ for me plz" post.....



-j

Mimatas
a hill giant
a hill giant
Posts: 262
Joined: Wed Mar 10, 2004 4:22 pm

Post by Mimatas » Thu Aug 05, 2004 4:20 pm

WAIT???!!!! You mean MQ doesn't have a button that just adds plat to my bank? And no instant AA button either? WTF did I come here for?!?! I'm going to sue for false advertising, cuz I'm a law student at Dr. Sweeny's University of Law and Sewer Repair.

heh

Braedo
a lesser mummy
a lesser mummy
Posts: 33
Joined: Mon Oct 28, 2002 12:02 am

Post by Braedo » Tue Aug 10, 2004 7:01 pm

Scathing...

I enojoyed it greatly!

wassup
Official Guardian and Writer of TFM
Official Guardian and Writer of TFM
Posts: 1487
Joined: Sat Oct 26, 2002 5:15 pm

Post by wassup » Tue Aug 10, 2004 9:16 pm

Kambic wrote:You need to change all of the < and > instances to < and > respectively.
The problem is much greater than that my friend...

User avatar
Kambic
a lesser mummy
a lesser mummy
Posts: 74
Joined: Fri May 28, 2004 11:48 am

Post by Kambic » Tue Aug 10, 2004 11:23 pm

He still needs to do 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 » Wed Aug 11, 2004 4:08 am

Kambic wrote:He still needs to do it.
No, he will never get this macro working in a million years, changing the html is a pointless excercise and will achive nothing. Delete that macro and look in the correct place for a new one HERE
[quote]"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning."[/quote]

JP5
a lesser mummy
a lesser mummy
Posts: 70
Joined: Tue Jul 06, 2004 10:32 pm

Post by JP5 » Wed Aug 11, 2004 1:54 pm

His macro is not correct syntax =x
Needs work for sure.

If you're looking to start out macroing, here are a few tips:
- don't ask any questions on the boards unless you are going to donate and then ask in a VIP forum.
- go read elretardo's guide under the OUTDATED threads. It's still pretty useful for getting the hang of macro coding.
- write a lot of macros. They will all fail. But don't worry! Eventually they will not fail as much.
- use the manual.
- start out slow.. you can't write a 15kb macro just yet =P

- re read "don't ask any questions". They never get answered, because MQ2 people hate people that don't have a fucking clue, and are not willing to do a little research.

If a newb bitches at you, just shove it up his ass.

Guest

Post by Guest » Wed Aug 11, 2004 11:56 pm

Fully updated and working version of this macro is posted in the VIP forums. You want it? Donate to the project devs.