Author Topic: [D2NT] Javazon/Bowazon Character Setup  (Read 5914 times)

cooptheking

  • Guest
[D2NT] Javazon/Bowazon Character Setup
« on: September 03, 2010, 11:55:33 AM »
This is BigApple@EONW's Script
Code: [Select]
.: Amazon Jav/Bow Class Script :.

.:.:.:.:.:.:.: Version 1.6 June 24 2010 :.:.:.:.:.:.:.

NOTES BOWZON:
* MAKE SURE YOUR BOW IS ON THE LEFT WEAPON SLOT.
* Make sure on weapon swap (CTA) the left skill is on attack and on bow switch (Main) left skill is NOT attack. This is in case bot leaves on wrong weapon switch and cannot equip arrows.
* It would be best to start with no arrows in weapon slot or in inventory.
* If you are worried that for some strange reason the bot will drop the bow then you shouldn't use this script.
* Bot will only buy arrows/bolts if multiple shot is at least level 1. This is to prevent javazon from buying arrows. If Javazon has 1 into multiple shot then you are screwed lol
* While attacking, if the bot reaches low arrows/bolts it will TP and either buy new ones
* Crossbow/bolts supported

NOTES JAVAZON:
* Bot will repair javelins if they break while attacking
Step[1] Replace your NTAttack.ntl with this
Code: [Select]
const NTA_DAMAGE_NONE = 0;
const NTA_DAMAGE_PHYSICAL = 1;
const NTA_DAMAGE_MAGIC = 2;
const NTA_DAMAGE_FIRE = 3;
const NTA_DAMAGE_LIGHTNING = 4;
const NTA_DAMAGE_COLD = 5;
const NTA_DAMAGE_POISON = 6;

var _NTA_SkillHand = new Array(7);
var _NTA_SkillDamage = new Array(7);
var _NTA_SkillRange = new Array(7);

function NTA_Initialize()
{
if(NTConfig_AttackSkill[1] == 0 || NTConfig_AttackSkill[3] == 0)
NTA_DetectAttackPattern();

for(var i = 0 ; i < 8 ; i++)
{
if(NTConfig_AttackSkill[i] > 0)
{
_NTA_SkillHand[i] = GetBaseStat("skills.txt", NTConfig_AttackSkill[i], 166) ? 2 : NTC_HAND_RIGHT;
_NTA_SkillDamage[i] = NTA_GetDamageType(NTConfig_AttackSkill[i]);

switch(NTConfig_AttackSkill[i])
{
case 6:  //Magic Arrow
case 7:  //Fire Arrow
            _NTA_SkillRange[i] = 15;
            break;
case 10: //Jab
            _NTA_SkillRange[i] = 3;
            break;
case 11: //Cold Arrow
case 12: //Multiple Shot
case 16: //Exploding Arrow
case 21: //Ice arrow
case 22: //Guided arrow
            _NTA_SkillRange[i] = 20;
            break;
case 24: //Charged Strike
            _NTA_SkillRange[i] = 3;
            break;
case 25: //Plague jav
            _NTA_SkillRange[i] = 10;
            break;
case 26://Strafe
case 27://Immolation Arrow
            _NTA_SkillRange[i] = 15;
            break;
case 30: //Fend
            _NTA_SkillRange[i] = 3;
            break;
case 31: //Freezing arrow
            _NTA_SkillRange[i] = 15;
            break;
case 35: //Lightning Fury
            _NTA_SkillRange[i] = 12;
            break;
case 44: //Frost Nova
case 48: // Nova
_NTA_SkillRange[i] = 10;
break;
case 64: // Frozen Orb
_NTA_SkillRange[i] = 15;
break;
case 97: //Smite
case 106: //Zeal
case 112: //Blessed Hammer
_NTA_SkillRange[i] = 3;
break;
case 151: //Whirlwind
_NTA_SkillRange[i] = 8;
break;
case 152: //Berserk
_NTA_SkillRange[i] = 3;
break;
default:
_NTA_SkillRange[i] = 25;
break;
}
}
}
}

function NTA_KillMonster(classid)
{
var _target;

if(NTConfig_AttackSkill[1] < 1)
return false;

_target = NTC_FindUnit(NTC_UNIT_MONSTER, classid, 5);

if(!_target)
return false;

if(_target.IsAttackable())
{
var _attackcount = 0;

while(_attackcount < 300 && NTA_IsValidMonster(_target))
{
if(NTA_Attack(_target, (_attackcount%30) == 0) < 2)
break;

_attackcount++;
}
}

return (_target.hp <= 0 || _target.mode == 0 || _target.mode == 12);
}

function NTA_ClearPosition(range, pickitem, safelevel)
{
var _orgx, _orgy;
var _spectype = [0x0A, 0x01, 0x01];
var _skiplist;
var _attackcount = 0;
var _target;
var _distance, _mingid, _mindistance;
var _result;

if(NTConfig_AttackSkill[1] < 1 || NTConfig_AttackSkill[3] < 1)
return false;

switch(arguments.length)
{
case 0:
range = 20;
case 1:
pickitem = false;
case 2:
safelevel = 0;
default:
if(NTConfig_CheckSelfSafe < 0x01 && NTConfig_CheckMercSafe < 0x01)
safelevel = 0;
break;
}

_orgx = me.x;
_orgy = me.y;

for(var i = 0 ; i < _spectype.length ; i++)
{
_skiplist = new Array();

while(_attackcount < (i+1)*100)
{
_mindistance = 100000;

_target = NTC_FindUnit(NTC_UNIT_MONSTER);

if(_target)
{
do
{
if(_skiplist.indexOf(_target.gid) < 0)
{
if(_target.IsAttackable() && (_target.spectype&_spectype[i]))
{
if(GetDistance(_orgx, _orgy, _target.x, _target.y) <= range && NTA_IsValidMonster(_target))
{
_distance = GetDistance(me, _target);

if(_distance < _mindistance)
{
_mingid = _target.gid;
_mindistance = _distance;
}
}
}
else
_skiplist.push(_target.gid);
}
} while(_target.GetNext());
}

if(_mindistance < 100000)
{
_target = NTC_FindUnit(NTC_UNIT_MONSTER, _mingid);

if(_target)
{
_result = NTA_Attack(_target, (_attackcount%30) == 0);

switch(_result)
{
case 1:
_skiplist.push(_mingid);
break;
case 2:
case 3:
_attackcount++;
break;
default:
return false;
}
}
}
else
break;
}
}

if(me.classid == NTC_CHAR_CLASS_PALADIN)
{
if(_attackcount > 2 && (parseInt(me.hp*100/me.hpmax) < NTConfig_UseRedemptionHP || parseInt(me.mp*100/me.mpmax) < NTConfig_UseRedemptionMP))
{
if(NTC_PutSkill(124, NTC_HAND_RIGHT))
NTC_PingDelay(1000);
}
}

if(NTConfig_OpenChest)
{
_target = NTC_GetSpecialChest();

if(_target && GetDistance(_orgx, _orgy, _target.x, _target.y) <= range && NTC_OpenChest(_target))
_attackcount++;
}

if(pickitem && _attackcount > 0)
NTSI_PickItems();

switch(safelevel)
{
case 1:
return NTTMGR_CheckSafe(0x00, NTConfig_CheckMercSafe&0x01);
case 2:
return NTTMGR_CheckSafe(NTConfig_CheckSelfSafe, NTConfig_CheckMercSafe);
}

return true;
}

function NTA_ClearLevel(pickitem, safelevel)
{
var i;
var _room, _rooms;
var _distance, _minindex, _mindistance;

_room = GetRoom();

if(!_room)
return false;

switch(arguments.length)
{
case 0:
pickitem = true;
case 1:
safelevel = 2;
default:
if(NTConfig_CheckSelfSafe < 0x01 && NTConfig_CheckMercSafe < 0x01)
safelevel = 0;
break;
}

_rooms = new Array();

do
{
_rooms.push([parseInt(_room.x*5 + _room.xsize*5/2), parseInt(_room.y*5 + _room.ysize*5/2)]);
} while(_room.GetNext());

while(_rooms.length > 0)
{
_mindistance = 100000;

for(i = 0 ; i < _rooms.length ; i++)
{
_distance = GetDistance(me.x, me.y, _rooms[i][0], _rooms[i][1]);

if(_distance < _mindistance)
{
_minindex = i;
_mindistance = _distance;
}
}

if(NTM_MoveTo(me.areaid, _rooms[_minindex][0], _rooms[_minindex][1], 1))
{
if(!NTA_ClearRoom(pickitem, safelevel))
return false;

NTP_DoPrecast(false);
}

_rooms.splice(_minindex, 1);
}

return true;
}

function NTA_ClearRoom(pickitem, safelevel)
{
var _room;
var _spectype = [0x0A, 0x01, 0x01];
var _skiplist;
var _attackcount = 0;
var _target;
var _distance, _mingid, _mindistance;
var _result;

if(NTConfig_AttackSkill[1] < 1 || NTConfig_AttackSkill[3] < 1)
return false;

_room = me.GetRoom();

if(!_room)
return false;

switch(arguments.length)
{
case 0:
pickitem = false;
case 1:
safelevel = 0;
default:
if(NTConfig_CheckSelfSafe < 0x01 && NTConfig_CheckMercSafe < 0x01)
safelevel = 0;
break;
}

for(var i = 0 ; i < _spectype.length ; i++)
{
_skiplist = new Array();

while(_attackcount < (i+1)*100)
{
_mindistance = 100000;

_target = NTC_FindUnit(NTC_UNIT_MONSTER);

if(_target)
{
do
{
if(_skiplist.indexOf(_target.gid) < 0)
{
if(_target.IsAttackable() && (_target.spectype&_spectype[i]))
{
if(_room.UnitInRoom(_target) && NTA_IsValidMonster(_target))
{
_distance = GetDistance(me, _target);

if(_distance < _mindistance)
{
_mingid = _target.gid;
_mindistance = _distance;
}
}
}
else
_skiplist.push(_target.gid);
}
} while(_target.GetNext());
}

if(_mindistance < 100000)
{
_target = NTC_FindUnit(NTC_UNIT_MONSTER, _mingid);

if(_target)
{
_result = NTA_Attack(_target, (_attackcount%30) == 0);

switch(_result)
{
case 1:
_skiplist.push(_mingid);
break;
case 2:
case 3:
_attackcount++;
break;
default:
return false;
}
}
}
else
break;
}
}

if(me.classid == NTC_CHAR_CLASS_PALADIN)
{
if(_attackcount > 2 && (parseInt(me.hp*100/me.hpmax) < NTConfig_UseRedemptionHP || parseInt(me.mp*100/me.mpmax) < NTConfig_UseRedemptionMP))
{
if(NTC_PutSkill(124, NTC_HAND_RIGHT))
NTC_PingDelay(1000);
}
}

if(NTConfig_OpenChest)
{
_target = NTC_GetSpecialChest();

if(_target && _room.UnitInRoom(_target) && NTC_OpenChest(_target))
_attackcount++;
}

if(pickitem && _attackcount > 0)
NTSI_PickItems();

switch(safelevel)
{
case 1:
return NTTMGR_CheckSafe(0x00, NTConfig_CheckMercSafe&0x01);
case 2:
return NTTMGR_CheckSafe(NTConfig_CheckSelfSafe, NTConfig_CheckMercSafe);
}

return true;
}

function NTA_IsValidMonster(monster)
{
var _classid;

if(monster.hp <= 0 || monster.mode == 0 || monster.mode == 12)
return false;

_classid = monster.classid;

if(((_classid >= 110 && _classid <= 113) || _classid == 608) && monster.mode == 8) // ignore flying scavengers
return false;

if(_classid == 68 && monster.mode == 14) // ignore burrowing maggots
return false;

if(_classid >= 258 && _classid <= 263 && monster.mode == 14) // ignore submerged WaterWatchers
return false;

if(monster.GetState(53) || monster.GetState(96)) // Conversion, Revive
return false;

return true;
}

function NTA_GetDamageType(skillid)
{
if(skillid == 74) // Corpse Explosion
return NTA_DAMAGE_PHYSICAL;

if(skillid == 112) // Blessed Hammer
return NTA_DAMAGE_NONE;

switch(GetBaseStat("skills.txt", skillid, 233))
{
case "cold":
return NTA_DAMAGE_COLD;
case "fire":
return NTA_DAMAGE_FIRE;
case "ltng":
return NTA_DAMAGE_LIGHTNING;
case "mag":
return NTA_DAMAGE_MAGIC;
case "pois":
return NTA_DAMAGE_POISON;
case "stun":
return NTA_DAMAGE_NONE;
default:
if(GetBaseStat("skills.txt", skillid, 178) || GetBaseStat("skills.txt", skillid, 182)) // aura or passive
return NTA_DAMAGE_NONE;
}

return NTA_DAMAGE_PHYSICAL;
}

function NTA_GetResistance(enemy, type)
{
switch(type)
{
case NTA_DAMAGE_PHYSICAL:
return enemy.GetStat(36);
case NTA_DAMAGE_MAGIC:
return enemy.GetStat(37);
case NTA_DAMAGE_FIRE:
return enemy.GetStat(39);
case NTA_DAMAGE_LIGHTNING:
return enemy.GetStat(41);
case NTA_DAMAGE_COLD:
return enemy.GetStat(43);
case NTA_DAMAGE_POISON:
return enemy.GetStat(45);
}

return 0;
}

function NTA_DetectAttackPattern()
{
switch(me.classid)
{
case NTC_CHAR_CLASS_AMAZON:
return NTA_AmazonAttackPatternInt();
case NTC_CHAR_CLASS_SORCERESS:
return NTA_SorceressAttackPatternInt();
case NTC_CHAR_CLASS_NECROMANCER:
return NTA_NecromancerAttackPatternInt();
case NTC_CHAR_CLASS_PALADIN:
return NTA_PaladinAttackPatternInt();
case NTC_CHAR_CLASS_BARBARIAN:
return NTA_BarbarianAttackPatternInt();
case NTC_CHAR_CLASS_DRUID:
return NTA_DruidAttackPatternInt();
case NTC_CHAR_CLASS_ASSASSIN:
return NTA_AssassinAttackPatternInt();
}

return false;
}

// Return value : 0 = Unrecoverable process, 1 = Unavailable attack, 2 = Onetime fail, 3 = Success
function NTA_Attack(target, firstorder)
{
switch(me.classid)
{
case NTC_CHAR_CLASS_AMAZON:
return NTA_AmazonAttackInt(target, firstorder);
case NTC_CHAR_CLASS_SORCERESS:
return NTA_SorceressAttackInt(target, firstorder);
case NTC_CHAR_CLASS_NECROMANCER:
return NTA_NecromancerAttackInt(target, firstorder);
case NTC_CHAR_CLASS_PALADIN:
return NTA_PaladinAttackInt(target, firstorder);
case NTC_CHAR_CLASS_BARBARIAN:
return NTA_BarbarianAttackInt(target, firstorder);
case NTC_CHAR_CLASS_DRUID:
return NTA_DruidAttackInt(target, firstorder);
case NTC_CHAR_CLASS_ASSASSIN:
return NTA_AssassinAttackInt(target, firstorder);
}

return 0;
}
function NTA_IsWeaponBroken()
{
   var _weapon;
   _weapon = me.GetItems();

      if(_weapon)
      {
         for(var i = 0 ; i < _weapon.length ; i++)
         {
            if(_weapon[i].itemflag&0x100)
            {   
               if(_weapon[i].mode == 1 && _weapon[i].itemloc == 4 || _weapon[i].itemloc == 5)
               {
                  Print("?c8My weapon broke, I am going to town to repair it.")
                  NTTMGR_VisitTown();
                  NTTMGR_TownManager();   
                  break;

               }   
            }
         }
      }
}
// Internal function
function NTA_AmazonAttackPatternInt()
{
   
   var _maxindex, _maxskill;
   var _avgskilllevel = new Array();

   _avgskilllevel[0]  = me.GetSkill(35, false);
   _avgskilllevel[1]  = parseInt((me.GetSkill(31, false) + me.GetSkill(11, false) + me.GetSkill(21, false)) /3 );
   _avgskilllevel[2]  = me.GetSkill(26, false);


   _maxindex = -1;
   _maxskill = 0;

   for(var i = 0 ; i < _avgskilllevel.length ; i++)
   {
      if(_avgskilllevel[i] > _maxskill)
      {
         _maxindex = i;
         _maxskill = _avgskilllevel[i];
      }
   }

   switch(_maxindex)
   {
   case 0: // Lightning Fury for Javazon
     
      NTConfig_AttackSkill[1] = 35;
      NTConfig_AttackSkill[2] = 35;
      NTConfig_AttackSkill[3] = 35;
      NTConfig_AttackSkill[4] = 35;
      NTConfig_AttackSkill[5] = 35;
      NTConfig_AttackSkill[6] = 35;
      NTConfig_AttackSkill[7] = 24;
      break;

   case 1: // Freezing Arrow for Bowzon
     
      NTConfig_AttackSkill[1] = 31;
      NTConfig_AttackSkill[2] = 31;
      NTConfig_AttackSkill[3] = 31;
      NTConfig_AttackSkill[4] = 31;
      NTConfig_AttackSkill[5] = 31;
      NTConfig_AttackSkill[6] = 31;
      NTConfig_AttackSkill[7] = 31;
      break;
   
   case 2: // Cold Arrow + Strafe for Bowzon
   
      NTConfig_AttackSkill[0] = 11;
      NTConfig_AttackSkill[1] = 26;
      NTConfig_AttackSkill[2] = 26;
      NTConfig_AttackSkill[3] = 26;
      NTConfig_AttackSkill[4] = 26;
      NTConfig_AttackSkill[5] = 26;
      NTConfig_AttackSkill[6] = 26;
      NTConfig_AttackSkill[7] = 22;
      break;
   }

   return (NTConfig_AttackSkill[1] && NTConfig_AttackSkill[3]);
}


function NTA_AmazonAttackInt(target, firstorder)
{
   var _primaryindex;
   
   if(NTTMGR_CheckCurse(NTConfig_CheckSelfSafe&0x10, NTConfig_CheckMercSafe&0x10))
   {
      if(!NTTMGR_VisitTown())
         return 0;
   }
   
   
   if(me.GetSkill(12, false) >= 1)
      NTA_HaveArrows();
   else
      NTA_IsWeaponBroken();
   

   if(firstorder && NTConfig_AttackSkill[0] > 0 && NTA_GetResistance(target, _NTA_SkillDamage[0]) < 100)
   {
      if(GetDistance(me, target) > _NTA_SkillRange[0] || !CheckCollision(me, target, 4))
      {
         var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _NTA_SkillRange[0], 4);

         if(_pos)
            NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
      }

      if(!NTC_CastSkill(NTConfig_AttackSkill[0], _NTA_SkillHand[0], target))
         return 2;

      return 3;
   }

   _primaryindex = (target.spectype&0x0A) ? 1 : 3;

   switch(target.classid)
   {
      case 243://Diablo
      case 544://Baal
      case 242:
         if(!NTA_AmazonCastSkillInt(7, target))
            return 2;

         return 3;
      default:
         break;
   }

   if(NTA_GetResistance(target, _NTA_SkillDamage[_primaryindex]) <= 90)
   {
      if(!NTA_AmazonCastSkillInt(_primaryindex, target))
         return 2;

      return 3;
   }
   
   
   if(NTConfig_AttackSkill[5] > 0  && NTA_GetResistance(target, _NTA_SkillDamage[5]) > 80)
   {
      if(!NTA_AmazonCastSkillInt(5, target))
         return 2;

      return 3;
   }
   
   if(NTA_GetResistance(target, _NTA_SkillDamage[_primaryindex]) < 100 || (_primaryindex == 1 && NTC_GetMerc()))
   {
      if(!NTA_AmazonCastSkillInt(_primaryindex, target))
         return 2;

      return 3;
   }

   return 1;
}

function NTA_AmazonCastSkillInt(index, target)
{

   if(GetDistance(me, target) > _NTA_SkillRange[index] || !CheckCollision(me, target, 4))
   {
      var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _NTA_SkillRange[index], 4);

      if(_pos)
         NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
   }
 
   return NTC_CastSkill(NTConfig_AttackSkill[index], NTC_HAND_LEFT, target);
   
   if(NTConfig_AttackSkill[index+1] > 0)
   {
      if(GetDistance(me, target) > _NTA_SkillRange[index+1] || !CheckCollision(me, target, 4))
            {
               var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _NTA_SkillRange[index+1], 4);

               if(_pos)
                     NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
           }

             return NTC_CastSkill(NTConfig_AttackSkill[index+1], _NTA_SkillHand[index+1], target);
        }
   
}

function NTA_SorceressAttackPatternInt()
{
var _maxindex, _maxskill;
var _avgskilllevel = new Array();

_avgskilllevel[0] = parseInt((me.GetSkill(59, false)+me.GetSkill(39, false)+me.GetSkill(45, false)+me.GetSkill(55, false))/4);
_avgskilllevel[1] = parseInt((me.GetSkill(53, false)+me.GetSkill(38, false)+me.GetSkill(48, false)+me.GetSkill(49, false))/4);
_avgskilllevel[2] = parseInt((me.GetSkill(47, false)+me.GetSkill(36, false)+me.GetSkill(56, false)+me.GetSkill(64, false))/4);
_avgskilllevel[3] = parseInt((me.GetSkill(47, false)+me.GetSkill(36, false)+me.GetSkill(56, false))/3);

_maxindex = -1;
_maxskill = 0;

for(var i = 0 ; i < _avgskilllevel.length ; i++)
{
if(_avgskilllevel[i] > _maxskill)
{
_maxindex = i;
_maxskill = _avgskilllevel[i];
}
}

switch(_maxindex)
{
case 0: // Blizzard + Glacial Spike
NTConfig_AttackSkill[1] = 59;
NTConfig_AttackSkill[2] = 55;
NTConfig_AttackSkill[3] = 59;
NTConfig_AttackSkill[4] = 55;
break;
case 1: // Chain Lightning + Lightning
NTConfig_AttackSkill[1] = 49;
NTConfig_AttackSkill[3] = 53;
break;
case 2: // Fire Ball + Frozen Orb
NTConfig_AttackSkill[0] = 64;
NTConfig_AttackSkill[1] = 47;
NTConfig_AttackSkill[3] = 47;
NTConfig_AttackSkill[5] = 64;
NTConfig_AttackSkill[6] = 55;
break;
case 3: // Fire Ball + Meteor
NTConfig_AttackSkill[1] = 56;
NTConfig_AttackSkill[2] = 47;
NTConfig_AttackSkill[3] = 56;
NTConfig_AttackSkill[4] = 47;
break;
}

return (NTConfig_AttackSkill[1] && NTConfig_AttackSkill[3]);
}

function NTA_SorceressAttackInt(target, firstorder)
{
var _primaryindex;

if(NTTMGR_CheckCurse(NTConfig_CheckSelfSafe&0x10, NTConfig_CheckMercSafe&0x10))
{
if(!NTTMGR_VisitTown())
return 0;
}

if(firstorder && NTConfig_AttackSkill[0] > 0 && NTA_GetResistance(target, _NTA_SkillDamage[0]) < 100 && me.GetSkillStatus(NTConfig_AttackSkill[0]) != 8)
{
if(GetDistance(me, target) > _NTA_SkillRange[0] || !CheckCollision(me, target, 4))
{
var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _NTA_SkillRange[0], 4);

if(_pos)
NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
}

if(!NTC_CastSkill(NTConfig_AttackSkill[0], _NTA_SkillHand[0], target))
return 2;

return 3;
}

if(NTConfig_CastStatic < 100 && parseInt(target.hp*100/target.hpmax) > NTConfig_CastStatic && NTA_GetResistance(target, NTA_DAMAGE_LIGHTNING) <= 80)
{
var _staticlevel = NTC_GetSkillLevel(42);

if(_staticlevel > 0)
{
var _staticrange;
var _castx, _casty;

_staticrange = Math.floor((5+_staticlevel-1)*2/3);

if(GetDistance(me, target) > _staticrange || !CheckCollision(me, target, 6))
{
var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _staticrange, 6);

if(_pos)
NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
}

if(target.x < me.x)
_castx = me.x - 1;
else if(target.x > me.x)
_castx = me.x + 1;
else
_castx = me.x;

if(target.y < me.y)
_casty = me.y - 1;
else if(target.y > me.y)
_casty = me.y + 1;
else
_casty = me.y;

if(!CheckCollision(target.areaid, _castx, _casty, 1))
{
_castx = me.x;
_casty = me.y;
}

if(!NTC_CastSkill(42, NTC_HAND_RIGHT, _castx, _casty))
return 2;

return 3;
}
}

_primaryindex = (target.spectype&0x0A) ? 1 : 3;

if(NTA_GetResistance(target, _NTA_SkillDamage[_primaryindex]) <= 90)
{
if(!NTA_SorceressCastSkillInt(_primaryindex, target))
return 2;

return 3;
}

if(NTConfig_AttackSkill[5] > 0 && NTA_GetResistance(target, _NTA_SkillDamage[5]) <= 80)
{
if(!NTA_SorceressCastSkillInt(5, target))
return 2;

return 3;
}

if(NTA_GetResistance(target, _NTA_SkillDamage[_primaryindex]) < 100 || (_primaryindex == 1 && NTC_GetMerc()))
{
if(!NTA_SorceressCastSkillInt(_primaryindex, target))
return 2;

return 3;
}

return 1;
}

function NTA_SorceressCastSkillInt(index, target)
{
if(me.GetSkillStatus(NTConfig_AttackSkill[index]) != 8)
{
if(GetDistance(me, target) > _NTA_SkillRange[index] || !CheckCollision(me, target, 4))
{
var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _NTA_SkillRange[index], 4);

if(_pos)
NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
}

return NTC_CastSkill(NTConfig_AttackSkill[index], _NTA_SkillHand[index], target);
}

if(NTConfig_AttackSkill[index+1] > 0)
{
if(GetDistance(me, target) > _NTA_SkillRange[index+1] || !CheckCollision(me, target, 4))
{
var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _NTA_SkillRange[index+1], 4);

if(_pos)
NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
}

return NTC_CastSkill(NTConfig_AttackSkill[index+1], _NTA_SkillHand[index+1], target);
}

for(var i = 0 ; i < 25 ; i++)
{
NTC_Delay(NTC_DELAY_FRAME);

if(me.GetSkillStatus(NTConfig_AttackSkill[index]) != 8)
break;
}

return false;
}

function NTA_NecromancerAttackPatternInt()
{
return false;
}

function NTA_NecromancerAttackInt(target, firstorder)
{
return 1;
}

function NTA_NecromancerCastSkillInt(index, target)
{
return false;
}

function NTA_PaladinAttackPatternInt()
{
var _maxindex, _maxskill;
var _avgskilllevel = new Array();

_avgskilllevel[0] = parseInt((me.GetSkill(112, false)+me.GetSkill(108, false)+me.GetSkill(115, false))/3);
_avgskilllevel[1] = parseInt((me.GetSkill(106, false)+me.GetSkill(96, false))/2);
_avgskilllevel[2] = parseInt((me.GetSkill(121, false)+me.GetSkill(101, false)+me.GetSkill(118, false))/3);

_maxindex = -1;
_maxskill = 0;

for(var i = 0 ; i < _avgskilllevel.length ; i++)
{
if(_avgskilllevel[i] > _maxskill)
{
_maxindex = i;
_maxskill = _avgskilllevel[i];
}
}

switch(_maxindex)
{
case 0: // Blessed Hammer
NTConfig_AttackSkill[1] = 112;
NTConfig_AttackSkill[2] = 113;
NTConfig_AttackSkill[3] = 112;
NTConfig_AttackSkill[4] = 113;
break;
case 1: // Zeal
NTConfig_AttackSkill[1] = 106;
NTConfig_AttackSkill[2] = 122;
NTConfig_AttackSkill[3] = 106;
NTConfig_AttackSkill[4] = 122;
break;
case 2: // Fist of the Heavens
NTConfig_AttackSkill[1] = 121;
NTConfig_AttackSkill[2] = 123;
NTConfig_AttackSkill[3] = 121;
NTConfig_AttackSkill[4] = 123;
break;
}

return (NTConfig_AttackSkill[1] && NTConfig_AttackSkill[3]);
}

function NTA_PaladinAttackInt(target, firstorder)
{
var _primaryindex;

if(NTTMGR_CheckCurse(NTConfig_CheckSelfSafe&0x10, NTConfig_CheckMercSafe&0x10))
{
if(!NTTMGR_VisitTown())
return 0;
}

if(firstorder && NTConfig_AttackSkill[0] > 0 && NTA_GetResistance(target, _NTA_SkillDamage[0]) < 100)
{
if(GetDistance(me, target) > _NTA_SkillRange[0] || !CheckCollision(me, target, 4))
{
var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _NTA_SkillRange[0], 4);

if(_pos)
NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
}

if(!NTC_CastSkill(NTConfig_AttackSkill[0], _NTA_SkillHand[0], target))
return 2;

return 3;
}

_primaryindex = (target.spectype&0x0A) ? 1 : 3;

if(NTA_GetResistance(target, _NTA_SkillDamage[_primaryindex]) < 100)
{
if(_NTA_SkillRange[_primaryindex] < 4 && !CheckCollision(target.areaid, target.x, target.y, 1))
return 1;

if(!NTA_PaladinCastSkillInt(_primaryindex, target))
return 2;

return 3;
}

if(NTConfig_AttackSkill[5] > 0 && NTA_GetResistance(target, _NTA_SkillDamage[5]) < 100)
{
if(_NTA_SkillRange[5] < 4 && !CheckCollision(target.areaid, target.x, target.y, 1))
return 1;

if(!NTA_PaladinCastSkillInt(5, target))
return 2;

return 3;
}

return 1;
}

function NTA_PaladinCastSkillInt(index, target)
{
if(NTConfig_AttackSkill[index] == 112)
{
if(me.x-target.x < 1 || me.x-target.x > 2 || me.y-target.y < 1 || me.y-target.y > 2)
{
if(CheckCollision(target.areaid, target.x+2, target.y+2, 1))
NTM_MoveTo(target.areaid, target.x+2, target.y+2, 0);
else if(me.x-target.x < -4 || me.x-target.x > 2 || me.y-target.y < 0 || me.y-target.y > 2)
NTM_MoveTo(target.areaid, target.x-4, target.y, 0);
}
}
else
{
if(GetDistance(me, target) > _NTA_SkillRange[index] || !CheckCollision(me, target, 4))
{
var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _NTA_SkillRange[index], 4);

if(_pos)
NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
}
}

if(NTConfig_AttackSkill[index+1] > 0)
NTC_PutSkill(NTConfig_AttackSkill[index+1], NTC_HAND_RIGHT);

return NTC_CastSkill(NTConfig_AttackSkill[index], _NTA_SkillHand[index], target);
}

function NTA_BarbarianAttackPatternInt()
{
var _maxindex, _maxskill;
var _avgskilllevel = new Array();

_avgskilllevel[0] = me.GetSkill(151, false);

_maxindex = -1;
_maxskill = 0;

for(var i = 0 ; i < _avgskilllevel.length ; i++)
{
if(_avgskilllevel[i] > _maxskill)
{
_maxindex = i;
_maxskill = _avgskilllevel[i];
}
}

switch(_maxindex)
{
case 0: // Whirlwind
NTConfig_AttackSkill[1] = 151;
NTConfig_AttackSkill[3] = 151;
NTConfig_AttackSkill[5] = 152;
break;
}

return (NTConfig_AttackSkill[1] && NTConfig_AttackSkill[3]);
}

function NTA_BarbarianAttackInt(target, firstorder)
{
var _primaryindex;

if(NTTMGR_CheckCurse(NTConfig_CheckSelfSafe&0x10, NTConfig_CheckMercSafe&0x10))
{
if(!NTTMGR_VisitTown())
return 0;
}

if(firstorder && NTConfig_AttackSkill[0] > 0 && NTA_GetResistance(target, _NTA_SkillDamage[0]) < 100)
{
if(GetDistance(me, target) > _NTA_SkillRange[0] || !CheckCollision(me, target, 4))
{
var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _NTA_SkillRange[0], 4);

if(_pos)
NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
}

if(!NTC_CastSkill(NTConfig_AttackSkill[0], _NTA_SkillHand[0], target))
return 2;

return 3;
}

_primaryindex = (target.spectype&0x0A) ? 1 : 3;

if(NTA_GetResistance(target, _NTA_SkillDamage[_primaryindex]) < 100)
{
if((_NTA_SkillRange[_primaryindex] < 4 || NTConfig_AttackSkill[_primaryindex] == 151) && !CheckCollision(target.areaid, target.x, target.y, 1))
return 1;

if(!NTA_BarbarianCastSkillInt(_primaryindex, target))
return 2;

return 3;
}

if(NTConfig_AttackSkill[5] > 0 && NTA_GetResistance(target, _NTA_SkillDamage[5]) < 100)
{
if((_NTA_SkillRange[5] < 4 || NTConfig_AttackSkill[5] == 151) && !CheckCollision(target.areaid, target.x, target.y, 1))
return 1;

if(!NTA_BarbarianCastSkillInt(5, target))
return 2;

return 3;
}

return 1;
}

function NTA_BarbarianCastSkillInt(index, target)
{
if(NTConfig_AttackSkill[index] == 151)
{
var _castx, _casty;

if(GetDistance(me, target) > _NTA_SkillRange[index] || !CheckCollision(me, target, 5))
{
var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _NTA_SkillRange[index], 5);

if(_pos)
NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
}

_castx =  target.x > me.x ? target.x+3 : target.x-3;
_casty =  target.y > me.y ? target.y+3 : target.y-3;

return NTC_CastSkill(NTConfig_AttackSkill[index], _NTA_SkillHand[index], _castx, _casty);
}

if(GetDistance(me, target) > _NTA_SkillRange[index] || !CheckCollision(me, target, 4))
{
var _pos = me.GetOptimalAttackPos(target.areaid, target.x, target.y, _NTA_SkillRange[index], 4);

if(_pos)
NTM_MoveTo(target.areaid, _pos[0], _pos[1], 0);
}

return NTC_CastSkill(NTConfig_AttackSkill[index], _NTA_SkillHand[index], target);
}

function NTA_DruidAttackPatternInt()
{
return false;
}

function NTA_DruidAttackInt(target, firstorder)
{
return 1;
}

function NTA_DruidCastSkillInt(index, target)
{
return false;
}

function NTA_AssassinAttackPatternInt()
{
return false;
}

function NTA_AssassinAttackInt(target, firstorder)
{
return 1;
}

function NTA_AssassinCastSkillInt(index, target)
{
return false;
}
If your not planning on doing a Bowazon please skip to
Step[4]
« Last Edit: October 06, 2011, 12:26:25 PM by cooptheking03 »

PureKaoz.com - D2NT, Diablo 3 & Starcaft 2 Hacks

[D2NT] Javazon/Bowazon Character Setup
« on: September 03, 2010, 11:55:33 AM »

cooptheking

  • Guest
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #1 on: September 04, 2010, 01:22:41 AM »
Step[2]: Open NTTown, and replace your file with this file
Code: [Select]
var _NTT_BeltColNeeded = new Array(4);
_NTT_BeltColNeeded[0] = 0;
_NTT_BeltColNeeded[1] = 0;
_NTT_BeltColNeeded[2] = 0;
_NTT_BeltColNeeded[3] = 0;

var _NTT_BeltSize = 0;

var _NTT_OldItems;

var _NTT_IgnoredItems = new Array(
"aqv", // Arrows quiver
"cqv", // Bolts quiver
"key", // Keys
"tbk", // Tome of Town Portal
"ibk", // Tome of Identify
"tsc", // Scroll of Town Portal
"isc", // Scroll of Identify
"yps", // Antidote potion
"vps", // Stamina potion
"wms", // Thawing potion
"gps", // Rancid Gas Pot
"ops", // Oil Potion
"gpm", // Choking Gas Pot
"opm", // Exploding Pot
"gpl", // Strangling Gas
"opl", // Fulminating Pot
"hp1","hp2","hp3","hp4","hp5", // Healing potions
"mp1","mp2","mp3","mp4","mp5", // Mana potions
"rvs","rvl"); // Rejuvenation potions

// type : 1 = shop, 2 = ressurect, 3 = repair, 4 = potion, 5 = scrolls, 6 = gamble, 7 = ammo, 8 = healing
function NTT_CheckNPC(npc, type)
{
var _npcclassid;

if(typeof(npc) == "number")
_npcclassid = npc;
else
_npcclassid = npc.classid;

if(type == 1)
{
if(_npcclassid == 147 || _npcclassid == 148 || _npcclassid == 154 || _npcclassid == 177 ||
_npcclassid == 178 || _npcclassid == 199 || _npcclassid == 202 || _npcclassid == 252 ||
_npcclassid == 253 || _npcclassid == 254 || _npcclassid == 255 || _npcclassid == 257 ||
_npcclassid == 405 || _npcclassid == 511 || _npcclassid == 512 || _npcclassid == 513)
return true;
else
return false;
}

if(type == 2)
{
if(_npcclassid == 150 || _npcclassid == 198 || _npcclassid == 252 || _npcclassid == 367 || _npcclassid == 515)
return true;
else
return false;
}

if(type == 3)
{
if(_npcclassid == 154 || _npcclassid == 178 || _npcclassid == 253 || _npcclassid == 257 || _npcclassid == 511)
return true;
else
return false;
}

if(type == 4)
{
if(_npcclassid == 148 || _npcclassid == 177 || _npcclassid == 198 || _npcclassid == 202 ||
_npcclassid == 255 || _npcclassid == 405 || _npcclassid == 513)
return true;
else
return false;
}

if(type == 5)
{
if(_npcclassid == 148 || _npcclassid == 177 || _npcclassid == 255 || _npcclassid == 405 || _npcclassid == 513)
return true;
else
return false;
}

if(type == 6)
{
if(_npcclassid == 147 || _npcclassid == 199 || _npcclassid == 254 ||
_npcclassid == 405 || _npcclassid == 512 || _npcclassid == 514)
return true;
else
return false;
}

if(type == 7)
{
if(_npcclassid == 147 || _npcclassid == 154 || _npcclassid == 178 || _npcclassid == 199 || _npcclassid == 252 ||
_npcclassid == 253 || _npcclassid == 257 || _npcclassid == 511 || _npcclassid == 512)
return true;
else
return false;
}

if(type == 8)
{
if(_npcclassid == 148 || _npcclassid == 178 || _npcclassid == 255 || _npcclassid == 513)
return true;
else
return false;
}

return false;
}

// npc : NPC, stash or cube
function NTT_DoInteract(npc)
{
var _uiflag = 0x08;

if(!npc)
return false;

if(npc.classid == NTC_UNIT_STASH)
_uiflag = 0x19;
else if(npc.classid == NTC_UNIT_CUBE)
_uiflag = 0x1A;

if(GetUIState(_uiflag))
return true;

for(var i = 0 ; i < 40 ; i++)
{
if((i % 10) == 0)
{
if(npc.classid == NTC_UNIT_CUBE)
me.ClickItem(1, npc);
else
{
if(i > 10)
me.Cancel(0);

NTC_DoClick(NTC_CLICK_LDOWN, NTC_SHIFT_NONE, npc);
}
}

NTC_Delay(200);

if(GetUIState(_uiflag))
{
NTC_PingDelay(500);
return true;
}
}

return false;
}

// type : 0 = shop, 1 = gamble
function NTT_DoTrade(npc, type)
{
if(!npc)
return false;

if(GetUIState(0x0C))
return true;

if(arguments.length < 2)
type = 0;

for(var i = 0 ; i < 20 ; i++)
{
if((i % 10) == 0)
{
if(NTT_CheckNPC(npc.classid, 3))
me.SelectNPCMenu(0x0D06);
else if(type == 1 && NTT_CheckNPC(npc.classid, 6))
me.SelectNPCMenu(0x0D46);
else
me.SelectNPCMenu(0x0D44);
}

NTC_Delay(200);

if(GetUIState(0x0C))
{
NTC_PingDelay(1000);

return true;
}
}

return false;
}

function NTT_GetCorpses()
{
var _corpse;

for(var i = 0 ; i < 4 ; i++)
{
_corpse = NTC_FindUnit(NTC_UNIT_PLAYER);

if(_corpse)
{
do
{
if(_corpse.name == me.name && _corpse.hpmax == 0)
{
NTC_SwapWeapons(0);

NTC_DoClick(NTC_CLICK_LDOWN, NTC_SHIFT_NONE, _corpse);

NTC_PingDelay(1000);

break;
}
} while(_corpse.GetNext());
}
}
}

function NTT_CheckMerc()
{
if(NTConfig_UseMerc)
{
if(NTC_GetMerc())
return false;
else
{
if(NTC_MyGold() < me.GetMercCost())
return false;

return true;
}
}

return false;
}

function NTT_ReviveMerc()
{
var _mygold;

if(!NTT_CheckMerc())
return true;

if(!GetUIState(0x08))
return false;

_mygold = NTC_MyGold();

if(_mygold < me.GetMercCost())
return false;

for(var i = 0 ; i < 8 ; i++)
{
if((i % 4) == 0)
me.SelectNPCMenu(0x1507);

NTC_Delay(500);

if(_mygold > NTC_MyGold())
return true;
}

return false;
}

function NTT_ResetWeaponMerc()
{
var i, n;
var _merc, _items;

_merc = NTC_GetMerc();

if(!_merc)
return false;

_items = _merc.GetItems();

if(!_items)
return false;

for(i = 0 ; i < _items.length ; i++)
{
if(_items[i].itemloc == 4 && (_items[i].itemflag&0x4000000))
{
SetUIState(0x24, true);

for(n = 0 ; n < 80 ; n++)
{
if((n % 40) == 0)
me.ClickMercItem(4);

NTC_Delay(100);

if(me.itemoncursor)
{
NTC_PingDelay(200);
break;
}
}

if(n >= 80)
{
me.Cancel(1);
break;
}

for(n = 0 ; n < 120 ; n++)
{
if((n % 40) == 0)
me.ClickMercItem(4);

NTC_Delay(100);

if(!me.itemoncursor)
break;
}

me.Cancel(1);

if(n < 120)
return true;

break;
}
}

return false;
}

function NTT_CheckRepair(repairpercent)
{
var _max_dur;
var _percent;
var _items = me.GetItems();

if(!_items)
return false;

for(var i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 1 && !(_items[i].itemflag&0x400000) && !_items[i].GetStat(152))
{
if(_items[i].itemtype == 42 || _items[i].itemtype == 43 || _items[i].itemtype == 44 || _items[i].itemtype == 87)
_percent = Math.floor((_items[i].GetStat(70)*100) / (GetBaseStat("weapons.txt", _items[i].classid, 45)+_items[i].GetStat(254)));
else
{
_max_dur = _items[i].GetStat(73);
if(_max_dur == 0)
continue;

_percent = Math.floor((_items[i].GetStat(72)*100) / (_max_dur*(_items[i].GetStat(75)/100 + 1)));
}

if(_percent <= repairpercent)
return true;
}
}

return false;
}

function NTT_RepairItems(npc)
{
var _mygold;

if(!npc)
return false;

if(!GetUIState(0x0C))
return false;

_mygold = NTC_MyGold();

for(var i = 0 ; i < 8 ; i++)
{
if((i % 4) == 0)
me.Repair();

NTC_Delay(500);

if(_mygold > NTC_MyGold())
return true;
}

return false;
}

function NTT_CheckInventory()
{
var x, y;
var _items;

_itemlist = new Array();
_ignorestring = _NTT_IgnoredItems.join();

if(!NTC_StashGoldFull() && NTC_MyGoldCarry() > NTConfig_MinGoldToStash)
return true;

_invspace = new Array(4);
_invspace[0] = new Array(10);
_invspace[1] = new Array(10);
_invspace[2] = new Array(10);
_invspace[3] = new Array(10);

for(y = 0 ; y < 4 ; y++)
{
for(x = 0 ; x < 10 ; x++)
_invspace[y][x] = 0;
}

_items = me.GetItems();

if(!_items)
return false;

for(var i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0)
{
if(NTConfig_Columns[_items[i].y][_items[i].x] > 0)
_itemlist.push(_items[i].code);

for(y = 0 ; y < _items[i].ysize ; y++)
{
for(x = 0 ; x < _items[i].xsize ; x++)
_invspace[y+_items[i].y][x+_items[i].x] = 1;
}
}
}

_freecols = new Array(10);

for(x = 0 ; x < 10 ; x++)
_freecols[x] = 0;

for(x = 0 ; x < 10 ; x++)
{
for(y = 0 ; y < 4 ; y++)
{
if(_invspace[y][x] == 1)
{
_freecols[x] = 1;
break;
}
}
}

_numfreecols = 0;

for(x = 0 ; x < 10 ; x++)
{
if(_freecols[x] == 0)
_numfreecols++;
}

if(NTConfig_FreeSpace > _numfreecols)
{
for(x = 0 ; x < _itemlist.length ; x++)
{
if(_ignorestring.indexOf(_itemlist[x]) != -1)
_itemlist.splice(x, 1);
}

if(_itemlist.length > 0)
return true;
}

return false;
}

function NTT_CheckStash()
{
var x, y;
var _items;
var _StashHeight = (me.gametype == 0) ? 4 : 8;
var _stashspace = new Array(_StashHeight);

for(y = 0 ; y < _StashHeight ; y++)
_stashspace[y] = new Array(6);

for(y = 0 ; y < _StashHeight ; y++)
{
for(x = 0 ; x < 6 ; x++)
_stashspace[y][x] = 0;
}

_items = me.GetItems();

if(!_items)
return false;

for(var i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 4)
{
for(y = 0 ; y < _items[i].ysize ; y++)
{
for(x = 0 ; x < _items[i].xsize ; x++)
_stashspace[y+_items[i].y][x+_items[i].x] = 1;
}
}
}

for(y = 0 ; y < _StashHeight ; y++)
{
for(x = 0 ; x < 6 ; x++)
{
if(_stashspace[y][x] != 1)
return true;
}
}

return false;
}

function NTT_ManageStash(invitem)
{
var i, x, y;
var _items;
var _stashall;
var StashHeight = (me.gametype == 0) ? 4 : 8;
var _ignorestring = _NTT_IgnoredItems.join();
var _ignoreitem;

if(!GetUIState(0x19))
return false;

if(arguments.length < 1)
_stashall = true;
else
_stashall = false;

if(!NTC_StashGoldFull() && NTC_MyGoldCarry() > NTConfig_MinGoldToStash)
{
var _mygold = NTC_MyGoldCarry();

Gold(3, _mygold);

for(i = 0 ; i < 2 ; i++)
{
NTC_Delay(500);

if(_mygold > NTC_MyGoldCarry())
break;
}
}

var _stashspace = new Array(StashHeight);

for(y = 0 ; y < StashHeight ; y++)
_stashspace[y] = new Array(6);

for(y = 0 ; y < StashHeight ; y++)
{
for(x = 0 ; x < 6 ; x++)
_stashspace[y][x] = 0;
}

_items = me.GetItems();

if(!_items)
return false;

for(i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 4)
{
for(y = 0 ; y < _items[i].ysize ; y++)
{
for(x = 0 ; x < _items[i].xsize ; x++)
_stashspace[y+_items[i].y][x+_items[i].x] = 1;
}
}
}

for(i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0 && (_stashall || (_items[i].x == invitem.x && _items[i].y == invitem.y)))
{
if(_stashall)
{
_ignoreitem = (NTConfig_Columns[_items[i].y][_items[i].x] == 0);

if(!_ignoreitem)
{
if( _ignorestring.indexOf(_items[i].code) != -1 || NTSI_CheckItem(_items[i]) <= 0 )
_ignoreitem = true;
}
}
else
_ignoreitem = false;

if(!_ignoreitem)
{
_itemdone = false;

for(y = 0 ; y < StashHeight ; y++)
{
if(_itemdone)
break;

for(x = 0 ; x < 6 ; x++)
{
if(_itemdone)
break;

if(_stashspace[y][x] == 0)
{
if((x+_items[i].xsize-1) < 6 && (y+_items[i].ysize-1) < StashHeight)
{
var _havespace = true;

for(m = 0 ; m < _items[i].ysize ; m++)
{
for(n = 0 ; n < _items[i].xsize ; n++)
{
if(_stashspace[y+m][x+n] == 1)
{
_havespace = false;
m = 4;
break;
}
}
}

if(_havespace)
{
if(NTC_ItemToCursor(_items[i]))
{
for(n = 0 ; n < 80 ; n++)
{
if((n % 40) == 0)
me.ClickItem(0, x, y, 4);

NTC_Delay(100);

if(!me.itemoncursor)
break;
}

if(n < 80)
{
for(m = 0 ; m < _items[i].ysize ; m++)
{
for(n = 0 ; n < _items[i].xsize ; n++)
_stashspace[y+m][x+n] = 1;
}
}

NTC_PingDelay(200);
}

_itemdone = true;
}
}
}
}
}
}

if(!_stashall)
return true;
}
}

return true;
}

// type : id = 0, tp = 1
function NTT_GetScroll(type)
{
var _items;

if(arguments.length < 1)
type = 0;

if(type)
_items = me.GetItems(529);
else
_items = me.GetItems(530);

if(_items)
{
for(var i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0)
return _items[i];
}
}

return null;
}

// type : id = 0, tp = 1
function NTT_GetTome(type)
{
var _items;

if(arguments.length < 1)
type = 0;

if(type)
_items = me.GetItems(518);
else
_items = me.GetItems(519);

if(_items)
{
for(var i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0)
return _items[i];
}
}

return null;
}

// type : id = 0, tp = 1
function NTT_FillTome(npc, type)
{
var _tome;

if(arguments.length < 1)
return false;

if(arguments.length < 2)
type = 0;

_tome = NTT_GetTome(type);

if(_tome)
{
var _items;

if(_tome.GetStat(70) >= 20)
return true;

if(type)
_items = npc.GetItems(529);
else
_items = npc.GetItems(530);

if(_items && _items.length > 0)
return NTT_ShopItem(_items[0], npc, 3);
}

return false;
}

// type : id = 0, tp = 1
function NTT_BuyScrolls(npc, type, amount)
{
var _items;
var _counter = 0;

if(arguments.length < 1)
return false;

if(arguments.length < 2)
type = 0;

if(arguments.length < 3)
amount = 1;

if(amount == 0)
return false;

if(type)
_items = npc.GetItems(529);
else
_items = npc.GetItems(530);

if(_items && _items.length > 0)
{
for(var i = 0 ; i < amount ; i++)
{
if(NTT_ShopItem(_items[0], npc, 2))
_counter++;
}
}

return (_counter > 0);
}

function NTT_GetKey()
{
var _items;

_items = me.GetItems(543);

if(_items)
{
for(var i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0)
return _items[i];
}
}

return null;
}

function NTT_FillKey(npc)
{
var _key;
var _items;

if(arguments.length < 1)
return false;

_key = NTT_GetKey();

if(_key)
{
if(_key.GetStat(70) >= 12)
return true;

_items = npc.GetItems(543);

if(_items && _items.length > 0)
return NTT_ShopItem(_items[0], npc, 3);
}
else
{
_items = npc.GetItems(543);

if(_items && _items.length > 0)
{
NTT_ShopItem(_items[0], npc, 2);
return NTT_ShopItem(_items[0], npc, 3);
}
}

return false;
}

function NTT_CheckBelt()
{
var _needpotions = false;

for(var i = 0 ; i < 4 ; i++)
{
_NTT_BeltColNeeded[i] = NTT_GetNeededPotionsColInt(NTConfig_BeltColType[i], i);

if(_NTT_BeltColNeeded[i] > 0 && NTConfig_BeltColType[i] != "rv")
_needpotions = true;
}

return _needpotions;
}

function NTT_FillBelt(npc)
{
if(!npc)
return false;

if(!GetUIState(0x0C))
return false;

if(_NTT_BeltSize < 1)
_NTT_BeltSize = NTC_GetBeltSize();

if(_NTT_BeltColNeeded[3] == _NTT_BeltSize || _NTT_BeltColNeeded[2] == _NTT_BeltSize || _NTT_BeltColNeeded[1] == _NTT_BeltSize || _NTT_BeltColNeeded[0] == _NTT_BeltSize)
NTT_BuyPotionsSlowInt(npc);
else
NTT_BuyPotionsFastInt(npc);

return true;
}

function NTT_CheckHeal()
{
var _merc;

if(parseInt(me.hp*100/me.hpmax) < NTConfig_SkipHealLife || parseInt(me.mp*100/me.mpmax) < NTConfig_SkipHealMana)
return true;

_merc = NTC_GetMerc();

if(_merc)
{
if(parseInt(_merc.hp*100/_merc.hpmax) < NTConfig_SkipHealLife)
return true;
}

return false;
}

function NTT_CheckSpace(itemX, itemY)
{
var i, j, x, y;
var _items;

_invspace = new Array(4);
_invspace[0] = new Array(10);
_invspace[1] = new Array(10);
_invspace[2] = new Array(10);
_invspace[3] = new Array(10);

for(y = 0 ; y < 4 ; y++)
{
for(x = 0 ; x < 10 ; x++)
_invspace[y][x] = 0;
}

_items = me.GetItems();

if(!_items)
return false;

for(i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0)
{
for(y = 0 ; y < _items[i].ysize ; y++)
{
for(x = 0 ; x < _items[i].xsize ; x++)
_invspace[y+_items[i].y][x+_items[i].x] = 1;
}
}
}

for(i = 0 ; i < 5-itemY ; i++)
{
invloop2:

for(j = 0 ; j < 11-itemX ; j++)
{
for(y = 0 ; y < itemY ; y++)
{
for(x = 0 ; x < itemX ; x++)
{
if(_invspace[i+y][j+x])
continue invloop2;
}
}

return true;
}
}

return false;
}

function NTT_CleanPotions()
{
var _items = me.GetItems();

if(!_items)
return;

for(var i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0 && (_items[i].itemtype == 76 || _items[i].itemtype == 77 || _items[i].itemtype == 78))
{
if(NTConfig_Columns[_items[i].y][_items[i].x] > 0)
{
SetUIState(0x01, true);

me.ClickItem(1, _items[i]);

NTC_PingDelay(500);
}
}
}

me.Cancel(1);
}

function NTT_ClearInventory()
{
var _retval = true;
var _ignorestring = _NTT_IgnoredItems.join();
var _items;

_items = me.GetItems();

if(!_items)
return false;

for(var i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0)
{
if(NTConfig_Columns[_items[i].y][_items[i].x] > 0)
{
if(_ignorestring.indexOf(_items[i].code) != -1 || NTSI_CheckItem(_items[i]) != 0)
continue;

SetUIState(0x01, true);

if(NTT_DropItem(_items[i]))
NTC_PingDelay(200);
else
_retval = false;
}
}
}

me.Cancel(1);

return _retval;
}

function NTT_DropItem(item)
{
if(!item)
return false;

if(NTC_ItemToCursor(item))
return NTC_ClearCursor();

return false;
}

function NTT_ClearBelt()
{
var i;
var _result, _needdrop;
var _items;

do
{
_items = me.GetItems();

if(!_items)
{
_result = false;
break;
}

_result = true;

for(i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 2 && _items[i].x < 4)
{
_needdrop = false;

switch(_items[i].itemtype)
{
case 76:
if(NTConfig_BeltColType[_items[i].x] != "hp")
_needdrop = true;
break;
case 77:
if(NTConfig_BeltColType[_items[i].x] != "mp")
_needdrop = true;
break;
case 78:
if(NTConfig_BeltColType[_items[i].x] != "rv")
_needdrop = true;
break;
default:
_needdrop = true;
break;
}

if(_needdrop)
{
SetUIState(0x1F, true);

if(NTT_DropItem(_items[i]))
NTC_PingDelay(200);

_result = false;
}
}
}
} while(!_result);

me.Cancel(1);

return _result;
}

// mode : 1 = sell, 2 = buy, 3 = shift buy
function NTT_ShopItem(item, npc, mode)
{
var _mygold = NTC_MyGold();

if(mode > 1)
{
if(item.GetItemCost(0, npc.classid) > _mygold)
return false;
}

if(mode > 1)
{
var _havespace = false;

if(item.classid == 529 || item.classid == 530)
{
var _book = (item.classid == 530) ? NTT_GetTome(0) : NTT_GetTome(1);

if(_book && _book.GetStat(70) < 20)
_havespace = true;
}

   if(!_havespace)
   {   
      if(item.classid == 526 || item.classid == 528)
         _havespace = true;
      else if(NTT_CheckSpace(item.xsize, item.ysize))
         _havespace = true;
   }

if(_havespace)
{
for(var i = 0 ; i < 40 ; i++)
{
if((i % 20) == 0)
me.ClickItem(mode > 2 ? 3 : 1, item);

NTC_Delay(100);

if(_mygold > NTC_MyGold())
{
NTC_PingDelay(500);
return true;
}
}
}
}
else
{
if(NTC_ItemToCursor(item))
{
for(var i = 0 ; i < 40 ; i++)
{
if((i % 20) == 0)
me.ClickItem(0, 8, 6, 1);

NTC_Delay(100);

if(!me.itemoncursor)
{
NTC_PingDelay(800);
return true;
}
}
}
        }

return false;
}

function NTT_IdItem(scroll, uniditem)
{
var i, _timer;

if(arguments.length < 1 || !scroll)
return false;

if(arguments.length < 2 || !uniditem)
return false;

if(uniditem.itemflag&0x10)
return true;

for(i = 0 ; i < 40 ; i++)
{
if((i % 20) == 0)
me.ClickItem(1, scroll);

NTC_Delay(100);

if(GetCursorType() == 6)
break;
}

if(i >= 40)
return false;

NTC_PingDelay(200);

for(i = 0 ; i < 40 ; i++)
{
if((i % 20) == 0)
me.ClickItem(0, uniditem);

NTC_Delay(100);

if(uniditem.itemflag&0x10)
{
NTC_PingDelay(200);
return true;
}
}

return false;
}

function NTT_CheckUnids()
{
var _unidcount = 0;
var _items = me.GetItems();

if(!_items)
return _unidcount;

for(var i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0 && !(_items[i].itemflag&0x10))
_unidcount++;
}

return _unidcount;
}

function NTT_GetUnidItems()
{
var _uniditems = new Array();
var _items = me.GetItems();

if(!_items)
return _uniditems;

for(var i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0 && !(_items[i].itemflag&0x10))
_uniditems.push(_items[i]);
}

return _uniditems;
}

function NTT_GambleIt(npc)
{
var _items, _newitem;

if(!npc)
return false;

if(!GetUIState(0x0C))
return false;

_items = npc.GetItems();

if(!_items)
return false;

for(var i = 0 ; i < _items.length ; i++)
{
if(NTC_MyGold() < NTConfig_GambleStopGold)
return false;

if(NTT_IsItemInGambleArrayInt(_items[i].classid))
{
if(NTT_CheckSpace(_items[i].xsize, _items[i].ysize))
{
NTT_GetOldItemsInt();

if(NTT_ShopItem(_items[i], npc, 2))
_newitem = NTT_GetGambledItemInt();
else
return false;

if(_newitem)
{
while(!(_newitem.itemflag&0x10))
NTC_Delay(100);

switch(NTSI_CheckItem(_newitem))
{
case 1:
NTC_SendLogToOOG(NTC_LOG_ITEM, "Kept " + NTC_ItemQualityToMGRColor[_newitem.quality] + _newitem.name.split("\n")[0] + ";" + _newitem.itemdesc);
case 2:
break;
default:
NTT_ShopItem(_newitem, npc, 1);
break;
}
}
}
}
}

return true;
}

// Internal function
function NTT_IsItemInGambleArrayInt(classid)
{
for(var i = 0 ; i < NTConfig_GambleItem.length ; i++)
{
if(classid == NTConfig_GambleItem[i])
return true;
}

return false;
}

function NTT_GetPotionAtNPCInt(type, npc)
{
var _items;

if(!type)
return null;

if(type == "hp" || type == "mp")
{
_items = npc.GetItems();

if(_items)
{
var n;

for(var i = 0 ; i < _items.length ; i++)
{
for(n = 5 ; n > 0 ; n--)
{
if(_items[i].code == (type+n))
return _items[i];
}
}
}
}
else
{
if(type == "rv")
return null;

_items = npc.GetItems(type);

if(_items && _items.length > 0)
return _items[0];
}

return null;
}

function NTT_BuyPotionsFastInt(npc)
{
var i, n;
var _insert, _potion;
var _typearray = new Array();

for(i = 0 ; i < 4 ; i++)
{
if(_NTT_BeltColNeeded[i] > 0)
{
if(_typearray.length == 0)
_typearray.push(NTConfig_BeltColType[i]);
else
{
_insert = true;

for(n = 0 ; n < _typearray.length ; n++)
{
if(_typearray[n] == NTConfig_BeltColType[i])
_insert = false;
}

if(_insert)
_typearray.push(NTConfig_BeltColType[i]);
}
}
}

for(i = 0 ; i < _typearray.length ; i++)
{
if(_typearray[i] == "rv")
continue;

_potion = NTT_GetPotionAtNPCInt(_typearray[i], npc);

if(_potion)
{
if(NTT_ShopItem(_potion, npc, 3))
continue;
else
return false;
}
else
return false;
}

return true;
}

function NTT_BuyPotionsColInt(npc, col)
{
var _numpotions;
var _potion;

if(col < 0 || col > 3)
return false;

if(NTConfig_BeltColType[col] == "rv")
return false;

_numpotions = _NTT_BeltColNeeded[col];

if(_numpotions == 0)
return false;

if(_numpotions > _NTT_BeltSize)
_numpotions = _NTT_BeltSize;

for(var _buyloop = 0 ; _buyloop < _numpotions ; _buyloop++)
{
_potion = NTT_GetPotionAtNPCInt(NTConfig_BeltColType[col], npc);

if(_potion)
NTT_ShopItem(_potion, npc, 2);
else
return false;
}

return true;
}

function NTT_BuyPotionsSlowInt(npc)
{
var _currentcol;

for(_currentcol = 0 ; _currentcol < 4 ; _currentcol++)
{
if(_NTT_BeltColNeeded[_currentcol] == _NTT_BeltSize)
{
NTT_BuyPotionsColInt(npc, _currentcol);
_NTT_BeltColNeeded[_currentcol] = 0;
}
}

for(_currentcol = 0 ; _currentcol < 4 ; _currentcol++)
NTT_BuyPotionsColInt(npc, _currentcol);

return true;
}

function NTT_GetNeededPotionsColInt(type, column)
{
var _restartloop = true;
var _amountneeded = 0;
var _items;

if(!type || column > 3)
return false;

if(_NTT_BeltSize < 1)
_NTT_BeltSize = NTC_GetBeltSize();

potionloop:
do
{
_amountneeded = _NTT_BeltSize;

_items = me.GetItems();

if(!_items)
continue potionloop;

for(i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 2)
{
if(NTT_PotInRightColInt(_items[i].x, column, _NTT_BeltSize))
{
var _potcode = _items[i].code;

if(_potcode.indexOf(type) != -1)
_amountneeded--;
else
{
if(_potcode.indexOf("rv") != -1)
{
if(_items[i].x < 4)
{
me.Cancel(1);
return 0;
}
else
_amountneeded--;
}
else
{
SetUIState(0x1F, true);

me.ClickItem(1, _items[i]);

NTC_PingDelay(500);
continue potionloop;
}
}
}
}
}

_restartloop = false;
} while(_restartloop);

me.Cancel(1);

return _amountneeded;
}

function NTT_PotInRightColInt(potx, column, beltsize)
{
for(var i = 0 ; i < beltsize ; i++)
{
if(potx-i*4 == column)
return true;
}

return false;
}

function NTT_GetGambledItemInt()
{
var i, n;
var _items;
var _founditem;

_items = me.GetItems();

if(!_items)
return null;

for(i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0)
{
_founditem = true;

for(n = 0 ; n < _NTT_OldItems.length ; n++)
{
if(_items[i].gid == _NTT_OldItems[n])
{
_founditem = false;
break;
}
}

if(_founditem)
return _items[i];
}
}

return null;
}

function NTT_GetOldItemsInt()
{
var _items;

_NTT_OldItems = new Array();

_items = me.GetItems();

if(!_items)
return false;

for(var i = 0 ; i < _items.length ; i++)
{
if(_items[i].mode == 0 && _items[i].itemloc == 0)
_NTT_OldItems.push(_items[i].gid);
}

return true;
}
function NTT_FillArrows(npc)
{
   var _arrows;
   var _items;
   var _weapon;
   var _name;
   var _bow =false;

   if(arguments.length < 1)
      return false;

   _weapon = me.GetItems();

   if(_weapon)
      for(var i = 0 ; i < _weapon.length ; i++)
           if(_weapon[i].mode == 1 && _weapon[i].itemloc == 4)
         switch(_weapon[i].classid)
         {
            case 68:   //Short Bow
            case 69:   //Hunter's Bow
            case 70:   //Longbow
            case 71:   //Composite Bow
            case 72:   //Short Battle Bow
            case 73:   //Long Battle Bow
            case 74:   //short war bow
            case 75:   //Long War Bow
            case 161:  //Edge Bow
            case 162:  //Razor Bow
            case 163:  //Cedar Bow
            case 164:  //Double Bow
            case 165:  //Short Siege Bow
            case 166:  //Large Siege Bow
            case 167:  //Rune Bow
            case 168:  //Gothic Bow
            case 264:  //Spider Bow
            case 265:  //Blade Bow
            case 266:  //Shadow Bow
            case 267:  //Great Bow
            case 268:  //Diamond Bow
            case 269:  //Crusader Bow
            case 270:  //Ward Bow
            case 271:  //Hydra Bow
            case 281:  //Stag Bow
            case 282:  //Reflex Bow
            case 291:  //Ashwood Bow
            case 292:  //Cermonial Bow
            case 301:  //Matriarchal Bow
            case 302:  //Grand Matron Bow
               _bow = true;
               _name = _weapon[i].name.split("\n")[0];
               break;

            default:
               _bow = false;
               _name = _weapon[i].name.split("\n")[0];
               break;
         }
   if(_bow)
   {
      Print("?c8Buying Arrows for my " + _name);
      Print(" ");
      _items = npc.GetItems(526);
   
         if(_items && _items.length > 0)
         {   
            NTT_ShopItem(_items[0], npc, 2);
         return;
         }
   }

   else
   {
      Print("?c8Buying Bolts for my " + _name);
      Print(" ");         
         _items = npc.GetItems(528);
   
         if(_items && _items.length > 0)
         {
            NTT_ShopItem(_items[0], npc, 2);
         return;
           
           }
   }

   return false;
}

Save and close NTTown.

PureKaoz.com - D2NT, Diablo 3 & Starcaft 2 Hacks

Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #1 on: September 04, 2010, 01:22:41 AM »

cooptheking

  • Guest
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #2 on: September 04, 2010, 01:33:16 AM »
Step[3]: Open NTTownManager.ntl and replace with this
Code: [Select]
var _NTTMGR_BuyPots;
var _NTTMGR_BuyTP;
var _NTTMGR_BuyKey;
var _NTTMGR_DoHeal;
var _NTTMGR_DoID;
var _NTTMGR_DoRepair;
var _NTTMGR_DoRevive;
var _NTTMGR_RemoveCurse;
var _NTTMGR_BuyArrows;

