De Medici
Grandmaster
This is a Tamer farming assistant script.
By looping this script you will obtain the following features:
1. Pk protection:
if a pk comes within your screen the script will aumatically recall you back. It is not possible for a dexxer to kill you anylonger. I tested this for monthes in shame 5. The only way a pk can get u is by precasting a spell and disrupt your recall spell. Otherwise the makro reacts to early that a dexxer could disrupt the spell (tested MANY times). Sometimes I realize that there is a pk BECAUSE of the recall. For the preloaded spell issue it provides:
2. Auto Cast protection:
You will be permanent under the influence of the spell protection --> while carrying pots u have good chances to cast succesfully recall after first recall spell was disrupted (what happens very rare).
3. Auto heal pets:
You need to make a makro with the name 'promptalias' and choose a hotkey for it:
The macro must look like this:
promptalias 'pet'
playmacro 'Champ Script'
Champ Script is the name of the whole assistant Script, so make sure u name that script Champ Script what means u go to starting point.
if u want to start healing a pet press your hotkey for promptalias, choose the pet and it will infinite autoheal the pet AS LONG as u are withing 1 yard AND the Pet is not full health. If you healed it up and the pet restart getting damaged it will automatically restart, not before. If u wanne choose the other pet press key for promtalias and choose it, it will now heal the other pet. Sometimes I want to go to next mob even if the selceted pet is not full healed and it would suck if it would restart healing it everytime on the way to the new mob because u will not stay withing the bandage distance all the time by running to the next mob and you would lose many badnis. For that reason the script will only try it one time on the way to the new mob.
4. Auto cast strenght if you carry to much.
5. I had an auto attack closest mob while having all guard status. Dunno if its // or i deleted it to lazy to take a look now.
Relax!
	
	
	
		
			
			By looping this script you will obtain the following features:
1. Pk protection:
if a pk comes within your screen the script will aumatically recall you back. It is not possible for a dexxer to kill you anylonger. I tested this for monthes in shame 5. The only way a pk can get u is by precasting a spell and disrupt your recall spell. Otherwise the makro reacts to early that a dexxer could disrupt the spell (tested MANY times). Sometimes I realize that there is a pk BECAUSE of the recall. For the preloaded spell issue it provides:
2. Auto Cast protection:
You will be permanent under the influence of the spell protection --> while carrying pots u have good chances to cast succesfully recall after first recall spell was disrupted (what happens very rare).
3. Auto heal pets:
You need to make a makro with the name 'promptalias' and choose a hotkey for it:
The macro must look like this:
promptalias 'pet'
playmacro 'Champ Script'
Champ Script is the name of the whole assistant Script, so make sure u name that script Champ Script what means u go to starting point.
if u want to start healing a pet press your hotkey for promptalias, choose the pet and it will infinite autoheal the pet AS LONG as u are withing 1 yard AND the Pet is not full health. If you healed it up and the pet restart getting damaged it will automatically restart, not before. If u wanne choose the other pet press key for promtalias and choose it, it will now heal the other pet. Sometimes I want to go to next mob even if the selceted pet is not full healed and it would suck if it would restart healing it everytime on the way to the new mob because u will not stay withing the bandage distance all the time by running to the next mob and you would lose many badnis. For that reason the script will only try it one time on the way to the new mob.
4. Auto cast strenght if you carry to much.
5. I had an auto attack closest mob while having all guard status. Dunno if its // or i deleted it to lazy to take a look now.
Relax!
		Code:
	
	//1. PK Protection + health warning + Auto attack colosest mob/animal
//------------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// Auto Strength Buff if carrying too much
if @injournal 'to move' 'system'
  cast 'Strength'
  waitfortarget 3000
  target! 'self'
  clearjournal
endif
//Auto Protection
if not timerexists 'Protect'
  createtimer 'Protect'
  settimer 'Protect' 300000
endif
if timer 'Protect' >= 300000
  cast 'Protection'
  settimer 'Protect' 0
endif
// Set Pet
if not findalias 'pet'
  promptalias 'pet'
endif
//Find RuneBook
if not findalias 'Escape Book'
  promptalias 'Escape Book'
endif
// Pk Recall Routine
@unsetalias 'friend'
getfriend 'murderer' 'humanoid' 'closest'
while @inrange 'friend' 28
  cast "Recall"
  msg 'all follow me'
  pause 200
  msg 'all follow me'
  pause 50
  msg 'all follow me'
  pause 50
  msg 'all follow me'
  pause 50
  msg 'all follow me'
  waitfortarget 2000
  target! 0x406afe4f
  @unsetalias 'friend'
endwhile
// 2. Autoheal Pet(s) //------------------------------------------------------------------------------
//-----------------------------------------------------------------------------
//Health check of your pets
//----------------------------------------------------------------------------
//Strength if carrying to much
while  @diffhits 'pet' > 0
  // Auto Strength Buff if carrying too much
  if @injournal 'to move'  'system'
    cast 'Strength'
    waitfortarget 3000
    target! 'self'
    clearjournal
  endif
  while inrange 'pet' 1
    if @injournal 'close enough' 'system'
      clearjournal
      playmacro 'Champ Script'
    endif
    if @findtype 0xe21 'backpack'
      useobject 'found'
      waitfortarget 2000
      target! 'pet'
    else headmsg 'no bandages'
    endif
    //time adding loop
    while not @injournal 'finish applying' 'system'
      pause 50
      // Auto Strength Buff if carrying too much
      if @injournal 'too much' 'system'
        cast 'Strength'
        waitfortarget 3000
        target! 'self'
        clearjournal
      endif
      // headmsg 'Time adding'
      // PK recall routine for protection during time adding loop--------
      @unsetalias 'friend'
      getfriend 'murderer' 'humanoid' 'closest'
      while @inrange 'friend' 28
        cast "Recall"
        msg 'all follow me'
        pause 200
        msg 'all follow me'
        pause 50
        msg 'all follow me'
        pause 50
        msg 'all follow me'
        pause 50
        msg 'all follow me'
        autotargetobject '0x406afe4f'
        pause 500
        @unsetalias 'friend'
      endwhile
      // to avoid getting lost in the time adding routine if pet is moving
      if not inrange 'pet' 2
        playmacro 'Champ Script'
      endif
      if @injournal 'not damaged' 'system'
        clearjournal
        playmacro 'Champ Script'
      endif
      //endwhile time adding until message in journal
    endwhile
    clearjournal
    @unsetalias 'friend'
    getfriend 'murderer' 'humanoid' 'closest'
    while @inrange 'friend' 28
      cast "Recall"
      msg 'all follow me'
      pause 200
      msg 'all follow me'
      pause 50
      msg 'all follow me'
      pause 50
      msg 'all follow me'
      pause 50
      msg 'all follow me'
      waitfortarget 2000
      target! 0x406afe4f
      @unsetalias 'enemy'
    endwhile
    //endwhile inrange
  endwhile
  @unsetalias 'friend'
  getfriend 'murderer' 'humanoid' 'closest'
  while @inrange 'friend' 28
    cast "Recall"
    msg 'all follow me'
    pause 200
    msg 'all follow me'
    pause 50
    msg 'all follow me'
    pause 50
    msg 'all follow me'
    pause 50
    msg 'all follow me'
    waitfortarget 2000
    target! 0x406afe4f
    @unsetalias 'friend'
    //endwhile pk protection
  endwhile
  //endwhile pet-health check
endwhile