Quote:
Originally Posted by lalilu11
test
|
Try something like this:
Code:
Func FightByzzr($lX, $lY)
UseSkillEX($SkillbarSlot[$Awaken_The_Blood])
MoveTo($lX, $lY,0)
$Byzzr = GetBoss()
ChangeTarget($Byzzr)
Do
For $i = 2 to 6
If GetIsDead(-2) Then Return
If GetNumberOfDeadBosses() = 1 Then Exitloop
If CanUse($i) Then UseSkillEX($i, $Byzzr)
Next
Sleep(50)
Until GetNumberOfDeadBosses() = 1 Or GetIsDead(-2)
Do
Sleep(50)
Until GetEnergy(-2) > 5
Out("Boss is dead, grabbing loot")
UseSkillEX($SkillbarSlot[$Necrotic_Traversal])
PickupLootEX()
Sleep(200)
EndFunc
Code:
Func GetBoss($aRange = 3000)
If GetMapLoading() == 0 Then Return
If GetIsDead(-2) Then Return
Local $lAgent, $lDistance
Local $lAgentArray = GetAgentArray(0xDB)
For $i = 1 To $lAgentArray[0]
$lAgent = $lAgentArray[$i]
If GetDistance($lAgent, GetMyID()) > $aRange Then ContinueLoop
If DllStructGetData($lAgent, 'typeMap') = 3072 Or DllStructGetData($lAgent, 'typeMap') = 3073 Then Return DllStructGetData($lAgentArray[$i], 'ID')
Next
Return 0
EndFunc ;==>GetBoss
Alternatively you can use Byzzr PlayerNumber (GetAgentByPlayerNumber) once you've found his player number.
To find the number of dead bosses, you can look for the typemap of a dead boss (instead of 3072 or 2073 it becomes 3080 when they die).