function NTTMGR_TownManager(simple)
{
var _cubing;

if(arguments.length < 1)
simple = false;

NTC_ClearCursor();
NTT_CleanPotions();

_NTTMGR_BuyPots = NTT_CheckBelt();
_NTTMGR_BuyTP = (NTTMGR_CheckScrolls(1) < 4);
_NTTMGR_BuyKey = (NTConfig_OpenChest && NTTMGR_CheckKeys() < 4);
_NTTMGR_DoHeal = NTT_CheckHeal();
_NTTMGR_DoID = NTT_CheckUnids();
_NTTMGR_DoRepair = NTT_CheckRepair(40);
_NTTMGR_DoRevive = NTT_CheckMerc();
_NTTMGR_RemoveCurse = NTTMGR_CheckCurse(NTConfig_CheckSelfSafe > 0x01 ? 0x7E : 0, NTConfig_CheckMercSafe > 0x01 ? 0x7E : 0);

NTCU_InitCubing();

NTC_PutSkill(115, NTC_HAND_RIGHT);
if(me.GetSkill(12, false) > 1)
{
   _NTTMGR_BuyArrows = true;
   if(NTC_InTown())
      NTTMGR_CheckAmazonBow();
}

switch(me.act)
{
case 1:
if(_NTTMGR_DoHeal || _NTTMGR_RemoveCurse || _NTTMGR_BuyPots || _NTTMGR_BuyTP || _NTTMGR_BuyKey || _NTTMGR_DoID)
NTTMGR_VisitAkara();

_cubing = (!simple && NTCU_CheckCubing());

if(_cubing || NTT_CheckInventory())
NTTMGR_VisitStash(_cubing);
if(_NTTMGR_DoRevive)
NTTMGR_VisitKashya();
if(_NTTMGR_DoRepair || _NTTMGR_BuyArrows)
NTTMGR_VisitCharsi();
if(!simple && NTConfig_Gamble && NTC_MyGold() > NTConfig_GambleStartGold)
{
NTTMGR_VisitGheed();

_cubing = (!simple && NTCU_CheckCubing());

if(_cubing || NTT_CheckInventory())
NTTMGR_VisitStash(_cubing);
}
break;

case 2:
if(_NTTMGR_DoHeal || _NTTMGR_RemoveCurse || _NTTMGR_DoRepair || _NTTMGR_BuyArrows)
NTTMGR_VisitFara();
if(_NTTMGR_BuyPots || _NTTMGR_BuyTP || _NTTMGR_DoID)
NTTMGR_VisitDrognan();
if(_NTTMGR_BuyKey)
NTTMGR_VisitLysander();

_cubing = (!simple && NTCU_CheckCubing());

if(_cubing || NTT_CheckInventory())
NTTMGR_VisitStash(_cubing);
if(_NTTMGR_DoRevive)
NTTMGR_VisitGreiz();
if(!simple && NTConfig_Gamble && NTC_MyGold() > NTConfig_GambleStartGold)
{
NTTMGR_VisitElzix();

_cubing = (!simple && NTCU_CheckCubing());

if(_cubing || NTT_CheckInventory())
NTTMGR_VisitStash(_cubing);
}
break;

case 3:
if(_NTTMGR_DoHeal || _NTTMGR_RemoveCurse || _NTTMGR_BuyPots || _NTTMGR_BuyTP || _NTTMGR_DoID)
NTTMGR_VisitOrmus();

_cubing = (!simple && NTCU_CheckCubing());

if(_cubing || NTT_CheckInventory())
NTTMGR_VisitStash(_cubing);
if(_NTTMGR_DoRevive)
NTTMGR_VisitAsheara();
if(_NTTMGR_DoRepair || _NTTMGR_BuyKey || _NTTMGR_BuyArrows)
NTTMGR_VisitHratli();
if(!simple && NTConfig_Gamble && NTC_MyGold() > NTConfig_GambleStartGold)
{
NTTMGR_VisitAlkor();

_cubing = (!simple && NTCU_CheckCubing());

if(_cubing || NTT_CheckInventory())
NTTMGR_VisitStash(_cubing);
}
break;

case 4:
if(_NTTMGR_DoHeal || _NTTMGR_RemoveCurse || _NTTMGR_BuyPots || _NTTMGR_BuyTP || _NTTMGR_BuyKey || _NTTMGR_DoID)
NTTMGR_VisitJamella(false);
if(_NTTMGR_DoRepair || _NTTMGR_BuyArrows)
NTTMGR_VisitHalbu();

_cubing = (!simple && NTCU_CheckCubing());

if(_cubing || NTT_CheckInventory())
NTTMGR_VisitStash(_cubing);
if(_NTTMGR_DoRevive)
NTTMGR_VisitTyrael();
if(!simple && NTConfig_Gamble && NTC_MyGold() > NTConfig_GambleStartGold)
{
NTTMGR_VisitJamella(true);

_cubing = (!simple && NTCU_CheckCubing());

if(_cubing || NTT_CheckInventory())
NTTMGR_VisitStash(_cubing);
}
break;

case 5:
if(_NTTMGR_DoHeal || _NTTMGR_RemoveCurse || _NTTMGR_BuyPots || _NTTMGR_BuyTP || _NTTMGR_BuyKey || _NTTMGR_DoID)
NTTMGR_VisitMalah();

_cubing = (!simple && NTCU_CheckCubing());

if(_cubing || NTT_CheckInventory())
NTTMGR_VisitStash(_cubing);
if(_NTTMGR_DoRepair || _NTTMGR_BuyArrows)
NTTMGR_VisitLarzuk();
if(_NTTMGR_DoRevive)
NTTMGR_VisitQualKehk();
if(!simple && NTConfig_Gamble && NTC_MyGold() > NTConfig_GambleStartGold)
{
NTTMGR_VisitAnya();

_cubing = (!simple && NTCU_CheckCubing());

if(_cubing || NTT_CheckInventory())
NTTMGR_VisitStash(_cubing);
}
break;
}
}

function NTTMGR_VisitTown()
{
var _prearea = me.areaid;

if(!NTTM_CheckAct())
return false;

NTTMGR_TownManager(true);

if(!NTTM_TownMove("portalspot"))
return false;

if(!NTM_UsePortal("BluePortal", _prearea))
return false;

if(NTConfig_PublicMode)
NTM_MakeTP();

return true;
}

function NTTMGR_VisitStash(cubing)
{
var _stash;

NTTM_TownMove("stash");

_stash = NTC_FindUnit(NTC_UNIT_OBJECT, NTC_UNIT_STASH, 5);

if(_stash)
{
if(NTT_DoInteract(_stash))
{
NTT_ManageStash();

if(cubing)
{
NTCU_DoCubing();

if(NTT_DoInteract(_stash))
NTT_ManageStash();

me.Cancel(1);
NTT_ClearInventory();
}
else
me.Cancel(1);
}
}
}

function NTTMGR_VisitAkara()
{
var _npc;

NTTM_TownMove("akara");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_AKARA, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
if(_NTTMGR_BuyPots || _NTTMGR_BuyTP || _NTTMGR_BuyKey || _NTTMGR_DoID)
{
if(NTT_DoTrade(_npc))
{
if(_NTTMGR_BuyPots)
NTT_FillBelt(_npc);
if(_NTTMGR_BuyTP)
NTT_FillTome(_npc, 1);
if(_NTTMGR_BuyKey)
NTT_FillKey(_npc);
if(_NTTMGR_DoID)
NTTMGR_IDItems(_npc);
}
}

me.Cancel(1);
}
}
}

function NTTMGR_VisitKashya()
{
var _npc;

NTTM_TownMove("kashya");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_KASHYA, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
NTT_ReviveMerc();
me.Cancel(1);

if(NTConfig_ResetWeapon)
NTT_ResetWeaponMerc();
}
}
}


function NTTMGR_VisitCharsi()
{
var _npc;

NTTM_TownMove("charsi");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_CHARSI, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
if(_NTTMGR_DoRepair || _NTTMGR_BuyArrows)

if(NTT_DoTrade(_npc))
if(_NTTMGR_DoRepair)
NTT_RepairItems(_npc);
if(_NTTMGR_BuyArrows)
NTT_FillArrows(_npc);
me.Cancel(1);
}
}
}
function NTTMGR_VisitGheed()
{
var _npc;

NTTM_TownMove("gheed");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_GHEED, 5);

if(_npc)
{
while(NTC_MyGold() > NTConfig_GambleStopGold)
{
if(NTT_DoInteract(_npc))
{
if(NTT_DoTrade(_npc, 1))
NTT_GambleIt(_npc);

me.Cancel(1);
}
else
break;
}
}
}

function NTTMGR_VisitFara()
{
var _npc;

NTTM_TownMove("fara");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_FARA, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
if(_NTTMGR_DoRepair || _NTTMGR_BuyArrows)

if(NTT_DoTrade(_npc))
if(_NTTMGR_DoRepair)
NTT_RepairItems(_npc);
if(_NTTMGR_BuyArrows)
NTT_FillArrows(_npc);

me.Cancel(1);
}
}
}

function NTTMGR_VisitDrognan()
{
var _npc;

NTTM_TownMove("drognan");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_DROGNAN, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
if(NTT_DoTrade(_npc))
{
if(_NTTMGR_BuyPots)
NTT_FillBelt(_npc);
if(_NTTMGR_BuyTP)
NTT_FillTome(_npc, 1);
if(_NTTMGR_DoID)
NTTMGR_IDItems(_npc);
}

me.Cancel(1);
}
}
}

function NTTMGR_VisitLysander()
{
var _npc;

NTTM_TownMove("lysander");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_LYSANDER, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
if(NTT_DoTrade(_npc))
NTT_FillKey(_npc);

me.Cancel(1);
}
}
}

function NTTMGR_VisitGreiz()
{
var _npc;

NTTM_TownMove("greiz");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_GREIZ, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
NTT_ReviveMerc();
me.Cancel(1);

if(NTConfig_ResetWeapon)
NTT_ResetWeaponMerc();
}
}
}

function NTTMGR_VisitElzix()
{
var _npc;

NTTM_TownMove("elzix");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_ELZIX, 5);

if(_npc)
{
while(NTC_MyGold() > NTConfig_GambleStopGold)
{
if(NTT_DoInteract(_npc))
{
if(NTT_DoTrade(_npc, 1))
NTT_GambleIt(_npc);

me.Cancel(1);
}
else
break;
}
}
}

function NTTMGR_VisitOrmus()
{
var _npc;

NTTM_TownMove("ormus");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_ORMUS, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
if(_NTTMGR_BuyPots || _NTTMGR_BuyTP || _NTTMGR_DoID)
{
if(NTT_DoTrade(_npc))
{
if(_NTTMGR_BuyPots)
NTT_FillBelt(_npc);
if(_NTTMGR_BuyTP)
NTT_FillTome(_npc, 1);
if(_NTTMGR_DoID)
NTTMGR_IDItems(_npc);
}
}

me.Cancel(1);
}
}
}

function NTTMGR_VisitAsheara()
{
var _npc;

NTTM_TownMove("asheara");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_ASHEARA, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
NTT_ReviveMerc();
me.Cancel(1);

if(NTConfig_ResetWeapon)
NTT_ResetWeaponMerc();
}
}
}

function NTTMGR_VisitHratli()
{
var _npc;

NTTM_TownMove("hratli");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_HRATLI, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
if(NTT_DoTrade(_npc))
{
if(_NTTMGR_DoRepair)
NTT_RepairItems(_npc);
if(_NTTMGR_BuyKey)
NTT_FillKey(_npc);
if(_NTTMGR_BuyArrows)
NTT_FillArrows(_npc);
}

me.Cancel(1);
}
}
}

function NTTMGR_VisitAlkor()
{
var _npc;

NTTM_TownMove("alkor");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_ALKOR, 5);

if(_npc)
{
while(NTC_MyGold() > NTConfig_GambleStopGold)
{
if(NTT_DoInteract(_npc))
{
if(NTT_DoTrade(_npc, 1))
NTT_GambleIt(_npc);

me.Cancel(1);
}
else
break;
}
}
}

function NTTMGR_VisitJamella(gamble)
{
var _npc;

NTTM_TownMove("jamella");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_JAMELLA, 5);

if(_npc)
{
if(gamble)
{
while(NTC_MyGold() > NTConfig_GambleStopGold)
{
if(NTT_DoInteract(_npc))
{
if(NTT_DoTrade(_npc, 1))
NTT_GambleIt(_npc);

me.Cancel(1);
}
else
break;
}
}
else
{
if(NTT_DoInteract(_npc))
{
if(_NTTMGR_BuyPots || _NTTMGR_BuyTP || _NTTMGR_BuyKey || _NTTMGR_DoID)
{
if(NTT_DoTrade(_npc))
{
if(_NTTMGR_BuyPots)
NTT_FillBelt(_npc);
if(_NTTMGR_BuyTP)
NTT_FillTome(_npc, 1);
if(_NTTMGR_BuyKey)
NTT_FillKey(_npc);
if(_NTTMGR_DoID)
NTTMGR_IDItems(_npc);
}
}

me.Cancel(1);
}
}
}
}

function NTTMGR_VisitHalbu()
{
var _npc;

NTTM_TownMove("halbu");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_HALBU, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
if(_NTTMGR_DoRepair || _NTTMGR_BuyArrows)

if(NTT_DoTrade(_npc))
if(_NTTMGR_DoRepair)
NTT_RepairItems(_npc);
if(_NTTMGR_BuyArrows)
NTT_FillArrows(_npc);
me.Cancel(1);
}
}
}

function NTTMGR_VisitTyrael()
{
var _npc;

NTTM_TownMove("tyrael");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_TYRAEL_ACT_4, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
NTT_ReviveMerc();
me.Cancel(1);

if(NTConfig_ResetWeapon)
NTT_ResetWeaponMerc();
}
}
}

function NTTMGR_VisitMalah()
{
var _npc;

NTTM_TownMove("malah");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_MALAH, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
if(_NTTMGR_BuyPots || _NTTMGR_BuyTP || _NTTMGR_BuyKey || _NTTMGR_DoID)
{
if(NTT_DoTrade(_npc))
{
if(_NTTMGR_BuyPots)
NTT_FillBelt(_npc);
if(_NTTMGR_BuyTP)
NTT_FillTome(_npc, 1);
if(_NTTMGR_BuyKey)
NTT_FillKey(_npc);
if(_NTTMGR_DoID)
NTTMGR_IDItems(_npc);
}
}

me.Cancel(1);
}
}
}

function NTTMGR_VisitLarzuk()
{
var _npc;

NTTM_TownMove("larzuk");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_LARZUK, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
if(NTT_DoTrade(_npc))

if(_NTTMGR_DoRepair || _NTTMGR_BuyArrows)
if(_NTTMGR_DoRepair)
NTT_RepairItems(_npc);
if(_NTTMGR_BuyArrows)
NTT_FillArrows(_npc);

me.Cancel(1);
}
}
}

function NTTMGR_VisitQualKehk()
{
var _npc;

NTTM_TownMove("qual-kehk");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_QUALKEHK, 5);

if(_npc)
{
if(NTT_DoInteract(_npc))
{
NTT_ReviveMerc();
me.Cancel(1);

if(NTConfig_ResetWeapon)
NTT_ResetWeaponMerc();
}
}
}

function NTTMGR_VisitAnya()
{
var _npc;

NTTM_TownMove("anya");

_npc = NTC_FindUnit(NTC_UNIT_NPC, NTC_NPC_ID_ANYA_TOWN, 5);

if(_npc)
{
while(NTC_MyGold() > NTConfig_GambleStopGold)
{
if(NTT_DoInteract(_npc))
{
if(NTT_DoTrade(_npc, 1))
NTT_GambleIt(_npc);

me.Cancel(1);
}
else
break;
}
}
}

function NTTMGR_CheckScrolls(scrolltype)
{
var _tome = NTT_GetTome(scrolltype);

if(_tome)
return _tome.GetStat(70);

return 0;
}

function NTTMGR_CheckKeys()
{
var _key;

if(me.classid == NTC_CHAR_CLASS_ASSASSIN)
return 12;

_key = NTT_GetKey();

if(_key)
return _key.GetStat(70);

return 0;
}

function NTTMGR_IDItems(npc)
{
var _tome, _scroll;
var _result;
var _items = NTT_GetUnidItems();

if(!_items || _items.length < 1)
return;

_tome = NTT_GetTome();

if(_tome && _tome.GetStat(70) < _items.length)
NTT_FillTome(npc);

for(var i = 0 ; i < _items.length ; i++)
{
switch(NTSI_CheckItem(_items[i]))
{
case 1:
NTC_SendLogToOOG(NTC_LOG_ITEM, "Kept " + NTC_ItemQualityToMGRColor[_items[i].quality] + _items[i].name.split("\n")[0] + ";" + _items[i].itemdesc);
case 2:
break;
case -1:
if(_tome)
_result = NTT_IdItem(_tome, _items[i]);
else
{
_scroll = NTT_GetScroll();

if(!_scroll)
{
NTT_BuyScrolls(npc);
_scroll = NTT_GetScroll();
}

_result = NTT_IdItem(_scroll, _items[i]);
}

if(_result)
{
switch(NTSI_CheckItem(_items[i]))
{
case 1:
NTC_SendLogToOOG(NTC_LOG_ITEM, "Kept " + NTC_ItemQualityToMGRColor[_items[i].quality] + _items[i].name.split("\n")[0] + ";" + _items[i].itemdesc);
case 2:
break;
default:
NTT_ShopItem(_items[i], npc, 1);
break;
}
}
else
NTT_ShopItem(_items[i], npc, 1);

break;
}
}
}

