UO Macros
Would you like to react to this message? Create an account in a few clicks or log in to continue.

good for raising Vet or training Pets

Go down

good for raising Vet or training Pets Empty good for raising Vet or training Pets

Post by Admin Sun Feb 15, 2015 9:47 pm

//Setup
if not findalias 'pet1'
headmsg 'Select first pet'
promptalias 'pet1'
endif
if not findalias 'pet2'
headmsg 'Select second pet'
promptalias 'pet2'
endif
if not findalias 'bandages'
headmsg 'Select bandages'
promptalias 'bandages'
endif
//Feed pets every hour
if not timerexists 'feed'
createtimer 'feed'
endif
if timer 'feed' > 600000
settimer 'feed' 0
feed 'pet1' 'Meat' 'any' 1
pause 500
feed 'pet2' 'Meat' 'any' 1
endif
//Tell pets to attack each other if they're full HP
if hits 'pet1' == maxhits 'pet1' and hits 'pet2' == maxhits 'pet2'
waitforcontext 'pet1' 3 15000
autotargetobject 'pet2'
pause 500
waitforcontext 'pet2' 3 15000
autotargetobject 'pet1'
pause 500
endif
//Heal the lowest HP pet
if @findobject 'bandages'
useobject 'found'
else //Out of bandages
msg 'all stay'
pause 3000
headmsg 'Select bandages'
promptalias 'bandages'
endif
if diffhits 'pet1' > diffhits 'pet2'
autotargetobject 'pet1'
else
autotargetobject 'pet2'
endif
pause 5500
//Tell pets to stop if either is missing 50%
if diffhits 'pet1' > 50 or diffhits 'pet2' > 50
msg 'all stop'
pause 2000
msg 'all stay'
pause 2000
//Heal them to full
while hits 'pet1' < maxhits 'pet1'
useobject 'bandages'
autotargetobject 'pet1'
pause 5500
endwhile
while hits 'pet2' < maxhits 'pet2'
useobject 'bandages'
autotargetobject 'pet2'
pause 5500
endwhile
endif

Admin
Admin

Posts : 24
Join date : 2015-02-15

https://uosteam-macros.board-directory.net

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum