This is what I have :
This section checks if there is a pet active and if not casts one. Now I want it to use the default key location binds of Ctrl 5 and Ctrl 6 to turn on defence and attack skill respectively.
This isnt working, I'm not sure if its actioning the hotkeys before the pet is fully active and this skipping over it. So I tried to make it check if pet is active before trying, but thats not working.
Also if I heal myself or my pet it doesnt seem to reaquire last target and finishes the combat and moves off to continue leaving pet to continue the fight on its own.
This isn't turning the skills on yet [Under Development]
Code: Select all
<onLoad><![CDATA[
if( player.PetPtr == 0 or ( player.Pet.HP/player.Pet.MaxHP*100 ) < 20 ) then
player:cast("WARDEN_SUMMON_SPIRIT_OF_THE_OAK");
yrest(50);
if ( player.PetPtr == 1 ) then
keyboardPress( key.VK_5, key.VK_CONTROL );
yrest(50);
keyboardPress( key.VK_6, key.VK_CONTROL );
yrest(50);
end;
end;
]]></onLoad>
Code: Select all
<onLeaveCombat><![CDATA[
if( player.PetPtr == 0 or ( player.Pet.HP/player.Pet.MaxHP*100) < 20 ) then
player:cast("WARDEN_SUMMON_SPIRIT_OF_THE_OAK");
end;
]]></onLeaveCombat>
Code: Select all
<onSkillCast><![CDATA[
mob = player.TargetPtr
player:target( player.Pet );
if 60 > ( player.Pet.HP/player.Pet.MaxHP*100 ) then
player:target( player.Pet );
player:cast("DRUID_RECOVER")
yrest(3000);
end;
player:target(mob)
if( 65 > player.HP/player.MaxHP*100 ) then
player:cast("DRUID_RECOVER");
elseif( 25 > player.HP/player.MaxHP*100 ) then
player:cast("DRUID_RECOVER");
player:cast("DRUID_RECOVER");
end;
]]></onSkillCast>