// mask - 0x02 : Poison, 0x04 : Amplify Damage, 0x08 : Weaken, 0x10 : Iron Maiden, 0x20 : Decrepify, 0x40 : Lower Resist
function NTTMGR_CheckCurse(selfmask, mercmask)
{
if(selfmask > 0x01)
{
if((selfmask&0x02) && me.GetState(2))
return true;

if((selfmask&0x04) && me.GetState(9))
return true;

if((selfmask&0x08) && me.GetState(19))
return true;

if((selfmask&0x10) && me.GetState(55))
return true;

if((selfmask&0x20) && me.GetState(60))
return true;

if((selfmask&0x40) && me.GetState(61))
return true;
}

if(mercmask > 0x01)
{
var _merc = NTC_GetMerc();

if(_merc)
{
if((mercmask&0x02) && _merc.GetState(2))
return true;

if((mercmask&0x04) && _merc.GetState(9))
return true;

if((mercmask&0x08) && _merc.GetState(19))
return true;

if((mercmask&0x10) && _merc.GetState(55))
return true;

if((mercmask&0x20) && _merc.GetState(60))
return true;

if((mercmask&0x40) && _merc.GetState(61))
return true;
}
}

return false;
}

// self - 0x01 : Potion
// merc - 0x01 : Death
// common - 0x02 : Poison, 0x04 : Amplify Damage, 0x08 : Weaken, 0x10 : Iron Maiden, 0x20 : Decrepify, 0x40 : Lower Resist
function NTTMGR_CheckSafe(selfmask, mercmask)
{
if(((selfmask&0x01) && NTT_CheckBelt()) || ((mercmask&0x01) && NTT_CheckMerc()) || NTTMGR_CheckCurse(selfmask, mercmask))
return NTTMGR_VisitTown();

return true;
}

function NTTMGR_CheckAmazonBow()
{
   if(me.GetSkill(NTC_HAND_LEFT) == 0 || me.GetSkill(NTC_HAND_RIGHT) == 149 || me.GetSkill(NTC_HAND_RIGHT) == 155)
      NTC_SwapWeapons();

   var _weapon = me.GetItems();

     if(_weapon)
     {
             for(var i = 0 ; i < _weapon.length ; i++)
           {
         if(_weapon[i].classid == 526 || _weapon[i].classid == 528)
                  {
                        if(_weapon[i].GetStat(70) <= 350 && _weapon[i].itemloc == 5 && _weapon[i].mode == 1)
                        {
                           SetUIState(0x01, true);
                           NTC_PingDelay(200);
                           NTC_ItemToCursor(_weapon[i]);
                           NTC_PingDelay(200);
                           NTC_ClearCursor();
                           NTC_PingDelay(200);
                           me.Cancel(1);
                           break;   
                        }
                     }         
            }
         }
}

cooptheking

  • Guest
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #3 on: September 04, 2010, 01:37:48 AM »
Step[4]: Goto your Char config folder and find file NTConfig.ntl. Open it and replace the file with this
Code: [Select]
var NTConfig_Script = new Array();

var NTConfig_NihlathakExtension;
var NTConfig_PindleskinExtension;
var NTConfig_ShenkExtension;
var NTConfig_ClearFrozenRiver;
var NTConfig_ClearGlacialTrail;
var NTConfig_ClearIcyCellar;
var NTConfig_KillBaal;
var NTConfig_ClearA3SewersLevel1;
var NTConfig_KillFireEye;
var NTConfig_ClearPitLevel1;
var NTConfig_KillBloodRaven;
var NTConfig_ClearHoleLevel1;
var NTConfig_KillRakanishu;

var NTConfig_StartDelay;
var NTConfig_AreaDelay;
var NTConfig_SnagDelay;

var NTConfig_SkipHealLife;
var NTConfig_SkipHealMana;
var NTConfig_UseMerc;
var NTConfig_ResetWeapon;

var NTConfig_LifeThresh;
var NTConfig_LifeRejuvThresh;
var NTConfig_ManaThresh;
var NTConfig_ManaRejuvThresh;
var NTConfig_LifeChicken;
var NTConfig_ManaChicken;

var NTConfig_MercLifeThresh;
var NTConfig_MercRejuvThresh;
var NTConfig_MercChicken;

var NTConfig_FreeSpace;

var NTConfig_Columns = new Array(4);
NTConfig_Columns[0] = new Array(10);
NTConfig_Columns[1] = new Array(10);
NTConfig_Columns[2] = new Array(10);
NTConfig_Columns[3] = new Array(10);

var NTConfig_MinGoldToStash;

var NTConfig_BeltColType = new Array(4);

var NTConfig_NIPFilePath = new Array();
var NTConfig_SnagRange;

var NTConfig_Cubing;
var NTConfig_CubingItem = new Array();

var NTConfig_Gamble;
var NTConfig_GambleStartGold;
var NTConfig_GambleStopGold;
var NTConfig_GambleItem = new Array();

var NTConfig_PublicMode;
var NTConfig_CheckCloneDiablo;
var NTConfig_OpenChest;

var NTConfig_AttackSkill = new Array(8);

var NTConfig_ClearPosition;
var NTConfig_CheckSelfSafe;
var NTConfig_CheckMercSafe;

PureKaoz.com - D2NT, Diablo 3 & Starcaft 2 Hacks

Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #3 on: September 04, 2010, 01:37:48 AM »

