Code: Select all
#chat chat
Sub Main
/if "$p0"=="" {
/echo Syntax: /macro ch <"channel-to-look-in"> <"string-to-look-for"> <delay-in-tenth-of-a-second>
/echo Example: /macro ch "chhain" "888 CH on" 15
/echo Will trigger on ex: Cleric_001 tells chhain: 888 CH on MainTank_004 CH 888
/endmacro
}
/varset a(2,0) "$p0"
/varset a(2,1) "$p1"
/varset a(2,2) $p2
:loop
/doevents
/goto :loop
/return
Sub Event_Chat
/if "$p0"~~"$a(2,0)" /if "$p2"~~"$a(2,1)" {
/delay $int($a(2,2))
/press 1
}
/returnThere's only one pretty important anomaly.
Let's say I start it up with this command : /macro chchat "testcleric" "3 3 3" 20
It will correctly /press 1 2 seconds after it sees 3 3 3 in the testcleric channel. Only problem is once the spell is done casting.. It will wait a second or two and cast it again! Thus ruining the sync of the rotation.
It will cast again even if there is no new mention of 3s or anything that could trigger it. My assumption is that the macro is not only looking for new entries in the channel it's monitoring.. but it might be keeping a chat buffer and looking in there? Meaning as soon as there's been one "3 3 3" in the channel.. then everytime there's anything said in the channel it will put the two together and cast again?
I know it sounds weird.. that's not the way it should be working.. but this is what it's doing right now.. Really weird.. my assumption might be wrong too.. but something's not working right and I'm hoping one of you geniuses can figure it out!
thanks in advance




