All pastes #372810 Raw Edit

Unnamed

public text v1 · immutable
#372810 ·published 2007-02-26 09:02 UTC
rendered paste body
SetActiveWindow Knight OnLine Client
ObjVar 10
CommandDelay 1500

Constants
/////////////////////////////////////////
//// Priest Macro v2.4 by Vinthian ////
//// Release Date: 06/25/06 ////
//// Please give me credit for this! ////
/////////////////////////////////////////

Resolution = 1024x768 // 1024x768 or 1280x1024
BuffOn = yes // yes/no
GroupBuff = Yes // yes/no
HealPercentMajor = .75 // % HealAt (Masssive Heal)
HealPercentMinor = .90 // % HealAt (Great Heal)

// Skill Bar
Heal1 = 6 // Massive Heal
Heal2 = 5 // Great Heal
ACBuff = 2 // AC Buff
HPBuff = 3 // Group HP Buff/HP Buff
REBuff = 0 // Resistance Buff, 0 is off
ManaPot = 7 // Mana Pot when out of mana
Gate = 8 // For towning

// Static Variables
Players = 8
HealAt = 0
HealAt2 = 0
CheckX = 0
HPEmpty = 0
HPFull = 0
SitX = 0
SitY = 0
End

If $Resolution = 1024x768
Compute CheckX = 910
Compute HPEmpty = 902
Compute HPFull = 1008
Compute SitX = 538
Compute SitY = 747
End

If $Resolution = 1280x1024
Compute CheckX = 1170
Compute HPEmpty = 1157
Compute HPFull = 1263
Compute SitX = 665
Compute SitY = 1001
End

// Compute Heal At
Compute HealAt = int( $HPEmpty + ( $HealPercentMinor * ( $HPFull - $HPEmpty ) ) )
Compute HealAt2 = int( $HPEmpty + ( $HealPercentMajor * ( $HPFull - $HPEmpty ) ) )

Procedure CheckParty
IsRed $CheckX, 75
Else
IsBlue $CheckX, 81
Else
Compute Players = 0
End
End
IsRed $CheckX, 75
IsBlue $CheckX, 81
Compute Players = 1
End
End
IsRed $CheckX, 120
IsBlue $CheckX, 126
Compute Players = 2
End
End
IsRed $CheckX, 165
IsBlue $CheckX, 171
Compute Players = 3
End
End
IsRed $CheckX, 210
IsBlue $CheckX, 216
Compute Players = 4
End
End
IsRed $CheckX, 255
IsBlue $CheckX, 262
Compute Players = 5
End
End
IsRed $CheckX, 300
IsBlue $CheckX, 307
Compute Players = 6
End
End
IsRed $CheckX, 345
IsBlue $CheckX, 352
Compute Players = 7
End
End
IsRed $CheckX, 390
IsBlue $CheckX, 397
Compute Players = 8
End
End
Delay 200
End

Procedure Sit
IsBlack $SitX, $SitY
KeyDown c 200
Delay 200
End
End

Procedure Town
If $Players = 0
Delay 3 sec
KeyDown $Gate 300
Say /town
Delay 15 sec
KeyDown c 200
Stop
End
End

Procedure LeftMouseClick
LeftMouseDown 200
Delay 200
LeftMouseUp 200
Delay 200
End

Procedure ManaPot
IsBlack 160, 27
KeyDown $ManaPot 200
Delay 200
End
End

Procedure HealSelf
IsBlack 233, 9
KeyDown z 200
Delay 200
KeyDown $Heal2 200
Delay 2500
End
End

Procedure Heal // Heal
If $Players > 0 // Player 1
IsRed $HealAt, 75 // If the person is below 90%
Else
MousePos $CheckX, 75 // Click
Call LeftMouseClick // Them
IsRed $HealAt2, 75 // If the person is ALSO below 60%
KeyDown $Heal2 200 // Great Heal because they aren't under 60%
Else
KeyDown $Heal1 200 // Massive Heal because they are under 60%
End
Delay 2500
End
End

If $Players > 1 // Player 2
IsRed $HealAt, 120
Else
MousePos $CheckX, 120
Call LeftMouseClick
IsRed $HealAt2, 120
KeyDown $Heal2 200
Else
KeyDown $Heal1 200
End
Delay 2500
End
End

If $Players > 2 // Player 3
IsRed $HealAt, 165
Else
MousePos $CheckX, 165
Call LeftMouseClick
IsRed $HealAt2, 120
KeyDown $Heal2 200
Else
KeyDown $Heal1 200
End
Delay 2500
End
End

If $Players > 3 // Player 4
IsRed $HealAt, 210
Else
MousePos $CheckX, 210
Call LeftMouseClick
IsRed $HealAt2, 210
KeyDown $Heal2 200
Else
KeyDown $Heal1 200
End
Delay 2500
End
End

If $Players > 4 // Player 5
IsRed $HealAt, 255
Else
MousePos $CheckX, 255
Call LeftMouseClick
IsRed $HealAt2, 255
KeyDown $Heal2 200
Else
KeyDown $Heal1 200
End
Delay 2500
End
End

If $Players > 5 // Player 6
IsRed $HealAt, 300
Else
MousePos $CheckX, 300
Call LeftMouseClick
IsRed $HealAt2, 300
KeyDown $Heal2 200
Else
KeyDown $Heal1 200
End
Delay 2500
End
End

If $Players > 6 // Player 7
IsRed $HealAt, 345
Else
MousePos $CheckX, 345
Call LeftMouseClick
IsRed $HealAt2, 345
KeyDown $Heal2 200
Else
KeyDown $Heal1 200
End
Delay 2500
End
End

If $Players > 7 // Player 8
IsRed $HealAt, 390
Else
MousePos $CheckX, 390
Call LeftMouseClick
IsRed $HealAt2, 390
KeyDown $Heal2 200
Else
KeyDown $Heal1 200
End
Delay 2500
End
End
End

Procedure Buffs
Call CheckParty
Call ManaPot
If $HPBuff = 0
Else
If $GroupBuff = yes
Else
KeyDown $HPBuff 200
Delay 2 sec
End
End
If $ACBuff = 0
Else
KeyDown $ACBuff 200
Delay 2 sec
End
If $REBuff = 0
Else
KeyDown $REBuff 200
Delay 2 sec
End
End

Procedure Buff Every 615 sec // Buff
Call CheckParty
Call ManaPot
Delay 2 Sec
If $GroupBuff = yes
KeyDown $HPBuff 200
Delay 2500
End
If $BuffOn = yes
If $Players > 0 // Player 1
MousePos $CheckX, 75
Call LeftMouseClick
Call Buffs
End

If $Players > 1 // Player 2
MousePos $CheckX, 120
Call LeftMouseClick
Call Buffs
End

If $Players > 2 // Player 3
MousePos $CheckX, 165
Call LeftMouseClick
Call Buffs
End

If $Players > 3 // Player 4
MousePos $CheckX, 210
Call LeftMouseClick
Call Buffs
End

If $Players > 4 // Player 5
MousePos $CheckX, 255
Call LeftMouseClick
Call Buffs
End

If $Players > 5 // Player 6
MousePos $CheckX, 300
Call LeftMouseClick
Call Buffs
End

If $Players > 6 // Player 7
MousePos $CheckX, 345
Call LeftMouseClick
Call Buffs
End

If $Players > 7 // Player 8
MousePos $CheckX, 390
Call LeftMouseClick
Call Buffs
End
End
End

While 1 = 1
ProcessMessages
Call CheckParty
Call ManaPot
Call HealSelf
Call Heal
Call town
Call Sit
Delay 200
End