cooptheking

  • Guest
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #4 on: September 04, 2010, 01:42:36 AM »
Step[5]: Goto your character config folder and find NTConfig_Sorceress.ntl.
Open the file and replace the contents with the code box below.
Afterwords, do not click save..instead click "save as" (very important)
File type: All files
File name : NTConfig_Amazon.ntl   (if you use a version that requires you to put your character name, please rename it to NTConfig_Amazon_YoUrCharac-terName.ntl (of course putting your character name there instead)
Double check to make sure you have "all files" selected an the appropriate file name before saving

Code: [Select]
function NT_LoadConfig()
{
//------------------------------------------------------------------------------
// Boss configuration
//------------------------------------------------------------------------------
//NTConfig_Script.push("NTPindleskin.ntj"); NTConfig_NihlathakExtension = false;
//NTConfig_Script.push("NTNihlathak.ntj"); NTConfig_PindleskinExtension = false;
NTConfig_Script.push("NTEldritch.ntj"); NTConfig_ShenkExtension = true;
//NTConfig_Script.push("NTThreshSocket.ntj");
//NTConfig_Script.push("NTFrozenRiver.ntj"); NTConfig_ClearFrozenRiver = false;
//NTConfig_Script.push("NTGlacialTrail.ntj"); NTConfig_ClearGlacialTrail = false;
//NTConfig_Script.push("NTIcyCellar.ntj"); NTConfig_ClearIcyCellar = false;
//NTConfig_Script.push("NTBaal.ntj"); NTConfig_KillBaal = true;
//NTConfig_Script.push("NTDiablo.ntj");
//NTConfig_Script.push("NTHephasto.ntj");
//NTConfig_Script.push("NTIzual.ntj");
NTConfig_Script.push("NTMephisto.ntj");
//NTConfig_Script.push("NTTravincal.ntj");
//NTConfig_Script.push("NTKurastTravel.ntj");
//NTConfig_Script.push("NTAct3Sewers.ntj"); NTConfig_ClearA3SewersLevel1 = 1; // 0 : don't clear, 1 : clear path only, 2 : clear all
//NTConfig_Script.push("NTSummoner.ntj"); NTConfig_KillFireEye = true;
//NTConfig_Script.push("NTDuriel.ntj");
//NTConfig_Script.push("NTAncientTunnels.ntj");
//NTConfig_Script.push("NTColdworm.ntj");
//NTConfig_Script.push("NTRadament.ntj");
NTConfig_Script.push("NTAndariel.ntj");
//NTConfig_Script.push("NTCountess.ntj");
//NTConfig_Script.push("NTTreehead.ntj");
//NTConfig_Script.push("NTPit.ntj"); NTConfig_ClearPitLevel1 = 1; // 0 : don't clear, 1 : clear path only, 2 : clear all
//NTConfig_Script.push("NTMausoleum.ntj"); NTConfig_KillBloodRaven = true;
//NTConfig_Script.push("NTHole.ntj"); NTConfig_ClearHoleLevel1 = 1; // 0 : don't clear, 1 : clear path only, 2 : clear all
NTConfig_Script.push("NTTristram.ntj"); NTConfig_KillRakanishu = true;

//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
me.maxgametime = 1200; // time in seconds, maximum game length (0 is infinite)
NTConfig_StartDelay = 0; // Delay time in milliseconds to start;
NTConfig_AreaDelay = 100; // Delay time in milliseconds to change area;
NTConfig_SnagDelay = 100; // Delay time in milliseconds to wait before starting picking items

//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
NTConfig_SkipHealLife = 95; // If you have more than this percent of life, you won't go to a healer
NTConfig_SkipHealMana = 30; // If you have more than this percent of mana, you won't go to a healer
NTConfig_UseMerc = true; // Set to true if you use a mercenary, will revive merc at a reviver npc.
NTConfig_ResetWeapon = false; // Set to true to reset weapon when reviving merc

NTConfig_LifeThresh = 90; // Drink a normal potion if under this percent of life.
NTConfig_LifeRejuvThresh = 75; // Drink a rejuvenation potion if under this percent of life.
NTConfig_ManaThresh = 30; // Drink a normal potion if under this percent of mana.
NTConfig_ManaRejuvThresh = 10; // Drink a rejuvenation potion if under this percent of mana.
NTConfig_LifeChicken = 55; // This is your chicken life percent. If you go below this life total, exit game.
NTConfig_ManaChicken = 0; // This is your chicken mana percent. If you go below this mana total, exit game.

NTConfig_MercLifeThresh = 70; // This is the threshold to use a life potion on your merc in percent.
NTConfig_MercRejuvThresh = 15; // This is the threshold to use a rejuv potion on your merc in percent.
NTConfig_MercChicken = 0; // This is your mercs chicken life percent. If he goes below this, exit game.

//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
NTConfig_FreeSpace = 3; // Number of free columns. If less full columns are free stashing is set.

// The numbers correspond to your inventory. Set 0 to keep whatever is there, 1 to stash it.
NTConfig_Columns[0] = [1,1,1,0,0,0,0,0,0,0];
NTConfig_Columns[1] = [1,1,1,0,0,0,0,0,0,0];
NTConfig_Columns[2] = [1,1,1,0,0,0,0,0,0,0];
NTConfig_Columns[3] = [1,1,1,0,0,0,0,0,0,0];

NTConfig_MinGoldToStash = 300000; // Maximum gold amount carried before going to stash

//----------------------------------------------------------------------------------------------
// Type of potion used in each belt column
// Available types : "hp" = health | "mp" = mana | "rv" = rejuv. Can use other potion types too.
// Keep equal types at adjacent columns. First HP then MP and then HP again is a bad choice.
// Keep HP and MP at the beginning of the belt (in case you want to use rejuv and other types).
// Rejuvenations MUST, I REPEAT MUST be at the end of the belt (last x columns).
// To use rejuvenations only, put "rv" in all columns.
//----------------------------------------------------------------------------------------------
NTConfig_BeltColType[0] = "rv";
NTConfig_BeltColType[1] = "rv";
NTConfig_BeltColType[2] = "rv";
NTConfig_BeltColType[3] = "mp";

//-----------------------------------------------------------------------------------
// SnagIt configuration
// Select one group only (normal / advance / extreme)
//-----------------------------------------------------------------------------------
//NTConfig_NIPFilePath.push("normal/normal.nip");
//NTConfig_NIPFilePath.push("normal/magic_rare.nip");
//NTConfig_NIPFilePath.push("normal/set.nip");
//NTConfig_NIPFilePath.push("normal/unique.nip");
//NTConfig_NIPFilePath.push("normal/craft.nip");

//NTConfig_NIPFilePath.push("advance/normal.nip");
//NTConfig_NIPFilePath.push("advance/magic_rare.nip");
//NTConfig_NIPFilePath.push("advance/set.nip");
//NTConfig_NIPFilePath.push("advance/unique.nip");
//NTConfig_NIPFilePath.push("advance/craft.nip");

//NTConfig_NIPFilePath.push("extreme/normal.nip");
//NTConfig_NIPFilePath.push("extreme/magic_rare.nip");
//NTConfig_NIPFilePath.push("extreme/set.nip");
//NTConfig_NIPFilePath.push("extreme/unique.nip");
//NTConfig_NIPFilePath.push("extreme/craft.nip");
      NTConfig_NIPFilePath.push("warpickit.nip");


NTConfig_SnagRange = 90; // Radius to check for dropped items. 40 is a good number here

//------------------------------------------------------------------------------
// Cubing configuration
//------------------------------------------------------------------------------
NTConfig_Cubing = false; // Enable cubing

//NTConfig_CubingItem.push([NTCU_GEM, 560]); // Flawless Amethyst
//NTConfig_CubingItem.push([NTCU_GEM, 565]); // Flawless Topaz
//NTConfig_CubingItem.push([NTCU_GEM, 570]); // Flawless Saphire
//NTConfig_CubingItem.push([NTCU_GEM, 575]); // Flawless Emerald
//NTConfig_CubingItem.push([NTCU_GEM, 580]); // Flawless Ruby
//NTConfig_CubingItem.push([NTCU_GEM, 585]); // Flawless Diamond
//NTConfig_CubingItem.push([NTCU_GEM, 600]); // Flawless Skull

//NTConfig_CubingItem.push([NTCU_MAGIC, 420]); // Magic Tiara
//NTConfig_CubingItem.push([NTCU_MAGIC, 421]); // Magic Diadem

//NTConfig_CubingItem.push([NTCU_MAGIC_CHARM, 603]); // Magic Small Charm
NTConfig_CubingItem.push([NTCU_MAGIC_CHARM, 605]); // Magic Grand Charm

NTConfig_CubingItem.push([NTCU_CRAFT_HITPOWER_GLOVES, 382]); // Craft Heavy Bracers
//NTConfig_CubingItem.push([NTCU_CRAFT_HITPOWER_GLOVES, 452]); // Craft Vambraces

//NTConfig_CubingItem.push([NTCU_CRAFT_BLOOD_HELM, 354]); // Craft Casque
//NTConfig_CubingItem.push([NTCU_CRAFT_BLOOD_HELM, 424]); // Craft Armet
//NTConfig_CubingItem.push([NTCU_CRAFT_BLOOD_BOOTS, 388]); // Craft Battle Boots
//NTConfig_CubingItem.push([NTCU_CRAFT_BLOOD_BOOTS, 458]); // Craft Mirrored Boots
//NTConfig_CubingItem.push([NTCU_CRAFT_BLOOD_GLOVES, 381]); // Craft Sharkskin Gloves
//NTConfig_CubingItem.push([NTCU_CRAFT_BLOOD_GLOVES, 451]); // Craft Vampirebone Gloves
//NTConfig_CubingItem.push([NTCU_CRAFT_BLOOD_BELT, 392]); // Craft Mesh Belt
//NTConfig_CubingItem.push([NTCU_CRAFT_BLOOD_BELT, 462]); // Craft Mithril Coil
//NTConfig_CubingItem.push([NTCU_CRAFT_BLOOD_AMULET, 520]); // Craft Amulet
NTConfig_CubingItem.push([NTCU_CRAFT_BLOOD_RING, 522]); // Craft Ring

NTConfig_CubingItem.push([NTCU_CRAFT_CASTER_AMULET, 520]); // Craft Amulet

//NTConfig_CubingItem.push([NTCU_CRAFT_SAFETY_SHIELD, 447]); // Craft Monarch
//NTConfig_CubingItem.push([NTCU_CRAFT_SAFETY_AMULET, 520]); // Craft Amulet

//NTConfig_CubingItem.push([NTCU_RUNE_THUL, 562]);
//NTConfig_CubingItem.push([NTCU_RUNE_AMN, 557]);
//NTConfig_CubingItem.push([NTCU_RUNE_SOL, 567]);
//NTConfig_CubingItem.push([NTCU_RUNE_SHAEL, 577]);
//NTConfig_CubingItem.push([NTCU_RUNE_DOL, 572]);
//NTConfig_CubingItem.push([NTCU_RUNE_HEL, 582]);
//NTConfig_CubingItem.push([NTCU_RUNE_IO, 563]);
NTConfig_CubingItem.push([NTCU_RUNE_LUM, 558]);
NTConfig_CubingItem.push([NTCU_RUNE_KO, 568]);
NTConfig_CubingItem.push([NTCU_RUNE_FAL, 578]);
NTConfig_CubingItem.push([NTCU_RUNE_LEM, 573]);
NTConfig_CubingItem.push([NTCU_RUNE_PUL, 583]);
NTConfig_CubingItem.push([NTCU_RUNE_UM, 564]);
NTConfig_CubingItem.push([NTCU_RUNE_MAL, 559]);
//NTConfig_CubingItem.push([NTCU_RUNE_IST, 569]);
//NTConfig_CubingItem.push([NTCU_RUNE_GUL, 579]);
//NTConfig_CubingItem.push([NTCU_RUNE_VEX, 574]);
//NTConfig_CubingItem.push([NTCU_RUNE_OHM, 584]);
//NTConfig_CubingItem.push([NTCU_RUNE_LO, 565]);
//NTConfig_CubingItem.push([NTCU_RUNE_SUR, 560]);
//NTConfig_CubingItem.push([NTCU_RUNE_BER, 570]);
//NTConfig_CubingItem.push([NTCU_RUNE_JAH, 580]);
//NTConfig_CubingItem.push([NTCU_RUNE_CHAM, 575]);

//***** Include the following, Primary item must be setted in item_configs folder *****

//NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 442]); // Socket Sacred Armor

//NTConfig_CubingItem.push([NTCU_SOCKET_WEAPON, 255]); // Socket Thresher
//NTConfig_CubingItem.push([NTCU_SOCKET_WEAPON, 256]); // Socket Cryptic Axe
//NTConfig_CubingItem.push([NTCU_SOCKET_WEAPON, 257]); // Socket Great Poleaxe
//NTConfig_CubingItem.push([NTCU_SOCKET_WEAPON, 258]); // Socket Giant Thresher

//NTConfig_CubingItem.push([NTCU_UPGRADE_E_UNIQUE_WEAPON, 295]); // Titan's Revenge : Exceptional -> Elite

//NTConfig_CubingItem.push([NTCU_UPGRADE_N_UNIQUE_ARMOR, 337]); // Magefist : Normal -> Exceptional
//NTConfig_CubingItem.push([NTCU_UPGRADE_E_UNIQUE_ARMOR, 360]); // Skin of the Vipermagi : Exceptional -> Elite
//NTConfig_CubingItem.push([NTCU_UPGRADE_E_UNIQUE_ARMOR, 383]); // Magefist or Lava Gout : Exceptional -> Elite
//NTConfig_CubingItem.push([NTCU_UPGRADE_E_UNIQUE_ARMOR, 389]); // Gore Rider : Exceptional -> Elite
//NTConfig_CubingItem.push([NTCU_UPGRADE_E_UNIQUE_ARMOR, 477]); // Arreat's Face : Exceptional -> Elite
//NTConfig_CubingItem.push([NTCU_UPGRADE_E_UNIQUE_ARMOR, 481]); // Herald Of Zakarum : Exceptional -> Elite

//------------------------------------------------------------------------------
// Gamble configuration
// To specify what items to gamble, adjust the array with the desired item codes
//------------------------------------------------------------------------------
NTConfig_Gamble = false; // Enable gambling
NTConfig_GambleStartGold = 1000000; // Gold amount to start the gambling
NTConfig_GambleStopGold = 300000; // Gold amount to stop the gambling

NTConfig_GambleItem.push(520); // Amulets
NTConfig_GambleItem.push(522); // Rings
//NTConfig_GambleItem.push(418); // Circlets
//NTConfig_GambleItem.push(419); // Coronets
//NTConfig_GambleItem.push(334); // Leather Gloves
//NTConfig_GambleItem.push(335); // Heavy Gloves
//NTConfig_GambleItem.push(336); // Chain Gloves
//NTConfig_GambleItem.push(337); // Light Gauntlets
//NTConfig_GambleItem.push(338); // Gauntlets

//------------------------------------------------------------------------------
// General configuration
//------------------------------------------------------------------------------
NTConfig_PublicMode = false;
NTConfig_CheckCloneDiablo = false; // Set to true if you want to wait in game after notifying "Diablo Walks the Earth" msg.
NTConfig_OpenChest = false; // Set to true to open chest
me.quitonhostile = true;

//------------------------------------------------------------------------------
// Attack configuration
//------------------------------------------------------------------------------

NTConfig_AttackSkill[0] = 0; // First skill. Maybe slow missiles
NTConfig_AttackSkill[1] = 0; // Primary skill to super unique/champion.
NTConfig_AttackSkill[2] = 0; // Primary untimed skill to super unique/champion.
NTConfig_AttackSkill[3] = 0; // Primary skill to others.
NTConfig_AttackSkill[4] = 0; // Primary untimed skill to others.
NTConfig_AttackSkill[5] = 0; // Secondary skill in case monster is immune to primary skill.
NTConfig_AttackSkill[6] = 0; // Secondary untimed skill.
NTConfig_AttackSkill[7] = 0; // Primary skill to boss (diablo/baal/meph/etc) Not immune to spells I guess.
NTConfig_ClearPosition = true; // Set to true if you want to clear area after killing boss.

// Check self safe in field (NOT in town). Set to 0 if you won't
// 0x01 : Potion, 0x02 : Poison, 0x04 : Amplify Damage, 0x08 : Weaken, 0x10 : Iron Maiden, 0x20 : Decrepify, 0x40 : Lower Resist
NTConfig_CheckSelfSafe = 0x04|0x40;
// Check merc's safe in field (NOT in town). Set to 0 if you won't
// 0x01 : Death, 0x02 : Poison, 0x04 : Amplify Damage, 0x08 : Weaken, 0x10 : Iron Maiden, 0x20 : Decrepify, 0x40 : Lower Resist
NTConfig_CheckMercSafe = 0x01|0x04|0x10|0x40;


}

PureKaoz.com - D2NT, Diablo 3 & Starcaft 2 Hacks

Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #4 on: September 04, 2010, 01:42:36 AM »

Offline drow

  • Newbie
  • *
  • Join Date: Oct 2010
  • Posts: 12
  • Reputation 0
  • I <3 PureKaoz.com
    • View Profile
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #5 on: December 03, 2010, 08:04:57 PM »
I followed the scripting to a T and I am getting this error. Can someone help?


Offline ekolan88

  • Newbie
  • *
  • Join Date: Nov 2010
  • Posts: 15
  • Reputation 0
  • I <3 PureKaoz.com
    • View Profile
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #6 on: December 08, 2010, 02:54:43 AM »
Will this script also work with the bowazon as leech fighter?

Offline drow

  • Newbie
  • *
  • Join Date: Oct 2010
  • Posts: 12
  • Reputation 0
  • I <3 PureKaoz.com
    • View Profile
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #7 on: December 08, 2010, 08:32:57 AM »
yes it does. that is how i lvl'd my bowzon after I got the script up and running. works perfectly.

PureKaoz.com - D2NT, Diablo 3 & Starcaft 2 Hacks

Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #7 on: December 08, 2010, 08:32:57 AM »

Offline Lefty

  • Newbie
  • *
  • Join Date: Feb 2011
  • Posts: 1
  • Reputation 0
  • I <3 PureKaoz.com
    • View Profile
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #8 on: February 20, 2011, 06:59:37 PM »
I had to make an account to personally thank you Coop. Major props. I have been dabbling with the zon script for awhile and couldn't get past an error with the Attack.ntl. You knew exactly what to do and submitted the whole thing. Damn, thanks again man. :D:D

Offline cooptheking03

  • D2NT Specialist
  • Big Boss Man
  • PureKaoz HeRo
  • *******
  • Join Date: Oct 2010
  • Posts: 1651
  • Reputation 4
  • I Run This Chizz
    • View Profile
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #9 on: February 20, 2011, 09:46:34 PM »
Well lefty, appreciate the comment. It was, in fact, Bigapple's overall script. I simply copied it here for the use on this site (with permission of course). I will pass on the thanks to big apple (as he uses a different site).  :)

Tho i have many scripts i've written myself, this is not one of them. :)   
I Do Not Do Support Via PM.
I Can Help Xfer Anycore/Anyrealm/Anytime.
PM me here or on JSP : TheAmazingShac0

Offline jbkid

  • Newbie
  • *
  • Join Date: Feb 2011
  • Posts: 2
  • Reputation 0
  • I <3 PureKaoz.com
    • View Profile
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #10 on: March 05, 2011, 10:39:40 PM »
hello, this is my first post on, so id like to start by saying thank you to everyone who has had any involvement in this website, bots, and support. amazing sit, bot, and community.

My issue recently developed when i downloaded this mod.  i bot with my sorc primarily and recently decided to set up my javazon for botting as well. the java bot works perfectly so thank you for that.
to bot with my zon i had to copy my original d2nt folder so i could modify the files for the javazon and still retain my original bot for my sorc.

problem is when i run both bots they seem to confuse eachother. i wish i could screenshot this but its not an in game error. 1 bot will run perfectly, the other will sit in game creation lobby and do nothing. the manager for the bot with the error keeps going back and forth between "lobby(0)" "create game" and "in game..." im sorry if im rambling but not being able to screenshot im trying to go into as much detail as possible. they will both start the first run, then the first one to complete the run will make a new game no problem, but the sec will then go into the above cycle.

any help would be greatly appreciated. again thank you so much to everyone whos had a hand in any of this. thank you

Offline cooptheking03

  • D2NT Specialist
  • Big Boss Man
  • PureKaoz HeRo
  • *******
  • Join Date: Oct 2010
  • Posts: 1651
  • Reputation 4
  • I Run This Chizz
    • View Profile
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #11 on: March 05, 2011, 11:20:20 PM »
Your problem is running 2xd2nt managers.
adding this file into your attack script will not alter your sorces fighting in anyway.
then you can run both on one manager and shouldnt be an issue
I Do Not Do Support Via PM.
I Can Help Xfer Anycore/Anyrealm/Anytime.
PM me here or on JSP : TheAmazingShac0

Offline jbkid

  • Newbie
  • *
  • Join Date: Feb 2011
  • Posts: 2
  • Reputation 0
  • I <3 PureKaoz.com
    • View Profile
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #12 on: March 06, 2011, 08:14:03 AM »
that fixed it, thanks for your help!

Offline xMACx

  • Newbie
  • *
  • Join Date: Mar 2011
  • Posts: 7
  • Reputation 0
  • 311 - I <3 Purekaoz.com
    • View Profile
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #13 on: March 29, 2011, 03:07:50 AM »
Hi i recently just made a cs javazon. I was wondering though, why is it that every time i try to copy/paste the selected text it pastes it sideways and not up and down like it shows in the scripts itself. would really like to use this bot and would appreciate anyhelp. paying anywhere from 50-100 forumgold on JSP for some1 to help me set this up. (I created an account on here just to get help but i like the site in general). thnx much appreciated -xMACX

Offline xMACx

  • Newbie
  • *
  • Join Date: Mar 2011
  • Posts: 7
  • Reputation 0
  • 311 - I <3 Purekaoz.com
    • View Profile
Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #14 on: March 29, 2011, 01:45:41 PM »
anyone? :<

PureKaoz.com - D2NT, Diablo 3 & Starcaft 2 Hacks

Re: [D2NT] Javazon/Bowazon Character Setup
« Reply #14 on: March 29, 2011, 01:45:41 PM »