Drag and Drag lots
Posted: Thu May 13, 2004 10:15 pm
I use this from an alias...... they both work.. the first is for draggin a single corpse, the second is for dragin any you target.. then target yourself, and it will begin. Target yourself again and it will end. I have drug up to 12 corpses at 1x, at a full run, and never droped 1.
I added this to my script when i made them...
Somewhere in your macro, add the lines..
#Event EvtCommandDrag "[MQ2] SRogue-Drag #*#"
/alias /drag /echo SRogue-Drag
Next add the following 3
| SRogue-Drag command. For draggin bodies
Sub Event_EvtCommandDrag(string EvtText)
/Declare Command string
/if (${EvtText.Arg[0].Equal["[MQ2]"]}) {
/varset Command ${EvtText.Arg[3]}
} else {
/return
}
/if (${gFuncInUse(int)}>0) {
/echo === EventDrag::Function already active ===
/return
}
/if (${Command.Equal[NULL]} || ${Command.Equal[single]}) {
/varset gFuncInUse 1
/call DragSingle
/varset gFuncInUse 0
/goto :Event_EvtCommandDrag_Done
}
/if (${Command.Equal[lots]}) {
/varset gFuncInUse 1
/call DragAll
/varset gFuncInUse 0
}
:Event_EvtCommandDrag_Done
/return
| Drag a single corpse that is already the target
Sub DragSingle
/echo Dragging your current target. Clear target to terminate.
/if (${Target.ID}==0) {
/echo === No target to drag. Terminated.
/return
}
/if (${Target.Type.NotEqual["corpse"]}) {
/echo === Your target is not a corpse! Terminated.
/return
}
ragSingle_Loop
/newif (${Target.ID}==0) /goto
ragSingle_Done
/corpse
/delay 3
/doevents
/goto
ragSingle_Loop
ragSingle_Done
/echo Single drag done.
/return
| Drag lots and lots of corpses
Sub DragAll
/Declare LastCorpse string
/Declare TotalCount int
/Declare Counter int
/varset Counter 0
/varset TotalCount 0
/echo Dragging all the corpses in my area that I can.
/echo Target any corpse you want pulled, target yourself to
/echo end the gathering phase, and beging moving them all out
ragAll_Targeting_Loop
/Delay 1
/call GMCheck
/doevents
/if (${Target.ID}==0) /goto
ragAll_Targeting_Loop
/if (${Target.CleanName.Equal[${LastCorpse}]}) /goto
ragAll_Targeting_Loop
/if (${Target.CleanName.Equal[${Me.Name}]}) /goto
ragAll_Targeting_Done
/if (${Target.Type.NotEqual[corpse]}) /goto
ragAll_Targeting_Loop
/echo === Adding ${Target.CleanName} to the corpse list. Last is ${LastCorpse}
/corpse
/varcalc TotalCount ${TotalCount(int)}+1
/varset gDragList[${TotalCount(int)}] ${Target.CleanName}
/varset LastCorpse ${Target.CleanName}
/goto
ragAll_Targeting_Loop
ragAll_Targeting_Done
/if (${TotalCount(int)}<1) {
/echo === No Targets to drag. Drag mode terminated.
/return
}
/echo Dragging ${TotalCount} bodies.
/target
ragAll_KeepGoing
/doevents
/for Counter 1 to ${Math.Calc[${TotalCount(int)}]}
/if (${Target.CleanName.Equal[${Me.Name}]}) /goto
ragAll_Done
/target ${gDragList[${Counter(int)}]}
/corpse
/delay 1
/next Counter
/if (${Target.CleanName.NotEqual["${Me.Name}"]}) /goto
ragAll_KeepGoing
ragAll_Done
/echo === Dragging done. ${TotalCount} corpses drug!
/return
I added this to my script when i made them...
Somewhere in your macro, add the lines..
#Event EvtCommandDrag "[MQ2] SRogue-Drag #*#"
/alias /drag /echo SRogue-Drag
Next add the following 3
| SRogue-Drag command. For draggin bodies
Sub Event_EvtCommandDrag(string EvtText)
/Declare Command string
/if (${EvtText.Arg[0].Equal["[MQ2]"]}) {
/varset Command ${EvtText.Arg[3]}
} else {
/return
}
/if (${gFuncInUse(int)}>0) {
/echo === EventDrag::Function already active ===
/return
}
/if (${Command.Equal[NULL]} || ${Command.Equal[single]}) {
/varset gFuncInUse 1
/call DragSingle
/varset gFuncInUse 0
/goto :Event_EvtCommandDrag_Done
}
/if (${Command.Equal[lots]}) {
/varset gFuncInUse 1
/call DragAll
/varset gFuncInUse 0
}
:Event_EvtCommandDrag_Done
/return
| Drag a single corpse that is already the target
Sub DragSingle
/echo Dragging your current target. Clear target to terminate.
/if (${Target.ID}==0) {
/echo === No target to drag. Terminated.
/return
}
/if (${Target.Type.NotEqual["corpse"]}) {
/echo === Your target is not a corpse! Terminated.
/return
}
/newif (${Target.ID}==0) /goto
/corpse
/delay 3
/doevents
/goto
/echo Single drag done.
/return
| Drag lots and lots of corpses
Sub DragAll
/Declare LastCorpse string
/Declare TotalCount int
/Declare Counter int
/varset Counter 0
/varset TotalCount 0
/echo Dragging all the corpses in my area that I can.
/echo Target any corpse you want pulled, target yourself to
/echo end the gathering phase, and beging moving them all out
/Delay 1
/call GMCheck
/doevents
/if (${Target.ID}==0) /goto
/if (${Target.CleanName.Equal[${LastCorpse}]}) /goto
/if (${Target.CleanName.Equal[${Me.Name}]}) /goto
/if (${Target.Type.NotEqual[corpse]}) /goto
/echo === Adding ${Target.CleanName} to the corpse list. Last is ${LastCorpse}
/corpse
/varcalc TotalCount ${TotalCount(int)}+1
/varset gDragList[${TotalCount(int)}] ${Target.CleanName}
/varset LastCorpse ${Target.CleanName}
/goto
/if (${TotalCount(int)}<1) {
/echo === No Targets to drag. Drag mode terminated.
/return
}
/echo Dragging ${TotalCount} bodies.
/target
/doevents
/for Counter 1 to ${Math.Calc[${TotalCount(int)}]}
/if (${Target.CleanName.Equal[${Me.Name}]}) /goto
/target ${gDragList[${Counter(int)}]}
/corpse
/delay 1
/next Counter
/if (${Target.CleanName.NotEqual["${Me.Name}"]}) /goto
/echo === Dragging done. ${TotalCount} corpses drug!
/return