|
You last visited: Today at 21:52
Advertisement
[Release] Muddy's D2NT
Discussion on [Release] Muddy's D2NT within the Diablo 2 Programming forum part of the Diablo 2 category.
01/22/2012, 17:28
|
#5386
|
elite*gold: 0
Join Date: Sep 2011
Posts: 16
Received Thanks: 0
|
was muss ich machen dass ich in einer datei alle items listen kann die der bot behalten soll und dann auch mulen soll?würde gerne von bluebirds nt bot das pickit nehmen
|
|
|
01/22/2012, 17:41
|
#5387
|
elite*gold: 0
Join Date: Jul 2006
Posts: 469
Received Thanks: 235
|
In der Charconfig musst du die Nips anpassen:
Code:
NTConfig_NIPFilePath.push("private/normal.nip");
NTConfig_NIPFilePath.push("private/magic_rare.nip");
NTConfig_NIPFilePath.push("private/set.nip");
NTConfig_NIPFilePath.push("private/unique.nip");
NTConfig_NIPFilePath.push("private/craft.nip");
NTConfig_NIPFilePath.push("private/temp.nip");
|
|
|
01/22/2012, 17:47
|
#5388
|
elite*gold: 0
Join Date: Sep 2011
Posts: 16
Received Thanks: 0
|
ja aber ich will magics,uniques,whites usw alles in einer datei haben
nun spinnt der bot total,der macht account name weg und will sich ohne was ein zu geben einloggen
|
|
|
01/22/2012, 23:17
|
#5389
|
elite*gold: 0
Join Date: May 2010
Posts: 9
Received Thanks: 0
|
mein Bot macht irgendwie keine Safe TP Message, alles andere funktioniert, von Bots und Leechbots usw ist alles in Ordnung, wenn ich jetzt aber andere Mitspieler in einem privaten Botrun einlade, dann brauchen die eben diese Safe TP Nachricht aber er posted einfach nichts.. ich post euch hier mal meine charconfig und meine botconfig rein
Code:
/**
* This file was modified by
* Check the programming section for updates and further scripts
* Last Update: 11:25 05.11.2011
*/
//------------------------------------------------------------------------------
// Delays
//------------------------------------------------------------------------------
var GameMinLength = 200; // Time in seconds, minimum game length, 180 seconds default (1 game/3 minutes).
var UnableToConnectRetry = 5; // Time in minutes to retry connecting on connection fail (real value is +/- 1 min).
var RealmDownRetry = 15; // Time in minutes to retry connecting on a realm down (default is 300 minutes).
var DisconnectedRetry = 5; // Time in minutes to retry on a disconnection (usually ip ban related).
var CdKeyInUseRetry = 5; // Time in minutes to retry on a cdkey in use error message (set to 0 to stop).
var ConnectingToBnetTimeout = 20; // Time in seconds to wait for a login to Time out and click cancel and retry.
var CharacterScreenTimeout = 10; // Time in seconds to wait for character screen to appear.
var PleaseWaitTimeout = 10; // Time in seconds to wait for a please wait popup.
var CreateGameThreshold = 10; // Time in seconds to wait between making games.
var CreateGameThresholdRandom = 5; // Time in seconds to randomly add +/- to the game create time.
var CreateGameTimeout = 15; // Time in seconds to register a failed to create game.
var WaitInLineTimeout = 60; // Time in seconds to wait in lines for a create game (60 second default).
var CharacterSelectDelay = 1000; // Time in milliseconds to wait before selecting a character on the char screen.
var GameDoesNotExistDelayMin = 10; // How long to wait when a Game Does Not Exist occurs - minimum - default 10 minutes.
var GameDoesNotExistDelayMax = 15; // How long to wait when a Game Does Not Exist occurs - maximum - default 15 minutes.
var GameDoesNotExistTimeout = 30; // How long to wait for the dialog to disappear (default 30 seconds, don't change this).
// Control
var LoginDelay = 5000; // Time in milliseconds to wait before submitting login information.
var ClickDelay = 2000; // Wait X milliseconds before next action after a click event.
var TextDelay = 2500; // Wait X milliseconds before next action after inserting text into a textbox.
var ClickDelayRandom = 500; // Random amount of Time in milliseconds to add to a click.
var TextDelayRandom = 500; // Random amount of Time in milliseconds to add to a text set.
// Channel
var WaitBeforeEnterChatMin = 1000; // Min time in milliseconds to wait before entering chat.
var WaitBeforeEnterChatMax = 2000; // Max time in milliseconds to wait before entering chat.
var WaitInChatBeforeActionsMin = 2000; // Min time in milliseconds to wait before joining channel.
var WaitInChatBeforeActionsMax = 3000; // Max time in milliseconds to wait before joining channel.
var GameAnnouncementDelay = 500; // Wait X milliseconds before posting the announcement message (don't set this too low!).
var GameAnnouncementDelayRandom = 50; // Random amount of time to add to a to the announcement delay.
var UseFileBackupTimeMax = 30; // Time in minutes that may pass since last file update - The backup File is updated at the beginning of every single game and is read everytime the name of your previous game is undefined (e.g. at restarts); Set to 0 to deactivate file backup.
//------------------------------------------------------------------------------
// Game settings
//------------------------------------------------------------------------------
var PlayersPerGame = 8; // Maximum number of players to be set when creating a game.
var CharacterDifference = 35; // Level difference to be set when creating games. Set to 0 not to use level restrictions.
var GameDescription = ""; // The description to be used for your game. Set to "" not to enter a game description.
var JoinRandomGamesChars = new Array("YourNameGoesHere");// Dynamic array that holds chars that are to join public games.
var JoinGameKeywords = new Array("dia", "baal"); // If your char is set to join public games, games will only be joined if the game name contains one of the given keywords.
//------------------------------------------------------------------------------
// Channel Settings
//------------------------------------------------------------------------------
var IgnoreWispers = false; // Set to true to ignore all incoming wispers from players that are not on your friendlist.
var JoinChatAfterLogin = true; // Join chat after login.
var JoinRandomChannel = false; // If this is true, will join a random channel, otherwise it will use the channel below..
var JoinChannelInChat = "Op pornobaal"; // Leave blank not to join a private channel.
var PerformChannelLogin = true; // Type ".login" once after joining the channel.
var ChannelUsers = new Array(); // Dynamic array that holds channel users.
// Add any char/account here that is supposed to perform chat actions/game announcements or join a private channel
ChannelUsers.push("pinapple");
// Or
ChannelUsers.push("orangensaft3");
// The following key expressions will be replaced by their actual values: %game --> "gamename-" <> %counter --> number of the next game <> %time --> time in seconds till game creation <> %password --> game password
// Note that the announcement will start after the first run, so there usually won't be any anncouncement right after login - If the gamename is undefined, the bot will try to load the backup file to announce the upcoming game properly.
var GameAnnouncement = "Creating %game%counter/// in about %time seconds.";
var ShowStatusOnStartup = true;
var JoinRetries = 5; // How many attempts before giving up the mule game?
var JoinRetryDelay = 55; // Seconds to wait between Retry Attempts.
var TimeBeforeMuleGame = 1; // Minutes to wait before creating the game.
var TimeAfterMule = 3; // Minutes to wait before logging back to bot account.
var WaitOnBlockedAccount = 2; // Minutes to wait if the mule account is currently being used by another char (this delay will be used up to 20 times).
//------------------------------------------------------------------------------
// Misc
//------------------------------------------------------------------------------
var MaximumLocationLoops = 5; // The maximum number of loops for a single location; if the window is does not respond and is caught in an infinite loop it will be restarted when the number of loops exceeds the one you specify here.
//---------------------------------------------------------------------------------------------------------------------------------------------------------
// DONT EDIT ANYTHING BELOW THIS!
//---------------------------------------------------------------------------------------------------------------------------------------------------------
// AutoMule Variables and Stuff
const DGDebug = false;
const AUTOMULE_READY = 1;
const AUTOMULE_FULL = 0;
const AUTOMULE_NOMULES = -1;
function AutomuleData()
{
this.InProgress = false;
this.PreventRecover = false;
this.IsWaiting = false;
this.State = "notmuling";
this.CurrentAccount = 0;
this.MuleIndex = 0;
this.IsReadyState = AUTOMULE_READY;
// Account creation variables
this.CreateAccount = false;
this.CharCreateNumber = -1;
this.RegMail = "";
this.MuleFull = false;
this.AccName;
this.AccPw;
this.AccPrefix;
this.AccSuffix = new Array();
this.NewAccPw = new Array();
this.UserNumbers;
this.IsLadder;
this.IsHC;
this.IsClassic;
this.RandomNameLength;
this.GameName;
this.GamePassword;
this.Mules = new Array();
this.MuleAccs;
this.MulePws;
this.NipFiles = new Array();
this.CharLoc;
this.MuleIsFullThreshold;
this.JoinBug;
this.NewCharBug = 0;
this.FullAuto = false;
}
var Automule = new AutomuleData();
Include("libs/controlInfo.ntl");
Include("libs/common/NTCommon.ntl");
Include("NTBot/mule_configs/NTConfig_AutoMule.ntl");
NT_LoadMuleConfig();
Include("libs/common/DGAutoMule.ntl");
// D2NT Manager Command
const D2NT_MGR_LOADING = 1;
const D2NT_MGR_READY = 2;
const D2NT_MGR_LOGIN = 3;
const D2NT_MGR_CREATE_GAME = 4;
const D2NT_MGR_INGAME = 5;
const D2NT_MGR_RESTART = 6;
const D2NT_MGR_CHICKEN = 7;
const D2NT_MGR_PRINT_STATUS = 8;
const D2NT_MGR_PRINT_LOG = 9;
var LastGameMade = GetTickCount();
var LastGameStatus = 0;
var NextGameMake = 0;
var InGameAt = 0;
var LocationLoops = new Array(2);
var ChatActionsDone = false;
var LastGameFailed = false;
var JoinedChannel = false;
var JustJoined = true;
var MadeAnnouncement = false;
// This is for recovering purpose, delete mulestate file is you get stuck
DGAM_ReadMuleStats();
MWAM_ReleaseUsedAccounts();
MWAM_InitializedMuleLoads(false);
var ControlData = new controlInfo();
function NTMain()
{
var _ingame, _scriptPath;
Delay(1000);
_ingame = false;
ConnectingToBnetTimeout *= 1000;
GameMinLength *= 1000;
CharacterScreenTimeout *= 1000;
PleaseWaitTimeout *= 1000;
CreateGameThreshold *= 1000;
CreateGameThresholdRandom *= 1000;
CreateGameTimeout *= 1000;
WaitInLineTimeout *= 1000;
GameDoesNotExistDelayMin *= 1000*60;
GameDoesNotExistDelayMax *= 1000*60;
GameDoesNotExistTimeout *= 1000;
ControlData.ClickDelay = ClickDelay;
ControlData.TextDelay = TextDelay;
ControlData.ClickDelayRandom = ClickDelayRandom;
ControlData.TextDelayRandom = TextDelayRandom;
RegisterEvent(EVENT_SCRIPTMSG, DGAM_MuleMsgEvents);
while(true)
{
if(me.ingame)
{
if(!InGameAt)
InGameAt = GetTickCount();
if(!_ingame)
{
if(Automule.InProgress)
{
if(DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "[Debug] Joined Mule Game");
switch(Automule.State)
{
case "notmuling": // Done or not yet started
// No... we really are not supposed to be here
Automule.InProgress = false;
ExitGame();
NTC_SendLogToOOG(NTC_LOG_COMMON, "AutoMule Error, try again.");
SetStatusText("ÿc1AutoMule Error... (Wait 60s)");
Delay(60000);
break;
case "mulestart": // Still on Bot Account
_scriptPath = "NTBot/bots/NTPermGameandMule.ntj";
break;
case "mule": //Muleing
case "mulefull": // Mule Full
case "done": // Next Account
case "recover": // Recovering
_scriptPath = "NTBot/bots/NTPickStuff.ntj";
break;
default:
_scriptPath = "NTBot/NTPermGameandMule.ntj";
break;
}
if(DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "Debug: Load " + _scriptPath);
RunGC();
if(Load(_scriptPath))
{
_ingame = true;
Automule.JoinBugCount = 0;
MadeAnnouncement = false;
LocationLoops[1] = 0;
MW_WriteBackupFile();
if(me.playtype > 0)
NT_SendEventToOOG(D2NT_MGR_INGAME, "Currently in Mule Game", 0);
else
NT_SendEventToOOG(D2NT_MGR_INGAME, "Oops, that's not gonna work honey.", 0);
LastGameStatus = 2; // in game successful
}
}
else
{
RunGC(); // run garbage collector between each game
if(Load("NTBot/MWBotGame.ntj"))
{
_ingame = true;
MadeAnnouncement = false;
LocationLoops[1] = 0;
MW_WriteBackupFile();
if(me.playtype > 0)
NT_SendEventToOOG(D2NT_MGR_INGAME, "In Game [IP:" + me.gameserverip.split(".")[3] + "]", 0);
else
NT_SendEventToOOG(D2NT_MGR_INGAME, "In Game", 0);
LastGameStatus = 2; // in game successful
}
}
}
Delay(1000);
}
else
{
if(Automule.IsWaiting)
Delay(1000);
else
{
if(_ingame)
{
_ingame = false;
NT_SendEventToOOG(D2NT_MGR_READY, "", 0);
Delay(4000);
}
if(Automule.InProgress)
DGAM_DoMuleLocationAction();
else
NT_LocationAction(ControlData.getLocation());
Delay(500);
}
}
}
}
function NT_LocationAction(location)
{
var _randomChannel, _output, _control;
MW_CheckLocationLoops(location);
switch(location.id)
{
case 3: // Lobby Chat
if(JustJoined)
{
JustJoined = false;
if(MW_ArrayContainsUser(ChannelUsers))
_output = "ÿc2Chat actions enabled!";
else
_output = "ÿc1Chat actions disabled!";
for(var i = 0; i < 3; i++)
{
SetStatusText(_output);
Delay(500);
SetStatusText("");
Delay(500);
}
if(IgnoreWispers)
{
Say("/o igw");
Delay(500);
}
}
if(!ChatActionsDone && MW_ArrayContainsUser(ChannelUsers))
{
ChatActionsDone = true;
Delay(Random(WaitInChatBeforeActionsMin, WaitInChatBeforeActionsMax));
if(!JoinedChannel && (JoinRandomChannel || JoinChannelInChat != ""))
{
_randomChannel = NT_GetRandomString(Random(3,10));
SetStatusText("ÿc8Joining Channel ÿc;" + (JoinRandomChannel ? _randomChannel : JoinChannelInChat));
Delay(500);
Say("/join " + (JoinRandomChannel ? _randomChannel : JoinChannelInChat));
JoinedChannel = true;
if(PerformChannelLogin)
{
SetStatusText("ÿc8Channel Login...");
Say(".login");
Delay(1000);
}
}
}
case 1: // Lobby
if(location.id == 1 && JoinChatAfterLogin)
{
Delay(Random(WaitBeforeEnterChatMin, WaitBeforeEnterChatMax));
ControlData.click(ControlData.controls.lobby.button.enterChat);
break;
}
if(GetTickCount() > NextGameMake)
{
LastGameFailed = false;
switch(LastGameStatus)
{
case 0:
if(MW_ArrayContainsUser(JoinRandomGamesChars))
{
_control = ControlData.get(ControlData.controls.lobby.button.join);
if(_control && _control.pressed)
{
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
}
ControlData.click(ControlData.controls.lobby.button.join);
}
else
{
_control = ControlData.get(ControlData.controls.lobby.button.create);
if(_control && _control.pressed)
{
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
}
ControlData.click(ControlData.controls.lobby.button.create);
}
NextGameMake = GetTickCount() + CreateGameTimeout; // set our timeout
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
break;
case 1: // game failed, rollover to reset timer
InGameAt = GetTickCount();
LastGameFailed = true;
Delay(5000);
case 2:
NT_OutputGameLength();
LastGameStatus = 0;
NT_SetNextGameMake();
if(LastGameFailed)
{
SetStatusText("ÿc1Failed to join!");
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Game creation failed!", 0);
Delay(1000);
}
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
break;
}
}
else
{
if(JoinChannelInChat && !MadeAnnouncement && MW_ArrayContainsUser(ChannelUsers))
{
if(MW_AnnounceGame())
MadeAnnouncement = true;
}
MW_TimeoutDelay(NextGameMake - GetTickCount(), location, !MW_ArrayContainsUser(JoinRandomGamesChars));
}
break;
case 2: // Waiting In Line
if(GetTickCount() - LastGameMade > WaitInLineTimeout)
ControlData.click(ControlData.controls.lobby.inLine.button.cancel);
break;
case 4: // Create Game
if(!MW_ArrayContainsUser(JoinRandomGamesChars))
{
if(!ControlData.get(ControlData.controls.lobby.create.editBox.gameName))
{
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
}
_control = ControlData.get(ControlData.controls.lobby.create.button.useCharacterDifference);
if(_control)
{
if(CharacterDifference == 0 && _control.pressed || CharacterDifference >= 1 && CharacterDifference <= 99 && !_control.pressed)
{
ControlData.click(ControlData.controls.lobby.create.button.useCharacterDifference);
Delay(1000);
}
}
_control = ControlData.get(ControlData.controls.lobby.create.editBox.maxNumberOfPlayers);
if(_control)
{
if(PlayersPerGame >= 1 && PlayersPerGame <= 8 && _control.text != PlayersPerGame.toString())
{
ControlData.setText(ControlData.controls.lobby.create.editBox.maxNumberOfPlayers, PlayersPerGame.toString());
Delay(1000);
}
}
_control = ControlData.get(ControlData.controls.lobby.create.editBox.characterDifference);
if(_control)
{
if(_control.text != CharacterDifference.toString())
{
ControlData.setText(ControlData.controls.lobby.create.editBox.characterDifference, CharacterDifference.toString());
Delay(1000);
}
}
if(GameDescription)
{
ControlData.setText(ControlData.controls.lobby.create.editBox.gameDescription, GameDescription);
Delay(1000);
}
NT_SendEventToOOG(D2NT_MGR_CREATE_GAME, location.name, 0);
NT_LocationTimeout(5000, location);
LastGameMade = GetTickCount();
LastGameStatus = 1; // pending creation
}
break;
case 5: // Join Game
if(MW_ArrayContainsUser(JoinRandomGamesChars))
{
var _games, _game;
_games = ControlData.get(ControlData.controls.lobby.join.textBox.gameList).GetText();
_game = "";
if(_games)
{
for(var i = 0; i < _games.length; i++)
{
for(var j = 0; j < JoinGameKeywords.length; j++)
{
if(_games[i].toLowerCase().indexOf(JoinGameKeywords[j].toLowerCase()) > -1)
{
_game = _games[i];
i = _games.length;
break;
}
}
}
}
if(_game != "")
{
SetStatusText("ÿc8Joining Game: " + _game);
Delay(250);
ControlData.setText(ControlData.controls.lobby.join.editBox.gameName, _game);
Delay(1000);
ControlData.click(ControlData.controls.lobby.join.button.joinGame);
NT_LocationTimeout(5000, location);
LastGameMade = GetTickCount();
LastGameStatus = 1; // pending creation
}
else
Delay(2500);
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
}
break;
case 6: // Ladder
break;
case 7: // Channel List
break;
case 8: // Main Menu
if(ControlData.getCurrentRealmIndex() == me.gatewayid)
{
NT_OutputGameLength();
ControlData.click(ControlData.gameTypes[me.playtype]);
}
else
ControlData.click(ControlData.controls.mainMenu.button.gateway);
break;
case 9: // Login
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
Delay(LoginDelay);
ControlData.setText(ControlData.controls.login.editBox.accountName, me.account);
NT_SendEventToOOG(D2NT_MGR_LOGIN, location.name, 0);
NT_LocationTimeout(5000, location);
break;
case 10: // Login Error (this is a fatal error, so stop)
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 10);
Delay(3500);
break;
case 11: // Unable To Connect
MW_TimeoutDelay(UnableToConnectRetry*60*1000, location);
ControlData.click(ControlData.controls.login.unableToConnect.button.ok);
break;
case 12: // Character Select
var _time, _control;
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
for(_time = 0 ; _time < CharacterScreenTimeout ; _time += 500)
{
_control = ControlData.get(ControlData.controls.characterSelect.textBox.characterInfo[me.charloc]);
if(_control && _control.GetText() != undefined)
break;
Delay(500);
}
if(_time < CharacterScreenTimeout)
{
Delay(CharacterSelectDelay);
ControlData.click(ControlData.controls.characterSelect.textBox.characters[me.charloc], 0, 0, 1);
ControlData.click(ControlData.controls.characterSelect.textBox.characterInfo[me.charloc], 0, 0, 1);
// reset last game made, so it doesnt make a game immediately
InGameAt = 0;
NT_SetNextGameMake();
}
else
{
ControlData.click(ControlData.controls.characterSelect.button.exit);
MW_TimeoutDelay(RealmDownRetry*60*1000, location);
}
break;
case 13: // Realm Down - Character Select screen
ControlData.click(ControlData.controls.characterSelect.button.exit);
MW_TimeoutDelay(RealmDownRetry*60*1000, location);
break;
case 14: // Character Select - Disconnected
MW_TimeoutDelay(DisconnectedRetry*60*1000, location);
ControlData.click(ControlData.controls.characterSelect.disconnected.button.ok);
break;
case 15: // New Character
break;
case 16: // Character Select - Please Wait popup
if(!NT_LocationTimeout(PleaseWaitTimeout, location))
ControlData.click(ControlData.controls.characterSelect.pleaseWait.button.cancel);
break;
case 17: // Lobby - Lost Connection - just click okay, since we're toast anyway
ControlData.click(ControlData.controls.lobby.lostConnection.button.ok);
break;
case 18: // D2 Splash
ControlData.click(ControlData.controls.d2Splash.textBox.copyright);
break;
case 19: // Login - Cdkey In Use
MW_TimeoutDelay(CdKeyInUseRetry*60*1000, location);
ControlData.click(ControlData.controls.login.cdkeyInUse.button.ok);
break;
case 20: // Single Player - Select Difficulty
ControlData.click(ControlData.singlePlayerDifficulties[me.diff]);
break;
case 21: // Main Menu - Connecting
if(!NT_LocationTimeout(ConnectingToBnetTimeout, location))
ControlData.click(ControlData.controls.mainMenu.connecting.button.cancel);
break;
case 22: // Login - Invalid Cdkey (classic or xpac)
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 3600);
Delay(3500);
break;
case 23: // Character Select - Connecting
if(!NT_LocationTimeout(CharacterScreenTimeout, location))
ControlData.click(ControlData.controls.characterSelect.button.exit);
break;
case 24: // Server Down - not much to do but wait..
break;
case 25: // Lobby - Please Wait
if(!NT_LocationTimeout(PleaseWaitTimeout, location))
ControlData.click(ControlData.controls.lobby.pleaseWait.button.cancel);
break;
case 26: // Lobby - Game Name Exists
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Game already exists", 0);
SetStatusText("ÿc1Game already exists!");
InGameAt = 0;
LastGameStatus = 0;
NT_SetNextGameMake();
NT_LocationTimeout(15000, location);
break;
case 27: // Gateway Select
ControlData.clickRealmEntry(me.gatewayid);
ControlData.click(ControlData.controls.gateway.button.ok);
break;
case 28: // Lobby - Game Does Not Exist
InGameAt = Random(GameDoesNotExistDelayMin, GameDoesNotExistDelayMax);
LastGameStatus = 0;
NT_SetNextGameMake();
NT_LocationTimeout(GameDoesNotExistTimeout, location);
break;
}
}
function NT_SendEventToOOG(locationId, statusString, pendingTime)
{
return SendCopyData("D2NT Manager", null, (locationId<<16)|pendingTime, statusString);
}
function NT_SetNextGameMake()
{
LastGameMade = GetTickCount();
NextGameMake = LastGameMade + CreateGameThreshold + Random(0 - CreateGameThresholdRandom, CreateGameThresholdRandom) + InGameAt;
InGameAt = 0;
ChatActionsDone = false;
}
function NT_OutputGameLength()
{
var _duration;
if(InGameAt)
{
_duration = GetTickCount() - InGameAt;
if(_duration < GameMinLength)
InGameAt = GameMinLength - _duration;
else
InGameAt = 0;
}
}
function NT_LocationTimeout(time, location)
{
var _endtime = GetTickCount() + time;
while(ControlData.getLocation().id == location.id && _endtime > GetTickCount())
{
if(LocationLoops[1] > 1)
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "] [" + LocationLoops[1] + "]", 0);
else
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "]", 0);
Delay(1000);
}
return (ControlData.getLocation().id != location.id);
}
function MW_TimeoutDelay(time, location, showNextGameStatus)
{
var _gamename, _outputString, _timeString;
if(arguments.length < 3)
showNextGameStatus = false;
_endtime = GetTickCount() + time;
_gamename = me.gamename;
_timeString = "";
if(!_gamename)
{
_gamename = MW_ReadBackupFile(0);
if(_gamename)
SetStatusText("ÿc8Using File Backup...");
}
while(_endtime > GetTickCount())
{
_timeString = " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "]";
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + _timeString , 0);
if(showNextGameStatus)
{
if(LastGameFailed && parseInt(_endtime-GetTickCount()) > CreateGameThreshold && parseInt((_endtime-GetTickCount())/1000) % 30 >= 0 && parseInt((_endtime-GetTickCount())/1000) % 30 <= 5)
{
_outputString = "ÿc1Last game failed!";
_timeString = "";
}
else if(parseInt((_endtime-GetTickCount())/1000) >= 0)
{
if(_gamename && MW_GetGameCounter(_gamename, false))
_outputString = "ÿc8Next game: " + MW_GetGameName(_gamename) + MW_GetGameCounter(_gamename, false);
else
_outputString = "ÿc8Game creation pending... ";
}
MWC_SetStatusText(_outputString, _timeString);
if(me.ingame)
_endtime = GetTickCount();
}
Delay(1000);
}
if(showNextGameStatus)
SetStatusText("ÿc8Creating game...");
return;
}
function NT_GetRandomString(length)
{
_retString = "";
_charSet = "0123456789abcdefghijklmnopqrstuvwxyz";
while(length--)
{
_retString += _charSet.charAt(Random(0, _charSet.length - 1));
Delay(1);
}
return _retString;
}
function MW_GetGameName(lastGameString)
{
if(!lastGameString)
return "";
else
return lastGameString.substr(0, lastGameString.lastIndexOf('-') + 1);
}
function MW_GetGameCounter(lastGameString, simple)
{
var _count, _countString;
if(!lastGameString)
return "-1";
else
{
_countString = lastGameString.slice(lastGameString.lastIndexOf('-') + 1);
if(_countString[0] == '0')
_countString = _countString.substr(1);
_count = parseInt(_countString) + 1;
if(_count == 100)
_count = 0;
if(!simple)
{
if(_count <= 9)
return '0' + _count;
}
return _count;
}
}
function MW_ArrayContainsUser(array)
{
for(var i = 0; i < array.length; i++)
{
if(me.account.toLowerCase() == array[i].toLowerCase() || me.charname.toLowerCase() == array[i].toLowerCase())
return true;
}
return false;
}
function MW_ReadBackupFile(type)
{
var _fhandle, _buffer, _time, _now, _retValue;
_fhandle = FileOpen("/Logs/Temporary Data/" + me.charname + ".channel", 2);
_retValue = "";
_now = new Date();
if(_fhandle && _now)
{
_buffer = _fhandle.ReadLine();
if(_buffer)
{
_time = parseInt(_buffer);
if(_now.getTime() - _time < UseFileBackupTimeMax*6E4)
{
_retValue = _fhandle.ReadLine();
if(type > 0)
_retValue = _fhandle.ReadLine();
}
}
_fhandle.Close();
}
else if(_fhandle)
_fhandle.Close();
return _retValue;
}
function MW_WriteBackupFile()
{
var _fhandle, _now;
if(UseFileBackupTimeMax == 0)
return false;
_fhandle = FileOpen("/Logs/Temporary Data/" + me.charname + ".channel", 1);
_now = new Date();
if(_fhandle && _now)
{
_fhandle.WriteLine(_now.getTime());
_fhandle.WriteLine(me.gamename);
_fhandle.WriteLine(me.gamepassword);
_fhandle.Close();
return true;
}
else if(_fhandle)
_fhandle.Close();
return false;
}
function MW_CheckLocationLoops(location)
{
if(!location)
return false;
if(!LocationLoops[0] || location.id != LocationLoops[0].id)
{
LocationLoops[0] = location;
LocationLoops[1] = 0;
}
else if(LocationLoops[0].id != 5)
{
LocationLoops[1]++;
if(LocationLoops[1] >= MaximumLocationLoops)
{
if(LocationLoops[1] < 1000)
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Location Loop Restart!;ÿc1Location Loops: " + LocationLoops[1] + "\nÿBE0000Location: " + LocationLoops[0].name + "\nÿBE0000Location ID: " + LocationLoops[0].id, 0);
LocationLoops[1] = 1000; // Make sure the location loop notification is only shown once
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 0);
}
}
return true;
}
function MW_AnnounceGame()
{
var _gamePass, _gameName, _gameText, _delay;
_gameName = me.gamename;
if(!_gameName)
_gameName = MW_ReadBackupFile(0);
_gamePass = me.gamepassword;
if(!_gamePass)
_gamePass = MW_ReadBackupFile(1);
if(_gameName && !me.ingame)
{
_delay = (GameAnnouncementDelay > 5000) ? GameAnnouncementDelay : 5000;
_delay += (GameAnnouncementDelayRandom > 500) ? Random(0, GameAnnouncementDelayRandom) : 500;
_gameText = GameAnnouncement.replace("%password", ((_gamePass) ? _gamePass : "N/A"));
_gameText = _gameText.replace("%game", MW_GetGameName(_gameName));
_gameText = _gameText.replace("%counter", MW_GetGameCounter(_gameName, false));
_gameText = _gameText.replace("%time", parseInt((NextGameMake - GetTickCount() - _delay + ClickDelay + TextDelay) / 1000 + 5));
if(_gameText.indexOf("NaN") > -1)
return false;
if(parseInt((NextGameMake - GetTickCount() - _delay + ClickDelay + TextDelay) / 1000) > 3)
{
Delay(_delay);
return Say(_gameText);
}
}
return false;
}
Code:
/**
* This file was modified by
* Check the programming section for updates and further scripts
* Last Update: 23:10 29.08.2011
*
* Hotkey Description
*
* Pause/Break Pauses the current bot script.
* Page up (PgUp) Skips the current bot script.
* Page down (PgDn) Repeats the previous bot script
* Home (Pos1) Shows your current coordinates and areaid.
* End Shows current ping in status text bar.
* Insert (Ins) Logs all items on your char to either XML or TXT.
* Delete (Del) Exits the game. NOTE: Always use this key to leave a game!
* Backspace Force trigger auto mule. NOTE: Won't work unless auto mule is actually activated for the current char.
*/
Include("NTBot/char_configs/MWConfig_GlobalSettings.ntl");
var NTConfig_UseRedemptionHP;
var NTConfig_UseRedemptionMP;
function NT_LoadConfig()
{
MW_LoadGlobalSettings();
//------------------------------------------------------------------------------
//
// Run Configuration
//
//------------------------------------------------------------------------------
// Use the following syntax for activating botscripts: MWConfig_Script.push([<ScriptName>, <Script runtime in minutes (0 is infinite)>]);
// ***************** Current schedule ******************
// MWConfig_Script.push(["NTAndariel.ntj", 5]);
// MWConfig_Script.push(["NTMausoleum.ntj", 10]); MWConfig_ClearPathSpectypes.Mausoleum = 0; MWConfig_ClearAreaSpectypes.Mausoleum = 0x01; NTConfig_KillBloodRaven = true;
// MWConfig_Script.push(["NTPit.ntj", 10]); MWConfig_ClearPathSpectypes.Pit = 0; MWConfig_ClearAreaSpectypes.Pit = 0x01; NTConfig_ClearPitLevel1 = 2; // 0 : don't clear, 1 : clear path only, 2 : clear all
// MWConfig_Script.push(["NTCountess.ntj", 5]); MWConfig_ClearPathSpectypes.Countess = 0; MWConfig_ClearAreaSpectypes.Countess = 0;
// MWConfig_Script.push(["NTSummoner.ntj", 5]); NTConfig_KillFireEye = false; MWConfig_ClearPathSpectypes.Summoner = 0;
// MWConfig_Script.push(["NTAncientTunnels.ntj", 10]); MWConfig_ClearPathSpectypes.AncientTunnels = 0x01; MWConfig_ClearAreaSpectypes.AncientTunnels = 0x01;
// MWConfig_Script.push(["MWKurastSewers.ntj", 5]); MWConfig_ClearPathSpectypes.KurastSewers = 0;
// MWConfig_Script.push(["NTTravincal.ntj", 5]);
//MWConfig_Script.push(["NTMephisto.ntj", 5]); MWConfig_OpenMephistoChest = true; MWConfig_MephistoClearArea = false;
// MWConfig_Script.push(["MWSuperChests.ntj", 20]); MWConfig_SuperChestClearAreaRadius = 5; MWConfig_SuperChestAreas = ["Arachnid Lair", "Swampy Pit Level 3", "Flayer Dungeon", "Abbadon", "Pit of Acheron", "Drifter Cavern", "Infernal Pit", "Icy Cellar"];
// MWConfig_Script.push(["NTNihlathak.ntj", 5]); MWConfig_ClearPathSpectypes.Nihlathak = 0; NTConfig_PindleskinExtension = false; MWConfig_SkipOnTombVipers = true;
// MWConfig_Script.push(["NTDiablo.ntj", 10]); MWConfig_KillFullInfectorMob = true; MWConfig_StartAtStar = false; MWConfig_IgnoreSealOpeningErrors = false; MWConfig_FastDia = false;
//MWConfig_Script.push(["NTEldritch.ntj", 5]); NTConfig_ShenkExtension = true;
MWConfig_Script.push(["NTBaal.ntj", 10]); NTConfig_KillBaal = true; MWConfig_SkipBaalOnDolls = false; MWConfig_SkipBaalOnSouls = false; MWConfig_DoBaalPreAttack = true;
// *****************************************************
//------------------------------------------------------------------------------
// Available Scripts
//------------------------------------------------------------------------------
/* NOTE:
// The scripts below are actually commented out; to add a script, copy one of the lines below and add it to the current schedule above. ;)
// You should also get yourself a decent editor that supports syntax highlighting for JavaScript, I'd recommend Notepad++. (http://notepad-plus-plus.org/download/)
// *********************** Act I ***********************
MWConfig_Script.push(["NTMausoleum.ntj", 10]); MWConfig_ClearPathSpectypes.Mausoleum = 0; MWConfig_ClearAreaSpectypes.Mausoleum = 0x01; NTConfig_KillBloodRaven = true;
MWConfig_Script.push(["NTTristram.ntj", 10]); NTConfig_KillRakanishu = true;
MWConfig_Script.push(["NTHole.ntj", 10]); MWConfig_ClearPathSpectypes.Hole = 0; MWConfig_ClearAreaSpectypes.Hole = 0x01; NTConfig_ClearHoleLevel1 = 1; // 0 : don't clear, 1 : clear path only, 2 : clear all
MWConfig_Script.push(["NTTreehead.ntj", 10]);
MWConfig_Script.push(["MWColdcrow.ntj", 10]); MWConfig_ClearCaveMode = 0; // 0: Only kill coldcrow; 1: Clear Cave Level 1; 2: Clear both Cave Level 1 & 2
MWConfig_Script.push(["NTCountess.ntj", 5]); MWConfig_ClearPathSpectypes.Countess = 0; MWConfig_ClearAreaSpectypes.Countess = 0;
MWConfig_Script.push(["NTPit.ntj", 10]); MWConfig_ClearPathSpectypes.Pit = 0; MWConfig_ClearAreaSpectypes.Pit = 0x01; NTConfig_ClearPitLevel1 = 2; // 0 : don't clear, 1 : clear path only, 2 : clear all
MWConfig_Script.push(["NTAndariel.ntj", 10]);
// *********************** Act II **********************
MWConfig_Script.push(["NTRadament.ntj", 10]); MWConfig_ClearPathSpectypes.Radament = 0;
MWConfig_Script.push(["MWMaggotsLair.ntj", 10]); MWConfig_ClearPathSpectypes.MaggotsLair = 0; MWConfig_ClearAreaSpectypes.MaggotsLair = 0x01;
MWConfig_Script.push(["NTAncientTunnels.ntj", 10]); MWConfig_ClearPathSpectypes.AncientTunnels = 0; MWConfig_ClearAreaSpectypes.AncientTunnels = 0x01;
MWConfig_Script.push(["NTSummoner.ntj", 5]); NTConfig_KillFireEye = false; MWConfig_ClearPathSpectypes.Summoner = 0;
MWConfig_Script.push(["NTDuriel.ntj", 10]); MWConfig_ClearPathSpectypes.Duriel = 0;
// ********************** Act III **********************
MWConfig_Script.push(["MWFlayerJungle.ntj", 10]); MWConfig_ClearAreaSpectypes.FlayerJungle = 0x01;
MWConfig_Script.push(["MWKurastSewers.ntj", 5]); MWConfig_ClearPathSpectypes.KurastSewers = 0;
MWConfig_Script.push(["MWKurastTemples.ntj", 5]); MWConfig_ClearPathSpectypes.KurastTemples = 0; MWConfig_ClearAreaSpectypes.KurastTemples = 0x01;
MWConfig_Script.push(["NTTravincal.ntj", 5]);
MWConfig_Script.push(["NTMephisto.ntj", 5]); MWConfig_OpenMephistoChest = true; MWConfig_MephistoClearArea = true;
// *********************** Act IV **********************
MWConfig_Script.push(["NTIzual.ntj", 5]); MWConfig_ClearPathSpectypes.Izual = 0;
MWConfig_Script.push(["MWRiverOfFlame.ntj", 10]); MWConfig_ClearAreaSpectypes.RiverOfFlame = 0x01;
MWConfig_Script.push(["NTHephasto.ntj", 10]); MWConfig_ClearPathSpectypes.Hephasto = 0;
MWConfig_Script.push(["NTDiablo.ntj", 10]); MWConfig_KillFullInfectorMob = true; MWConfig_StartAtStar = false; MWConfig_IgnoreSealOpeningErrors = false; MWConfig_FastDia = true;
// *********************** Act V ***********************
MWConfig_Script.push(["MWAbbadon.ntj", 10]); MWConfig_ClearPathSpectypes.Abbadon = 0; MWConfig_ClearAreaSpectypes.Abbadon = 0x01;
MWConfig_Script.push(["MWPitOfAcheron.ntj", 10]); MWConfig_ClearPathSpectypes.PitOfAcheron = 0; MWConfig_ClearAreaSpectypes.PitOfAcheron = 0x01;
MWConfig_Script.push(["MWInfernalPit.ntj", 10]); MWConfig_ClearPathSpectypes.InfernalPit = 0; MWConfig_ClearAreaSpectypes.InfernalPit = 0x01;
MWConfig_Script.push(["MWHallsOfPain.ntj", 15]); MWConfig_ClearAreaSpectypes.HallsOfPain = 0x01; MWConfig_ClearHallsOfAnguish = true;
MWConfig_Script.push(["NTPindleskin.ntj", 5]); NTConfig_NihlathakExtension = false; MWConfig_SkipOnTombVipers = true;
MWConfig_Script.push(["NTEldritch.ntj", 5]); NTConfig_ShenkExtension = true;
MWConfig_Script.push(["NTThreshSocket.ntj", 5]); MWConfig_ClearPathSpectypes.ThreshSocket = 0;
MWConfig_Script.push(["NTFrozenRiver.ntj", 10]); MWConfig_ClearPathSpectypes.FrozenRiver = 0; MWConfig_ClearAreaSpectypes.FrozenRiver = 0x01;
MWConfig_Script.push(["NTGlacialTrail.ntj", 10]); MWConfig_ClearPathSpectypes.GlacialTrail = 0; MWConfig_ClearAreaSpectypes.GlacialTrail = 0x01;
MWConfig_Script.push(["NTIcyCellar.ntj", 5]); MWConfig_ClearPathSpectypes.IcyCellar = 0; MWConfig_ClearAreaSpectypes.IcyCellar = 0x01;
MWConfig_Script.push(["NTNihlathak.ntj", 5]); MWConfig_ClearPathSpectypes.Nihlathak = 0; NTConfig_PindleskinExtension = false; MWConfig_SkipOnTombVipers = true;
MWConfig_Script.push(["MWWorldstoneKeep.ntj", 10]); MWConfig_ClearAreaSpectypes.WorldstoneKeep = 0x01; MWConfig_SkipLevelOnWitches = true; MWConfig_SkipLevelOnSouls = false; MWConfig_SkipLevelOnDeathLords = true;
MWConfig_Script.push(["NTBaal.ntj", 10]); NTConfig_KillBaal = true; MWConfig_SkipBaalOnDolls = true; MWConfig_SkipBaalOnSouls = false; MWConfig_DoBaalPreAttack = true; MWConfig_ClearPathSpectypes.Baal = 0;
// *********************** Misc ************************
MWConfig_Script.push(["MWAuraStack.ntj", 10]); MWConfig_StackRepetitions = 100; MWConfig_ResetMercWeaponAfterStacking = false;
MWConfig_Script.push(["MWSuperChests.ntj", 20]); MWConfig_SuperChestClearAreaRadius = 10; MWConfig_SuperChestAreas = ["Cave Level 2", "Mausoleum", "Hole Level 2", "Pit Level 2", "Sewers Level 3", "Halls of the Dead Level 2", "Stony Tomb Level 2", "Maggot's Lair Level 3", "Ancient Tunnels", "Tal Rasha's Tomb", "Arachnid Lair", "Swampy Pit Level 3", "Flayer Dungeon", "Sewers Level 2", "Abbadon", "Pit of Acheron", "Drifter Cavern", "Infernal Pit", "Icy Cellar", "Halls of Pain"];
MWConfig_Script.push(["MWRush.ntj", 0]); MWConfig_IsRusher = true;
MWConfig_Script.push(["MWWaypointCatcher.ntj", 0]); MWConfig_WaypointCatcherActs = [1, 2, 3, 4, 5]; MWConfig_TPWaypoints = true; MWConfig_SkipHallsOfPain = true; MWConfig_ClearWaypointPaths = false;
MWConfig_Script.push(["MWIdleMode.ntj", 0]); MWConfig_IdleModeRuntime = 5; // Runtime in Minutes
MWConfig_Script.push(["NTCows.ntj", 10]);
MWConfig_Script.push(["MWBloodyRejuvs.ntj", 10]);
MWConfig_Script.push(["MWOrganHarvest.ntj", 10]); MWConfig_EnterInvalidUberPortals = true; MWConfig_PauseOnLackOfKeys = false; MWConfig_IntendedUberPortal = 0; // Matron's Den: 133; Forgotten Sands: 134; Furnace Of Pain: 135;
MWConfig_Script.push(["MWUberTristram.ntj", 10]); MWConfig_PauseOnLackOfOrgans = false; MWConfig_PauseOnKeptTorch = false;
MWConfig_Script.push(["MWAnyasBargain.ntj", 10]); MWConfig_ShoppingMinGold = 500000; MWConfig_ShoppingAttempts = 200;
// ************ Leech and friends by lanara ************
MWConfig_Script.push(["NTDiabloLeechFight.ntj", 10]); MWConfig_StartAtStar = true; MWConfig_EnterUnsafeTP = true; NTConfig_PreBuff = true; MWConfig_IgnoreSealOpeningErrors = true; NTConfig_Leader = "LeaderNameGoesHere";
MWConfig_Script.push(["NTBaalLeech.ntj", 10]); NTConfig_KillBaal = true; MWConfig_EnterUnsafeTP = false; NTConfig_Leader = "LeaderNameGoesHere";
MWConfig_Script.push(["NTBaalLeechFight.ntj", 10]); NTConfig_KillBaal = true; MWConfig_DoBaalPreAttack = true; MWConfig_EnterUnsafeTP = true; NTConfig_Leader = "LeaderNameGoesHere";
*/
//------------------------------------------------------------------------------
// Misc Configuration
//------------------------------------------------------------------------------
NTConfig_SkipHealLife = 90; // If you have more than this percent of life, you won't go to a healer.
NTConfig_SkipHealMana = 70; // 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.
// Exit game or to reset your Enigma if Teleport skill is missing (due to identifying an item having +x to Teleport [Sorceress only]). WARNING: Activating this feature may - though not likely will - result in the loss of your enigma. Use at your own risk and make sure your char has sufficient strength!
// 0: Don't do anything; 1: Reset armor; 2: Exit game
MWConfig_ResetArmorMode = 0;
//------------------------------------------------------------------------------
// Potion Configuration
//------------------------------------------------------------------------------
NTConfig_LifeThresh = 70; // Drink a normal potion if under this percent of life.
NTConfig_LifeRejuvThresh = 60; // 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 = 1; // Drink a rejuvenation potion if under this percent of mana.
NTConfig_MercLifeThresh = 50; // This is the threshold to use a life potion on your merc in percent.
NTConfig_MercRejuvThresh = 30; // This is the threshold to use a rejuv potion on your merc in percent.
//------------------------------------------------------------------------------
// Chicken Configuration
//------------------------------------------------------------------------------
// This is your chicken life. If you go below this threshhold, your char will exit the game. You can either enter a percentage (1-100), an absolute threshold (>100) or 0 to deactivate life chicken.
NTConfig_LifeChicken = 30;
// This is your chicken mana. If you go below this threshhold, your char will exit the game. You can either enter a percentage (1-100), an absolute threshold (>100) or 0 to deactivate mana chicken.
NTConfig_ManaChicken = 0;
// This is your merc's chicken life in percent. If your merc goes below this threshhold, your char will exit the game.
NTConfig_MercChicken = 0;
// Whether or not to disable chicken when you pause the bot.
MWConfig_DisableChickenOnPause = true;
//------------------------------------------------------------------------------
// Inventory Configuration
//------------------------------------------------------------------------------
// Each number represents a slot in your inventory.
// Set to 0 if the slot and its content must not be touched.
// Set to 1 to allow access to this slot.
// Set to 2 to select the slot that is used for storing keys. (if keys are kept at another slot, your char will try to move them)
NTConfig_Columns[0] = [1,1,1,1,1,1,1,1,2,0];
NTConfig_Columns[1] = [1,1,1,1,1,1,1,1,1,0];
NTConfig_Columns[2] = [1,1,1,1,1,1,1,1,1,0];
NTConfig_Columns[3] = [1,1,1,1,1,1,1,1,1,0];
// Number of free columns. If less full columns are free stashing is set. Call SetFreeColumns(NTConfig_Columns) to always stash right away (recommended).
NTConfig_FreeSpace = SetFreeColumns(NTConfig_Columns);
// Maximum gold amount carried before going to stash.
NTConfig_MinGoldToStash = 100000;
// Set to true if your char is supposed to carry, buy and pick up keys. You do not need to add keys to your .nip files, they will be picked up anyway if this is set to true.
MWConfig_CarryKeys = true;
//------------------------------------------------------------------------------
// Belt Configuration
//------------------------------------------------------------------------------
// Available types : "hp" = health, "mp" = mana, "rv" = rejuvenation.
// Define how many columns are used for each potion type.
MWConfig_BeltColType["hp"].Columns = 1;
MWConfig_BeltColType["mp"].Columns = 1;
MWConfig_BeltColType["rv"].Columns = 2;
// Define minimum number of potions per column. If the actual number of potions in a column is below this value, your char will visit a merchant when in town in order to buy potions.
MWConfig_BeltColType["hp"].MinPots = 3;
MWConfig_BeltColType["mp"].MinPots = 3;
// Visit Town and buy potions if your char lacks mana when trying to loot a corpse or teleport.
MWConfig_BuyPotionsOnLackOfMana = true;
// Set to true to replace low quality potions with higher quality potions that just dropped.
MWConfig_ReplaceLowQualityPotions = true;
//-----------------------------------------------------------------------------------
// NipFile Configuration
//-----------------------------------------------------------------------------------
NTConfig_NIPFilePath.push("private/normal.nip");
NTConfig_NIPFilePath.push("private/magic_rare.nip");
NTConfig_NIPFilePath.push("private/set.nip");
NTConfig_NIPFilePath.push("private/unique.nip");
NTConfig_NIPFilePath.push("private/craft.nip");
NTConfig_NIPFilePath.push("private/temp.nip");
//------------------------------------------------------------------------------
// Pickit Configuration
//------------------------------------------------------------------------------
// Radius to check for dropped items. NOTE: The maximum is at about ~75, entering higher values will not have any effect.
NTConfig_SnagRange = 70;
// Set to true to check for dropped items whenever you kill a monster. (Recommended value to avoid crashes: false)
MWConfig_PickItemsInstantly = true;
//------------------------------------------------------------------------------
// Chest Configuration
//------------------------------------------------------------------------------
// Select which containers shall be looted. 0: None; 1: Super Chests, 2: All
MWConfig_OpenContainerMode = 2;
// Set to true to check for dropped items right after opening a chest. NOTE: This will slow down your runs and therefore should definately be set to false when doing private games.
MWConfig_PickChestLootsInstantly = true;
// This is the range being checked for chests after clearing an area or room. NOTE: You should not set this too high, 30 is a good value.
MWConfig_OpenChestsRange = 30;
// If you do not like to open chests in a certain area, you can its areaid as an exception below. NOTE: All areaids can be found in "sdk\areas.txt".
// MWConfig_ChestExceptions.push(<areaid1>, <areaid2>, <areaidn>);
//------------------------------------------------------------------------------
// Cubing Configuration
//------------------------------------------------------------------------------
// Set to true to enable cubing and crafting. NOTE: The recipes are added in the global config by default. If you like to craft certain recipe only using this very char, add those recipes below.
NTConfig_Cubing = true;
//------------------------------------------------------------------------------
// General Configuration
//------------------------------------------------------------------------------
// Set to true to activate public mode. By activating public mode, your char will form a party, open TPs and do some chat outputs when running certain bot scripts.
NTConfig_PublicMode = true;
// Set to true to exit the game instantly if the game is public. This may happen sometimes due to an error pasting the password correctly.
MWConfig_ExitGameOnMissingPassword = false;
// Set to true to exit the game when another player expresses hostility towards you.
me.quitonhostile = false;
// This is the maximum time in seconds your char will remain in a single game. Set to 0 to stay in game infinitely.
me.maxgametime = 3000;
// This is the minimum time in seconds for your char to remain in a single game. Your char will not exit the game before this time elapsed.
me.mingametime = 180;
//------------------------------------------------------------------------------
// Automule Configuration
//------------------------------------------------------------------------------
// Set to true to enable auto mule.
MWConfig_Automule.Activated = false;
// The maximum stash load in percent before auto mule is triggered.
MWConfig_Automule.MaxLoad = 95;
// Set to true to show your stash's current load whenever managing stash.
MWConfig_Automule.ShowCurrentLoad = true;
// Set to true to finish your current game before muling, otherwise the game is left right away in case your stash is full.
MWConfig_Automule.FinishGame = true;
// Define which items are not to be touched when muling.
MWConfig_Automule.DontMule.push("mule/dont_mule.nip");
MWConfig_Automule.DontMule.push("mule/gems.nip");
//------------------------------------------------------------------------------
// Shrine Configuration
//------------------------------------------------------------------------------
// Set to true to activate nearby shrines. Shrines will only be activated if it is actually useful.
MWConfig_ActivateNearbyShrines = true;
// If you would like to skip shrines in a certain area, you can its areaid as an exception below. NOTE: All areaids can be found in "sdk\areas.txt".
// MWConfig_ShrineExceptions.push(<areaid1>, <areaid2>, <areaidn>);
//------------------------------------------------------------------------------
// Precast Configuration
//------------------------------------------------------------------------------
// Your precast skills can be defined in the array below. NOTE: Battle Command, Battle Orders and Shout will be cast automatically. Constants for all skill ids can be found in "scripts\libs\common\MWSkills.ntl".
MWConfig_PrecastSkills = [MWS_HOLY_SHIELD];
// Set this to true if you would like to switch slots right after casting BC, BO and Shout. If set to false, your char will remain with the BO Slot until the whole precast procedure is done.
MWConfig_SwitchSlotsAfterBoPrecast = true;
//------------------------------------------------------------------------------
// Attack Configuration
//------------------------------------------------------------------------------
// Specify your attack skills below. NOTE: Constants for all skill ids can be found in "scripts\libs\common\MWSkills.ntl".
NTConfig_AttackSkill[0] = -1; // This skill is used once whenever attacking a new target. Set to -1 to deactivate.
NTConfig_AttackSkill[1] = MWS_BLESSED_HAMMER; // Primary skill to bosses.
NTConfig_AttackSkill[2] = MWS_CONCENTRATION; // Primary aura to bosses. Set to -1 to deactivate.
NTConfig_AttackSkill[3] = MWS_BLESSED_HAMMER; // Primary skill to others.
NTConfig_AttackSkill[4] = MWS_CONCENTRATION; // Primary aura to others. Set to -1 to deactivate.
NTConfig_AttackSkill[5] = MWS_HOLY_BOLT; // Secondary skill in case monster is immune to primary skill. Set to 0 if you won't
NTConfig_AttackSkill[6] = MWS_CONCENTRATION; // Secondary aura. Set to 0 not to activate any aura.
NTConfig_AttackSkill[7] = MWS_SALVATION; // Aura to be used against Uber Mephisto. Set to -1 to deactivate.
// Set to true if you want to clear area after killing boss. NOTE: This only affects a few botscripts.
NTConfig_ClearPosition = true;
// Set to true to clear area when killing a boss and the position is crowded by monsters. NOTE: Setting this to true may cause NTA_KillMonster() to fail way more often.
MWConfig_ClearBossPosition = false;
// This is the number of attacks to be performed before the the character tries to move to another position. Set to 0 not to reposition.
MWConfig_AttacksBeforeRepositioning = 25;
// Define a time limit for your attacks for each type of monster.
MWConfig_AttackTimeLimit[0] = 20; // Maximum time in seconds to attack a normal monster
MWConfig_AttackTimeLimit[1] = 120; // Maximum time in seconds to attack a super unique monster
MWConfig_AttackTimeLimit[2] = 30; // Maximum time in seconds to attack a champion
MWConfig_AttackTimeLimit[3] = 120; // Maximum time in seconds to attack a bosse
MWConfig_AttackTimeLimit[4] = 30; // Maximum time in seconds to attack a minion
// Define when a monster is considered immune by entering the index of one or more of your attack skills. As an example: [1, 3] means that a monster is considered immune if it is immune to both NTConfig_AttackSkill[1] and NTConfig_AttackSkill[3], whatever those may be.
MWConfig_CheckImmunitySkills = [];
// Select the behaviour of your character when encountering a monsters that is considered immune referring to the definition above.
// 0: Don't do anything. (D2NT default)
// 1: Get close to the monster.
// 2: Skip the monster.
// 3: Attack the monster using NTConfig_AttackSkill[8] and NTConfig_AttackSkill[9]
NTConfig_BehaviourOnImmuneMonster = 0;
NTConfig_AttackSkill[8] = -1; // Skill to be used against user defined immunes.
NTConfig_AttackSkill[9] = -1; // Untimed Skill to be used against user defined immunes.
// Activate Redemption if your health is lower than this percentage. Set to 0 not to use Redemption.
NTConfig_UseRedemptionHP = 80;
// Activate Redemption if your health is lower than this percentage. Set to 0 not to use Redemption.
NTConfig_UseRedemptionMP = 60;
// Select whether or not you'd like to swap slots right before killing a boss in order to benefit from some extra MF in your second slot.
// The first element can either be the classid of the target or its name (case insensitive), second element is the life threshold in percent.
//MWConfig_SlotSwapMonsters.push([156, 50]); // Andariel, 50%
//MWConfig_SlotSwapMonsters.push([211, 20]); // Duriel, 20%
//MWConfig_SlotSwapMonsters.push([242, 20]); // Mephisto, 20%
//MWConfig_SlotSwapMonsters.push([243, 20]); // Diablo, 20%
//MWConfig_SlotSwapMonsters.push([544, 15]); // Baal, 15%
// 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 = 0;
// 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;
}
|
|
|
01/22/2012, 23:29
|
#5390
|
elite*gold: 0
Join Date: Jan 2009
Posts: 7,310
Received Thanks: 2,205
|
Quote:
Originally Posted by brain_91
mein Bot macht irgendwie keine Safe TP Message, alles andere funktioniert, von Bots und Leechbots usw ist alles in Ordnung, wenn ich jetzt aber andere Mitspieler in einem privaten Botrun einlade, dann brauchen die eben diese Safe TP Nachricht aber er posted einfach nichts.. ich post euch hier mal meine charconfig und meine botconfig rein
Code:
/**
* This file was modified by
* Check the programming section for updates and further scripts
* Last Update: 11:25 05.11.2011
*/
//------------------------------------------------------------------------------
// Delays
//------------------------------------------------------------------------------
var GameMinLength = 200; // Time in seconds, minimum game length, 180 seconds default (1 game/3 minutes).
var UnableToConnectRetry = 5; // Time in minutes to retry connecting on connection fail (real value is +/- 1 min).
var RealmDownRetry = 15; // Time in minutes to retry connecting on a realm down (default is 300 minutes).
var DisconnectedRetry = 5; // Time in minutes to retry on a disconnection (usually ip ban related).
var CdKeyInUseRetry = 5; // Time in minutes to retry on a cdkey in use error message (set to 0 to stop).
var ConnectingToBnetTimeout = 20; // Time in seconds to wait for a login to Time out and click cancel and retry.
var CharacterScreenTimeout = 10; // Time in seconds to wait for character screen to appear.
var PleaseWaitTimeout = 10; // Time in seconds to wait for a please wait popup.
var CreateGameThreshold = 10; // Time in seconds to wait between making games.
var CreateGameThresholdRandom = 5; // Time in seconds to randomly add +/- to the game create time.
var CreateGameTimeout = 15; // Time in seconds to register a failed to create game.
var WaitInLineTimeout = 60; // Time in seconds to wait in lines for a create game (60 second default).
var CharacterSelectDelay = 1000; // Time in milliseconds to wait before selecting a character on the char screen.
var GameDoesNotExistDelayMin = 10; // How long to wait when a Game Does Not Exist occurs - minimum - default 10 minutes.
var GameDoesNotExistDelayMax = 15; // How long to wait when a Game Does Not Exist occurs - maximum - default 15 minutes.
var GameDoesNotExistTimeout = 30; // How long to wait for the dialog to disappear (default 30 seconds, don't change this).
// Control
var LoginDelay = 5000; // Time in milliseconds to wait before submitting login information.
var ClickDelay = 2000; // Wait X milliseconds before next action after a click event.
var TextDelay = 2500; // Wait X milliseconds before next action after inserting text into a textbox.
var ClickDelayRandom = 500; // Random amount of Time in milliseconds to add to a click.
var TextDelayRandom = 500; // Random amount of Time in milliseconds to add to a text set.
// Channel
var WaitBeforeEnterChatMin = 1000; // Min time in milliseconds to wait before entering chat.
var WaitBeforeEnterChatMax = 2000; // Max time in milliseconds to wait before entering chat.
var WaitInChatBeforeActionsMin = 2000; // Min time in milliseconds to wait before joining channel.
var WaitInChatBeforeActionsMax = 3000; // Max time in milliseconds to wait before joining channel.
var GameAnnouncementDelay = 500; // Wait X milliseconds before posting the announcement message (don't set this too low!).
var GameAnnouncementDelayRandom = 50; // Random amount of time to add to a to the announcement delay.
var UseFileBackupTimeMax = 30; // Time in minutes that may pass since last file update - The backup File is updated at the beginning of every single game and is read everytime the name of your previous game is undefined (e.g. at restarts); Set to 0 to deactivate file backup.
//------------------------------------------------------------------------------
// Game settings
//------------------------------------------------------------------------------
var PlayersPerGame = 8; // Maximum number of players to be set when creating a game.
var CharacterDifference = 35; // Level difference to be set when creating games. Set to 0 not to use level restrictions.
var GameDescription = ""; // The description to be used for your game. Set to "" not to enter a game description.
var JoinRandomGamesChars = new Array("YourNameGoesHere");// Dynamic array that holds chars that are to join public games.
var JoinGameKeywords = new Array("dia", "baal"); // If your char is set to join public games, games will only be joined if the game name contains one of the given keywords.
//------------------------------------------------------------------------------
// Channel Settings
//------------------------------------------------------------------------------
var IgnoreWispers = false; // Set to true to ignore all incoming wispers from players that are not on your friendlist.
var JoinChatAfterLogin = true; // Join chat after login.
var JoinRandomChannel = false; // If this is true, will join a random channel, otherwise it will use the channel below..
var JoinChannelInChat = "Op pornobaal"; // Leave blank not to join a private channel.
var PerformChannelLogin = true; // Type ".login" once after joining the channel.
var ChannelUsers = new Array(); // Dynamic array that holds channel users.
// Add any char/account here that is supposed to perform chat actions/game announcements or join a private channel
ChannelUsers.push("pinapple");
// Or
ChannelUsers.push("orangensaft3");
// The following key expressions will be replaced by their actual values: %game --> "gamename-" <> %counter --> number of the next game <> %time --> time in seconds till game creation <> %password --> game password
// Note that the announcement will start after the first run, so there usually won't be any anncouncement right after login - If the gamename is undefined, the bot will try to load the backup file to announce the upcoming game properly.
var GameAnnouncement = "Creating %game%counter/// in about %time seconds.";
var ShowStatusOnStartup = true;
var JoinRetries = 5; // How many attempts before giving up the mule game?
var JoinRetryDelay = 55; // Seconds to wait between Retry Attempts.
var TimeBeforeMuleGame = 1; // Minutes to wait before creating the game.
var TimeAfterMule = 3; // Minutes to wait before logging back to bot account.
var WaitOnBlockedAccount = 2; // Minutes to wait if the mule account is currently being used by another char (this delay will be used up to 20 times).
//------------------------------------------------------------------------------
// Misc
//------------------------------------------------------------------------------
var MaximumLocationLoops = 5; // The maximum number of loops for a single location; if the window is does not respond and is caught in an infinite loop it will be restarted when the number of loops exceeds the one you specify here.
//---------------------------------------------------------------------------------------------------------------------------------------------------------
// DONT EDIT ANYTHING BELOW THIS!
//---------------------------------------------------------------------------------------------------------------------------------------------------------
// AutoMule Variables and Stuff
const DGDebug = false;
const AUTOMULE_READY = 1;
const AUTOMULE_FULL = 0;
const AUTOMULE_NOMULES = -1;
function AutomuleData()
{
this.InProgress = false;
this.PreventRecover = false;
this.IsWaiting = false;
this.State = "notmuling";
this.CurrentAccount = 0;
this.MuleIndex = 0;
this.IsReadyState = AUTOMULE_READY;
// Account creation variables
this.CreateAccount = false;
this.CharCreateNumber = -1;
this.RegMail = "";
this.MuleFull = false;
this.AccName;
this.AccPw;
this.AccPrefix;
this.AccSuffix = new Array();
this.NewAccPw = new Array();
this.UserNumbers;
this.IsLadder;
this.IsHC;
this.IsClassic;
this.RandomNameLength;
this.GameName;
this.GamePassword;
this.Mules = new Array();
this.MuleAccs;
this.MulePws;
this.NipFiles = new Array();
this.CharLoc;
this.MuleIsFullThreshold;
this.JoinBug;
this.NewCharBug = 0;
this.FullAuto = false;
}
var Automule = new AutomuleData();
Include("libs/controlInfo.ntl");
Include("libs/common/NTCommon.ntl");
Include("NTBot/mule_configs/NTConfig_AutoMule.ntl");
NT_LoadMuleConfig();
Include("libs/common/DGAutoMule.ntl");
// D2NT Manager Command
const D2NT_MGR_LOADING = 1;
const D2NT_MGR_READY = 2;
const D2NT_MGR_LOGIN = 3;
const D2NT_MGR_CREATE_GAME = 4;
const D2NT_MGR_INGAME = 5;
const D2NT_MGR_RESTART = 6;
const D2NT_MGR_CHICKEN = 7;
const D2NT_MGR_PRINT_STATUS = 8;
const D2NT_MGR_PRINT_LOG = 9;
var LastGameMade = GetTickCount();
var LastGameStatus = 0;
var NextGameMake = 0;
var InGameAt = 0;
var LocationLoops = new Array(2);
var ChatActionsDone = false;
var LastGameFailed = false;
var JoinedChannel = false;
var JustJoined = true;
var MadeAnnouncement = false;
// This is for recovering purpose, delete mulestate file is you get stuck
DGAM_ReadMuleStats();
MWAM_ReleaseUsedAccounts();
MWAM_InitializedMuleLoads(false);
var ControlData = new controlInfo();
function NTMain()
{
var _ingame, _scriptPath;
Delay(1000);
_ingame = false;
ConnectingToBnetTimeout *= 1000;
GameMinLength *= 1000;
CharacterScreenTimeout *= 1000;
PleaseWaitTimeout *= 1000;
CreateGameThreshold *= 1000;
CreateGameThresholdRandom *= 1000;
CreateGameTimeout *= 1000;
WaitInLineTimeout *= 1000;
GameDoesNotExistDelayMin *= 1000*60;
GameDoesNotExistDelayMax *= 1000*60;
GameDoesNotExistTimeout *= 1000;
ControlData.ClickDelay = ClickDelay;
ControlData.TextDelay = TextDelay;
ControlData.ClickDelayRandom = ClickDelayRandom;
ControlData.TextDelayRandom = TextDelayRandom;
RegisterEvent(EVENT_SCRIPTMSG, DGAM_MuleMsgEvents);
while(true)
{
if(me.ingame)
{
if(!InGameAt)
InGameAt = GetTickCount();
if(!_ingame)
{
if(Automule.InProgress)
{
if(DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "[Debug] Joined Mule Game");
switch(Automule.State)
{
case "notmuling": // Done or not yet started
// No... we really are not supposed to be here
Automule.InProgress = false;
ExitGame();
NTC_SendLogToOOG(NTC_LOG_COMMON, "AutoMule Error, try again.");
SetStatusText("ÿc1AutoMule Error... (Wait 60s)");
Delay(60000);
break;
case "mulestart": // Still on Bot Account
_scriptPath = "NTBot/bots/NTPermGameandMule.ntj";
break;
case "mule": //Muleing
case "mulefull": // Mule Full
case "done": // Next Account
case "recover": // Recovering
_scriptPath = "NTBot/bots/NTPickStuff.ntj";
break;
default:
_scriptPath = "NTBot/NTPermGameandMule.ntj";
break;
}
if(DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "Debug: Load " + _scriptPath);
RunGC();
if(Load(_scriptPath))
{
_ingame = true;
Automule.JoinBugCount = 0;
MadeAnnouncement = false;
LocationLoops[1] = 0;
MW_WriteBackupFile();
if(me.playtype > 0)
NT_SendEventToOOG(D2NT_MGR_INGAME, "Currently in Mule Game", 0);
else
NT_SendEventToOOG(D2NT_MGR_INGAME, "Oops, that's not gonna work honey.", 0);
LastGameStatus = 2; // in game successful
}
}
else
{
RunGC(); // run garbage collector between each game
if(Load("NTBot/MWBotGame.ntj"))
{
_ingame = true;
MadeAnnouncement = false;
LocationLoops[1] = 0;
MW_WriteBackupFile();
if(me.playtype > 0)
NT_SendEventToOOG(D2NT_MGR_INGAME, "In Game [IP:" + me.gameserverip.split(".")[3] + "]", 0);
else
NT_SendEventToOOG(D2NT_MGR_INGAME, "In Game", 0);
LastGameStatus = 2; // in game successful
}
}
}
Delay(1000);
}
else
{
if(Automule.IsWaiting)
Delay(1000);
else
{
if(_ingame)
{
_ingame = false;
NT_SendEventToOOG(D2NT_MGR_READY, "", 0);
Delay(4000);
}
if(Automule.InProgress)
DGAM_DoMuleLocationAction();
else
NT_LocationAction(ControlData.getLocation());
Delay(500);
}
}
}
}
function NT_LocationAction(location)
{
var _randomChannel, _output, _control;
MW_CheckLocationLoops(location);
switch(location.id)
{
case 3: // Lobby Chat
if(JustJoined)
{
JustJoined = false;
if(MW_ArrayContainsUser(ChannelUsers))
_output = "ÿc2Chat actions enabled!";
else
_output = "ÿc1Chat actions disabled!";
for(var i = 0; i < 3; i++)
{
SetStatusText(_output);
Delay(500);
SetStatusText("");
Delay(500);
}
if(IgnoreWispers)
{
Say("/o igw");
Delay(500);
}
}
if(!ChatActionsDone && MW_ArrayContainsUser(ChannelUsers))
{
ChatActionsDone = true;
Delay(Random(WaitInChatBeforeActionsMin, WaitInChatBeforeActionsMax));
if(!JoinedChannel && (JoinRandomChannel || JoinChannelInChat != ""))
{
_randomChannel = NT_GetRandomString(Random(3,10));
SetStatusText("ÿc8Joining Channel ÿc;" + (JoinRandomChannel ? _randomChannel : JoinChannelInChat));
Delay(500);
Say("/join " + (JoinRandomChannel ? _randomChannel : JoinChannelInChat));
JoinedChannel = true;
if(PerformChannelLogin)
{
SetStatusText("ÿc8Channel Login...");
Say(".login");
Delay(1000);
}
}
}
case 1: // Lobby
if(location.id == 1 && JoinChatAfterLogin)
{
Delay(Random(WaitBeforeEnterChatMin, WaitBeforeEnterChatMax));
ControlData.click(ControlData.controls.lobby.button.enterChat);
break;
}
if(GetTickCount() > NextGameMake)
{
LastGameFailed = false;
switch(LastGameStatus)
{
case 0:
if(MW_ArrayContainsUser(JoinRandomGamesChars))
{
_control = ControlData.get(ControlData.controls.lobby.button.join);
if(_control && _control.pressed)
{
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
}
ControlData.click(ControlData.controls.lobby.button.join);
}
else
{
_control = ControlData.get(ControlData.controls.lobby.button.create);
if(_control && _control.pressed)
{
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
}
ControlData.click(ControlData.controls.lobby.button.create);
}
NextGameMake = GetTickCount() + CreateGameTimeout; // set our timeout
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
break;
case 1: // game failed, rollover to reset timer
InGameAt = GetTickCount();
LastGameFailed = true;
Delay(5000);
case 2:
NT_OutputGameLength();
LastGameStatus = 0;
NT_SetNextGameMake();
if(LastGameFailed)
{
SetStatusText("ÿc1Failed to join!");
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Game creation failed!", 0);
Delay(1000);
}
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
break;
}
}
else
{
if(JoinChannelInChat && !MadeAnnouncement && MW_ArrayContainsUser(ChannelUsers))
{
if(MW_AnnounceGame())
MadeAnnouncement = true;
}
MW_TimeoutDelay(NextGameMake - GetTickCount(), location, !MW_ArrayContainsUser(JoinRandomGamesChars));
}
break;
case 2: // Waiting In Line
if(GetTickCount() - LastGameMade > WaitInLineTimeout)
ControlData.click(ControlData.controls.lobby.inLine.button.cancel);
break;
case 4: // Create Game
if(!MW_ArrayContainsUser(JoinRandomGamesChars))
{
if(!ControlData.get(ControlData.controls.lobby.create.editBox.gameName))
{
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
}
_control = ControlData.get(ControlData.controls.lobby.create.button.useCharacterDifference);
if(_control)
{
if(CharacterDifference == 0 && _control.pressed || CharacterDifference >= 1 && CharacterDifference <= 99 && !_control.pressed)
{
ControlData.click(ControlData.controls.lobby.create.button.useCharacterDifference);
Delay(1000);
}
}
_control = ControlData.get(ControlData.controls.lobby.create.editBox.maxNumberOfPlayers);
if(_control)
{
if(PlayersPerGame >= 1 && PlayersPerGame <= 8 && _control.text != PlayersPerGame.toString())
{
ControlData.setText(ControlData.controls.lobby.create.editBox.maxNumberOfPlayers, PlayersPerGame.toString());
Delay(1000);
}
}
_control = ControlData.get(ControlData.controls.lobby.create.editBox.characterDifference);
if(_control)
{
if(_control.text != CharacterDifference.toString())
{
ControlData.setText(ControlData.controls.lobby.create.editBox.characterDifference, CharacterDifference.toString());
Delay(1000);
}
}
if(GameDescription)
{
ControlData.setText(ControlData.controls.lobby.create.editBox.gameDescription, GameDescription);
Delay(1000);
}
NT_SendEventToOOG(D2NT_MGR_CREATE_GAME, location.name, 0);
NT_LocationTimeout(5000, location);
LastGameMade = GetTickCount();
LastGameStatus = 1; // pending creation
}
break;
case 5: // Join Game
if(MW_ArrayContainsUser(JoinRandomGamesChars))
{
var _games, _game;
_games = ControlData.get(ControlData.controls.lobby.join.textBox.gameList).GetText();
_game = "";
if(_games)
{
for(var i = 0; i < _games.length; i++)
{
for(var j = 0; j < JoinGameKeywords.length; j++)
{
if(_games[i].toLowerCase().indexOf(JoinGameKeywords[j].toLowerCase()) > -1)
{
_game = _games[i];
i = _games.length;
break;
}
}
}
}
if(_game != "")
{
SetStatusText("ÿc8Joining Game: " + _game);
Delay(250);
ControlData.setText(ControlData.controls.lobby.join.editBox.gameName, _game);
Delay(1000);
ControlData.click(ControlData.controls.lobby.join.button.joinGame);
NT_LocationTimeout(5000, location);
LastGameMade = GetTickCount();
LastGameStatus = 1; // pending creation
}
else
Delay(2500);
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
}
break;
case 6: // Ladder
break;
case 7: // Channel List
break;
case 8: // Main Menu
if(ControlData.getCurrentRealmIndex() == me.gatewayid)
{
NT_OutputGameLength();
ControlData.click(ControlData.gameTypes[me.playtype]);
}
else
ControlData.click(ControlData.controls.mainMenu.button.gateway);
break;
case 9: // Login
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
Delay(LoginDelay);
ControlData.setText(ControlData.controls.login.editBox.accountName, me.account);
NT_SendEventToOOG(D2NT_MGR_LOGIN, location.name, 0);
NT_LocationTimeout(5000, location);
break;
case 10: // Login Error (this is a fatal error, so stop)
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 10);
Delay(3500);
break;
case 11: // Unable To Connect
MW_TimeoutDelay(UnableToConnectRetry*60*1000, location);
ControlData.click(ControlData.controls.login.unableToConnect.button.ok);
break;
case 12: // Character Select
var _time, _control;
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
for(_time = 0 ; _time < CharacterScreenTimeout ; _time += 500)
{
_control = ControlData.get(ControlData.controls.characterSelect.textBox.characterInfo[me.charloc]);
if(_control && _control.GetText() != undefined)
break;
Delay(500);
}
if(_time < CharacterScreenTimeout)
{
Delay(CharacterSelectDelay);
ControlData.click(ControlData.controls.characterSelect.textBox.characters[me.charloc], 0, 0, 1);
ControlData.click(ControlData.controls.characterSelect.textBox.characterInfo[me.charloc], 0, 0, 1);
// reset last game made, so it doesnt make a game immediately
InGameAt = 0;
NT_SetNextGameMake();
}
else
{
ControlData.click(ControlData.controls.characterSelect.button.exit);
MW_TimeoutDelay(RealmDownRetry*60*1000, location);
}
break;
case 13: // Realm Down - Character Select screen
ControlData.click(ControlData.controls.characterSelect.button.exit);
MW_TimeoutDelay(RealmDownRetry*60*1000, location);
break;
case 14: // Character Select - Disconnected
MW_TimeoutDelay(DisconnectedRetry*60*1000, location);
ControlData.click(ControlData.controls.characterSelect.disconnected.button.ok);
break;
case 15: // New Character
break;
case 16: // Character Select - Please Wait popup
if(!NT_LocationTimeout(PleaseWaitTimeout, location))
ControlData.click(ControlData.controls.characterSelect.pleaseWait.button.cancel);
break;
case 17: // Lobby - Lost Connection - just click okay, since we're toast anyway
ControlData.click(ControlData.controls.lobby.lostConnection.button.ok);
break;
case 18: // D2 Splash
ControlData.click(ControlData.controls.d2Splash.textBox.copyright);
break;
case 19: // Login - Cdkey In Use
MW_TimeoutDelay(CdKeyInUseRetry*60*1000, location);
ControlData.click(ControlData.controls.login.cdkeyInUse.button.ok);
break;
case 20: // Single Player - Select Difficulty
ControlData.click(ControlData.singlePlayerDifficulties[me.diff]);
break;
case 21: // Main Menu - Connecting
if(!NT_LocationTimeout(ConnectingToBnetTimeout, location))
ControlData.click(ControlData.controls.mainMenu.connecting.button.cancel);
break;
case 22: // Login - Invalid Cdkey (classic or xpac)
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 3600);
Delay(3500);
break;
case 23: // Character Select - Connecting
if(!NT_LocationTimeout(CharacterScreenTimeout, location))
ControlData.click(ControlData.controls.characterSelect.button.exit);
break;
case 24: // Server Down - not much to do but wait..
break;
case 25: // Lobby - Please Wait
if(!NT_LocationTimeout(PleaseWaitTimeout, location))
ControlData.click(ControlData.controls.lobby.pleaseWait.button.cancel);
break;
case 26: // Lobby - Game Name Exists
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Game already exists", 0);
SetStatusText("ÿc1Game already exists!");
InGameAt = 0;
LastGameStatus = 0;
NT_SetNextGameMake();
NT_LocationTimeout(15000, location);
break;
case 27: // Gateway Select
ControlData.clickRealmEntry(me.gatewayid);
ControlData.click(ControlData.controls.gateway.button.ok);
break;
case 28: // Lobby - Game Does Not Exist
InGameAt = Random(GameDoesNotExistDelayMin, GameDoesNotExistDelayMax);
LastGameStatus = 0;
NT_SetNextGameMake();
NT_LocationTimeout(GameDoesNotExistTimeout, location);
break;
}
}
function NT_SendEventToOOG(locationId, statusString, pendingTime)
{
return SendCopyData("D2NT Manager", null, (locationId<<16)|pendingTime, statusString);
}
function NT_SetNextGameMake()
{
LastGameMade = GetTickCount();
NextGameMake = LastGameMade + CreateGameThreshold + Random(0 - CreateGameThresholdRandom, CreateGameThresholdRandom) + InGameAt;
InGameAt = 0;
ChatActionsDone = false;
}
function NT_OutputGameLength()
{
var _duration;
if(InGameAt)
{
_duration = GetTickCount() - InGameAt;
if(_duration < GameMinLength)
InGameAt = GameMinLength - _duration;
else
InGameAt = 0;
}
}
function NT_LocationTimeout(time, location)
{
var _endtime = GetTickCount() + time;
while(ControlData.getLocation().id == location.id && _endtime > GetTickCount())
{
if(LocationLoops[1] > 1)
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "] [" + LocationLoops[1] + "]", 0);
else
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "]", 0);
Delay(1000);
}
return (ControlData.getLocation().id != location.id);
}
function MW_TimeoutDelay(time, location, showNextGameStatus)
{
var _gamename, _outputString, _timeString;
if(arguments.length < 3)
showNextGameStatus = false;
_endtime = GetTickCount() + time;
_gamename = me.gamename;
_timeString = "";
if(!_gamename)
{
_gamename = MW_ReadBackupFile(0);
if(_gamename)
SetStatusText("ÿc8Using File Backup...");
}
while(_endtime > GetTickCount())
{
_timeString = " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "]";
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + _timeString , 0);
if(showNextGameStatus)
{
if(LastGameFailed && parseInt(_endtime-GetTickCount()) > CreateGameThreshold && parseInt((_endtime-GetTickCount())/1000) % 30 >= 0 && parseInt((_endtime-GetTickCount())/1000) % 30 <= 5)
{
_outputString = "ÿc1Last game failed!";
_timeString = "";
}
else if(parseInt((_endtime-GetTickCount())/1000) >= 0)
{
if(_gamename && MW_GetGameCounter(_gamename, false))
_outputString = "ÿc8Next game: " + MW_GetGameName(_gamename) + MW_GetGameCounter(_gamename, false);
else
_outputString = "ÿc8Game creation pending... ";
}
MWC_SetStatusText(_outputString, _timeString);
if(me.ingame)
_endtime = GetTickCount();
}
Delay(1000);
}
if(showNextGameStatus)
SetStatusText("ÿc8Creating game...");
return;
}
function NT_GetRandomString(length)
{
_retString = "";
_charSet = "0123456789abcdefghijklmnopqrstuvwxyz";
while(length--)
{
_retString += _charSet.charAt(Random(0, _charSet.length - 1));
Delay(1);
}
return _retString;
}
function MW_GetGameName(lastGameString)
{
if(!lastGameString)
return "";
else
return lastGameString.substr(0, lastGameString.lastIndexOf('-') + 1);
}
function MW_GetGameCounter(lastGameString, simple)
{
var _count, _countString;
if(!lastGameString)
return "-1";
else
{
_countString = lastGameString.slice(lastGameString.lastIndexOf('-') + 1);
if(_countString[0] == '0')
_countString = _countString.substr(1);
_count = parseInt(_countString) + 1;
if(_count == 100)
_count = 0;
if(!simple)
{
if(_count <= 9)
return '0' + _count;
}
return _count;
}
}
function MW_ArrayContainsUser(array)
{
for(var i = 0; i < array.length; i++)
{
if(me.account.toLowerCase() == array[i].toLowerCase() || me.charname.toLowerCase() == array[i].toLowerCase())
return true;
}
return false;
}
function MW_ReadBackupFile(type)
{
var _fhandle, _buffer, _time, _now, _retValue;
_fhandle = FileOpen("/Logs/Temporary Data/" + me.charname + ".channel", 2);
_retValue = "";
_now = new Date();
if(_fhandle && _now)
{
_buffer = _fhandle.ReadLine();
if(_buffer)
{
_time = parseInt(_buffer);
if(_now.getTime() - _time < UseFileBackupTimeMax*6E4)
{
_retValue = _fhandle.ReadLine();
if(type > 0)
_retValue = _fhandle.ReadLine();
}
}
_fhandle.Close();
}
else if(_fhandle)
_fhandle.Close();
return _retValue;
}
function MW_WriteBackupFile()
{
var _fhandle, _now;
if(UseFileBackupTimeMax == 0)
return false;
_fhandle = FileOpen("/Logs/Temporary Data/" + me.charname + ".channel", 1);
_now = new Date();
if(_fhandle && _now)
{
_fhandle.WriteLine(_now.getTime());
_fhandle.WriteLine(me.gamename);
_fhandle.WriteLine(me.gamepassword);
_fhandle.Close();
return true;
}
else if(_fhandle)
_fhandle.Close();
return false;
}
function MW_CheckLocationLoops(location)
{
if(!location)
return false;
if(!LocationLoops[0] || location.id != LocationLoops[0].id)
{
LocationLoops[0] = location;
LocationLoops[1] = 0;
}
else if(LocationLoops[0].id != 5)
{
LocationLoops[1]++;
if(LocationLoops[1] >= MaximumLocationLoops)
{
if(LocationLoops[1] < 1000)
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Location Loop Restart!;ÿc1Location Loops: " + LocationLoops[1] + "\nÿBE0000Location: " + LocationLoops[0].name + "\nÿBE0000Location ID: " + LocationLoops[0].id, 0);
LocationLoops[1] = 1000; // Make sure the location loop notification is only shown once
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 0);
}
}
return true;
}
function MW_AnnounceGame()
{
var _gamePass, _gameName, _gameText, _delay;
_gameName = me.gamename;
if(!_gameName)
_gameName = MW_ReadBackupFile(0);
_gamePass = me.gamepassword;
if(!_gamePass)
_gamePass = MW_ReadBackupFile(1);
if(_gameName && !me.ingame)
{
_delay = (GameAnnouncementDelay > 5000) ? GameAnnouncementDelay : 5000;
_delay += (GameAnnouncementDelayRandom > 500) ? Random(0, GameAnnouncementDelayRandom) : 500;
_gameText = GameAnnouncement.replace("%password", ((_gamePass) ? _gamePass : "N/A"));
_gameText = _gameText.replace("%game", MW_GetGameName(_gameName));
_gameText = _gameText.replace("%counter", MW_GetGameCounter(_gameName, false));
_gameText = _gameText.replace("%time", parseInt((NextGameMake - GetTickCount() - _delay + ClickDelay + TextDelay) / 1000 + 5));
if(_gameText.indexOf("NaN") > -1)
return false;
if(parseInt((NextGameMake - GetTickCount() - _delay + ClickDelay + TextDelay) / 1000) > 3)
{
Delay(_delay);
return Say(_gameText);
}
}
return false;
}
Code:
/**
* This file was modified by
* Check the programming section for updates and further scripts
* Last Update: 23:10 29.08.2011
*
* Hotkey Description
*
* Pause/Break Pauses the current bot script.
* Page up (PgUp) Skips the current bot script.
* Page down (PgDn) Repeats the previous bot script
* Home (Pos1) Shows your current coordinates and areaid.
* End Shows current ping in status text bar.
* Insert (Ins) Logs all items on your char to either XML or TXT.
* Delete (Del) Exits the game. NOTE: Always use this key to leave a game!
* Backspace Force trigger auto mule. NOTE: Won't work unless auto mule is actually activated for the current char.
*/
Include("NTBot/char_configs/MWConfig_GlobalSettings.ntl");
var NTConfig_UseRedemptionHP;
var NTConfig_UseRedemptionMP;
function NT_LoadConfig()
{
MW_LoadGlobalSettings();
//------------------------------------------------------------------------------
//
// Run Configuration
//
//------------------------------------------------------------------------------
// Use the following syntax for activating botscripts: MWConfig_Script.push([<ScriptName>, <Script runtime in minutes (0 is infinite)>]);
// ***************** Current schedule ******************
// MWConfig_Script.push(["NTAndariel.ntj", 5]);
// MWConfig_Script.push(["NTMausoleum.ntj", 10]); MWConfig_ClearPathSpectypes.Mausoleum = 0; MWConfig_ClearAreaSpectypes.Mausoleum = 0x01; NTConfig_KillBloodRaven = true;
// MWConfig_Script.push(["NTPit.ntj", 10]); MWConfig_ClearPathSpectypes.Pit = 0; MWConfig_ClearAreaSpectypes.Pit = 0x01; NTConfig_ClearPitLevel1 = 2; // 0 : don't clear, 1 : clear path only, 2 : clear all
// MWConfig_Script.push(["NTCountess.ntj", 5]); MWConfig_ClearPathSpectypes.Countess = 0; MWConfig_ClearAreaSpectypes.Countess = 0;
// MWConfig_Script.push(["NTSummoner.ntj", 5]); NTConfig_KillFireEye = false; MWConfig_ClearPathSpectypes.Summoner = 0;
// MWConfig_Script.push(["NTAncientTunnels.ntj", 10]); MWConfig_ClearPathSpectypes.AncientTunnels = 0x01; MWConfig_ClearAreaSpectypes.AncientTunnels = 0x01;
// MWConfig_Script.push(["MWKurastSewers.ntj", 5]); MWConfig_ClearPathSpectypes.KurastSewers = 0;
// MWConfig_Script.push(["NTTravincal.ntj", 5]);
//MWConfig_Script.push(["NTMephisto.ntj", 5]); MWConfig_OpenMephistoChest = true; MWConfig_MephistoClearArea = false;
// MWConfig_Script.push(["MWSuperChests.ntj", 20]); MWConfig_SuperChestClearAreaRadius = 5; MWConfig_SuperChestAreas = ["Arachnid Lair", "Swampy Pit Level 3", "Flayer Dungeon", "Abbadon", "Pit of Acheron", "Drifter Cavern", "Infernal Pit", "Icy Cellar"];
// MWConfig_Script.push(["NTNihlathak.ntj", 5]); MWConfig_ClearPathSpectypes.Nihlathak = 0; NTConfig_PindleskinExtension = false; MWConfig_SkipOnTombVipers = true;
// MWConfig_Script.push(["NTDiablo.ntj", 10]); MWConfig_KillFullInfectorMob = true; MWConfig_StartAtStar = false; MWConfig_IgnoreSealOpeningErrors = false; MWConfig_FastDia = false;
//MWConfig_Script.push(["NTEldritch.ntj", 5]); NTConfig_ShenkExtension = true;
MWConfig_Script.push(["NTBaal.ntj", 10]); NTConfig_KillBaal = true; MWConfig_SkipBaalOnDolls = false; MWConfig_SkipBaalOnSouls = false; MWConfig_DoBaalPreAttack = true;
// *****************************************************
//------------------------------------------------------------------------------
// Available Scripts
//------------------------------------------------------------------------------
/* NOTE:
// The scripts below are actually commented out; to add a script, copy one of the lines below and add it to the current schedule above. ;)
// You should also get yourself a decent editor that supports syntax highlighting for JavaScript, I'd recommend Notepad++. (http://notepad-plus-plus.org/download/)
// *********************** Act I ***********************
MWConfig_Script.push(["NTMausoleum.ntj", 10]); MWConfig_ClearPathSpectypes.Mausoleum = 0; MWConfig_ClearAreaSpectypes.Mausoleum = 0x01; NTConfig_KillBloodRaven = true;
MWConfig_Script.push(["NTTristram.ntj", 10]); NTConfig_KillRakanishu = true;
MWConfig_Script.push(["NTHole.ntj", 10]); MWConfig_ClearPathSpectypes.Hole = 0; MWConfig_ClearAreaSpectypes.Hole = 0x01; NTConfig_ClearHoleLevel1 = 1; // 0 : don't clear, 1 : clear path only, 2 : clear all
MWConfig_Script.push(["NTTreehead.ntj", 10]);
MWConfig_Script.push(["MWColdcrow.ntj", 10]); MWConfig_ClearCaveMode = 0; // 0: Only kill coldcrow; 1: Clear Cave Level 1; 2: Clear both Cave Level 1 & 2
MWConfig_Script.push(["NTCountess.ntj", 5]); MWConfig_ClearPathSpectypes.Countess = 0; MWConfig_ClearAreaSpectypes.Countess = 0;
MWConfig_Script.push(["NTPit.ntj", 10]); MWConfig_ClearPathSpectypes.Pit = 0; MWConfig_ClearAreaSpectypes.Pit = 0x01; NTConfig_ClearPitLevel1 = 2; // 0 : don't clear, 1 : clear path only, 2 : clear all
MWConfig_Script.push(["NTAndariel.ntj", 10]);
// *********************** Act II **********************
MWConfig_Script.push(["NTRadament.ntj", 10]); MWConfig_ClearPathSpectypes.Radament = 0;
MWConfig_Script.push(["MWMaggotsLair.ntj", 10]); MWConfig_ClearPathSpectypes.MaggotsLair = 0; MWConfig_ClearAreaSpectypes.MaggotsLair = 0x01;
MWConfig_Script.push(["NTAncientTunnels.ntj", 10]); MWConfig_ClearPathSpectypes.AncientTunnels = 0; MWConfig_ClearAreaSpectypes.AncientTunnels = 0x01;
MWConfig_Script.push(["NTSummoner.ntj", 5]); NTConfig_KillFireEye = false; MWConfig_ClearPathSpectypes.Summoner = 0;
MWConfig_Script.push(["NTDuriel.ntj", 10]); MWConfig_ClearPathSpectypes.Duriel = 0;
// ********************** Act III **********************
MWConfig_Script.push(["MWFlayerJungle.ntj", 10]); MWConfig_ClearAreaSpectypes.FlayerJungle = 0x01;
MWConfig_Script.push(["MWKurastSewers.ntj", 5]); MWConfig_ClearPathSpectypes.KurastSewers = 0;
MWConfig_Script.push(["MWKurastTemples.ntj", 5]); MWConfig_ClearPathSpectypes.KurastTemples = 0; MWConfig_ClearAreaSpectypes.KurastTemples = 0x01;
MWConfig_Script.push(["NTTravincal.ntj", 5]);
MWConfig_Script.push(["NTMephisto.ntj", 5]); MWConfig_OpenMephistoChest = true; MWConfig_MephistoClearArea = true;
// *********************** Act IV **********************
MWConfig_Script.push(["NTIzual.ntj", 5]); MWConfig_ClearPathSpectypes.Izual = 0;
MWConfig_Script.push(["MWRiverOfFlame.ntj", 10]); MWConfig_ClearAreaSpectypes.RiverOfFlame = 0x01;
MWConfig_Script.push(["NTHephasto.ntj", 10]); MWConfig_ClearPathSpectypes.Hephasto = 0;
MWConfig_Script.push(["NTDiablo.ntj", 10]); MWConfig_KillFullInfectorMob = true; MWConfig_StartAtStar = false; MWConfig_IgnoreSealOpeningErrors = false; MWConfig_FastDia = true;
// *********************** Act V ***********************
MWConfig_Script.push(["MWAbbadon.ntj", 10]); MWConfig_ClearPathSpectypes.Abbadon = 0; MWConfig_ClearAreaSpectypes.Abbadon = 0x01;
MWConfig_Script.push(["MWPitOfAcheron.ntj", 10]); MWConfig_ClearPathSpectypes.PitOfAcheron = 0; MWConfig_ClearAreaSpectypes.PitOfAcheron = 0x01;
MWConfig_Script.push(["MWInfernalPit.ntj", 10]); MWConfig_ClearPathSpectypes.InfernalPit = 0; MWConfig_ClearAreaSpectypes.InfernalPit = 0x01;
MWConfig_Script.push(["MWHallsOfPain.ntj", 15]); MWConfig_ClearAreaSpectypes.HallsOfPain = 0x01; MWConfig_ClearHallsOfAnguish = true;
MWConfig_Script.push(["NTPindleskin.ntj", 5]); NTConfig_NihlathakExtension = false; MWConfig_SkipOnTombVipers = true;
MWConfig_Script.push(["NTEldritch.ntj", 5]); NTConfig_ShenkExtension = true;
MWConfig_Script.push(["NTThreshSocket.ntj", 5]); MWConfig_ClearPathSpectypes.ThreshSocket = 0;
MWConfig_Script.push(["NTFrozenRiver.ntj", 10]); MWConfig_ClearPathSpectypes.FrozenRiver = 0; MWConfig_ClearAreaSpectypes.FrozenRiver = 0x01;
MWConfig_Script.push(["NTGlacialTrail.ntj", 10]); MWConfig_ClearPathSpectypes.GlacialTrail = 0; MWConfig_ClearAreaSpectypes.GlacialTrail = 0x01;
MWConfig_Script.push(["NTIcyCellar.ntj", 5]); MWConfig_ClearPathSpectypes.IcyCellar = 0; MWConfig_ClearAreaSpectypes.IcyCellar = 0x01;
MWConfig_Script.push(["NTNihlathak.ntj", 5]); MWConfig_ClearPathSpectypes.Nihlathak = 0; NTConfig_PindleskinExtension = false; MWConfig_SkipOnTombVipers = true;
MWConfig_Script.push(["MWWorldstoneKeep.ntj", 10]); MWConfig_ClearAreaSpectypes.WorldstoneKeep = 0x01; MWConfig_SkipLevelOnWitches = true; MWConfig_SkipLevelOnSouls = false; MWConfig_SkipLevelOnDeathLords = true;
MWConfig_Script.push(["NTBaal.ntj", 10]); NTConfig_KillBaal = true; MWConfig_SkipBaalOnDolls = true; MWConfig_SkipBaalOnSouls = false; MWConfig_DoBaalPreAttack = true; MWConfig_ClearPathSpectypes.Baal = 0;
// *********************** Misc ************************
MWConfig_Script.push(["MWAuraStack.ntj", 10]); MWConfig_StackRepetitions = 100; MWConfig_ResetMercWeaponAfterStacking = false;
MWConfig_Script.push(["MWSuperChests.ntj", 20]); MWConfig_SuperChestClearAreaRadius = 10; MWConfig_SuperChestAreas = ["Cave Level 2", "Mausoleum", "Hole Level 2", "Pit Level 2", "Sewers Level 3", "Halls of the Dead Level 2", "Stony Tomb Level 2", "Maggot's Lair Level 3", "Ancient Tunnels", "Tal Rasha's Tomb", "Arachnid Lair", "Swampy Pit Level 3", "Flayer Dungeon", "Sewers Level 2", "Abbadon", "Pit of Acheron", "Drifter Cavern", "Infernal Pit", "Icy Cellar", "Halls of Pain"];
MWConfig_Script.push(["MWRush.ntj", 0]); MWConfig_IsRusher = true;
MWConfig_Script.push(["MWWaypointCatcher.ntj", 0]); MWConfig_WaypointCatcherActs = [1, 2, 3, 4, 5]; MWConfig_TPWaypoints = true; MWConfig_SkipHallsOfPain = true; MWConfig_ClearWaypointPaths = false;
MWConfig_Script.push(["MWIdleMode.ntj", 0]); MWConfig_IdleModeRuntime = 5; // Runtime in Minutes
MWConfig_Script.push(["NTCows.ntj", 10]);
MWConfig_Script.push(["MWBloodyRejuvs.ntj", 10]);
MWConfig_Script.push(["MWOrganHarvest.ntj", 10]); MWConfig_EnterInvalidUberPortals = true; MWConfig_PauseOnLackOfKeys = false; MWConfig_IntendedUberPortal = 0; // Matron's Den: 133; Forgotten Sands: 134; Furnace Of Pain: 135;
MWConfig_Script.push(["MWUberTristram.ntj", 10]); MWConfig_PauseOnLackOfOrgans = false; MWConfig_PauseOnKeptTorch = false;
MWConfig_Script.push(["MWAnyasBargain.ntj", 10]); MWConfig_ShoppingMinGold = 500000; MWConfig_ShoppingAttempts = 200;
// ************ Leech and friends by lanara ************
MWConfig_Script.push(["NTDiabloLeechFight.ntj", 10]); MWConfig_StartAtStar = true; MWConfig_EnterUnsafeTP = true; NTConfig_PreBuff = true; MWConfig_IgnoreSealOpeningErrors = true; NTConfig_Leader = "LeaderNameGoesHere";
MWConfig_Script.push(["NTBaalLeech.ntj", 10]); NTConfig_KillBaal = true; MWConfig_EnterUnsafeTP = false; NTConfig_Leader = "LeaderNameGoesHere";
MWConfig_Script.push(["NTBaalLeechFight.ntj", 10]); NTConfig_KillBaal = true; MWConfig_DoBaalPreAttack = true; MWConfig_EnterUnsafeTP = true; NTConfig_Leader = "LeaderNameGoesHere";
*/
//------------------------------------------------------------------------------
// Misc Configuration
//------------------------------------------------------------------------------
NTConfig_SkipHealLife = 90; // If you have more than this percent of life, you won't go to a healer.
NTConfig_SkipHealMana = 70; // 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.
// Exit game or to reset your Enigma if Teleport skill is missing (due to identifying an item having +x to Teleport [Sorceress only]). WARNING: Activating this feature may - though not likely will - result in the loss of your enigma. Use at your own risk and make sure your char has sufficient strength!
// 0: Don't do anything; 1: Reset armor; 2: Exit game
MWConfig_ResetArmorMode = 0;
//------------------------------------------------------------------------------
// Potion Configuration
//------------------------------------------------------------------------------
NTConfig_LifeThresh = 70; // Drink a normal potion if under this percent of life.
NTConfig_LifeRejuvThresh = 60; // 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 = 1; // Drink a rejuvenation potion if under this percent of mana.
NTConfig_MercLifeThresh = 50; // This is the threshold to use a life potion on your merc in percent.
NTConfig_MercRejuvThresh = 30; // This is the threshold to use a rejuv potion on your merc in percent.
//------------------------------------------------------------------------------
// Chicken Configuration
//------------------------------------------------------------------------------
// This is your chicken life. If you go below this threshhold, your char will exit the game. You can either enter a percentage (1-100), an absolute threshold (>100) or 0 to deactivate life chicken.
NTConfig_LifeChicken = 30;
// This is your chicken mana. If you go below this threshhold, your char will exit the game. You can either enter a percentage (1-100), an absolute threshold (>100) or 0 to deactivate mana chicken.
NTConfig_ManaChicken = 0;
// This is your merc's chicken life in percent. If your merc goes below this threshhold, your char will exit the game.
NTConfig_MercChicken = 0;
// Whether or not to disable chicken when you pause the bot.
MWConfig_DisableChickenOnPause = true;
//------------------------------------------------------------------------------
// Inventory Configuration
//------------------------------------------------------------------------------
// Each number represents a slot in your inventory.
// Set to 0 if the slot and its content must not be touched.
// Set to 1 to allow access to this slot.
// Set to 2 to select the slot that is used for storing keys. (if keys are kept at another slot, your char will try to move them)
NTConfig_Columns[0] = [1,1,1,1,1,1,1,1,2,0];
NTConfig_Columns[1] = [1,1,1,1,1,1,1,1,1,0];
NTConfig_Columns[2] = [1,1,1,1,1,1,1,1,1,0];
NTConfig_Columns[3] = [1,1,1,1,1,1,1,1,1,0];
// Number of free columns. If less full columns are free stashing is set. Call SetFreeColumns(NTConfig_Columns) to always stash right away (recommended).
NTConfig_FreeSpace = SetFreeColumns(NTConfig_Columns);
// Maximum gold amount carried before going to stash.
NTConfig_MinGoldToStash = 100000;
// Set to true if your char is supposed to carry, buy and pick up keys. You do not need to add keys to your .nip files, they will be picked up anyway if this is set to true.
MWConfig_CarryKeys = true;
//------------------------------------------------------------------------------
// Belt Configuration
//------------------------------------------------------------------------------
// Available types : "hp" = health, "mp" = mana, "rv" = rejuvenation.
// Define how many columns are used for each potion type.
MWConfig_BeltColType["hp"].Columns = 1;
MWConfig_BeltColType["mp"].Columns = 1;
MWConfig_BeltColType["rv"].Columns = 2;
// Define minimum number of potions per column. If the actual number of potions in a column is below this value, your char will visit a merchant when in town in order to buy potions.
MWConfig_BeltColType["hp"].MinPots = 3;
MWConfig_BeltColType["mp"].MinPots = 3;
// Visit Town and buy potions if your char lacks mana when trying to loot a corpse or teleport.
MWConfig_BuyPotionsOnLackOfMana = true;
// Set to true to replace low quality potions with higher quality potions that just dropped.
MWConfig_ReplaceLowQualityPotions = true;
//-----------------------------------------------------------------------------------
// NipFile Configuration
//-----------------------------------------------------------------------------------
NTConfig_NIPFilePath.push("private/normal.nip");
NTConfig_NIPFilePath.push("private/magic_rare.nip");
NTConfig_NIPFilePath.push("private/set.nip");
NTConfig_NIPFilePath.push("private/unique.nip");
NTConfig_NIPFilePath.push("private/craft.nip");
NTConfig_NIPFilePath.push("private/temp.nip");
//------------------------------------------------------------------------------
// Pickit Configuration
//------------------------------------------------------------------------------
// Radius to check for dropped items. NOTE: The maximum is at about ~75, entering higher values will not have any effect.
NTConfig_SnagRange = 70;
// Set to true to check for dropped items whenever you kill a monster. (Recommended value to avoid crashes: false)
MWConfig_PickItemsInstantly = true;
//------------------------------------------------------------------------------
// Chest Configuration
//------------------------------------------------------------------------------
// Select which containers shall be looted. 0: None; 1: Super Chests, 2: All
MWConfig_OpenContainerMode = 2;
// Set to true to check for dropped items right after opening a chest. NOTE: This will slow down your runs and therefore should definately be set to false when doing private games.
MWConfig_PickChestLootsInstantly = true;
// This is the range being checked for chests after clearing an area or room. NOTE: You should not set this too high, 30 is a good value.
MWConfig_OpenChestsRange = 30;
// If you do not like to open chests in a certain area, you can its areaid as an exception below. NOTE: All areaids can be found in "sdk\areas.txt".
// MWConfig_ChestExceptions.push(<areaid1>, <areaid2>, <areaidn>);
//------------------------------------------------------------------------------
// Cubing Configuration
//------------------------------------------------------------------------------
// Set to true to enable cubing and crafting. NOTE: The recipes are added in the global config by default. If you like to craft certain recipe only using this very char, add those recipes below.
NTConfig_Cubing = true;
//------------------------------------------------------------------------------
// General Configuration
//------------------------------------------------------------------------------
// Set to true to activate public mode. By activating public mode, your char will form a party, open TPs and do some chat outputs when running certain bot scripts.
NTConfig_PublicMode = true;
// Set to true to exit the game instantly if the game is public. This may happen sometimes due to an error pasting the password correctly.
MWConfig_ExitGameOnMissingPassword = false;
// Set to true to exit the game when another player expresses hostility towards you.
me.quitonhostile = false;
// This is the maximum time in seconds your char will remain in a single game. Set to 0 to stay in game infinitely.
me.maxgametime = 3000;
// This is the minimum time in seconds for your char to remain in a single game. Your char will not exit the game before this time elapsed.
me.mingametime = 180;
//------------------------------------------------------------------------------
// Automule Configuration
//------------------------------------------------------------------------------
// Set to true to enable auto mule.
MWConfig_Automule.Activated = false;
// The maximum stash load in percent before auto mule is triggered.
MWConfig_Automule.MaxLoad = 95;
// Set to true to show your stash's current load whenever managing stash.
MWConfig_Automule.ShowCurrentLoad = true;
// Set to true to finish your current game before muling, otherwise the game is left right away in case your stash is full.
MWConfig_Automule.FinishGame = true;
// Define which items are not to be touched when muling.
MWConfig_Automule.DontMule.push("mule/dont_mule.nip");
MWConfig_Automule.DontMule.push("mule/gems.nip");
//------------------------------------------------------------------------------
// Shrine Configuration
//------------------------------------------------------------------------------
// Set to true to activate nearby shrines. Shrines will only be activated if it is actually useful.
MWConfig_ActivateNearbyShrines = true;
// If you would like to skip shrines in a certain area, you can its areaid as an exception below. NOTE: All areaids can be found in "sdk\areas.txt".
// MWConfig_ShrineExceptions.push(<areaid1>, <areaid2>, <areaidn>);
//------------------------------------------------------------------------------
// Precast Configuration
//------------------------------------------------------------------------------
// Your precast skills can be defined in the array below. NOTE: Battle Command, Battle Orders and Shout will be cast automatically. Constants for all skill ids can be found in "scripts\libs\common\MWSkills.ntl".
MWConfig_PrecastSkills = [MWS_HOLY_SHIELD];
// Set this to true if you would like to switch slots right after casting BC, BO and Shout. If set to false, your char will remain with the BO Slot until the whole precast procedure is done.
MWConfig_SwitchSlotsAfterBoPrecast = true;
//------------------------------------------------------------------------------
// Attack Configuration
//------------------------------------------------------------------------------
// Specify your attack skills below. NOTE: Constants for all skill ids can be found in "scripts\libs\common\MWSkills.ntl".
NTConfig_AttackSkill[0] = -1; // This skill is used once whenever attacking a new target. Set to -1 to deactivate.
NTConfig_AttackSkill[1] = MWS_BLESSED_HAMMER; // Primary skill to bosses.
NTConfig_AttackSkill[2] = MWS_CONCENTRATION; // Primary aura to bosses. Set to -1 to deactivate.
NTConfig_AttackSkill[3] = MWS_BLESSED_HAMMER; // Primary skill to others.
NTConfig_AttackSkill[4] = MWS_CONCENTRATION; // Primary aura to others. Set to -1 to deactivate.
NTConfig_AttackSkill[5] = MWS_HOLY_BOLT; // Secondary skill in case monster is immune to primary skill. Set to 0 if you won't
NTConfig_AttackSkill[6] = MWS_CONCENTRATION; // Secondary aura. Set to 0 not to activate any aura.
NTConfig_AttackSkill[7] = MWS_SALVATION; // Aura to be used against Uber Mephisto. Set to -1 to deactivate.
// Set to true if you want to clear area after killing boss. NOTE: This only affects a few botscripts.
NTConfig_ClearPosition = true;
// Set to true to clear area when killing a boss and the position is crowded by monsters. NOTE: Setting this to true may cause NTA_KillMonster() to fail way more often.
MWConfig_ClearBossPosition = false;
// This is the number of attacks to be performed before the the character tries to move to another position. Set to 0 not to reposition.
MWConfig_AttacksBeforeRepositioning = 25;
// Define a time limit for your attacks for each type of monster.
MWConfig_AttackTimeLimit[0] = 20; // Maximum time in seconds to attack a normal monster
MWConfig_AttackTimeLimit[1] = 120; // Maximum time in seconds to attack a super unique monster
MWConfig_AttackTimeLimit[2] = 30; // Maximum time in seconds to attack a champion
MWConfig_AttackTimeLimit[3] = 120; // Maximum time in seconds to attack a bosse
MWConfig_AttackTimeLimit[4] = 30; // Maximum time in seconds to attack a minion
// Define when a monster is considered immune by entering the index of one or more of your attack skills. As an example: [1, 3] means that a monster is considered immune if it is immune to both NTConfig_AttackSkill[1] and NTConfig_AttackSkill[3], whatever those may be.
MWConfig_CheckImmunitySkills = [];
// Select the behaviour of your character when encountering a monsters that is considered immune referring to the definition above.
// 0: Don't do anything. (D2NT default)
// 1: Get close to the monster.
// 2: Skip the monster.
// 3: Attack the monster using NTConfig_AttackSkill[8] and NTConfig_AttackSkill[9]
NTConfig_BehaviourOnImmuneMonster = 0;
NTConfig_AttackSkill[8] = -1; // Skill to be used against user defined immunes.
NTConfig_AttackSkill[9] = -1; // Untimed Skill to be used against user defined immunes.
// Activate Redemption if your health is lower than this percentage. Set to 0 not to use Redemption.
NTConfig_UseRedemptionHP = 80;
// Activate Redemption if your health is lower than this percentage. Set to 0 not to use Redemption.
NTConfig_UseRedemptionMP = 60;
// Select whether or not you'd like to swap slots right before killing a boss in order to benefit from some extra MF in your second slot.
// The first element can either be the classid of the target or its name (case insensitive), second element is the life threshold in percent.
//MWConfig_SlotSwapMonsters.push([156, 50]); // Andariel, 50%
//MWConfig_SlotSwapMonsters.push([211, 20]); // Duriel, 20%
//MWConfig_SlotSwapMonsters.push([242, 20]); // Mephisto, 20%
//MWConfig_SlotSwapMonsters.push([243, 20]); // Diablo, 20%
//MWConfig_SlotSwapMonsters.push([544, 15]); // Baal, 15%
// 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 = 0;
// 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;
}
|
MWConfig_GlobalSettings
|
|
|
01/23/2012, 03:22
|
#5391
|
elite*gold: 0
Join Date: Jul 2010
Posts: 213
Received Thanks: 36
|
wie kommt es eigendlich dass mein leecher 450 und mein leader 550 runs hat im manager?
hab die beiden über nacht laufen lassen und am morgen sahs dann so aus. wieso macht der leecher 20% weniger runs?
|
|
|
01/23/2012, 07:10
|
#5392
|
elite*gold: 0
Join Date: Jan 2009
Posts: 3,170
Received Thanks: 1,191
|
Joinbug maybe?
|
|
|
01/23/2012, 10:01
|
#5393
|
elite*gold: 0
Join Date: May 2010
Posts: 9
Received Thanks: 0
|
mein Bot macht irgendwie keine Safe TP Message, alles andere funktioniert, von Bots und Leechbots usw ist alles in Ordnung, wenn ich jetzt aber andere Mitspieler in einem privaten Botrun einlade, dann brauchen die eben diese Safe TP Nachricht aber er posted einfach nichts.. ich post euch hier mal meine charconfig und meine botconfig rein
Code:
/**
* This file was modified by
* Check the programming section for updates and further scripts
* Last Update: 11:25 05.11.2011
*/
//------------------------------------------------------------------------------
// Delays
//------------------------------------------------------------------------------
var GameMinLength = 200; // Time in seconds, minimum game length, 180 seconds default (1 game/3 minutes).
var UnableToConnectRetry = 5; // Time in minutes to retry connecting on connection fail (real value is +/- 1 min).
var RealmDownRetry = 15; // Time in minutes to retry connecting on a realm down (default is 300 minutes).
var DisconnectedRetry = 5; // Time in minutes to retry on a disconnection (usually ip ban related).
var CdKeyInUseRetry = 5; // Time in minutes to retry on a cdkey in use error message (set to 0 to stop).
var ConnectingToBnetTimeout = 20; // Time in seconds to wait for a login to Time out and click cancel and retry.
var CharacterScreenTimeout = 10; // Time in seconds to wait for character screen to appear.
var PleaseWaitTimeout = 10; // Time in seconds to wait for a please wait popup.
var CreateGameThreshold = 10; // Time in seconds to wait between making games.
var CreateGameThresholdRandom = 5; // Time in seconds to randomly add +/- to the game create time.
var CreateGameTimeout = 15; // Time in seconds to register a failed to create game.
var WaitInLineTimeout = 60; // Time in seconds to wait in lines for a create game (60 second default).
var CharacterSelectDelay = 1000; // Time in milliseconds to wait before selecting a character on the char screen.
var GameDoesNotExistDelayMin = 10; // How long to wait when a Game Does Not Exist occurs - minimum - default 10 minutes.
var GameDoesNotExistDelayMax = 15; // How long to wait when a Game Does Not Exist occurs - maximum - default 15 minutes.
var GameDoesNotExistTimeout = 30; // How long to wait for the dialog to disappear (default 30 seconds, don't change this).
// Control
var LoginDelay = 5000; // Time in milliseconds to wait before submitting login information.
var ClickDelay = 2000; // Wait X milliseconds before next action after a click event.
var TextDelay = 2500; // Wait X milliseconds before next action after inserting text into a textbox.
var ClickDelayRandom = 500; // Random amount of Time in milliseconds to add to a click.
var TextDelayRandom = 500; // Random amount of Time in milliseconds to add to a text set.
// Channel
var WaitBeforeEnterChatMin = 1000; // Min time in milliseconds to wait before entering chat.
var WaitBeforeEnterChatMax = 2000; // Max time in milliseconds to wait before entering chat.
var WaitInChatBeforeActionsMin = 2000; // Min time in milliseconds to wait before joining channel.
var WaitInChatBeforeActionsMax = 3000; // Max time in milliseconds to wait before joining channel.
var GameAnnouncementDelay = 500; // Wait X milliseconds before posting the announcement message (don't set this too low!).
var GameAnnouncementDelayRandom = 50; // Random amount of time to add to a to the announcement delay.
var UseFileBackupTimeMax = 30; // Time in minutes that may pass since last file update - The backup File is updated at the beginning of every single game and is read everytime the name of your previous game is undefined (e.g. at restarts); Set to 0 to deactivate file backup.
//------------------------------------------------------------------------------
// Game settings
//------------------------------------------------------------------------------
var PlayersPerGame = 8; // Maximum number of players to be set when creating a game.
var CharacterDifference = 35; // Level difference to be set when creating games. Set to 0 not to use level restrictions.
var GameDescription = ""; // The description to be used for your game. Set to "" not to enter a game description.
var JoinRandomGamesChars = new Array("YourNameGoesHere");// Dynamic array that holds chars that are to join public games.
var JoinGameKeywords = new Array("dia", "baal"); // If your char is set to join public games, games will only be joined if the game name contains one of the given keywords.
//------------------------------------------------------------------------------
// Channel Settings
//------------------------------------------------------------------------------
var IgnoreWispers = false; // Set to true to ignore all incoming wispers from players that are not on your friendlist.
var JoinChatAfterLogin = true; // Join chat after login.
var JoinRandomChannel = false; // If this is true, will join a random channel, otherwise it will use the channel below..
var JoinChannelInChat = "Op pornobaal"; // Leave blank not to join a private channel.
var PerformChannelLogin = true; // Type ".login" once after joining the channel.
var ChannelUsers = new Array(); // Dynamic array that holds channel users.
// Add any char/account here that is supposed to perform chat actions/game announcements or join a private channel
ChannelUsers.push("pinapple");
// Or
ChannelUsers.push("orangensaft3");
// The following key expressions will be replaced by their actual values: %game --> "gamename-" <> %counter --> number of the next game <> %time --> time in seconds till game creation <> %password --> game password
// Note that the announcement will start after the first run, so there usually won't be any anncouncement right after login - If the gamename is undefined, the bot will try to load the backup file to announce the upcoming game properly.
var GameAnnouncement = "Creating %game%counter/// in about %time seconds.";
var ShowStatusOnStartup = true;
var JoinRetries = 5; // How many attempts before giving up the mule game?
var JoinRetryDelay = 55; // Seconds to wait between Retry Attempts.
var TimeBeforeMuleGame = 1; // Minutes to wait before creating the game.
var TimeAfterMule = 3; // Minutes to wait before logging back to bot account.
var WaitOnBlockedAccount = 2; // Minutes to wait if the mule account is currently being used by another char (this delay will be used up to 20 times).
//------------------------------------------------------------------------------
// Misc
//------------------------------------------------------------------------------
var MaximumLocationLoops = 5; // The maximum number of loops for a single location; if the window is does not respond and is caught in an infinite loop it will be restarted when the number of loops exceeds the one you specify here.
//---------------------------------------------------------------------------------------------------------------------------------------------------------
// DONT EDIT ANYTHING BELOW THIS!
//---------------------------------------------------------------------------------------------------------------------------------------------------------
// AutoMule Variables and Stuff
const DGDebug = false;
const AUTOMULE_READY = 1;
const AUTOMULE_FULL = 0;
const AUTOMULE_NOMULES = -1;
function AutomuleData()
{
this.InProgress = false;
this.PreventRecover = false;
this.IsWaiting = false;
this.State = "notmuling";
this.CurrentAccount = 0;
this.MuleIndex = 0;
this.IsReadyState = AUTOMULE_READY;
// Account creation variables
this.CreateAccount = false;
this.CharCreateNumber = -1;
this.RegMail = "";
this.MuleFull = false;
this.AccName;
this.AccPw;
this.AccPrefix;
this.AccSuffix = new Array();
this.NewAccPw = new Array();
this.UserNumbers;
this.IsLadder;
this.IsHC;
this.IsClassic;
this.RandomNameLength;
this.GameName;
this.GamePassword;
this.Mules = new Array();
this.MuleAccs;
this.MulePws;
this.NipFiles = new Array();
this.CharLoc;
this.MuleIsFullThreshold;
this.JoinBug;
this.NewCharBug = 0;
this.FullAuto = false;
}
var Automule = new AutomuleData();
Include("libs/controlInfo.ntl");
Include("libs/common/NTCommon.ntl");
Include("NTBot/mule_configs/NTConfig_AutoMule.ntl");
NT_LoadMuleConfig();
Include("libs/common/DGAutoMule.ntl");
// D2NT Manager Command
const D2NT_MGR_LOADING = 1;
const D2NT_MGR_READY = 2;
const D2NT_MGR_LOGIN = 3;
const D2NT_MGR_CREATE_GAME = 4;
const D2NT_MGR_INGAME = 5;
const D2NT_MGR_RESTART = 6;
const D2NT_MGR_CHICKEN = 7;
const D2NT_MGR_PRINT_STATUS = 8;
const D2NT_MGR_PRINT_LOG = 9;
var LastGameMade = GetTickCount();
var LastGameStatus = 0;
var NextGameMake = 0;
var InGameAt = 0;
var LocationLoops = new Array(2);
var ChatActionsDone = false;
var LastGameFailed = false;
var JoinedChannel = false;
var JustJoined = true;
var MadeAnnouncement = false;
// This is for recovering purpose, delete mulestate file is you get stuck
DGAM_ReadMuleStats();
MWAM_ReleaseUsedAccounts();
MWAM_InitializedMuleLoads(false);
var ControlData = new controlInfo();
function NTMain()
{
var _ingame, _scriptPath;
Delay(1000);
_ingame = false;
ConnectingToBnetTimeout *= 1000;
GameMinLength *= 1000;
CharacterScreenTimeout *= 1000;
PleaseWaitTimeout *= 1000;
CreateGameThreshold *= 1000;
CreateGameThresholdRandom *= 1000;
CreateGameTimeout *= 1000;
WaitInLineTimeout *= 1000;
GameDoesNotExistDelayMin *= 1000*60;
GameDoesNotExistDelayMax *= 1000*60;
GameDoesNotExistTimeout *= 1000;
ControlData.ClickDelay = ClickDelay;
ControlData.TextDelay = TextDelay;
ControlData.ClickDelayRandom = ClickDelayRandom;
ControlData.TextDelayRandom = TextDelayRandom;
RegisterEvent(EVENT_SCRIPTMSG, DGAM_MuleMsgEvents);
while(true)
{
if(me.ingame)
{
if(!InGameAt)
InGameAt = GetTickCount();
if(!_ingame)
{
if(Automule.InProgress)
{
if(DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "[Debug] Joined Mule Game");
switch(Automule.State)
{
case "notmuling": // Done or not yet started
// No... we really are not supposed to be here
Automule.InProgress = false;
ExitGame();
NTC_SendLogToOOG(NTC_LOG_COMMON, "AutoMule Error, try again.");
SetStatusText("ÿc1AutoMule Error... (Wait 60s)");
Delay(60000);
break;
case "mulestart": // Still on Bot Account
_scriptPath = "NTBot/bots/NTPermGameandMule.ntj";
break;
case "mule": //Muleing
case "mulefull": // Mule Full
case "done": // Next Account
case "recover": // Recovering
_scriptPath = "NTBot/bots/NTPickStuff.ntj";
break;
default:
_scriptPath = "NTBot/NTPermGameandMule.ntj";
break;
}
if(DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "Debug: Load " + _scriptPath);
RunGC();
if(Load(_scriptPath))
{
_ingame = true;
Automule.JoinBugCount = 0;
MadeAnnouncement = false;
LocationLoops[1] = 0;
MW_WriteBackupFile();
if(me.playtype > 0)
NT_SendEventToOOG(D2NT_MGR_INGAME, "Currently in Mule Game", 0);
else
NT_SendEventToOOG(D2NT_MGR_INGAME, "Oops, that's not gonna work honey.", 0);
LastGameStatus = 2; // in game successful
}
}
else
{
RunGC(); // run garbage collector between each game
if(Load("NTBot/MWBotGame.ntj"))
{
_ingame = true;
MadeAnnouncement = false;
LocationLoops[1] = 0;
MW_WriteBackupFile();
if(me.playtype > 0)
NT_SendEventToOOG(D2NT_MGR_INGAME, "In Game [IP:" + me.gameserverip.split(".")[3] + "]", 0);
else
NT_SendEventToOOG(D2NT_MGR_INGAME, "In Game", 0);
LastGameStatus = 2; // in game successful
}
}
}
Delay(1000);
}
else
{
if(Automule.IsWaiting)
Delay(1000);
else
{
if(_ingame)
{
_ingame = false;
NT_SendEventToOOG(D2NT_MGR_READY, "", 0);
Delay(4000);
}
if(Automule.InProgress)
DGAM_DoMuleLocationAction();
else
NT_LocationAction(ControlData.getLocation());
Delay(500);
}
}
}
}
function NT_LocationAction(location)
{
var _randomChannel, _output, _control;
MW_CheckLocationLoops(location);
switch(location.id)
{
case 3: // Lobby Chat
if(JustJoined)
{
JustJoined = false;
if(MW_ArrayContainsUser(ChannelUsers))
_output = "ÿc2Chat actions enabled!";
else
_output = "ÿc1Chat actions disabled!";
for(var i = 0; i < 3; i++)
{
SetStatusText(_output);
Delay(500);
SetStatusText("");
Delay(500);
}
if(IgnoreWispers)
{
Say("/o igw");
Delay(500);
}
}
if(!ChatActionsDone && MW_ArrayContainsUser(ChannelUsers))
{
ChatActionsDone = true;
Delay(Random(WaitInChatBeforeActionsMin, WaitInChatBeforeActionsMax));
if(!JoinedChannel && (JoinRandomChannel || JoinChannelInChat != ""))
{
_randomChannel = NT_GetRandomString(Random(3,10));
SetStatusText("ÿc8Joining Channel ÿc;" + (JoinRandomChannel ? _randomChannel : JoinChannelInChat));
Delay(500);
Say("/join " + (JoinRandomChannel ? _randomChannel : JoinChannelInChat));
JoinedChannel = true;
if(PerformChannelLogin)
{
SetStatusText("ÿc8Channel Login...");
Say(".login");
Delay(1000);
}
}
}
case 1: // Lobby
if(location.id == 1 && JoinChatAfterLogin)
{
Delay(Random(WaitBeforeEnterChatMin, WaitBeforeEnterChatMax));
ControlData.click(ControlData.controls.lobby.button.enterChat);
break;
}
if(GetTickCount() > NextGameMake)
{
LastGameFailed = false;
switch(LastGameStatus)
{
case 0:
if(MW_ArrayContainsUser(JoinRandomGamesChars))
{
_control = ControlData.get(ControlData.controls.lobby.button.join);
if(_control && _control.pressed)
{
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
}
ControlData.click(ControlData.controls.lobby.button.join);
}
else
{
_control = ControlData.get(ControlData.controls.lobby.button.create);
if(_control && _control.pressed)
{
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
}
ControlData.click(ControlData.controls.lobby.button.create);
}
NextGameMake = GetTickCount() + CreateGameTimeout; // set our timeout
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
break;
case 1: // game failed, rollover to reset timer
InGameAt = GetTickCount();
LastGameFailed = true;
Delay(5000);
case 2:
NT_OutputGameLength();
LastGameStatus = 0;
NT_SetNextGameMake();
if(LastGameFailed)
{
SetStatusText("ÿc1Failed to join!");
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Game creation failed!", 0);
Delay(1000);
}
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
break;
}
}
else
{
if(JoinChannelInChat && !MadeAnnouncement && MW_ArrayContainsUser(ChannelUsers))
{
if(MW_AnnounceGame())
MadeAnnouncement = true;
}
MW_TimeoutDelay(NextGameMake - GetTickCount(), location, !MW_ArrayContainsUser(JoinRandomGamesChars));
}
break;
case 2: // Waiting In Line
if(GetTickCount() - LastGameMade > WaitInLineTimeout)
ControlData.click(ControlData.controls.lobby.inLine.button.cancel);
break;
case 4: // Create Game
if(!MW_ArrayContainsUser(JoinRandomGamesChars))
{
if(!ControlData.get(ControlData.controls.lobby.create.editBox.gameName))
{
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
}
_control = ControlData.get(ControlData.controls.lobby.create.button.useCharacterDifference);
if(_control)
{
if(CharacterDifference == 0 && _control.pressed || CharacterDifference >= 1 && CharacterDifference <= 99 && !_control.pressed)
{
ControlData.click(ControlData.controls.lobby.create.button.useCharacterDifference);
Delay(1000);
}
}
_control = ControlData.get(ControlData.controls.lobby.create.editBox.maxNumberOfPlayers);
if(_control)
{
if(PlayersPerGame >= 1 && PlayersPerGame <= 8 && _control.text != PlayersPerGame.toString())
{
ControlData.setText(ControlData.controls.lobby.create.editBox.maxNumberOfPlayers, PlayersPerGame.toString());
Delay(1000);
}
}
_control = ControlData.get(ControlData.controls.lobby.create.editBox.characterDifference);
if(_control)
{
if(_control.text != CharacterDifference.toString())
{
ControlData.setText(ControlData.controls.lobby.create.editBox.characterDifference, CharacterDifference.toString());
Delay(1000);
}
}
if(GameDescription)
{
ControlData.setText(ControlData.controls.lobby.create.editBox.gameDescription, GameDescription);
Delay(1000);
}
NT_SendEventToOOG(D2NT_MGR_CREATE_GAME, location.name, 0);
NT_LocationTimeout(5000, location);
LastGameMade = GetTickCount();
LastGameStatus = 1; // pending creation
}
break;
case 5: // Join Game
if(MW_ArrayContainsUser(JoinRandomGamesChars))
{
var _games, _game;
_games = ControlData.get(ControlData.controls.lobby.join.textBox.gameList).GetText();
_game = "";
if(_games)
{
for(var i = 0; i < _games.length; i++)
{
for(var j = 0; j < JoinGameKeywords.length; j++)
{
if(_games[i].toLowerCase().indexOf(JoinGameKeywords[j].toLowerCase()) > -1)
{
_game = _games[i];
i = _games.length;
break;
}
}
}
}
if(_game != "")
{
SetStatusText("ÿc8Joining Game: " + _game);
Delay(250);
ControlData.setText(ControlData.controls.lobby.join.editBox.gameName, _game);
Delay(1000);
ControlData.click(ControlData.controls.lobby.join.button.joinGame);
NT_LocationTimeout(5000, location);
LastGameMade = GetTickCount();
LastGameStatus = 1; // pending creation
}
else
Delay(2500);
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
}
break;
case 6: // Ladder
break;
case 7: // Channel List
break;
case 8: // Main Menu
if(ControlData.getCurrentRealmIndex() == me.gatewayid)
{
NT_OutputGameLength();
ControlData.click(ControlData.gameTypes[me.playtype]);
}
else
ControlData.click(ControlData.controls.mainMenu.button.gateway);
break;
case 9: // Login
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
Delay(LoginDelay);
ControlData.setText(ControlData.controls.login.editBox.accountName, me.account);
NT_SendEventToOOG(D2NT_MGR_LOGIN, location.name, 0);
NT_LocationTimeout(5000, location);
break;
case 10: // Login Error (this is a fatal error, so stop)
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 10);
Delay(3500);
break;
case 11: // Unable To Connect
MW_TimeoutDelay(UnableToConnectRetry*60*1000, location);
ControlData.click(ControlData.controls.login.unableToConnect.button.ok);
break;
case 12: // Character Select
var _time, _control;
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
for(_time = 0 ; _time < CharacterScreenTimeout ; _time += 500)
{
_control = ControlData.get(ControlData.controls.characterSelect.textBox.characterInfo[me.charloc]);
if(_control && _control.GetText() != undefined)
break;
Delay(500);
}
if(_time < CharacterScreenTimeout)
{
Delay(CharacterSelectDelay);
ControlData.click(ControlData.controls.characterSelect.textBox.characters[me.charloc], 0, 0, 1);
ControlData.click(ControlData.controls.characterSelect.textBox.characterInfo[me.charloc], 0, 0, 1);
// reset last game made, so it doesnt make a game immediately
InGameAt = 0;
NT_SetNextGameMake();
}
else
{
ControlData.click(ControlData.controls.characterSelect.button.exit);
MW_TimeoutDelay(RealmDownRetry*60*1000, location);
}
break;
case 13: // Realm Down - Character Select screen
ControlData.click(ControlData.controls.characterSelect.button.exit);
MW_TimeoutDelay(RealmDownRetry*60*1000, location);
break;
case 14: // Character Select - Disconnected
MW_TimeoutDelay(DisconnectedRetry*60*1000, location);
ControlData.click(ControlData.controls.characterSelect.disconnected.button.ok);
break;
case 15: // New Character
break;
case 16: // Character Select - Please Wait popup
if(!NT_LocationTimeout(PleaseWaitTimeout, location))
ControlData.click(ControlData.controls.characterSelect.pleaseWait.button.cancel);
break;
case 17: // Lobby - Lost Connection - just click okay, since we're toast anyway
ControlData.click(ControlData.controls.lobby.lostConnection.button.ok);
break;
case 18: // D2 Splash
ControlData.click(ControlData.controls.d2Splash.textBox.copyright);
break;
case 19: // Login - Cdkey In Use
MW_TimeoutDelay(CdKeyInUseRetry*60*1000, location);
ControlData.click(ControlData.controls.login.cdkeyInUse.button.ok);
break;
case 20: // Single Player - Select Difficulty
ControlData.click(ControlData.singlePlayerDifficulties[me.diff]);
break;
case 21: // Main Menu - Connecting
if(!NT_LocationTimeout(ConnectingToBnetTimeout, location))
ControlData.click(ControlData.controls.mainMenu.connecting.button.cancel);
break;
case 22: // Login - Invalid Cdkey (classic or xpac)
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 3600);
Delay(3500);
break;
case 23: // Character Select - Connecting
if(!NT_LocationTimeout(CharacterScreenTimeout, location))
ControlData.click(ControlData.controls.characterSelect.button.exit);
break;
case 24: // Server Down - not much to do but wait..
break;
case 25: // Lobby - Please Wait
if(!NT_LocationTimeout(PleaseWaitTimeout, location))
ControlData.click(ControlData.controls.lobby.pleaseWait.button.cancel);
break;
case 26: // Lobby - Game Name Exists
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Game already exists", 0);
SetStatusText("ÿc1Game already exists!");
InGameAt = 0;
LastGameStatus = 0;
NT_SetNextGameMake();
NT_LocationTimeout(15000, location);
break;
case 27: // Gateway Select
ControlData.clickRealmEntry(me.gatewayid);
ControlData.click(ControlData.controls.gateway.button.ok);
break;
case 28: // Lobby - Game Does Not Exist
InGameAt = Random(GameDoesNotExistDelayMin, GameDoesNotExistDelayMax);
LastGameStatus = 0;
NT_SetNextGameMake();
NT_LocationTimeout(GameDoesNotExistTimeout, location);
break;
}
}
function NT_SendEventToOOG(locationId, statusString, pendingTime)
{
return SendCopyData("D2NT Manager", null, (locationId<<16)|pendingTime, statusString);
}
function NT_SetNextGameMake()
{
LastGameMade = GetTickCount();
NextGameMake = LastGameMade + CreateGameThreshold + Random(0 - CreateGameThresholdRandom, CreateGameThresholdRandom) + InGameAt;
InGameAt = 0;
ChatActionsDone = false;
}
function NT_OutputGameLength()
{
var _duration;
if(InGameAt)
{
_duration = GetTickCount() - InGameAt;
if(_duration < GameMinLength)
InGameAt = GameMinLength - _duration;
else
InGameAt = 0;
}
}
function NT_LocationTimeout(time, location)
{
var _endtime = GetTickCount() + time;
while(ControlData.getLocation().id == location.id && _endtime > GetTickCount())
{
if(LocationLoops[1] > 1)
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "] [" + LocationLoops[1] + "]", 0);
else
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "]", 0);
Delay(1000);
}
return (ControlData.getLocation().id != location.id);
}
function MW_TimeoutDelay(time, location, showNextGameStatus)
{
var _gamename, _outputString, _timeString;
if(arguments.length < 3)
showNextGameStatus = false;
_endtime = GetTickCount() + time;
_gamename = me.gamename;
_timeString = "";
if(!_gamename)
{
_gamename = MW_ReadBackupFile(0);
if(_gamename)
SetStatusText("ÿc8Using File Backup...");
}
while(_endtime > GetTickCount())
{
_timeString = " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "]";
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + _timeString , 0);
if(showNextGameStatus)
{
if(LastGameFailed && parseInt(_endtime-GetTickCount()) > CreateGameThreshold && parseInt((_endtime-GetTickCount())/1000) % 30 >= 0 && parseInt((_endtime-GetTickCount())/1000) % 30 <= 5)
{
_outputString = "ÿc1Last game failed!";
_timeString = "";
}
else if(parseInt((_endtime-GetTickCount())/1000) >= 0)
{
if(_gamename && MW_GetGameCounter(_gamename, false))
_outputString = "ÿc8Next game: " + MW_GetGameName(_gamename) + MW_GetGameCounter(_gamename, false);
else
_outputString = "ÿc8Game creation pending... ";
}
MWC_SetStatusText(_outputString, _timeString);
if(me.ingame)
_endtime = GetTickCount();
}
Delay(1000);
}
if(showNextGameStatus)
SetStatusText("ÿc8Creating game...");
return;
}
function NT_GetRandomString(length)
{
_retString = "";
_charSet = "0123456789abcdefghijklmnopqrstuvwxyz";
while(length--)
{
_retString += _charSet.charAt(Random(0, _charSet.length - 1));
Delay(1);
}
return _retString;
}
function MW_GetGameName(lastGameString)
{
if(!lastGameString)
return "";
else
return lastGameString.substr(0, lastGameString.lastIndexOf('-') + 1);
}
function MW_GetGameCounter(lastGameString, simple)
{
var _count, _countString;
if(!lastGameString)
return "-1";
else
{
_countString = lastGameString.slice(lastGameString.lastIndexOf('-') + 1);
if(_countString[0] == '0')
_countString = _countString.substr(1);
_count = parseInt(_countString) + 1;
if(_count == 100)
_count = 0;
if(!simple)
{
if(_count <= 9)
return '0' + _count;
}
return _count;
}
}
function MW_ArrayContainsUser(array)
{
for(var i = 0; i < array.length; i++)
{
if(me.account.toLowerCase() == array[i].toLowerCase() || me.charname.toLowerCase() == array[i].toLowerCase())
return true;
}
return false;
}
function MW_ReadBackupFile(type)
{
var _fhandle, _buffer, _time, _now, _retValue;
_fhandle = FileOpen("/Logs/Temporary Data/" + me.charname + ".channel", 2);
_retValue = "";
_now = new Date();
if(_fhandle && _now)
{
_buffer = _fhandle.ReadLine();
if(_buffer)
{
_time = parseInt(_buffer);
if(_now.getTime() - _time < UseFileBackupTimeMax*6E4)
{
_retValue = _fhandle.ReadLine();
if(type > 0)
_retValue = _fhandle.ReadLine();
}
}
_fhandle.Close();
}
else if(_fhandle)
_fhandle.Close();
return _retValue;
}
function MW_WriteBackupFile()
{
var _fhandle, _now;
if(UseFileBackupTimeMax == 0)
return false;
_fhandle = FileOpen("/Logs/Temporary Data/" + me.charname + ".channel", 1);
_now = new Date();
if(_fhandle && _now)
{
_fhandle.WriteLine(_now.getTime());
_fhandle.WriteLine(me.gamename);
_fhandle.WriteLine(me.gamepassword);
_fhandle.Close();
return true;
}
else if(_fhandle)
_fhandle.Close();
return false;
}
function MW_CheckLocationLoops(location)
{
if(!location)
return false;
if(!LocationLoops[0] || location.id != LocationLoops[0].id)
{
LocationLoops[0] = location;
LocationLoops[1] = 0;
}
else if(LocationLoops[0].id != 5)
{
LocationLoops[1]++;
if(LocationLoops[1] >= MaximumLocationLoops)
{
if(LocationLoops[1] < 1000)
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Location Loop Restart!;ÿc1Location Loops: " + LocationLoops[1] + "\nÿBE0000Location: " + LocationLoops[0].name + "\nÿBE0000Location ID: " + LocationLoops[0].id, 0);
LocationLoops[1] = 1000; // Make sure the location loop notification is only shown once
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 0);
}
}
return true;
}
function MW_AnnounceGame()
{
var _gamePass, _gameName, _gameText, _delay;
_gameName = me.gamename;
if(!_gameName)
_gameName = MW_ReadBackupFile(0);
_gamePass = me.gamepassword;
if(!_gamePass)
_gamePass = MW_ReadBackupFile(1);
if(_gameName && !me.ingame)
{
_delay = (GameAnnouncementDelay > 5000) ? GameAnnouncementDelay : 5000;
_delay += (GameAnnouncementDelayRandom > 500) ? Random(0, GameAnnouncementDelayRandom) : 500;
_gameText = GameAnnouncement.replace("%password", ((_gamePass) ? _gamePass : "N/A"));
_gameText = _gameText.replace("%game", MW_GetGameName(_gameName));
_gameText = _gameText.replace("%counter", MW_GetGameCounter(_gameName, false));
_gameText = _gameText.replace("%time", parseInt((NextGameMake - GetTickCount() - _delay + ClickDelay + TextDelay) / 1000 + 5));
if(_gameText.indexOf("NaN") > -1)
return false;
if(parseInt((NextGameMake - GetTickCount() - _delay + ClickDelay + TextDelay) / 1000) > 3)
{
Delay(_delay);
return Say(_gameText);
}
}
return false;
}
Code:
/**
* This file was modified by
* Check the programming section for updates and further scripts
* Last Update: 23:10 29.08.2011
*
* Hotkey Description
*
* Pause/Break Pauses the current bot script.
* Page up (PgUp) Skips the current bot script.
* Page down (PgDn) Repeats the previous bot script
* Home (Pos1) Shows your current coordinates and areaid.
* End Shows current ping in status text bar.
* Insert (Ins) Logs all items on your char to either XML or TXT.
* Delete (Del) Exits the game. NOTE: Always use this key to leave a game!
* Backspace Force trigger auto mule. NOTE: Won't work unless auto mule is actually activated for the current char.
*/
Include("NTBot/char_configs/MWConfig_GlobalSettings.ntl");
var NTConfig_UseRedemptionHP;
var NTConfig_UseRedemptionMP;
function NT_LoadConfig()
{
MW_LoadGlobalSettings();
//------------------------------------------------------------------------------
//
// Run Configuration
//
//------------------------------------------------------------------------------
// Use the following syntax for activating botscripts: MWConfig_Script.push([<ScriptName>, <Script runtime in minutes (0 is infinite)>]);
// ***************** Current schedule ******************
// MWConfig_Script.push(["NTAndariel.ntj", 5]);
// MWConfig_Script.push(["NTMausoleum.ntj", 10]); MWConfig_ClearPathSpectypes.Mausoleum = 0; MWConfig_ClearAreaSpectypes.Mausoleum = 0x01; NTConfig_KillBloodRaven = true;
// MWConfig_Script.push(["NTPit.ntj", 10]); MWConfig_ClearPathSpectypes.Pit = 0; MWConfig_ClearAreaSpectypes.Pit = 0x01; NTConfig_ClearPitLevel1 = 2; // 0 : don't clear, 1 : clear path only, 2 : clear all
// MWConfig_Script.push(["NTCountess.ntj", 5]); MWConfig_ClearPathSpectypes.Countess = 0; MWConfig_ClearAreaSpectypes.Countess = 0;
// MWConfig_Script.push(["NTSummoner.ntj", 5]); NTConfig_KillFireEye = false; MWConfig_ClearPathSpectypes.Summoner = 0;
// MWConfig_Script.push(["NTAncientTunnels.ntj", 10]); MWConfig_ClearPathSpectypes.AncientTunnels = 0x01; MWConfig_ClearAreaSpectypes.AncientTunnels = 0x01;
// MWConfig_Script.push(["MWKurastSewers.ntj", 5]); MWConfig_ClearPathSpectypes.KurastSewers = 0;
// MWConfig_Script.push(["NTTravincal.ntj", 5]);
//MWConfig_Script.push(["NTMephisto.ntj", 5]); MWConfig_OpenMephistoChest = true; MWConfig_MephistoClearArea = false;
// MWConfig_Script.push(["MWSuperChests.ntj", 20]); MWConfig_SuperChestClearAreaRadius = 5; MWConfig_SuperChestAreas = ["Arachnid Lair", "Swampy Pit Level 3", "Flayer Dungeon", "Abbadon", "Pit of Acheron", "Drifter Cavern", "Infernal Pit", "Icy Cellar"];
// MWConfig_Script.push(["NTNihlathak.ntj", 5]); MWConfig_ClearPathSpectypes.Nihlathak = 0; NTConfig_PindleskinExtension = false; MWConfig_SkipOnTombVipers = true;
// MWConfig_Script.push(["NTDiablo.ntj", 10]); MWConfig_KillFullInfectorMob = true; MWConfig_StartAtStar = false; MWConfig_IgnoreSealOpeningErrors = false; MWConfig_FastDia = false;
//MWConfig_Script.push(["NTEldritch.ntj", 5]); NTConfig_ShenkExtension = true;
MWConfig_Script.push(["NTBaal.ntj", 10]); NTConfig_KillBaal = true; MWConfig_SkipBaalOnDolls = false; MWConfig_SkipBaalOnSouls = false; MWConfig_DoBaalPreAttack = true;
// *****************************************************
//------------------------------------------------------------------------------
// Available Scripts
//------------------------------------------------------------------------------
/* NOTE:
// The scripts below are actually commented out; to add a script, copy one of the lines below and add it to the current schedule above. ;)
// You should also get yourself a decent editor that supports syntax highlighting for JavaScript, I'd recommend Notepad++. (http://notepad-plus-plus.org/download/)
// *********************** Act I ***********************
MWConfig_Script.push(["NTMausoleum.ntj", 10]); MWConfig_ClearPathSpectypes.Mausoleum = 0; MWConfig_ClearAreaSpectypes.Mausoleum = 0x01; NTConfig_KillBloodRaven = true;
MWConfig_Script.push(["NTTristram.ntj", 10]); NTConfig_KillRakanishu = true;
MWConfig_Script.push(["NTHole.ntj", 10]); MWConfig_ClearPathSpectypes.Hole = 0; MWConfig_ClearAreaSpectypes.Hole = 0x01; NTConfig_ClearHoleLevel1 = 1; // 0 : don't clear, 1 : clear path only, 2 : clear all
MWConfig_Script.push(["NTTreehead.ntj", 10]);
MWConfig_Script.push(["MWColdcrow.ntj", 10]); MWConfig_ClearCaveMode = 0; // 0: Only kill coldcrow; 1: Clear Cave Level 1; 2: Clear both Cave Level 1 & 2
MWConfig_Script.push(["NTCountess.ntj", 5]); MWConfig_ClearPathSpectypes.Countess = 0; MWConfig_ClearAreaSpectypes.Countess = 0;
MWConfig_Script.push(["NTPit.ntj", 10]); MWConfig_ClearPathSpectypes.Pit = 0; MWConfig_ClearAreaSpectypes.Pit = 0x01; NTConfig_ClearPitLevel1 = 2; // 0 : don't clear, 1 : clear path only, 2 : clear all
MWConfig_Script.push(["NTAndariel.ntj", 10]);
// *********************** Act II **********************
MWConfig_Script.push(["NTRadament.ntj", 10]); MWConfig_ClearPathSpectypes.Radament = 0;
MWConfig_Script.push(["MWMaggotsLair.ntj", 10]); MWConfig_ClearPathSpectypes.MaggotsLair = 0; MWConfig_ClearAreaSpectypes.MaggotsLair = 0x01;
MWConfig_Script.push(["NTAncientTunnels.ntj", 10]); MWConfig_ClearPathSpectypes.AncientTunnels = 0; MWConfig_ClearAreaSpectypes.AncientTunnels = 0x01;
MWConfig_Script.push(["NTSummoner.ntj", 5]); NTConfig_KillFireEye = false; MWConfig_ClearPathSpectypes.Summoner = 0;
MWConfig_Script.push(["NTDuriel.ntj", 10]); MWConfig_ClearPathSpectypes.Duriel = 0;
// ********************** Act III **********************
MWConfig_Script.push(["MWFlayerJungle.ntj", 10]); MWConfig_ClearAreaSpectypes.FlayerJungle = 0x01;
MWConfig_Script.push(["MWKurastSewers.ntj", 5]); MWConfig_ClearPathSpectypes.KurastSewers = 0;
MWConfig_Script.push(["MWKurastTemples.ntj", 5]); MWConfig_ClearPathSpectypes.KurastTemples = 0; MWConfig_ClearAreaSpectypes.KurastTemples = 0x01;
MWConfig_Script.push(["NTTravincal.ntj", 5]);
MWConfig_Script.push(["NTMephisto.ntj", 5]); MWConfig_OpenMephistoChest = true; MWConfig_MephistoClearArea = true;
// *********************** Act IV **********************
MWConfig_Script.push(["NTIzual.ntj", 5]); MWConfig_ClearPathSpectypes.Izual = 0;
MWConfig_Script.push(["MWRiverOfFlame.ntj", 10]); MWConfig_ClearAreaSpectypes.RiverOfFlame = 0x01;
MWConfig_Script.push(["NTHephasto.ntj", 10]); MWConfig_ClearPathSpectypes.Hephasto = 0;
MWConfig_Script.push(["NTDiablo.ntj", 10]); MWConfig_KillFullInfectorMob = true; MWConfig_StartAtStar = false; MWConfig_IgnoreSealOpeningErrors = false; MWConfig_FastDia = true;
// *********************** Act V ***********************
MWConfig_Script.push(["MWAbbadon.ntj", 10]); MWConfig_ClearPathSpectypes.Abbadon = 0; MWConfig_ClearAreaSpectypes.Abbadon = 0x01;
MWConfig_Script.push(["MWPitOfAcheron.ntj", 10]); MWConfig_ClearPathSpectypes.PitOfAcheron = 0; MWConfig_ClearAreaSpectypes.PitOfAcheron = 0x01;
MWConfig_Script.push(["MWInfernalPit.ntj", 10]); MWConfig_ClearPathSpectypes.InfernalPit = 0; MWConfig_ClearAreaSpectypes.InfernalPit = 0x01;
MWConfig_Script.push(["MWHallsOfPain.ntj", 15]); MWConfig_ClearAreaSpectypes.HallsOfPain = 0x01; MWConfig_ClearHallsOfAnguish = true;
MWConfig_Script.push(["NTPindleskin.ntj", 5]); NTConfig_NihlathakExtension = false; MWConfig_SkipOnTombVipers = true;
MWConfig_Script.push(["NTEldritch.ntj", 5]); NTConfig_ShenkExtension = true;
MWConfig_Script.push(["NTThreshSocket.ntj", 5]); MWConfig_ClearPathSpectypes.ThreshSocket = 0;
MWConfig_Script.push(["NTFrozenRiver.ntj", 10]); MWConfig_ClearPathSpectypes.FrozenRiver = 0; MWConfig_ClearAreaSpectypes.FrozenRiver = 0x01;
MWConfig_Script.push(["NTGlacialTrail.ntj", 10]); MWConfig_ClearPathSpectypes.GlacialTrail = 0; MWConfig_ClearAreaSpectypes.GlacialTrail = 0x01;
MWConfig_Script.push(["NTIcyCellar.ntj", 5]); MWConfig_ClearPathSpectypes.IcyCellar = 0; MWConfig_ClearAreaSpectypes.IcyCellar = 0x01;
MWConfig_Script.push(["NTNihlathak.ntj", 5]); MWConfig_ClearPathSpectypes.Nihlathak = 0; NTConfig_PindleskinExtension = false; MWConfig_SkipOnTombVipers = true;
MWConfig_Script.push(["MWWorldstoneKeep.ntj", 10]); MWConfig_ClearAreaSpectypes.WorldstoneKeep = 0x01; MWConfig_SkipLevelOnWitches = true; MWConfig_SkipLevelOnSouls = false; MWConfig_SkipLevelOnDeathLords = true;
MWConfig_Script.push(["NTBaal.ntj", 10]); NTConfig_KillBaal = true; MWConfig_SkipBaalOnDolls = true; MWConfig_SkipBaalOnSouls = false; MWConfig_DoBaalPreAttack = true; MWConfig_ClearPathSpectypes.Baal = 0;
// *********************** Misc ************************
MWConfig_Script.push(["MWAuraStack.ntj", 10]); MWConfig_StackRepetitions = 100; MWConfig_ResetMercWeaponAfterStacking = false;
MWConfig_Script.push(["MWSuperChests.ntj", 20]); MWConfig_SuperChestClearAreaRadius = 10; MWConfig_SuperChestAreas = ["Cave Level 2", "Mausoleum", "Hole Level 2", "Pit Level 2", "Sewers Level 3", "Halls of the Dead Level 2", "Stony Tomb Level 2", "Maggot's Lair Level 3", "Ancient Tunnels", "Tal Rasha's Tomb", "Arachnid Lair", "Swampy Pit Level 3", "Flayer Dungeon", "Sewers Level 2", "Abbadon", "Pit of Acheron", "Drifter Cavern", "Infernal Pit", "Icy Cellar", "Halls of Pain"];
MWConfig_Script.push(["MWRush.ntj", 0]); MWConfig_IsRusher = true;
MWConfig_Script.push(["MWWaypointCatcher.ntj", 0]); MWConfig_WaypointCatcherActs = [1, 2, 3, 4, 5]; MWConfig_TPWaypoints = true; MWConfig_SkipHallsOfPain = true; MWConfig_ClearWaypointPaths = false;
MWConfig_Script.push(["MWIdleMode.ntj", 0]); MWConfig_IdleModeRuntime = 5; // Runtime in Minutes
MWConfig_Script.push(["NTCows.ntj", 10]);
MWConfig_Script.push(["MWBloodyRejuvs.ntj", 10]);
MWConfig_Script.push(["MWOrganHarvest.ntj", 10]); MWConfig_EnterInvalidUberPortals = true; MWConfig_PauseOnLackOfKeys = false; MWConfig_IntendedUberPortal = 0; // Matron's Den: 133; Forgotten Sands: 134; Furnace Of Pain: 135;
MWConfig_Script.push(["MWUberTristram.ntj", 10]); MWConfig_PauseOnLackOfOrgans = false; MWConfig_PauseOnKeptTorch = false;
MWConfig_Script.push(["MWAnyasBargain.ntj", 10]); MWConfig_ShoppingMinGold = 500000; MWConfig_ShoppingAttempts = 200;
// ************ Leech and friends by lanara ************
MWConfig_Script.push(["NTDiabloLeechFight.ntj", 10]); MWConfig_StartAtStar = true; MWConfig_EnterUnsafeTP = true; NTConfig_PreBuff = true; MWConfig_IgnoreSealOpeningErrors = true; NTConfig_Leader = "LeaderNameGoesHere";
MWConfig_Script.push(["NTBaalLeech.ntj", 10]); NTConfig_KillBaal = true; MWConfig_EnterUnsafeTP = false; NTConfig_Leader = "LeaderNameGoesHere";
MWConfig_Script.push(["NTBaalLeechFight.ntj", 10]); NTConfig_KillBaal = true; MWConfig_DoBaalPreAttack = true; MWConfig_EnterUnsafeTP = true; NTConfig_Leader = "LeaderNameGoesHere";
*/
//------------------------------------------------------------------------------
// Misc Configuration
//------------------------------------------------------------------------------
NTConfig_SkipHealLife = 90; // If you have more than this percent of life, you won't go to a healer.
NTConfig_SkipHealMana = 70; // 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.
// Exit game or to reset your Enigma if Teleport skill is missing (due to identifying an item having +x to Teleport [Sorceress only]). WARNING: Activating this feature may - though not likely will - result in the loss of your enigma. Use at your own risk and make sure your char has sufficient strength!
// 0: Don't do anything; 1: Reset armor; 2: Exit game
MWConfig_ResetArmorMode = 0;
//------------------------------------------------------------------------------
// Potion Configuration
//------------------------------------------------------------------------------
NTConfig_LifeThresh = 70; // Drink a normal potion if under this percent of life.
NTConfig_LifeRejuvThresh = 60; // 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 = 1; // Drink a rejuvenation potion if under this percent of mana.
NTConfig_MercLifeThresh = 50; // This is the threshold to use a life potion on your merc in percent.
NTConfig_MercRejuvThresh = 30; // This is the threshold to use a rejuv potion on your merc in percent.
//------------------------------------------------------------------------------
// Chicken Configuration
//------------------------------------------------------------------------------
// This is your chicken life. If you go below this threshhold, your char will exit the game. You can either enter a percentage (1-100), an absolute threshold (>100) or 0 to deactivate life chicken.
NTConfig_LifeChicken = 30;
// This is your chicken mana. If you go below this threshhold, your char will exit the game. You can either enter a percentage (1-100), an absolute threshold (>100) or 0 to deactivate mana chicken.
NTConfig_ManaChicken = 0;
// This is your merc's chicken life in percent. If your merc goes below this threshhold, your char will exit the game.
NTConfig_MercChicken = 0;
// Whether or not to disable chicken when you pause the bot.
MWConfig_DisableChickenOnPause = true;
//------------------------------------------------------------------------------
// Inventory Configuration
//------------------------------------------------------------------------------
// Each number represents a slot in your inventory.
// Set to 0 if the slot and its content must not be touched.
// Set to 1 to allow access to this slot.
// Set to 2 to select the slot that is used for storing keys. (if keys are kept at another slot, your char will try to move them)
NTConfig_Columns[0] = [1,1,1,1,1,1,1,1,2,0];
NTConfig_Columns[1] = [1,1,1,1,1,1,1,1,1,0];
NTConfig_Columns[2] = [1,1,1,1,1,1,1,1,1,0];
NTConfig_Columns[3] = [1,1,1,1,1,1,1,1,1,0];
// Number of free columns. If less full columns are free stashing is set. Call SetFreeColumns(NTConfig_Columns) to always stash right away (recommended).
NTConfig_FreeSpace = SetFreeColumns(NTConfig_Columns);
// Maximum gold amount carried before going to stash.
NTConfig_MinGoldToStash = 100000;
// Set to true if your char is supposed to carry, buy and pick up keys. You do not need to add keys to your .nip files, they will be picked up anyway if this is set to true.
MWConfig_CarryKeys = true;
//------------------------------------------------------------------------------
// Belt Configuration
//------------------------------------------------------------------------------
// Available types : "hp" = health, "mp" = mana, "rv" = rejuvenation.
// Define how many columns are used for each potion type.
MWConfig_BeltColType["hp"].Columns = 1;
MWConfig_BeltColType["mp"].Columns = 1;
MWConfig_BeltColType["rv"].Columns = 2;
// Define minimum number of potions per column. If the actual number of potions in a column is below this value, your char will visit a merchant when in town in order to buy potions.
MWConfig_BeltColType["hp"].MinPots = 3;
MWConfig_BeltColType["mp"].MinPots = 3;
// Visit Town and buy potions if your char lacks mana when trying to loot a corpse or teleport.
MWConfig_BuyPotionsOnLackOfMana = true;
// Set to true to replace low quality potions with higher quality potions that just dropped.
MWConfig_ReplaceLowQualityPotions = true;
//-----------------------------------------------------------------------------------
// NipFile Configuration
//-----------------------------------------------------------------------------------
NTConfig_NIPFilePath.push("private/normal.nip");
NTConfig_NIPFilePath.push("private/magic_rare.nip");
NTConfig_NIPFilePath.push("private/set.nip");
NTConfig_NIPFilePath.push("private/unique.nip");
NTConfig_NIPFilePath.push("private/craft.nip");
NTConfig_NIPFilePath.push("private/temp.nip");
//------------------------------------------------------------------------------
// Pickit Configuration
//------------------------------------------------------------------------------
// Radius to check for dropped items. NOTE: The maximum is at about ~75, entering higher values will not have any effect.
NTConfig_SnagRange = 70;
// Set to true to check for dropped items whenever you kill a monster. (Recommended value to avoid crashes: false)
MWConfig_PickItemsInstantly = true;
//------------------------------------------------------------------------------
// Chest Configuration
//------------------------------------------------------------------------------
// Select which containers shall be looted. 0: None; 1: Super Chests, 2: All
MWConfig_OpenContainerMode = 2;
// Set to true to check for dropped items right after opening a chest. NOTE: This will slow down your runs and therefore should definately be set to false when doing private games.
MWConfig_PickChestLootsInstantly = true;
// This is the range being checked for chests after clearing an area or room. NOTE: You should not set this too high, 30 is a good value.
MWConfig_OpenChestsRange = 30;
// If you do not like to open chests in a certain area, you can its areaid as an exception below. NOTE: All areaids can be found in "sdk\areas.txt".
// MWConfig_ChestExceptions.push(<areaid1>, <areaid2>, <areaidn>);
//------------------------------------------------------------------------------
// Cubing Configuration
//------------------------------------------------------------------------------
// Set to true to enable cubing and crafting. NOTE: The recipes are added in the global config by default. If you like to craft certain recipe only using this very char, add those recipes below.
NTConfig_Cubing = true;
//------------------------------------------------------------------------------
// General Configuration
//------------------------------------------------------------------------------
// Set to true to activate public mode. By activating public mode, your char will form a party, open TPs and do some chat outputs when running certain bot scripts.
NTConfig_PublicMode = true;
// Set to true to exit the game instantly if the game is public. This may happen sometimes due to an error pasting the password correctly.
MWConfig_ExitGameOnMissingPassword = false;
// Set to true to exit the game when another player expresses hostility towards you.
me.quitonhostile = false;
// This is the maximum time in seconds your char will remain in a single game. Set to 0 to stay in game infinitely.
me.maxgametime = 3000;
// This is the minimum time in seconds for your char to remain in a single game. Your char will not exit the game before this time elapsed.
me.mingametime = 180;
//------------------------------------------------------------------------------
// Automule Configuration
//------------------------------------------------------------------------------
// Set to true to enable auto mule.
MWConfig_Automule.Activated = false;
// The maximum stash load in percent before auto mule is triggered.
MWConfig_Automule.MaxLoad = 95;
// Set to true to show your stash's current load whenever managing stash.
MWConfig_Automule.ShowCurrentLoad = true;
// Set to true to finish your current game before muling, otherwise the game is left right away in case your stash is full.
MWConfig_Automule.FinishGame = true;
// Define which items are not to be touched when muling.
MWConfig_Automule.DontMule.push("mule/dont_mule.nip");
MWConfig_Automule.DontMule.push("mule/gems.nip");
//------------------------------------------------------------------------------
// Shrine Configuration
//------------------------------------------------------------------------------
// Set to true to activate nearby shrines. Shrines will only be activated if it is actually useful.
MWConfig_ActivateNearbyShrines = true;
// If you would like to skip shrines in a certain area, you can its areaid as an exception below. NOTE: All areaids can be found in "sdk\areas.txt".
// MWConfig_ShrineExceptions.push(<areaid1>, <areaid2>, <areaidn>);
//------------------------------------------------------------------------------
// Precast Configuration
//------------------------------------------------------------------------------
// Your precast skills can be defined in the array below. NOTE: Battle Command, Battle Orders and Shout will be cast automatically. Constants for all skill ids can be found in "scripts\libs\common\MWSkills.ntl".
MWConfig_PrecastSkills = [MWS_HOLY_SHIELD];
// Set this to true if you would like to switch slots right after casting BC, BO and Shout. If set to false, your char will remain with the BO Slot until the whole precast procedure is done.
MWConfig_SwitchSlotsAfterBoPrecast = true;
//------------------------------------------------------------------------------
// Attack Configuration
//------------------------------------------------------------------------------
// Specify your attack skills below. NOTE: Constants for all skill ids can be found in "scripts\libs\common\MWSkills.ntl".
NTConfig_AttackSkill[0] = -1; // This skill is used once whenever attacking a new target. Set to -1 to deactivate.
NTConfig_AttackSkill[1] = MWS_BLESSED_HAMMER; // Primary skill to bosses.
NTConfig_AttackSkill[2] = MWS_CONCENTRATION; // Primary aura to bosses. Set to -1 to deactivate.
NTConfig_AttackSkill[3] = MWS_BLESSED_HAMMER; // Primary skill to others.
NTConfig_AttackSkill[4] = MWS_CONCENTRATION; // Primary aura to others. Set to -1 to deactivate.
NTConfig_AttackSkill[5] = MWS_HOLY_BOLT; // Secondary skill in case monster is immune to primary skill. Set to 0 if you won't
NTConfig_AttackSkill[6] = MWS_CONCENTRATION; // Secondary aura. Set to 0 not to activate any aura.
NTConfig_AttackSkill[7] = MWS_SALVATION; // Aura to be used against Uber Mephisto. Set to -1 to deactivate.
// Set to true if you want to clear area after killing boss. NOTE: This only affects a few botscripts.
NTConfig_ClearPosition = true;
// Set to true to clear area when killing a boss and the position is crowded by monsters. NOTE: Setting this to true may cause NTA_KillMonster() to fail way more often.
MWConfig_ClearBossPosition = false;
// This is the number of attacks to be performed before the the character tries to move to another position. Set to 0 not to reposition.
MWConfig_AttacksBeforeRepositioning = 25;
// Define a time limit for your attacks for each type of monster.
MWConfig_AttackTimeLimit[0] = 20; // Maximum time in seconds to attack a normal monster
MWConfig_AttackTimeLimit[1] = 120; // Maximum time in seconds to attack a super unique monster
MWConfig_AttackTimeLimit[2] = 30; // Maximum time in seconds to attack a champion
MWConfig_AttackTimeLimit[3] = 120; // Maximum time in seconds to attack a bosse
MWConfig_AttackTimeLimit[4] = 30; // Maximum time in seconds to attack a minion
// Define when a monster is considered immune by entering the index of one or more of your attack skills. As an example: [1, 3] means that a monster is considered immune if it is immune to both NTConfig_AttackSkill[1] and NTConfig_AttackSkill[3], whatever those may be.
MWConfig_CheckImmunitySkills = [];
// Select the behaviour of your character when encountering a monsters that is considered immune referring to the definition above.
// 0: Don't do anything. (D2NT default)
// 1: Get close to the monster.
// 2: Skip the monster.
// 3: Attack the monster using NTConfig_AttackSkill[8] and NTConfig_AttackSkill[9]
NTConfig_BehaviourOnImmuneMonster = 0;
NTConfig_AttackSkill[8] = -1; // Skill to be used against user defined immunes.
NTConfig_AttackSkill[9] = -1; // Untimed Skill to be used against user defined immunes.
// Activate Redemption if your health is lower than this percentage. Set to 0 not to use Redemption.
NTConfig_UseRedemptionHP = 80;
// Activate Redemption if your health is lower than this percentage. Set to 0 not to use Redemption.
NTConfig_UseRedemptionMP = 60;
// Select whether or not you'd like to swap slots right before killing a boss in order to benefit from some extra MF in your second slot.
// The first element can either be the classid of the target or its name (case insensitive), second element is the life threshold in percent.
//MWConfig_SlotSwapMonsters.push([156, 50]); // Andariel, 50%
//MWConfig_SlotSwapMonsters.push([211, 20]); // Duriel, 20%
//MWConfig_SlotSwapMonsters.push([242, 20]); // Mephisto, 20%
//MWConfig_SlotSwapMonsters.push([243, 20]); // Diablo, 20%
//MWConfig_SlotSwapMonsters.push([544, 15]); // Baal, 15%
// 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 = 0;
// 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;
}
Code:
/**
* This file was written by
* Check the programming section for updates and further scripts
* Last Update: 15:19 05.11.2011
*/
Include("libs/common/MWSkills.ntl");
function MW_LoadGlobalSettings()
{
//------------------------------------------------------------------------------
// General Configuration
//------------------------------------------------------------------------------
// Set to false will disable auto mule for all chars. Note that you have to set both this variable and MWConfig_Automule.Activated (in you char config) to true in order to enable auto mule for a char.
MWConfig_Automule.Enabled = false;
// Set to true to buy items that match your Nips whenever visiting a merchant.
MWConfig_DoShopping = true;
// Set to true to have the status text show the script runtime. (Note: enabling this might lead to an increased number of crashes/restarts.)
MWConfig_EnableStatusTextTimer = true;
// Set to true to always check the selected Nips for errors after including them. Check "..\scripts\Logs\NipErrors.txt" for a precise error description!
MWConfig_RunNipCheck = false;
// Set to true to run sorting algorithm whenever managing your stash.
MWConfig_SortStash = true;
// Set to true to run sorting algorithm if your stash is full and items are stored in your inventory.
MWConfig_SortInventory = true;
// Set to true to form a party even if public mode is deactivated.
MWConfig_AutoParty = true;
// This is the maximum number of errors that may occur in a single game. If more errors occur, your char will exit the game.
MWConfig_GameErrorLimit = 3;
// This is the delay in milliseconds before the first bot script is loaded.
NTConfig_StartDelay = 500;
// This is the delay in milliseconds on area changes. Do not set this too low!
NTConfig_AreaDelay = 750;
// This is the delay in milliseconds before picking up items. Do not set this too low!
NTConfig_SnagDelay = 750;
// This is the delay in milliseconds after finishing a bot script.
MWConfig_ScriptDelay = 1000;
// Set to true to enable overhead status messages. NOTE: This will be visible for everyone in the game so you might not want to activate it when doing public games.
MWConfig_ShowOverheadStatus = true;
// Define a list of chars that may be in your bot's game. If a player enters your game who is not in that list, your bot will leave the game. To disable this options, simply don't add any chars to the list or known players.
// MWConfig_KnownPlayers.push("SomeBuddyOfMine'sCharName", "AnotherBuddy'sCharName");
// Define which negative states on your char require visiting a healer when in town. Set to 0 not to visit a healer.
// 0x02 : Poison
// 0x04 : Amplify Damage
// 0x08 : Weaken
// 0x10 : Iron Maiden
// 0x20 : Decrepify
// 0x40 : Lower Resist
MWConfig_CheckSelfSafeTown = 0x0C;
// Define which negative states on your merc require visiting a healer when in town. Set to 0 not to visit a healer.
// 0x02 : Poison
// 0x04 : Amplify Damage
// 0x08 : Weaken
// 0x10 : Iron Maiden
// 0x20 : Decrepify
// 0x40 : Lower Resist
MWConfig_CheckMercSafeTown = 0;
//------------------------------------------------------------------------------
// Chat Announcements
//------------------------------------------------------------------------------
// These announcements will not be made unless NTConfig_PublicMode is set to true. Set to "" not to post a message.
// NOTE: You have to set a TPSafe message when using leechers and not entering unsafe TPs.
/*
MWConfig_Announcements.BaalThrone = "There are %d monster(s) in Throne!";
MWConfig_Announcements.BaalTpNone = "TP is safe!";
MWConfig_Announcements.BaalTpCold = "TP cold, %d monsters close!";
MWConfig_Announcements.BaalTpWarm = "TP warm, %d monsters close!";
MWConfig_Announcements.BaalTpHot = "TP hot, %d monsters close!";
MWConfig_Announcements.BaalTpSafe = "TP is safe!";
MWConfig_Announcements.BaalPreChamber = "Killing Baal!";
*/
MWConfig_Announcements.BaalKilled = "Next game!";
/*
MWConfig_Announcements.DiabloTpNone = "TP up, no monsters close!";
MWConfig_Announcements.DiabloTpCold = "TP cold, %d monsters close!";
MWConfig_Announcements.DiabloTpWarm = "TP warm, %d monsters close!";
MWConfig_Announcements.DiabloTpHot = "TP hot, %d monsters close!";
MWConfig_Announcements.DiabloTpSafe = "TP is safe!";
MWConfig_Announcements.DiabloPre = "Killing Diablo!";
*/
MWConfig_Announcements.DiabloKilled = "Next game!";
// Message to announce right before leaving a game.
MWConfig_Announcements.NextGame = "Next game!";
// Minimum char level to show level up message. Set to 99 to deactivate level up messages.
MWConfig_Announcements.ShowLevelUpMessagMinLevel = 75;
// These level up messages will be posted in chat whenever another player in game has a level up. (chosen randomly)
MWConfig_Announcements.LevelUpMessages.push("Congratulations on level %level, %name!");
MWConfig_Announcements.LevelUpMessages.push("Nice level up, %name!");
MWConfig_Announcements.LevelUpMessages.push("Good job reaching level %level, %name!");
MWConfig_Announcements.LevelUpMessages.push("Congratulations are in order, for %name just reached level %level!");
//------------------------------------------------------------------------------
// Bulletin Board Output Configuration
//------------------------------------------------------------------------------
// Select the path of your output textfile. The file extension .txt is added automatically.
MWConfig_BulletinBoardFilePath = "Logs/BBOutput";
// Select the mode for writing to the output textfile. Use 1 to overwrite the existing content and use 2 to append to the existing content.
MWConfig_BulletinBoardFileMode = 1;
// Define the colors used for replacing the D2 color codes. WARNING: You should not change these unless you are familiar with hexadecimal colors.
MWConfig_BulletinBoardColors["white"] = "#FFFFFF";
MWConfig_BulletinBoardColors["red"] = "#CD0000";
MWConfig_BulletinBoardColors["green"] = "#00FF00";
MWConfig_BulletinBoardColors["blue"] = "#3A5FCD";
MWConfig_BulletinBoardColors["gold"] = "#8B814C";
MWConfig_BulletinBoardColors["gray"] = "#606060";
MWConfig_BulletinBoardColors["orange"] = "#FF8C00";
MWConfig_BulletinBoardColors["yellow"] = "#FFFF00";
//------------------------------------------------------------------------------
// User Defined Commands
//------------------------------------------------------------------------------
// This feature allows you to assign some commands to your numpad.
// The current assignment is shown by pressing "Numpad +".
//
// Command Name Description
// -----------------------------------------------------------------------------
// ShowChickenThresholds Shows your chars current chicken thresholds.
// ShowTotalGoldCarried Shows the amount of gold your char currently carries.
// ShowActiveStates Shows the active states or your char.
// ShowScriptOrder Shows the current bot script schedule.
// ShowStash Shows the current layout of your stash and how many slots are used/unused.
// ClearPosition_X Kills all monsters in a radius of X. NOTE: Will not work while a bot script is running.
// PickItems Check for dropped items. NOTE: Will not work while a bot script is running.
// RevealMap Reveals the automap.
// ShowEnemiesOnMap Shows nearby enemies on automap.
// ShowMisslesOnMap Shows nearby missles on automap.
// ShowKeysCarried Shows how many of each type of key your character currently carries.
// ShowOrgansCarried Shows how many of each type of organ your character currently carries.
// ShowRunesCarried Shows how many runes of each type your character currently carries.
// ShowItemLevel Shows the item level and nip info of a selected item. NOTE: "Selected" means placed in your cube. ;)
// WriteBBOutput Generates BB Code output for a selected item's description. NOTE: "Selected" means placed in your cube. ;)
// -----------------------------------------------------------------------------
// ShowObjectUnits_X Shows the properties of all object units in a radius of X.
// ShowNpcUnits_X Shows the properties of all npc units in a radius of X.
// ShowPlayerUnits_X Shows the properties of all player units in a radius of X.
// ShowItemUnits_X Shows the properties of all item units in a radius of X.
// ShowTileUnits Shows the properties of all nearby tile units.
MWConfig_CommandAssignedToNumpad[0] = "ShowScriptOrder";
MWConfig_CommandAssignedToNumpad[1] = "ShowStash";
MWConfig_CommandAssignedToNumpad[2] = "ShowTotalGoldCarried";
MWConfig_CommandAssignedToNumpad[3] = "ShowChickenThresholds";
MWConfig_CommandAssignedToNumpad[4] = "ShowOrgansCarried";
MWConfig_CommandAssignedToNumpad[5] = "ShowKeysCarried";
MWConfig_CommandAssignedToNumpad[6] = "ShowRunesCarried";
MWConfig_CommandAssignedToNumpad[7] = "ShowMisslesOnMap";
MWConfig_CommandAssignedToNumpad[8] = "ShowEnemiesOnMap";
MWConfig_CommandAssignedToNumpad[9] = "RevealMap";
//------------------------------------------------------------------------------
// World Event Configuration
//------------------------------------------------------------------------------
// Set to true to stop and wait some minutes after receiving "x Stones of Jordan sold to Merchants" message. Your char will switch acts every couple of minutes so he won't be kicked.
MWConfig_CheckSojSales = true;
// Set to true to wait ingame after receiving a "Diablo Walks the Earth" message. Your char will switch acts every couple of minutes so he won't be kicked.
NTConfig_CheckCloneDiablo = true;
// Enter an account name that will be informed about soj sales or world events. Leave empty not to wisper any account.
MWConfig_WorldEventAccount = "";
// This is the time in minutes your char will remain in the game in case of a world event. Set to 0 to wait infinitely.
MWConfig_WorldEventWaitTime = 0;
// This can be used to specify IPs of servers that are currently hot, i.e. if a considerable amount of sojs has been sold on a server and thus a World Event is in order. The char will check if his current game IP is included in your list and wait in case it is.
MWConfig_HotServerIps = [-1, -1];
// This is the time in minutes that you would like your char to wait for in case his current game is hosted on a hot server.
MWConfig_HotIpIdleTime = 10;
//------------------------------------------------------------------------------
// Identification Configuration
//------------------------------------------------------------------------------
// Set to true to visit Deckard Cain in order to identify items. NOTE: Cain will NOT be visited if you char carries items that you like to be kept unidentified.
MWConfig_IdentAtCain = true;
// Set to true to always visit a merchant in order to sell items that are not required. If set to false, the char will drop these items, unless he is visiting a merchant anyway.
MWConfig_AlwaysSellTrashItems = true;
// Set to true to identify items when not in town. Items that do not meet your requirements will be dropped.
MWConfig_IdentAfterPickup = false;
// This is the minimum number of unid items to be carried before your char identifies them when not in town.
MWConfig_MinItemsToIdent = 3;
//------------------------------------------------------------------------------
// Itemlog Configuration
//------------------------------------------------------------------------------
// Set to true to log both sold and kept items in an XML logfile that can be viewed in a browser. NOTE: For some reason that does not work using IE, try Firefox instead.
// Also, using the XML log is known for increasing the number of crashes/restarts, better set this to false if you not necessarily need it.
MWConfig_UseXMLItemlog = false;
// Set to true to activate Nip debug mode. The Nip debug mode adds additional information to the item tooltips in the manager's item log that tells you exactly why an item was kept.
MWConfig_NipDebugMode = false;
// Set to true to log items in manager's log that were not required and therefore sold. NOTE: You should definately set this to false when running multiple bots. Use the XML log instead in order to keep track of sold items. ;)
MWConfig_LogSoldItems = false;
// Set to true to print how much gold was picked up during the last script after it is finished. Quite useful when using a goldbarb.
MWConfig_ShowGoldPickupsPerScript = false;
// Set to true to show a pick up message for gold.
MWConfig_ShowGoldPickups = true;
// Set to true to show a pick up message for potions.
MWConfig_ShowPotionPickups = true;
// This is the number of the lowest rune to be logged in the manager's item log when picked up. Mostly useful to keep your item log clean when collecting low runes. The default value 19 means that only runes equal or greater than LEM will be shown in the manager's item log.
MWConfig_LowestRuneToLog = 0;
// Set to true to create a Muddy's Mule Manager logfile at the end of every game.
MWConfig_WriteMMMLog = true;
// Set to true to write a common lofiles that logs how many gems, runes, keys, organs or essences your chars picked up.
MWConfig_WriteCommonLog = false;
// Show a drop notification on drops of items matching the below Nip line. Set to "" not to detect drops.
MWConfig_ShowDroppedItemSpecs = "[Quality] == Unique || [Quality] == Set || [Type] == Rune || [Flag] == Runeword";
//------------------------------------------------------------------------------
// Pickit Configuration
//------------------------------------------------------------------------------
// Set to true to pick up possibly useful items before picking up low priority items like keys, scrolls, gold, potions, and runes <= FAL.
MWConfig_PickUpPriorityItemsFirst = false;
// Pick up all items that are likely to be worth a lot of gold whenever your character is about to visit town.
MWConfig_PickUpMoneymakers = true;
// This is the minimum quantity of TP scrolls in your tome. If you got less, scrolls will be picked up in order to fill your tome.
MWConfig_MinimumTpScrollCount = 20;
// This is the minimum quantity of ID scrolls in your tome. If you got less, scrolls will be picked up in order to fill your tome.
MWConfig_MinimumIdScrollCount = 20;
//------------------------------------------------------------------------------
// Gambling Configuration
//------------------------------------------------------------------------------
// Set to true to enable gambling.
NTConfig_Gamble = true;
// This is the gold mount to start gambling.
NTConfig_GambleStartGold = 2300000;
// This is the gold mount to stop gambling.
NTConfig_GambleStopGold = 150000;
// Select which items are gambled by adding the classids of the desired items to the gambling array.
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
// NTConfig_GambleItem.push(<classid>);
//------------------------------------------------------------------------------
// Cubing Configuration
//------------------------------------------------------------------------------
// Set to true to log cubing of gems in the manager's common log.
MWConfig_ShowCubedGemsInCommonLog = false;
// Set to true to always remove all items from cube after transmuting. If set to false, the item will remain in cube and is not removed until it interferes with another recipe.
MWConfig_ClearCubeAfterCubing = false;
// Set to true to enable an advanced cubing algorithm that allows collecting ingredients for multiple recipes at the same time.
MWConfig_UseAdvancedCubingAlgorithm = true;
// Set to true if you do not want kept low runes or gems to be used for cubing. Set to false to use them anyway.
MWConfig_RestrictKeptItemsFromCubing = false;
// *********************** Misc ***********************
NTConfig_CubingItem.push([NTCU_ESSENCE, 653]); // Essences --> Token
// ****************** Transmute Gems ******************
//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
// ************* Transmute magic and rares *************
//NTConfig_CubingItem.push([NTCU_MAGIC_CHARM, 603]); // Magic Small Charm
//NTConfig_CubingItem.push([NTCU_MAGIC_CHARM, 605]); // Magic Grand Charm
//NTConfig_CubingItem.push([MWCU_RARE, 421]); // Rare Diadem
// ********************** Crafting *********************
//NTConfig_CubingItem.push([NTCU_CRAFT_HITPOWER_GLOVES, 336]); // Craft Chain Gloves
//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_HITPOWER_RING, 522]); // Craft Ring
//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_BOOTS, 455]); // Craft Wyrmhide Boots
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
// ****************** Transmute runes ******************
//NTConfig_CubingItem.push([NTCU_RUNE_THUL, 562]); // Transmute 3xTHUL --> 1xAMN
//NTConfig_CubingItem.push([NTCU_RUNE_AMN, 557]); // Transmute 3xAMN --> 1xSOL
//NTConfig_CubingItem.push([NTCU_RUNE_SOL, 567]); // Transmute 3xSOL --> 1xSHAEL
//NTConfig_CubingItem.push([NTCU_RUNE_SHAEL, 577]); // Transmute 3xSHAEL --> 1xDOL
//NTConfig_CubingItem.push([NTCU_RUNE_DOL, 572]); // Transmute 3xDOL --> 1xHEL
//NTConfig_CubingItem.push([NTCU_RUNE_HEL, 582]); // Transmute 3xHEL --> 1xIO
//NTConfig_CubingItem.push([NTCU_RUNE_IO, 563]); // Transmute 3xIO --> 1xLUM
//NTConfig_CubingItem.push([NTCU_RUNE_LUM, 558]); // Transmute 3xLUM --> 1xKO
//NTConfig_CubingItem.push([NTCU_RUNE_KO, 568]); // Transmute 3xKO --> 1xFAL
//NTConfig_CubingItem.push([NTCU_RUNE_FAL, 578]); // Transmute 3xFAL --> 1xLEM
//NTConfig_CubingItem.push([NTCU_RUNE_LEM, 573]); // Transmute 3xLEM --> 1xPUL
NTConfig_CubingItem.push([NTCU_RUNE_PUL, 583]); // Transmute 2xPUL --> 1xUM
NTConfig_CubingItem.push([NTCU_RUNE_UM, 564]); // Transmute 2xUM --> 1xMAL
NTConfig_CubingItem.push([NTCU_RUNE_MAL, 559]); // Transmute 2xMAL --> 1xIST
//NTConfig_CubingItem.push([NTCU_RUNE_IST, 569]); // Transmute 2xIST --> 1xGUL
NTConfig_CubingItem.push([NTCU_RUNE_GUL, 579]); // Transmute 2xGUL --> 1xVEX
//NTConfig_CubingItem.push([NTCU_RUNE_VEX, 574]); // Transmute 2xVEX --> 1xOHM
//NTConfig_CubingItem.push([NTCU_RUNE_OHM, 584]); // Transmute 2xOHM --> 1xLO
//NTConfig_CubingItem.push([NTCU_RUNE_LO, 565]); // Transmute 2xLO --> 1xSUR
//NTConfig_CubingItem.push([NTCU_RUNE_SUR, 560]); // Transmute 2xSUR --> 1xBER
//NTConfig_CubingItem.push([NTCU_RUNE_BER, 570]); // Transmute 2xBER --> 1xJAH
//NTConfig_CubingItem.push([NTCU_RUNE_JAH, 580]); // Transmute 2xJAH --> 1xCHAM
//NTConfig_CubingItem.push([NTCU_RUNE_CHAM, 575]); // Transmute 2xCHAM --> 1xZOD
// ******************* Socket items ********************
// Primary item must inlcluded in one of your .nip Files
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 429]); // Socket Dusk Shroud
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 430]); // Socket Wyrmhide
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 431]); // Socket Scarab Husk
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 432]); // Socket Wire Fleece
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 433]); // Socket Diamond Mail
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 434]); // Socket Loricated Mail
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 435]); // Socket Bone Weave
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 436]); // Socket Great Hauberk
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 437]); // Socket Balrog Skin
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 438]); // Socket Hellforge Plate
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 439]); // Socket Kraken Shell
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 440]); // Socket Lacquered Plate
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 441]); // Socket Shadow Plate
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 442]); // Socket Sacred Armor
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 443]); // Socket Archon Plate
//NTConfig_CubingItem.push([NTCU_SOCKET_WEAPON, 200]); NTConfig_CubingItem[NTConfig_CubingItem.length - 1].Ethereal = false; // Socket Berserker Axe
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_SOCKET_SHIELD, 447]); NTConfig_CubingItem[NTConfig_CubingItem.length - 1].Ethereal = true; // Socket Monarch
NTConfig_CubingItem.push([NTCU_SOCKET_SHIELD, 498]); NTConfig_CubingItem[NTConfig_CubingItem.length - 1].Ethereal = true; // Socket Sacred Targe
NTConfig_CubingItem.push([NTCU_SOCKET_SHIELD, 502]); NTConfig_CubingItem[NTConfig_CubingItem.length - 1].Ethereal = true; // Socket Vortex Shield
// ******************* Upgrade items *******************
//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
//NTConfig_CubingItem.push([NTCU_UPGRADE_N_UNIQUE_ARMOR, 342]); // Goblin Toe N -> E
//NTConfig_CubingItem.push([NTCU_UPGRADE_E_UNIQUE_ARMOR, 388]); // Goblin Toe E -> E
}
|
|
|
01/23/2012, 11:01
|
#5394
|
elite*gold: 0
Join Date: Jan 2009
Posts: 7,310
Received Thanks: 2,205
|
Quote:
Originally Posted by brain_91
mein Bot macht irgendwie keine Safe TP Message, alles andere funktioniert, von Bots und Leechbots usw ist alles in Ordnung, wenn ich jetzt aber andere Mitspieler in einem privaten Botrun einlade, dann brauchen die eben diese Safe TP Nachricht aber er posted einfach nichts.. ich post euch hier mal meine charconfig und meine botconfig rein
Code:
/**
* This file was modified by
* Check the programming section for updates and further scripts
* Last Update: 11:25 05.11.2011
*/
//------------------------------------------------------------------------------
// Delays
//------------------------------------------------------------------------------
var GameMinLength = 200; // Time in seconds, minimum game length, 180 seconds default (1 game/3 minutes).
var UnableToConnectRetry = 5; // Time in minutes to retry connecting on connection fail (real value is +/- 1 min).
var RealmDownRetry = 15; // Time in minutes to retry connecting on a realm down (default is 300 minutes).
var DisconnectedRetry = 5; // Time in minutes to retry on a disconnection (usually ip ban related).
var CdKeyInUseRetry = 5; // Time in minutes to retry on a cdkey in use error message (set to 0 to stop).
var ConnectingToBnetTimeout = 20; // Time in seconds to wait for a login to Time out and click cancel and retry.
var CharacterScreenTimeout = 10; // Time in seconds to wait for character screen to appear.
var PleaseWaitTimeout = 10; // Time in seconds to wait for a please wait popup.
var CreateGameThreshold = 10; // Time in seconds to wait between making games.
var CreateGameThresholdRandom = 5; // Time in seconds to randomly add +/- to the game create time.
var CreateGameTimeout = 15; // Time in seconds to register a failed to create game.
var WaitInLineTimeout = 60; // Time in seconds to wait in lines for a create game (60 second default).
var CharacterSelectDelay = 1000; // Time in milliseconds to wait before selecting a character on the char screen.
var GameDoesNotExistDelayMin = 10; // How long to wait when a Game Does Not Exist occurs - minimum - default 10 minutes.
var GameDoesNotExistDelayMax = 15; // How long to wait when a Game Does Not Exist occurs - maximum - default 15 minutes.
var GameDoesNotExistTimeout = 30; // How long to wait for the dialog to disappear (default 30 seconds, don't change this).
// Control
var LoginDelay = 5000; // Time in milliseconds to wait before submitting login information.
var ClickDelay = 2000; // Wait X milliseconds before next action after a click event.
var TextDelay = 2500; // Wait X milliseconds before next action after inserting text into a textbox.
var ClickDelayRandom = 500; // Random amount of Time in milliseconds to add to a click.
var TextDelayRandom = 500; // Random amount of Time in milliseconds to add to a text set.
// Channel
var WaitBeforeEnterChatMin = 1000; // Min time in milliseconds to wait before entering chat.
var WaitBeforeEnterChatMax = 2000; // Max time in milliseconds to wait before entering chat.
var WaitInChatBeforeActionsMin = 2000; // Min time in milliseconds to wait before joining channel.
var WaitInChatBeforeActionsMax = 3000; // Max time in milliseconds to wait before joining channel.
var GameAnnouncementDelay = 500; // Wait X milliseconds before posting the announcement message (don't set this too low!).
var GameAnnouncementDelayRandom = 50; // Random amount of time to add to a to the announcement delay.
var UseFileBackupTimeMax = 30; // Time in minutes that may pass since last file update - The backup File is updated at the beginning of every single game and is read everytime the name of your previous game is undefined (e.g. at restarts); Set to 0 to deactivate file backup.
//------------------------------------------------------------------------------
// Game settings
//------------------------------------------------------------------------------
var PlayersPerGame = 8; // Maximum number of players to be set when creating a game.
var CharacterDifference = 35; // Level difference to be set when creating games. Set to 0 not to use level restrictions.
var GameDescription = ""; // The description to be used for your game. Set to "" not to enter a game description.
var JoinRandomGamesChars = new Array("YourNameGoesHere");// Dynamic array that holds chars that are to join public games.
var JoinGameKeywords = new Array("dia", "baal"); // If your char is set to join public games, games will only be joined if the game name contains one of the given keywords.
//------------------------------------------------------------------------------
// Channel Settings
//------------------------------------------------------------------------------
var IgnoreWispers = false; // Set to true to ignore all incoming wispers from players that are not on your friendlist.
var JoinChatAfterLogin = true; // Join chat after login.
var JoinRandomChannel = false; // If this is true, will join a random channel, otherwise it will use the channel below..
var JoinChannelInChat = "Op pornobaal"; // Leave blank not to join a private channel.
var PerformChannelLogin = true; // Type ".login" once after joining the channel.
var ChannelUsers = new Array(); // Dynamic array that holds channel users.
// Add any char/account here that is supposed to perform chat actions/game announcements or join a private channel
ChannelUsers.push("pinapple");
// Or
ChannelUsers.push("orangensaft3");
// The following key expressions will be replaced by their actual values: %game --> "gamename-" <> %counter --> number of the next game <> %time --> time in seconds till game creation <> %password --> game password
// Note that the announcement will start after the first run, so there usually won't be any anncouncement right after login - If the gamename is undefined, the bot will try to load the backup file to announce the upcoming game properly.
var GameAnnouncement = "Creating %game%counter/// in about %time seconds.";
var ShowStatusOnStartup = true;
var JoinRetries = 5; // How many attempts before giving up the mule game?
var JoinRetryDelay = 55; // Seconds to wait between Retry Attempts.
var TimeBeforeMuleGame = 1; // Minutes to wait before creating the game.
var TimeAfterMule = 3; // Minutes to wait before logging back to bot account.
var WaitOnBlockedAccount = 2; // Minutes to wait if the mule account is currently being used by another char (this delay will be used up to 20 times).
//------------------------------------------------------------------------------
// Misc
//------------------------------------------------------------------------------
var MaximumLocationLoops = 5; // The maximum number of loops for a single location; if the window is does not respond and is caught in an infinite loop it will be restarted when the number of loops exceeds the one you specify here.
//---------------------------------------------------------------------------------------------------------------------------------------------------------
// DONT EDIT ANYTHING BELOW THIS!
//---------------------------------------------------------------------------------------------------------------------------------------------------------
// AutoMule Variables and Stuff
const DGDebug = false;
const AUTOMULE_READY = 1;
const AUTOMULE_FULL = 0;
const AUTOMULE_NOMULES = -1;
function AutomuleData()
{
this.InProgress = false;
this.PreventRecover = false;
this.IsWaiting = false;
this.State = "notmuling";
this.CurrentAccount = 0;
this.MuleIndex = 0;
this.IsReadyState = AUTOMULE_READY;
// Account creation variables
this.CreateAccount = false;
this.CharCreateNumber = -1;
this.RegMail = "";
this.MuleFull = false;
this.AccName;
this.AccPw;
this.AccPrefix;
this.AccSuffix = new Array();
this.NewAccPw = new Array();
this.UserNumbers;
this.IsLadder;
this.IsHC;
this.IsClassic;
this.RandomNameLength;
this.GameName;
this.GamePassword;
this.Mules = new Array();
this.MuleAccs;
this.MulePws;
this.NipFiles = new Array();
this.CharLoc;
this.MuleIsFullThreshold;
this.JoinBug;
this.NewCharBug = 0;
this.FullAuto = false;
}
var Automule = new AutomuleData();
Include("libs/controlInfo.ntl");
Include("libs/common/NTCommon.ntl");
Include("NTBot/mule_configs/NTConfig_AutoMule.ntl");
NT_LoadMuleConfig();
Include("libs/common/DGAutoMule.ntl");
// D2NT Manager Command
const D2NT_MGR_LOADING = 1;
const D2NT_MGR_READY = 2;
const D2NT_MGR_LOGIN = 3;
const D2NT_MGR_CREATE_GAME = 4;
const D2NT_MGR_INGAME = 5;
const D2NT_MGR_RESTART = 6;
const D2NT_MGR_CHICKEN = 7;
const D2NT_MGR_PRINT_STATUS = 8;
const D2NT_MGR_PRINT_LOG = 9;
var LastGameMade = GetTickCount();
var LastGameStatus = 0;
var NextGameMake = 0;
var InGameAt = 0;
var LocationLoops = new Array(2);
var ChatActionsDone = false;
var LastGameFailed = false;
var JoinedChannel = false;
var JustJoined = true;
var MadeAnnouncement = false;
// This is for recovering purpose, delete mulestate file is you get stuck
DGAM_ReadMuleStats();
MWAM_ReleaseUsedAccounts();
MWAM_InitializedMuleLoads(false);
var ControlData = new controlInfo();
function NTMain()
{
var _ingame, _scriptPath;
Delay(1000);
_ingame = false;
ConnectingToBnetTimeout *= 1000;
GameMinLength *= 1000;
CharacterScreenTimeout *= 1000;
PleaseWaitTimeout *= 1000;
CreateGameThreshold *= 1000;
CreateGameThresholdRandom *= 1000;
CreateGameTimeout *= 1000;
WaitInLineTimeout *= 1000;
GameDoesNotExistDelayMin *= 1000*60;
GameDoesNotExistDelayMax *= 1000*60;
GameDoesNotExistTimeout *= 1000;
ControlData.ClickDelay = ClickDelay;
ControlData.TextDelay = TextDelay;
ControlData.ClickDelayRandom = ClickDelayRandom;
ControlData.TextDelayRandom = TextDelayRandom;
RegisterEvent(EVENT_SCRIPTMSG, DGAM_MuleMsgEvents);
while(true)
{
if(me.ingame)
{
if(!InGameAt)
InGameAt = GetTickCount();
if(!_ingame)
{
if(Automule.InProgress)
{
if(DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "[Debug] Joined Mule Game");
switch(Automule.State)
{
case "notmuling": // Done or not yet started
// No... we really are not supposed to be here
Automule.InProgress = false;
ExitGame();
NTC_SendLogToOOG(NTC_LOG_COMMON, "AutoMule Error, try again.");
SetStatusText("ÿc1AutoMule Error... (Wait 60s)");
Delay(60000);
break;
case "mulestart": // Still on Bot Account
_scriptPath = "NTBot/bots/NTPermGameandMule.ntj";
break;
case "mule": //Muleing
case "mulefull": // Mule Full
case "done": // Next Account
case "recover": // Recovering
_scriptPath = "NTBot/bots/NTPickStuff.ntj";
break;
default:
_scriptPath = "NTBot/NTPermGameandMule.ntj";
break;
}
if(DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "Debug: Load " + _scriptPath);
RunGC();
if(Load(_scriptPath))
{
_ingame = true;
Automule.JoinBugCount = 0;
MadeAnnouncement = false;
LocationLoops[1] = 0;
MW_WriteBackupFile();
if(me.playtype > 0)
NT_SendEventToOOG(D2NT_MGR_INGAME, "Currently in Mule Game", 0);
else
NT_SendEventToOOG(D2NT_MGR_INGAME, "Oops, that's not gonna work honey.", 0);
LastGameStatus = 2; // in game successful
}
}
else
{
RunGC(); // run garbage collector between each game
if(Load("NTBot/MWBotGame.ntj"))
{
_ingame = true;
MadeAnnouncement = false;
LocationLoops[1] = 0;
MW_WriteBackupFile();
if(me.playtype > 0)
NT_SendEventToOOG(D2NT_MGR_INGAME, "In Game [IP:" + me.gameserverip.split(".")[3] + "]", 0);
else
NT_SendEventToOOG(D2NT_MGR_INGAME, "In Game", 0);
LastGameStatus = 2; // in game successful
}
}
}
Delay(1000);
}
else
{
if(Automule.IsWaiting)
Delay(1000);
else
{
if(_ingame)
{
_ingame = false;
NT_SendEventToOOG(D2NT_MGR_READY, "", 0);
Delay(4000);
}
if(Automule.InProgress)
DGAM_DoMuleLocationAction();
else
NT_LocationAction(ControlData.getLocation());
Delay(500);
}
}
}
}
function NT_LocationAction(location)
{
var _randomChannel, _output, _control;
MW_CheckLocationLoops(location);
switch(location.id)
{
case 3: // Lobby Chat
if(JustJoined)
{
JustJoined = false;
if(MW_ArrayContainsUser(ChannelUsers))
_output = "ÿc2Chat actions enabled!";
else
_output = "ÿc1Chat actions disabled!";
for(var i = 0; i < 3; i++)
{
SetStatusText(_output);
Delay(500);
SetStatusText("");
Delay(500);
}
if(IgnoreWispers)
{
Say("/o igw");
Delay(500);
}
}
if(!ChatActionsDone && MW_ArrayContainsUser(ChannelUsers))
{
ChatActionsDone = true;
Delay(Random(WaitInChatBeforeActionsMin, WaitInChatBeforeActionsMax));
if(!JoinedChannel && (JoinRandomChannel || JoinChannelInChat != ""))
{
_randomChannel = NT_GetRandomString(Random(3,10));
SetStatusText("ÿc8Joining Channel ÿc;" + (JoinRandomChannel ? _randomChannel : JoinChannelInChat));
Delay(500);
Say("/join " + (JoinRandomChannel ? _randomChannel : JoinChannelInChat));
JoinedChannel = true;
if(PerformChannelLogin)
{
SetStatusText("ÿc8Channel Login...");
Say(".login");
Delay(1000);
}
}
}
case 1: // Lobby
if(location.id == 1 && JoinChatAfterLogin)
{
Delay(Random(WaitBeforeEnterChatMin, WaitBeforeEnterChatMax));
ControlData.click(ControlData.controls.lobby.button.enterChat);
break;
}
if(GetTickCount() > NextGameMake)
{
LastGameFailed = false;
switch(LastGameStatus)
{
case 0:
if(MW_ArrayContainsUser(JoinRandomGamesChars))
{
_control = ControlData.get(ControlData.controls.lobby.button.join);
if(_control && _control.pressed)
{
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
}
ControlData.click(ControlData.controls.lobby.button.join);
}
else
{
_control = ControlData.get(ControlData.controls.lobby.button.create);
if(_control && _control.pressed)
{
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
}
ControlData.click(ControlData.controls.lobby.button.create);
}
NextGameMake = GetTickCount() + CreateGameTimeout; // set our timeout
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
break;
case 1: // game failed, rollover to reset timer
InGameAt = GetTickCount();
LastGameFailed = true;
Delay(5000);
case 2:
NT_OutputGameLength();
LastGameStatus = 0;
NT_SetNextGameMake();
if(LastGameFailed)
{
SetStatusText("ÿc1Failed to join!");
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Game creation failed!", 0);
Delay(1000);
}
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
break;
}
}
else
{
if(JoinChannelInChat && !MadeAnnouncement && MW_ArrayContainsUser(ChannelUsers))
{
if(MW_AnnounceGame())
MadeAnnouncement = true;
}
MW_TimeoutDelay(NextGameMake - GetTickCount(), location, !MW_ArrayContainsUser(JoinRandomGamesChars));
}
break;
case 2: // Waiting In Line
if(GetTickCount() - LastGameMade > WaitInLineTimeout)
ControlData.click(ControlData.controls.lobby.inLine.button.cancel);
break;
case 4: // Create Game
if(!MW_ArrayContainsUser(JoinRandomGamesChars))
{
if(!ControlData.get(ControlData.controls.lobby.create.editBox.gameName))
{
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
}
_control = ControlData.get(ControlData.controls.lobby.create.button.useCharacterDifference);
if(_control)
{
if(CharacterDifference == 0 && _control.pressed || CharacterDifference >= 1 && CharacterDifference <= 99 && !_control.pressed)
{
ControlData.click(ControlData.controls.lobby.create.button.useCharacterDifference);
Delay(1000);
}
}
_control = ControlData.get(ControlData.controls.lobby.create.editBox.maxNumberOfPlayers);
if(_control)
{
if(PlayersPerGame >= 1 && PlayersPerGame <= 8 && _control.text != PlayersPerGame.toString())
{
ControlData.setText(ControlData.controls.lobby.create.editBox.maxNumberOfPlayers, PlayersPerGame.toString());
Delay(1000);
}
}
_control = ControlData.get(ControlData.controls.lobby.create.editBox.characterDifference);
if(_control)
{
if(_control.text != CharacterDifference.toString())
{
ControlData.setText(ControlData.controls.lobby.create.editBox.characterDifference, CharacterDifference.toString());
Delay(1000);
}
}
if(GameDescription)
{
ControlData.setText(ControlData.controls.lobby.create.editBox.gameDescription, GameDescription);
Delay(1000);
}
NT_SendEventToOOG(D2NT_MGR_CREATE_GAME, location.name, 0);
NT_LocationTimeout(5000, location);
LastGameMade = GetTickCount();
LastGameStatus = 1; // pending creation
}
break;
case 5: // Join Game
if(MW_ArrayContainsUser(JoinRandomGamesChars))
{
var _games, _game;
_games = ControlData.get(ControlData.controls.lobby.join.textBox.gameList).GetText();
_game = "";
if(_games)
{
for(var i = 0; i < _games.length; i++)
{
for(var j = 0; j < JoinGameKeywords.length; j++)
{
if(_games[i].toLowerCase().indexOf(JoinGameKeywords[j].toLowerCase()) > -1)
{
_game = _games[i];
i = _games.length;
break;
}
}
}
}
if(_game != "")
{
SetStatusText("ÿc8Joining Game: " + _game);
Delay(250);
ControlData.setText(ControlData.controls.lobby.join.editBox.gameName, _game);
Delay(1000);
ControlData.click(ControlData.controls.lobby.join.button.joinGame);
NT_LocationTimeout(5000, location);
LastGameMade = GetTickCount();
LastGameStatus = 1; // pending creation
}
else
Delay(2500);
ControlData.click(ControlData.controls.lobby.button.create);
Delay(500);
ControlData.click(ControlData.controls.lobby.button.join);
Delay(500);
}
break;
case 6: // Ladder
break;
case 7: // Channel List
break;
case 8: // Main Menu
if(ControlData.getCurrentRealmIndex() == me.gatewayid)
{
NT_OutputGameLength();
ControlData.click(ControlData.gameTypes[me.playtype]);
}
else
ControlData.click(ControlData.controls.mainMenu.button.gateway);
break;
case 9: // Login
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
Delay(LoginDelay);
ControlData.setText(ControlData.controls.login.editBox.accountName, me.account);
NT_SendEventToOOG(D2NT_MGR_LOGIN, location.name, 0);
NT_LocationTimeout(5000, location);
break;
case 10: // Login Error (this is a fatal error, so stop)
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 10);
Delay(3500);
break;
case 11: // Unable To Connect
MW_TimeoutDelay(UnableToConnectRetry*60*1000, location);
ControlData.click(ControlData.controls.login.unableToConnect.button.ok);
break;
case 12: // Character Select
var _time, _control;
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
for(_time = 0 ; _time < CharacterScreenTimeout ; _time += 500)
{
_control = ControlData.get(ControlData.controls.characterSelect.textBox.characterInfo[me.charloc]);
if(_control && _control.GetText() != undefined)
break;
Delay(500);
}
if(_time < CharacterScreenTimeout)
{
Delay(CharacterSelectDelay);
ControlData.click(ControlData.controls.characterSelect.textBox.characters[me.charloc], 0, 0, 1);
ControlData.click(ControlData.controls.characterSelect.textBox.characterInfo[me.charloc], 0, 0, 1);
// reset last game made, so it doesnt make a game immediately
InGameAt = 0;
NT_SetNextGameMake();
}
else
{
ControlData.click(ControlData.controls.characterSelect.button.exit);
MW_TimeoutDelay(RealmDownRetry*60*1000, location);
}
break;
case 13: // Realm Down - Character Select screen
ControlData.click(ControlData.controls.characterSelect.button.exit);
MW_TimeoutDelay(RealmDownRetry*60*1000, location);
break;
case 14: // Character Select - Disconnected
MW_TimeoutDelay(DisconnectedRetry*60*1000, location);
ControlData.click(ControlData.controls.characterSelect.disconnected.button.ok);
break;
case 15: // New Character
break;
case 16: // Character Select - Please Wait popup
if(!NT_LocationTimeout(PleaseWaitTimeout, location))
ControlData.click(ControlData.controls.characterSelect.pleaseWait.button.cancel);
break;
case 17: // Lobby - Lost Connection - just click okay, since we're toast anyway
ControlData.click(ControlData.controls.lobby.lostConnection.button.ok);
break;
case 18: // D2 Splash
ControlData.click(ControlData.controls.d2Splash.textBox.copyright);
break;
case 19: // Login - Cdkey In Use
MW_TimeoutDelay(CdKeyInUseRetry*60*1000, location);
ControlData.click(ControlData.controls.login.cdkeyInUse.button.ok);
break;
case 20: // Single Player - Select Difficulty
ControlData.click(ControlData.singlePlayerDifficulties[me.diff]);
break;
case 21: // Main Menu - Connecting
if(!NT_LocationTimeout(ConnectingToBnetTimeout, location))
ControlData.click(ControlData.controls.mainMenu.connecting.button.cancel);
break;
case 22: // Login - Invalid Cdkey (classic or xpac)
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 3600);
Delay(3500);
break;
case 23: // Character Select - Connecting
if(!NT_LocationTimeout(CharacterScreenTimeout, location))
ControlData.click(ControlData.controls.characterSelect.button.exit);
break;
case 24: // Server Down - not much to do but wait..
break;
case 25: // Lobby - Please Wait
if(!NT_LocationTimeout(PleaseWaitTimeout, location))
ControlData.click(ControlData.controls.lobby.pleaseWait.button.cancel);
break;
case 26: // Lobby - Game Name Exists
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Game already exists", 0);
SetStatusText("ÿc1Game already exists!");
InGameAt = 0;
LastGameStatus = 0;
NT_SetNextGameMake();
NT_LocationTimeout(15000, location);
break;
case 27: // Gateway Select
ControlData.clickRealmEntry(me.gatewayid);
ControlData.click(ControlData.controls.gateway.button.ok);
break;
case 28: // Lobby - Game Does Not Exist
InGameAt = Random(GameDoesNotExistDelayMin, GameDoesNotExistDelayMax);
LastGameStatus = 0;
NT_SetNextGameMake();
NT_LocationTimeout(GameDoesNotExistTimeout, location);
break;
}
}
function NT_SendEventToOOG(locationId, statusString, pendingTime)
{
return SendCopyData("D2NT Manager", null, (locationId<<16)|pendingTime, statusString);
}
function NT_SetNextGameMake()
{
LastGameMade = GetTickCount();
NextGameMake = LastGameMade + CreateGameThreshold + Random(0 - CreateGameThresholdRandom, CreateGameThresholdRandom) + InGameAt;
InGameAt = 0;
ChatActionsDone = false;
}
function NT_OutputGameLength()
{
var _duration;
if(InGameAt)
{
_duration = GetTickCount() - InGameAt;
if(_duration < GameMinLength)
InGameAt = GameMinLength - _duration;
else
InGameAt = 0;
}
}
function NT_LocationTimeout(time, location)
{
var _endtime = GetTickCount() + time;
while(ControlData.getLocation().id == location.id && _endtime > GetTickCount())
{
if(LocationLoops[1] > 1)
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "] [" + LocationLoops[1] + "]", 0);
else
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "]", 0);
Delay(1000);
}
return (ControlData.getLocation().id != location.id);
}
function MW_TimeoutDelay(time, location, showNextGameStatus)
{
var _gamename, _outputString, _timeString;
if(arguments.length < 3)
showNextGameStatus = false;
_endtime = GetTickCount() + time;
_gamename = me.gamename;
_timeString = "";
if(!_gamename)
{
_gamename = MW_ReadBackupFile(0);
if(_gamename)
SetStatusText("ÿc8Using File Backup...");
}
while(_endtime > GetTickCount())
{
_timeString = " [" + MWC_ConvertTicksToTimeString(_endtime - GetTickCount()) + "]";
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + _timeString , 0);
if(showNextGameStatus)
{
if(LastGameFailed && parseInt(_endtime-GetTickCount()) > CreateGameThreshold && parseInt((_endtime-GetTickCount())/1000) % 30 >= 0 && parseInt((_endtime-GetTickCount())/1000) % 30 <= 5)
{
_outputString = "ÿc1Last game failed!";
_timeString = "";
}
else if(parseInt((_endtime-GetTickCount())/1000) >= 0)
{
if(_gamename && MW_GetGameCounter(_gamename, false))
_outputString = "ÿc8Next game: " + MW_GetGameName(_gamename) + MW_GetGameCounter(_gamename, false);
else
_outputString = "ÿc8Game creation pending... ";
}
MWC_SetStatusText(_outputString, _timeString);
if(me.ingame)
_endtime = GetTickCount();
}
Delay(1000);
}
if(showNextGameStatus)
SetStatusText("ÿc8Creating game...");
return;
}
function NT_GetRandomString(length)
{
_retString = "";
_charSet = "0123456789abcdefghijklmnopqrstuvwxyz";
while(length--)
{
_retString += _charSet.charAt(Random(0, _charSet.length - 1));
Delay(1);
}
return _retString;
}
function MW_GetGameName(lastGameString)
{
if(!lastGameString)
return "";
else
return lastGameString.substr(0, lastGameString.lastIndexOf('-') + 1);
}
function MW_GetGameCounter(lastGameString, simple)
{
var _count, _countString;
if(!lastGameString)
return "-1";
else
{
_countString = lastGameString.slice(lastGameString.lastIndexOf('-') + 1);
if(_countString[0] == '0')
_countString = _countString.substr(1);
_count = parseInt(_countString) + 1;
if(_count == 100)
_count = 0;
if(!simple)
{
if(_count <= 9)
return '0' + _count;
}
return _count;
}
}
function MW_ArrayContainsUser(array)
{
for(var i = 0; i < array.length; i++)
{
if(me.account.toLowerCase() == array[i].toLowerCase() || me.charname.toLowerCase() == array[i].toLowerCase())
return true;
}
return false;
}
function MW_ReadBackupFile(type)
{
var _fhandle, _buffer, _time, _now, _retValue;
_fhandle = FileOpen("/Logs/Temporary Data/" + me.charname + ".channel", 2);
_retValue = "";
_now = new Date();
if(_fhandle && _now)
{
_buffer = _fhandle.ReadLine();
if(_buffer)
{
_time = parseInt(_buffer);
if(_now.getTime() - _time < UseFileBackupTimeMax*6E4)
{
_retValue = _fhandle.ReadLine();
if(type > 0)
_retValue = _fhandle.ReadLine();
}
}
_fhandle.Close();
}
else if(_fhandle)
_fhandle.Close();
return _retValue;
}
function MW_WriteBackupFile()
{
var _fhandle, _now;
if(UseFileBackupTimeMax == 0)
return false;
_fhandle = FileOpen("/Logs/Temporary Data/" + me.charname + ".channel", 1);
_now = new Date();
if(_fhandle && _now)
{
_fhandle.WriteLine(_now.getTime());
_fhandle.WriteLine(me.gamename);
_fhandle.WriteLine(me.gamepassword);
_fhandle.Close();
return true;
}
else if(_fhandle)
_fhandle.Close();
return false;
}
function MW_CheckLocationLoops(location)
{
if(!location)
return false;
if(!LocationLoops[0] || location.id != LocationLoops[0].id)
{
LocationLoops[0] = location;
LocationLoops[1] = 0;
}
else if(LocationLoops[0].id != 5)
{
LocationLoops[1]++;
if(LocationLoops[1] >= MaximumLocationLoops)
{
if(LocationLoops[1] < 1000)
NT_SendEventToOOG(D2NT_MGR_PRINT_LOG, "ÿBE0000Location Loop Restart!;ÿc1Location Loops: " + LocationLoops[1] + "\nÿBE0000Location: " + LocationLoops[0].name + "\nÿBE0000Location ID: " + LocationLoops[0].id, 0);
LocationLoops[1] = 1000; // Make sure the location loop notification is only shown once
NT_SendEventToOOG(D2NT_MGR_RESTART, location.name, 0);
}
}
return true;
}
function MW_AnnounceGame()
{
var _gamePass, _gameName, _gameText, _delay;
_gameName = me.gamename;
if(!_gameName)
_gameName = MW_ReadBackupFile(0);
_gamePass = me.gamepassword;
if(!_gamePass)
_gamePass = MW_ReadBackupFile(1);
if(_gameName && !me.ingame)
{
_delay = (GameAnnouncementDelay > 5000) ? GameAnnouncementDelay : 5000;
_delay += (GameAnnouncementDelayRandom > 500) ? Random(0, GameAnnouncementDelayRandom) : 500;
_gameText = GameAnnouncement.replace("%password", ((_gamePass) ? _gamePass : "N/A"));
_gameText = _gameText.replace("%game", MW_GetGameName(_gameName));
_gameText = _gameText.replace("%counter", MW_GetGameCounter(_gameName, false));
_gameText = _gameText.replace("%time", parseInt((NextGameMake - GetTickCount() - _delay + ClickDelay + TextDelay) / 1000 + 5));
if(_gameText.indexOf("NaN") > -1)
return false;
if(parseInt((NextGameMake - GetTickCount() - _delay + ClickDelay + TextDelay) / 1000) > 3)
{
Delay(_delay);
return Say(_gameText);
}
}
return false;
}
Code:
/**
* This file was modified by
* Check the programming section for updates and further scripts
* Last Update: 23:10 29.08.2011
*
* Hotkey Description
*
* Pause/Break Pauses the current bot script.
* Page up (PgUp) Skips the current bot script.
* Page down (PgDn) Repeats the previous bot script
* Home (Pos1) Shows your current coordinates and areaid.
* End Shows current ping in status text bar.
* Insert (Ins) Logs all items on your char to either XML or TXT.
* Delete (Del) Exits the game. NOTE: Always use this key to leave a game!
* Backspace Force trigger auto mule. NOTE: Won't work unless auto mule is actually activated for the current char.
*/
Include("NTBot/char_configs/MWConfig_GlobalSettings.ntl");
var NTConfig_UseRedemptionHP;
var NTConfig_UseRedemptionMP;
function NT_LoadConfig()
{
MW_LoadGlobalSettings();
//------------------------------------------------------------------------------
//
// Run Configuration
//
//------------------------------------------------------------------------------
// Use the following syntax for activating botscripts: MWConfig_Script.push([<ScriptName>, <Script runtime in minutes (0 is infinite)>]);
// ***************** Current schedule ******************
// MWConfig_Script.push(["NTAndariel.ntj", 5]);
// MWConfig_Script.push(["NTMausoleum.ntj", 10]); MWConfig_ClearPathSpectypes.Mausoleum = 0; MWConfig_ClearAreaSpectypes.Mausoleum = 0x01; NTConfig_KillBloodRaven = true;
// MWConfig_Script.push(["NTPit.ntj", 10]); MWConfig_ClearPathSpectypes.Pit = 0; MWConfig_ClearAreaSpectypes.Pit = 0x01; NTConfig_ClearPitLevel1 = 2; // 0 : don't clear, 1 : clear path only, 2 : clear all
// MWConfig_Script.push(["NTCountess.ntj", 5]); MWConfig_ClearPathSpectypes.Countess = 0; MWConfig_ClearAreaSpectypes.Countess = 0;
// MWConfig_Script.push(["NTSummoner.ntj", 5]); NTConfig_KillFireEye = false; MWConfig_ClearPathSpectypes.Summoner = 0;
// MWConfig_Script.push(["NTAncientTunnels.ntj", 10]); MWConfig_ClearPathSpectypes.AncientTunnels = 0x01; MWConfig_ClearAreaSpectypes.AncientTunnels = 0x01;
// MWConfig_Script.push(["MWKurastSewers.ntj", 5]); MWConfig_ClearPathSpectypes.KurastSewers = 0;
// MWConfig_Script.push(["NTTravincal.ntj", 5]);
//MWConfig_Script.push(["NTMephisto.ntj", 5]); MWConfig_OpenMephistoChest = true; MWConfig_MephistoClearArea = false;
// MWConfig_Script.push(["MWSuperChests.ntj", 20]); MWConfig_SuperChestClearAreaRadius = 5; MWConfig_SuperChestAreas = ["Arachnid Lair", "Swampy Pit Level 3", "Flayer Dungeon", "Abbadon", "Pit of Acheron", "Drifter Cavern", "Infernal Pit", "Icy Cellar"];
// MWConfig_Script.push(["NTNihlathak.ntj", 5]); MWConfig_ClearPathSpectypes.Nihlathak = 0; NTConfig_PindleskinExtension = false; MWConfig_SkipOnTombVipers = true;
// MWConfig_Script.push(["NTDiablo.ntj", 10]); MWConfig_KillFullInfectorMob = true; MWConfig_StartAtStar = false; MWConfig_IgnoreSealOpeningErrors = false; MWConfig_FastDia = false;
//MWConfig_Script.push(["NTEldritch.ntj", 5]); NTConfig_ShenkExtension = true;
MWConfig_Script.push(["NTBaal.ntj", 10]); NTConfig_KillBaal = true; MWConfig_SkipBaalOnDolls = false; MWConfig_SkipBaalOnSouls = false; MWConfig_DoBaalPreAttack = true;
// *****************************************************
//------------------------------------------------------------------------------
// Available Scripts
//------------------------------------------------------------------------------
/* NOTE:
// The scripts below are actually commented out; to add a script, copy one of the lines below and add it to the current schedule above. ;)
// You should also get yourself a decent editor that supports syntax highlighting for JavaScript, I'd recommend Notepad++. (http://notepad-plus-plus.org/download/)
// *********************** Act I ***********************
MWConfig_Script.push(["NTMausoleum.ntj", 10]); MWConfig_ClearPathSpectypes.Mausoleum = 0; MWConfig_ClearAreaSpectypes.Mausoleum = 0x01; NTConfig_KillBloodRaven = true;
MWConfig_Script.push(["NTTristram.ntj", 10]); NTConfig_KillRakanishu = true;
MWConfig_Script.push(["NTHole.ntj", 10]); MWConfig_ClearPathSpectypes.Hole = 0; MWConfig_ClearAreaSpectypes.Hole = 0x01; NTConfig_ClearHoleLevel1 = 1; // 0 : don't clear, 1 : clear path only, 2 : clear all
MWConfig_Script.push(["NTTreehead.ntj", 10]);
MWConfig_Script.push(["MWColdcrow.ntj", 10]); MWConfig_ClearCaveMode = 0; // 0: Only kill coldcrow; 1: Clear Cave Level 1; 2: Clear both Cave Level 1 & 2
MWConfig_Script.push(["NTCountess.ntj", 5]); MWConfig_ClearPathSpectypes.Countess = 0; MWConfig_ClearAreaSpectypes.Countess = 0;
MWConfig_Script.push(["NTPit.ntj", 10]); MWConfig_ClearPathSpectypes.Pit = 0; MWConfig_ClearAreaSpectypes.Pit = 0x01; NTConfig_ClearPitLevel1 = 2; // 0 : don't clear, 1 : clear path only, 2 : clear all
MWConfig_Script.push(["NTAndariel.ntj", 10]);
// *********************** Act II **********************
MWConfig_Script.push(["NTRadament.ntj", 10]); MWConfig_ClearPathSpectypes.Radament = 0;
MWConfig_Script.push(["MWMaggotsLair.ntj", 10]); MWConfig_ClearPathSpectypes.MaggotsLair = 0; MWConfig_ClearAreaSpectypes.MaggotsLair = 0x01;
MWConfig_Script.push(["NTAncientTunnels.ntj", 10]); MWConfig_ClearPathSpectypes.AncientTunnels = 0; MWConfig_ClearAreaSpectypes.AncientTunnels = 0x01;
MWConfig_Script.push(["NTSummoner.ntj", 5]); NTConfig_KillFireEye = false; MWConfig_ClearPathSpectypes.Summoner = 0;
MWConfig_Script.push(["NTDuriel.ntj", 10]); MWConfig_ClearPathSpectypes.Duriel = 0;
// ********************** Act III **********************
MWConfig_Script.push(["MWFlayerJungle.ntj", 10]); MWConfig_ClearAreaSpectypes.FlayerJungle = 0x01;
MWConfig_Script.push(["MWKurastSewers.ntj", 5]); MWConfig_ClearPathSpectypes.KurastSewers = 0;
MWConfig_Script.push(["MWKurastTemples.ntj", 5]); MWConfig_ClearPathSpectypes.KurastTemples = 0; MWConfig_ClearAreaSpectypes.KurastTemples = 0x01;
MWConfig_Script.push(["NTTravincal.ntj", 5]);
MWConfig_Script.push(["NTMephisto.ntj", 5]); MWConfig_OpenMephistoChest = true; MWConfig_MephistoClearArea = true;
// *********************** Act IV **********************
MWConfig_Script.push(["NTIzual.ntj", 5]); MWConfig_ClearPathSpectypes.Izual = 0;
MWConfig_Script.push(["MWRiverOfFlame.ntj", 10]); MWConfig_ClearAreaSpectypes.RiverOfFlame = 0x01;
MWConfig_Script.push(["NTHephasto.ntj", 10]); MWConfig_ClearPathSpectypes.Hephasto = 0;
MWConfig_Script.push(["NTDiablo.ntj", 10]); MWConfig_KillFullInfectorMob = true; MWConfig_StartAtStar = false; MWConfig_IgnoreSealOpeningErrors = false; MWConfig_FastDia = true;
// *********************** Act V ***********************
MWConfig_Script.push(["MWAbbadon.ntj", 10]); MWConfig_ClearPathSpectypes.Abbadon = 0; MWConfig_ClearAreaSpectypes.Abbadon = 0x01;
MWConfig_Script.push(["MWPitOfAcheron.ntj", 10]); MWConfig_ClearPathSpectypes.PitOfAcheron = 0; MWConfig_ClearAreaSpectypes.PitOfAcheron = 0x01;
MWConfig_Script.push(["MWInfernalPit.ntj", 10]); MWConfig_ClearPathSpectypes.InfernalPit = 0; MWConfig_ClearAreaSpectypes.InfernalPit = 0x01;
MWConfig_Script.push(["MWHallsOfPain.ntj", 15]); MWConfig_ClearAreaSpectypes.HallsOfPain = 0x01; MWConfig_ClearHallsOfAnguish = true;
MWConfig_Script.push(["NTPindleskin.ntj", 5]); NTConfig_NihlathakExtension = false; MWConfig_SkipOnTombVipers = true;
MWConfig_Script.push(["NTEldritch.ntj", 5]); NTConfig_ShenkExtension = true;
MWConfig_Script.push(["NTThreshSocket.ntj", 5]); MWConfig_ClearPathSpectypes.ThreshSocket = 0;
MWConfig_Script.push(["NTFrozenRiver.ntj", 10]); MWConfig_ClearPathSpectypes.FrozenRiver = 0; MWConfig_ClearAreaSpectypes.FrozenRiver = 0x01;
MWConfig_Script.push(["NTGlacialTrail.ntj", 10]); MWConfig_ClearPathSpectypes.GlacialTrail = 0; MWConfig_ClearAreaSpectypes.GlacialTrail = 0x01;
MWConfig_Script.push(["NTIcyCellar.ntj", 5]); MWConfig_ClearPathSpectypes.IcyCellar = 0; MWConfig_ClearAreaSpectypes.IcyCellar = 0x01;
MWConfig_Script.push(["NTNihlathak.ntj", 5]); MWConfig_ClearPathSpectypes.Nihlathak = 0; NTConfig_PindleskinExtension = false; MWConfig_SkipOnTombVipers = true;
MWConfig_Script.push(["MWWorldstoneKeep.ntj", 10]); MWConfig_ClearAreaSpectypes.WorldstoneKeep = 0x01; MWConfig_SkipLevelOnWitches = true; MWConfig_SkipLevelOnSouls = false; MWConfig_SkipLevelOnDeathLords = true;
MWConfig_Script.push(["NTBaal.ntj", 10]); NTConfig_KillBaal = true; MWConfig_SkipBaalOnDolls = true; MWConfig_SkipBaalOnSouls = false; MWConfig_DoBaalPreAttack = true; MWConfig_ClearPathSpectypes.Baal = 0;
// *********************** Misc ************************
MWConfig_Script.push(["MWAuraStack.ntj", 10]); MWConfig_StackRepetitions = 100; MWConfig_ResetMercWeaponAfterStacking = false;
MWConfig_Script.push(["MWSuperChests.ntj", 20]); MWConfig_SuperChestClearAreaRadius = 10; MWConfig_SuperChestAreas = ["Cave Level 2", "Mausoleum", "Hole Level 2", "Pit Level 2", "Sewers Level 3", "Halls of the Dead Level 2", "Stony Tomb Level 2", "Maggot's Lair Level 3", "Ancient Tunnels", "Tal Rasha's Tomb", "Arachnid Lair", "Swampy Pit Level 3", "Flayer Dungeon", "Sewers Level 2", "Abbadon", "Pit of Acheron", "Drifter Cavern", "Infernal Pit", "Icy Cellar", "Halls of Pain"];
MWConfig_Script.push(["MWRush.ntj", 0]); MWConfig_IsRusher = true;
MWConfig_Script.push(["MWWaypointCatcher.ntj", 0]); MWConfig_WaypointCatcherActs = [1, 2, 3, 4, 5]; MWConfig_TPWaypoints = true; MWConfig_SkipHallsOfPain = true; MWConfig_ClearWaypointPaths = false;
MWConfig_Script.push(["MWIdleMode.ntj", 0]); MWConfig_IdleModeRuntime = 5; // Runtime in Minutes
MWConfig_Script.push(["NTCows.ntj", 10]);
MWConfig_Script.push(["MWBloodyRejuvs.ntj", 10]);
MWConfig_Script.push(["MWOrganHarvest.ntj", 10]); MWConfig_EnterInvalidUberPortals = true; MWConfig_PauseOnLackOfKeys = false; MWConfig_IntendedUberPortal = 0; // Matron's Den: 133; Forgotten Sands: 134; Furnace Of Pain: 135;
MWConfig_Script.push(["MWUberTristram.ntj", 10]); MWConfig_PauseOnLackOfOrgans = false; MWConfig_PauseOnKeptTorch = false;
MWConfig_Script.push(["MWAnyasBargain.ntj", 10]); MWConfig_ShoppingMinGold = 500000; MWConfig_ShoppingAttempts = 200;
// ************ Leech and friends by lanara ************
MWConfig_Script.push(["NTDiabloLeechFight.ntj", 10]); MWConfig_StartAtStar = true; MWConfig_EnterUnsafeTP = true; NTConfig_PreBuff = true; MWConfig_IgnoreSealOpeningErrors = true; NTConfig_Leader = "LeaderNameGoesHere";
MWConfig_Script.push(["NTBaalLeech.ntj", 10]); NTConfig_KillBaal = true; MWConfig_EnterUnsafeTP = false; NTConfig_Leader = "LeaderNameGoesHere";
MWConfig_Script.push(["NTBaalLeechFight.ntj", 10]); NTConfig_KillBaal = true; MWConfig_DoBaalPreAttack = true; MWConfig_EnterUnsafeTP = true; NTConfig_Leader = "LeaderNameGoesHere";
*/
//------------------------------------------------------------------------------
// Misc Configuration
//------------------------------------------------------------------------------
NTConfig_SkipHealLife = 90; // If you have more than this percent of life, you won't go to a healer.
NTConfig_SkipHealMana = 70; // 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.
// Exit game or to reset your Enigma if Teleport skill is missing (due to identifying an item having +x to Teleport [Sorceress only]). WARNING: Activating this feature may - though not likely will - result in the loss of your enigma. Use at your own risk and make sure your char has sufficient strength!
// 0: Don't do anything; 1: Reset armor; 2: Exit game
MWConfig_ResetArmorMode = 0;
//------------------------------------------------------------------------------
// Potion Configuration
//------------------------------------------------------------------------------
NTConfig_LifeThresh = 70; // Drink a normal potion if under this percent of life.
NTConfig_LifeRejuvThresh = 60; // 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 = 1; // Drink a rejuvenation potion if under this percent of mana.
NTConfig_MercLifeThresh = 50; // This is the threshold to use a life potion on your merc in percent.
NTConfig_MercRejuvThresh = 30; // This is the threshold to use a rejuv potion on your merc in percent.
//------------------------------------------------------------------------------
// Chicken Configuration
//------------------------------------------------------------------------------
// This is your chicken life. If you go below this threshhold, your char will exit the game. You can either enter a percentage (1-100), an absolute threshold (>100) or 0 to deactivate life chicken.
NTConfig_LifeChicken = 30;
// This is your chicken mana. If you go below this threshhold, your char will exit the game. You can either enter a percentage (1-100), an absolute threshold (>100) or 0 to deactivate mana chicken.
NTConfig_ManaChicken = 0;
// This is your merc's chicken life in percent. If your merc goes below this threshhold, your char will exit the game.
NTConfig_MercChicken = 0;
// Whether or not to disable chicken when you pause the bot.
MWConfig_DisableChickenOnPause = true;
//------------------------------------------------------------------------------
// Inventory Configuration
//------------------------------------------------------------------------------
// Each number represents a slot in your inventory.
// Set to 0 if the slot and its content must not be touched.
// Set to 1 to allow access to this slot.
// Set to 2 to select the slot that is used for storing keys. (if keys are kept at another slot, your char will try to move them)
NTConfig_Columns[0] = [1,1,1,1,1,1,1,1,2,0];
NTConfig_Columns[1] = [1,1,1,1,1,1,1,1,1,0];
NTConfig_Columns[2] = [1,1,1,1,1,1,1,1,1,0];
NTConfig_Columns[3] = [1,1,1,1,1,1,1,1,1,0];
// Number of free columns. If less full columns are free stashing is set. Call SetFreeColumns(NTConfig_Columns) to always stash right away (recommended).
NTConfig_FreeSpace = SetFreeColumns(NTConfig_Columns);
// Maximum gold amount carried before going to stash.
NTConfig_MinGoldToStash = 100000;
// Set to true if your char is supposed to carry, buy and pick up keys. You do not need to add keys to your .nip files, they will be picked up anyway if this is set to true.
MWConfig_CarryKeys = true;
//------------------------------------------------------------------------------
// Belt Configuration
//------------------------------------------------------------------------------
// Available types : "hp" = health, "mp" = mana, "rv" = rejuvenation.
// Define how many columns are used for each potion type.
MWConfig_BeltColType["hp"].Columns = 1;
MWConfig_BeltColType["mp"].Columns = 1;
MWConfig_BeltColType["rv"].Columns = 2;
// Define minimum number of potions per column. If the actual number of potions in a column is below this value, your char will visit a merchant when in town in order to buy potions.
MWConfig_BeltColType["hp"].MinPots = 3;
MWConfig_BeltColType["mp"].MinPots = 3;
// Visit Town and buy potions if your char lacks mana when trying to loot a corpse or teleport.
MWConfig_BuyPotionsOnLackOfMana = true;
// Set to true to replace low quality potions with higher quality potions that just dropped.
MWConfig_ReplaceLowQualityPotions = true;
//-----------------------------------------------------------------------------------
// NipFile Configuration
//-----------------------------------------------------------------------------------
NTConfig_NIPFilePath.push("private/normal.nip");
NTConfig_NIPFilePath.push("private/magic_rare.nip");
NTConfig_NIPFilePath.push("private/set.nip");
NTConfig_NIPFilePath.push("private/unique.nip");
NTConfig_NIPFilePath.push("private/craft.nip");
NTConfig_NIPFilePath.push("private/temp.nip");
//------------------------------------------------------------------------------
// Pickit Configuration
//------------------------------------------------------------------------------
// Radius to check for dropped items. NOTE: The maximum is at about ~75, entering higher values will not have any effect.
NTConfig_SnagRange = 70;
// Set to true to check for dropped items whenever you kill a monster. (Recommended value to avoid crashes: false)
MWConfig_PickItemsInstantly = true;
//------------------------------------------------------------------------------
// Chest Configuration
//------------------------------------------------------------------------------
// Select which containers shall be looted. 0: None; 1: Super Chests, 2: All
MWConfig_OpenContainerMode = 2;
// Set to true to check for dropped items right after opening a chest. NOTE: This will slow down your runs and therefore should definately be set to false when doing private games.
MWConfig_PickChestLootsInstantly = true;
// This is the range being checked for chests after clearing an area or room. NOTE: You should not set this too high, 30 is a good value.
MWConfig_OpenChestsRange = 30;
// If you do not like to open chests in a certain area, you can its areaid as an exception below. NOTE: All areaids can be found in "sdk\areas.txt".
// MWConfig_ChestExceptions.push(<areaid1>, <areaid2>, <areaidn>);
//------------------------------------------------------------------------------
// Cubing Configuration
//------------------------------------------------------------------------------
// Set to true to enable cubing and crafting. NOTE: The recipes are added in the global config by default. If you like to craft certain recipe only using this very char, add those recipes below.
NTConfig_Cubing = true;
//------------------------------------------------------------------------------
// General Configuration
//------------------------------------------------------------------------------
// Set to true to activate public mode. By activating public mode, your char will form a party, open TPs and do some chat outputs when running certain bot scripts.
NTConfig_PublicMode = true;
// Set to true to exit the game instantly if the game is public. This may happen sometimes due to an error pasting the password correctly.
MWConfig_ExitGameOnMissingPassword = false;
// Set to true to exit the game when another player expresses hostility towards you.
me.quitonhostile = false;
// This is the maximum time in seconds your char will remain in a single game. Set to 0 to stay in game infinitely.
me.maxgametime = 3000;
// This is the minimum time in seconds for your char to remain in a single game. Your char will not exit the game before this time elapsed.
me.mingametime = 180;
//------------------------------------------------------------------------------
// Automule Configuration
//------------------------------------------------------------------------------
// Set to true to enable auto mule.
MWConfig_Automule.Activated = false;
// The maximum stash load in percent before auto mule is triggered.
MWConfig_Automule.MaxLoad = 95;
// Set to true to show your stash's current load whenever managing stash.
MWConfig_Automule.ShowCurrentLoad = true;
// Set to true to finish your current game before muling, otherwise the game is left right away in case your stash is full.
MWConfig_Automule.FinishGame = true;
// Define which items are not to be touched when muling.
MWConfig_Automule.DontMule.push("mule/dont_mule.nip");
MWConfig_Automule.DontMule.push("mule/gems.nip");
//------------------------------------------------------------------------------
// Shrine Configuration
//------------------------------------------------------------------------------
// Set to true to activate nearby shrines. Shrines will only be activated if it is actually useful.
MWConfig_ActivateNearbyShrines = true;
// If you would like to skip shrines in a certain area, you can its areaid as an exception below. NOTE: All areaids can be found in "sdk\areas.txt".
// MWConfig_ShrineExceptions.push(<areaid1>, <areaid2>, <areaidn>);
//------------------------------------------------------------------------------
// Precast Configuration
//------------------------------------------------------------------------------
// Your precast skills can be defined in the array below. NOTE: Battle Command, Battle Orders and Shout will be cast automatically. Constants for all skill ids can be found in "scripts\libs\common\MWSkills.ntl".
MWConfig_PrecastSkills = [MWS_HOLY_SHIELD];
// Set this to true if you would like to switch slots right after casting BC, BO and Shout. If set to false, your char will remain with the BO Slot until the whole precast procedure is done.
MWConfig_SwitchSlotsAfterBoPrecast = true;
//------------------------------------------------------------------------------
// Attack Configuration
//------------------------------------------------------------------------------
// Specify your attack skills below. NOTE: Constants for all skill ids can be found in "scripts\libs\common\MWSkills.ntl".
NTConfig_AttackSkill[0] = -1; // This skill is used once whenever attacking a new target. Set to -1 to deactivate.
NTConfig_AttackSkill[1] = MWS_BLESSED_HAMMER; // Primary skill to bosses.
NTConfig_AttackSkill[2] = MWS_CONCENTRATION; // Primary aura to bosses. Set to -1 to deactivate.
NTConfig_AttackSkill[3] = MWS_BLESSED_HAMMER; // Primary skill to others.
NTConfig_AttackSkill[4] = MWS_CONCENTRATION; // Primary aura to others. Set to -1 to deactivate.
NTConfig_AttackSkill[5] = MWS_HOLY_BOLT; // Secondary skill in case monster is immune to primary skill. Set to 0 if you won't
NTConfig_AttackSkill[6] = MWS_CONCENTRATION; // Secondary aura. Set to 0 not to activate any aura.
NTConfig_AttackSkill[7] = MWS_SALVATION; // Aura to be used against Uber Mephisto. Set to -1 to deactivate.
// Set to true if you want to clear area after killing boss. NOTE: This only affects a few botscripts.
NTConfig_ClearPosition = true;
// Set to true to clear area when killing a boss and the position is crowded by monsters. NOTE: Setting this to true may cause NTA_KillMonster() to fail way more often.
MWConfig_ClearBossPosition = false;
// This is the number of attacks to be performed before the the character tries to move to another position. Set to 0 not to reposition.
MWConfig_AttacksBeforeRepositioning = 25;
// Define a time limit for your attacks for each type of monster.
MWConfig_AttackTimeLimit[0] = 20; // Maximum time in seconds to attack a normal monster
MWConfig_AttackTimeLimit[1] = 120; // Maximum time in seconds to attack a super unique monster
MWConfig_AttackTimeLimit[2] = 30; // Maximum time in seconds to attack a champion
MWConfig_AttackTimeLimit[3] = 120; // Maximum time in seconds to attack a bosse
MWConfig_AttackTimeLimit[4] = 30; // Maximum time in seconds to attack a minion
// Define when a monster is considered immune by entering the index of one or more of your attack skills. As an example: [1, 3] means that a monster is considered immune if it is immune to both NTConfig_AttackSkill[1] and NTConfig_AttackSkill[3], whatever those may be.
MWConfig_CheckImmunitySkills = [];
// Select the behaviour of your character when encountering a monsters that is considered immune referring to the definition above.
// 0: Don't do anything. (D2NT default)
// 1: Get close to the monster.
// 2: Skip the monster.
// 3: Attack the monster using NTConfig_AttackSkill[8] and NTConfig_AttackSkill[9]
NTConfig_BehaviourOnImmuneMonster = 0;
NTConfig_AttackSkill[8] = -1; // Skill to be used against user defined immunes.
NTConfig_AttackSkill[9] = -1; // Untimed Skill to be used against user defined immunes.
// Activate Redemption if your health is lower than this percentage. Set to 0 not to use Redemption.
NTConfig_UseRedemptionHP = 80;
// Activate Redemption if your health is lower than this percentage. Set to 0 not to use Redemption.
NTConfig_UseRedemptionMP = 60;
// Select whether or not you'd like to swap slots right before killing a boss in order to benefit from some extra MF in your second slot.
// The first element can either be the classid of the target or its name (case insensitive), second element is the life threshold in percent.
//MWConfig_SlotSwapMonsters.push([156, 50]); // Andariel, 50%
//MWConfig_SlotSwapMonsters.push([211, 20]); // Duriel, 20%
//MWConfig_SlotSwapMonsters.push([242, 20]); // Mephisto, 20%
//MWConfig_SlotSwapMonsters.push([243, 20]); // Diablo, 20%
//MWConfig_SlotSwapMonsters.push([544, 15]); // Baal, 15%
// 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 = 0;
// 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;
}
Code:
/**
* This file was written by
* Check the programming section for updates and further scripts
* Last Update: 15:19 05.11.2011
*/
Include("libs/common/MWSkills.ntl");
function MW_LoadGlobalSettings()
{
//------------------------------------------------------------------------------
// General Configuration
//------------------------------------------------------------------------------
// Set to false will disable auto mule for all chars. Note that you have to set both this variable and MWConfig_Automule.Activated (in you char config) to true in order to enable auto mule for a char.
MWConfig_Automule.Enabled = false;
// Set to true to buy items that match your Nips whenever visiting a merchant.
MWConfig_DoShopping = true;
// Set to true to have the status text show the script runtime. (Note: enabling this might lead to an increased number of crashes/restarts.)
MWConfig_EnableStatusTextTimer = true;
// Set to true to always check the selected Nips for errors after including them. Check "..\scripts\Logs\NipErrors.txt" for a precise error description!
MWConfig_RunNipCheck = false;
// Set to true to run sorting algorithm whenever managing your stash.
MWConfig_SortStash = true;
// Set to true to run sorting algorithm if your stash is full and items are stored in your inventory.
MWConfig_SortInventory = true;
// Set to true to form a party even if public mode is deactivated.
MWConfig_AutoParty = true;
// This is the maximum number of errors that may occur in a single game. If more errors occur, your char will exit the game.
MWConfig_GameErrorLimit = 3;
// This is the delay in milliseconds before the first bot script is loaded.
NTConfig_StartDelay = 500;
// This is the delay in milliseconds on area changes. Do not set this too low!
NTConfig_AreaDelay = 750;
// This is the delay in milliseconds before picking up items. Do not set this too low!
NTConfig_SnagDelay = 750;
// This is the delay in milliseconds after finishing a bot script.
MWConfig_ScriptDelay = 1000;
// Set to true to enable overhead status messages. NOTE: This will be visible for everyone in the game so you might not want to activate it when doing public games.
MWConfig_ShowOverheadStatus = true;
// Define a list of chars that may be in your bot's game. If a player enters your game who is not in that list, your bot will leave the game. To disable this options, simply don't add any chars to the list or known players.
// MWConfig_KnownPlayers.push("SomeBuddyOfMine'sCharName", "AnotherBuddy'sCharName");
// Define which negative states on your char require visiting a healer when in town. Set to 0 not to visit a healer.
// 0x02 : Poison
// 0x04 : Amplify Damage
// 0x08 : Weaken
// 0x10 : Iron Maiden
// 0x20 : Decrepify
// 0x40 : Lower Resist
MWConfig_CheckSelfSafeTown = 0x0C;
// Define which negative states on your merc require visiting a healer when in town. Set to 0 not to visit a healer.
// 0x02 : Poison
// 0x04 : Amplify Damage
// 0x08 : Weaken
// 0x10 : Iron Maiden
// 0x20 : Decrepify
// 0x40 : Lower Resist
MWConfig_CheckMercSafeTown = 0;
//------------------------------------------------------------------------------
// Chat Announcements
//------------------------------------------------------------------------------
// These announcements will not be made unless NTConfig_PublicMode is set to true. Set to "" not to post a message.
// NOTE: You have to set a TPSafe message when using leechers and not entering unsafe TPs.
/*
MWConfig_Announcements.BaalThrone = "There are %d monster(s) in Throne!";
MWConfig_Announcements.BaalTpNone = "TP is safe!";
MWConfig_Announcements.BaalTpCold = "TP cold, %d monsters close!";
MWConfig_Announcements.BaalTpWarm = "TP warm, %d monsters close!";
MWConfig_Announcements.BaalTpHot = "TP hot, %d monsters close!";
MWConfig_Announcements.BaalTpSafe = "TP is safe!";
MWConfig_Announcements.BaalPreChamber = "Killing Baal!";
*/
MWConfig_Announcements.BaalKilled = "Next game!";
/*
MWConfig_Announcements.DiabloTpNone = "TP up, no monsters close!";
MWConfig_Announcements.DiabloTpCold = "TP cold, %d monsters close!";
MWConfig_Announcements.DiabloTpWarm = "TP warm, %d monsters close!";
MWConfig_Announcements.DiabloTpHot = "TP hot, %d monsters close!";
MWConfig_Announcements.DiabloTpSafe = "TP is safe!";
MWConfig_Announcements.DiabloPre = "Killing Diablo!";
*/
MWConfig_Announcements.DiabloKilled = "Next game!";
// Message to announce right before leaving a game.
MWConfig_Announcements.NextGame = "Next game!";
// Minimum char level to show level up message. Set to 99 to deactivate level up messages.
MWConfig_Announcements.ShowLevelUpMessagMinLevel = 75;
// These level up messages will be posted in chat whenever another player in game has a level up. (chosen randomly)
MWConfig_Announcements.LevelUpMessages.push("Congratulations on level %level, %name!");
MWConfig_Announcements.LevelUpMessages.push("Nice level up, %name!");
MWConfig_Announcements.LevelUpMessages.push("Good job reaching level %level, %name!");
MWConfig_Announcements.LevelUpMessages.push("Congratulations are in order, for %name just reached level %level!");
//------------------------------------------------------------------------------
// Bulletin Board Output Configuration
//------------------------------------------------------------------------------
// Select the path of your output textfile. The file extension .txt is added automatically.
MWConfig_BulletinBoardFilePath = "Logs/BBOutput";
// Select the mode for writing to the output textfile. Use 1 to overwrite the existing content and use 2 to append to the existing content.
MWConfig_BulletinBoardFileMode = 1;
// Define the colors used for replacing the D2 color codes. WARNING: You should not change these unless you are familiar with hexadecimal colors.
MWConfig_BulletinBoardColors["white"] = "#FFFFFF";
MWConfig_BulletinBoardColors["red"] = "#CD0000";
MWConfig_BulletinBoardColors["green"] = "#00FF00";
MWConfig_BulletinBoardColors["blue"] = "#3A5FCD";
MWConfig_BulletinBoardColors["gold"] = "#8B814C";
MWConfig_BulletinBoardColors["gray"] = "#606060";
MWConfig_BulletinBoardColors["orange"] = "#FF8C00";
MWConfig_BulletinBoardColors["yellow"] = "#FFFF00";
//------------------------------------------------------------------------------
// User Defined Commands
//------------------------------------------------------------------------------
// This feature allows you to assign some commands to your numpad.
// The current assignment is shown by pressing "Numpad +".
//
// Command Name Description
// -----------------------------------------------------------------------------
// ShowChickenThresholds Shows your chars current chicken thresholds.
// ShowTotalGoldCarried Shows the amount of gold your char currently carries.
// ShowActiveStates Shows the active states or your char.
// ShowScriptOrder Shows the current bot script schedule.
// ShowStash Shows the current layout of your stash and how many slots are used/unused.
// ClearPosition_X Kills all monsters in a radius of X. NOTE: Will not work while a bot script is running.
// PickItems Check for dropped items. NOTE: Will not work while a bot script is running.
// RevealMap Reveals the automap.
// ShowEnemiesOnMap Shows nearby enemies on automap.
// ShowMisslesOnMap Shows nearby missles on automap.
// ShowKeysCarried Shows how many of each type of key your character currently carries.
// ShowOrgansCarried Shows how many of each type of organ your character currently carries.
// ShowRunesCarried Shows how many runes of each type your character currently carries.
// ShowItemLevel Shows the item level and nip info of a selected item. NOTE: "Selected" means placed in your cube. ;)
// WriteBBOutput Generates BB Code output for a selected item's description. NOTE: "Selected" means placed in your cube. ;)
// -----------------------------------------------------------------------------
// ShowObjectUnits_X Shows the properties of all object units in a radius of X.
// ShowNpcUnits_X Shows the properties of all npc units in a radius of X.
// ShowPlayerUnits_X Shows the properties of all player units in a radius of X.
// ShowItemUnits_X Shows the properties of all item units in a radius of X.
// ShowTileUnits Shows the properties of all nearby tile units.
MWConfig_CommandAssignedToNumpad[0] = "ShowScriptOrder";
MWConfig_CommandAssignedToNumpad[1] = "ShowStash";
MWConfig_CommandAssignedToNumpad[2] = "ShowTotalGoldCarried";
MWConfig_CommandAssignedToNumpad[3] = "ShowChickenThresholds";
MWConfig_CommandAssignedToNumpad[4] = "ShowOrgansCarried";
MWConfig_CommandAssignedToNumpad[5] = "ShowKeysCarried";
MWConfig_CommandAssignedToNumpad[6] = "ShowRunesCarried";
MWConfig_CommandAssignedToNumpad[7] = "ShowMisslesOnMap";
MWConfig_CommandAssignedToNumpad[8] = "ShowEnemiesOnMap";
MWConfig_CommandAssignedToNumpad[9] = "RevealMap";
//------------------------------------------------------------------------------
// World Event Configuration
//------------------------------------------------------------------------------
// Set to true to stop and wait some minutes after receiving "x Stones of Jordan sold to Merchants" message. Your char will switch acts every couple of minutes so he won't be kicked.
MWConfig_CheckSojSales = true;
// Set to true to wait ingame after receiving a "Diablo Walks the Earth" message. Your char will switch acts every couple of minutes so he won't be kicked.
NTConfig_CheckCloneDiablo = true;
// Enter an account name that will be informed about soj sales or world events. Leave empty not to wisper any account.
MWConfig_WorldEventAccount = "";
// This is the time in minutes your char will remain in the game in case of a world event. Set to 0 to wait infinitely.
MWConfig_WorldEventWaitTime = 0;
// This can be used to specify IPs of servers that are currently hot, i.e. if a considerable amount of sojs has been sold on a server and thus a World Event is in order. The char will check if his current game IP is included in your list and wait in case it is.
MWConfig_HotServerIps = [-1, -1];
// This is the time in minutes that you would like your char to wait for in case his current game is hosted on a hot server.
MWConfig_HotIpIdleTime = 10;
//------------------------------------------------------------------------------
// Identification Configuration
//------------------------------------------------------------------------------
// Set to true to visit Deckard Cain in order to identify items. NOTE: Cain will NOT be visited if you char carries items that you like to be kept unidentified.
MWConfig_IdentAtCain = true;
// Set to true to always visit a merchant in order to sell items that are not required. If set to false, the char will drop these items, unless he is visiting a merchant anyway.
MWConfig_AlwaysSellTrashItems = true;
// Set to true to identify items when not in town. Items that do not meet your requirements will be dropped.
MWConfig_IdentAfterPickup = false;
// This is the minimum number of unid items to be carried before your char identifies them when not in town.
MWConfig_MinItemsToIdent = 3;
//------------------------------------------------------------------------------
// Itemlog Configuration
//------------------------------------------------------------------------------
// Set to true to log both sold and kept items in an XML logfile that can be viewed in a browser. NOTE: For some reason that does not work using IE, try Firefox instead.
// Also, using the XML log is known for increasing the number of crashes/restarts, better set this to false if you not necessarily need it.
MWConfig_UseXMLItemlog = false;
// Set to true to activate Nip debug mode. The Nip debug mode adds additional information to the item tooltips in the manager's item log that tells you exactly why an item was kept.
MWConfig_NipDebugMode = false;
// Set to true to log items in manager's log that were not required and therefore sold. NOTE: You should definately set this to false when running multiple bots. Use the XML log instead in order to keep track of sold items. ;)
MWConfig_LogSoldItems = false;
// Set to true to print how much gold was picked up during the last script after it is finished. Quite useful when using a goldbarb.
MWConfig_ShowGoldPickupsPerScript = false;
// Set to true to show a pick up message for gold.
MWConfig_ShowGoldPickups = true;
// Set to true to show a pick up message for potions.
MWConfig_ShowPotionPickups = true;
// This is the number of the lowest rune to be logged in the manager's item log when picked up. Mostly useful to keep your item log clean when collecting low runes. The default value 19 means that only runes equal or greater than LEM will be shown in the manager's item log.
MWConfig_LowestRuneToLog = 0;
// Set to true to create a Muddy's Mule Manager logfile at the end of every game.
MWConfig_WriteMMMLog = true;
// Set to true to write a common lofiles that logs how many gems, runes, keys, organs or essences your chars picked up.
MWConfig_WriteCommonLog = false;
// Show a drop notification on drops of items matching the below Nip line. Set to "" not to detect drops.
MWConfig_ShowDroppedItemSpecs = "[Quality] == Unique || [Quality] == Set || [Type] == Rune || [Flag] == Runeword";
//------------------------------------------------------------------------------
// Pickit Configuration
//------------------------------------------------------------------------------
// Set to true to pick up possibly useful items before picking up low priority items like keys, scrolls, gold, potions, and runes <= FAL.
MWConfig_PickUpPriorityItemsFirst = false;
// Pick up all items that are likely to be worth a lot of gold whenever your character is about to visit town.
MWConfig_PickUpMoneymakers = true;
// This is the minimum quantity of TP scrolls in your tome. If you got less, scrolls will be picked up in order to fill your tome.
MWConfig_MinimumTpScrollCount = 20;
// This is the minimum quantity of ID scrolls in your tome. If you got less, scrolls will be picked up in order to fill your tome.
MWConfig_MinimumIdScrollCount = 20;
//------------------------------------------------------------------------------
// Gambling Configuration
//------------------------------------------------------------------------------
// Set to true to enable gambling.
NTConfig_Gamble = true;
// This is the gold mount to start gambling.
NTConfig_GambleStartGold = 2300000;
// This is the gold mount to stop gambling.
NTConfig_GambleStopGold = 150000;
// Select which items are gambled by adding the classids of the desired items to the gambling array.
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
// NTConfig_GambleItem.push(<classid>);
//------------------------------------------------------------------------------
// Cubing Configuration
//------------------------------------------------------------------------------
// Set to true to log cubing of gems in the manager's common log.
MWConfig_ShowCubedGemsInCommonLog = false;
// Set to true to always remove all items from cube after transmuting. If set to false, the item will remain in cube and is not removed until it interferes with another recipe.
MWConfig_ClearCubeAfterCubing = false;
// Set to true to enable an advanced cubing algorithm that allows collecting ingredients for multiple recipes at the same time.
MWConfig_UseAdvancedCubingAlgorithm = true;
// Set to true if you do not want kept low runes or gems to be used for cubing. Set to false to use them anyway.
MWConfig_RestrictKeptItemsFromCubing = false;
// *********************** Misc ***********************
NTConfig_CubingItem.push([NTCU_ESSENCE, 653]); // Essences --> Token
// ****************** Transmute Gems ******************
//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
// ************* Transmute magic and rares *************
//NTConfig_CubingItem.push([NTCU_MAGIC_CHARM, 603]); // Magic Small Charm
//NTConfig_CubingItem.push([NTCU_MAGIC_CHARM, 605]); // Magic Grand Charm
//NTConfig_CubingItem.push([MWCU_RARE, 421]); // Rare Diadem
// ********************** Crafting *********************
//NTConfig_CubingItem.push([NTCU_CRAFT_HITPOWER_GLOVES, 336]); // Craft Chain Gloves
//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_HITPOWER_RING, 522]); // Craft Ring
//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_BOOTS, 455]); // Craft Wyrmhide Boots
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
// ****************** Transmute runes ******************
//NTConfig_CubingItem.push([NTCU_RUNE_THUL, 562]); // Transmute 3xTHUL --> 1xAMN
//NTConfig_CubingItem.push([NTCU_RUNE_AMN, 557]); // Transmute 3xAMN --> 1xSOL
//NTConfig_CubingItem.push([NTCU_RUNE_SOL, 567]); // Transmute 3xSOL --> 1xSHAEL
//NTConfig_CubingItem.push([NTCU_RUNE_SHAEL, 577]); // Transmute 3xSHAEL --> 1xDOL
//NTConfig_CubingItem.push([NTCU_RUNE_DOL, 572]); // Transmute 3xDOL --> 1xHEL
//NTConfig_CubingItem.push([NTCU_RUNE_HEL, 582]); // Transmute 3xHEL --> 1xIO
//NTConfig_CubingItem.push([NTCU_RUNE_IO, 563]); // Transmute 3xIO --> 1xLUM
//NTConfig_CubingItem.push([NTCU_RUNE_LUM, 558]); // Transmute 3xLUM --> 1xKO
//NTConfig_CubingItem.push([NTCU_RUNE_KO, 568]); // Transmute 3xKO --> 1xFAL
//NTConfig_CubingItem.push([NTCU_RUNE_FAL, 578]); // Transmute 3xFAL --> 1xLEM
//NTConfig_CubingItem.push([NTCU_RUNE_LEM, 573]); // Transmute 3xLEM --> 1xPUL
NTConfig_CubingItem.push([NTCU_RUNE_PUL, 583]); // Transmute 2xPUL --> 1xUM
NTConfig_CubingItem.push([NTCU_RUNE_UM, 564]); // Transmute 2xUM --> 1xMAL
NTConfig_CubingItem.push([NTCU_RUNE_MAL, 559]); // Transmute 2xMAL --> 1xIST
//NTConfig_CubingItem.push([NTCU_RUNE_IST, 569]); // Transmute 2xIST --> 1xGUL
NTConfig_CubingItem.push([NTCU_RUNE_GUL, 579]); // Transmute 2xGUL --> 1xVEX
//NTConfig_CubingItem.push([NTCU_RUNE_VEX, 574]); // Transmute 2xVEX --> 1xOHM
//NTConfig_CubingItem.push([NTCU_RUNE_OHM, 584]); // Transmute 2xOHM --> 1xLO
//NTConfig_CubingItem.push([NTCU_RUNE_LO, 565]); // Transmute 2xLO --> 1xSUR
//NTConfig_CubingItem.push([NTCU_RUNE_SUR, 560]); // Transmute 2xSUR --> 1xBER
//NTConfig_CubingItem.push([NTCU_RUNE_BER, 570]); // Transmute 2xBER --> 1xJAH
//NTConfig_CubingItem.push([NTCU_RUNE_JAH, 580]); // Transmute 2xJAH --> 1xCHAM
//NTConfig_CubingItem.push([NTCU_RUNE_CHAM, 575]); // Transmute 2xCHAM --> 1xZOD
// ******************* Socket items ********************
// Primary item must inlcluded in one of your .nip Files
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 429]); // Socket Dusk Shroud
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 430]); // Socket Wyrmhide
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 431]); // Socket Scarab Husk
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 432]); // Socket Wire Fleece
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 433]); // Socket Diamond Mail
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 434]); // Socket Loricated Mail
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 435]); // Socket Bone Weave
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 436]); // Socket Great Hauberk
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 437]); // Socket Balrog Skin
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 438]); // Socket Hellforge Plate
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 439]); // Socket Kraken Shell
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 440]); // Socket Lacquered Plate
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 441]); // Socket Shadow Plate
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 442]); // Socket Sacred Armor
NTConfig_CubingItem.push([NTCU_SOCKET_BODYARMOR, 443]); // Socket Archon Plate
//NTConfig_CubingItem.push([NTCU_SOCKET_WEAPON, 200]); NTConfig_CubingItem[NTConfig_CubingItem.length - 1].Ethereal = false; // Socket Berserker Axe
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_SOCKET_SHIELD, 447]); NTConfig_CubingItem[NTConfig_CubingItem.length - 1].Ethereal = true; // Socket Monarch
NTConfig_CubingItem.push([NTCU_SOCKET_SHIELD, 498]); NTConfig_CubingItem[NTConfig_CubingItem.length - 1].Ethereal = true; // Socket Sacred Targe
NTConfig_CubingItem.push([NTCU_SOCKET_SHIELD, 502]); NTConfig_CubingItem[NTConfig_CubingItem.length - 1].Ethereal = true; // Socket Vortex Shield
// ******************* Upgrade items *******************
//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
//NTConfig_CubingItem.push([NTCU_UPGRADE_N_UNIQUE_ARMOR, 342]); // Goblin Toe N -> E
//NTConfig_CubingItem.push([NTCU_UPGRADE_E_UNIQUE_ARMOR, 388]); // Goblin Toe E -> E
}
|
man soll sich eben keinen eingestellten bot schenken lassen...
Code:
//------------------------------------------------------------------------------
// Chat Announcements
//------------------------------------------------------------------------------
// These announcements will not be made unless NTConfig_PublicMode is set to true. Set to "" not to post a message.
// NOTE: You have to set a TPSafe message when using leechers and not entering unsafe TPs.
[B][COLOR="red"]/*[/COLOR][/B] MWConfig_Announcements.BaalThrone = "There are %d monster(s) in Throne!";
MWConfig_Announcements.BaalTpNone = "TP is safe!";
MWConfig_Announcements.BaalTpCold = "TP cold, %d monsters close!";
MWConfig_Announcements.BaalTpWarm = "TP warm, %d monsters close!";
MWConfig_Announcements.BaalTpHot = "TP hot, %d monsters close!";
MWConfig_Announcements.BaalTpSafe = "TP is safe!";
MWConfig_Announcements.BaalPreChamber = "Killing Baal!";
[B][COLOR="red"]*/[/COLOR][/B] MWConfig_Announcements.BaalKilled = "Next game!";
[B][COLOR="red"]/*[/COLOR][/B] MWConfig_Announcements.DiabloTpNone = "TP up, no monsters close!";
MWConfig_Announcements.DiabloTpCold = "TP cold, %d monsters close!";
MWConfig_Announcements.DiabloTpWarm = "TP warm, %d monsters close!";
MWConfig_Announcements.DiabloTpHot = "TP hot, %d monsters close!";
MWConfig_Announcements.DiabloTpSafe = "TP is safe!";
MWConfig_Announcements.DiabloPre = "Killing Diablo!";
[B][COLOR="Red"]*/[/COLOR][/B]
die /* wegmachen
|
|
|
01/23/2012, 11:06
|
#5395
|
elite*gold: 0
Join Date: Jan 2009
Posts: 3,170
Received Thanks: 1,191
|
Liegt einfach daran, dass die Nachrichten ausgeklammert sind mit /* ... */
So wie es kal_el schon dir aufzeigt
|
|
|
01/23/2012, 11:11
|
#5396
|
elite*gold: 0
Join Date: Jan 2009
Posts: 7,310
Received Thanks: 2,205
|
Quote:
Originally Posted by prrovoss
wie kommt es eigendlich dass mein leecher 450 und mein leader 550 runs hat im manager?
hab die beiden über nacht laufen lassen und am morgen sahs dann so aus. wieso macht der leecher 20% weniger runs?
|
kann auch sein das dein leecher zu schnell folgt, is beim leader das tor no ned mal ganz auf.. gehts beim leecher gar nicht mehr auf, und er landet wieder im channel.
|
|
|
01/23/2012, 13:49
|
#5397
|
elite*gold: 0
Join Date: Jan 2012
Posts: 25
Received Thanks: 0
|
Hallo ich wurde gerne Multi Boten habe 2 keys ! Habe auch schon geschafft 2 games gleichzeitig zu starten. Aber irgendwie bin ich zu doof die confics einzustellen. Leader char soll ein hammer, dia baal oder nur baal runs machen. Und leacher soll ne bowa sein. Hat das jemand ne Config für mich.
Danke
|
|
|
01/23/2012, 14:18
|
#5398
|
elite*gold: 0
Join Date: Mar 2009
Posts: 22
Received Thanks: 0
|
Hi!
Zunächst mal einen kleinen Dank, den ich hier aussprechen möchte. Der Bot ist wirklich gut! Der erste der es bei mir wirklich tut.
Ein kleines Problem habe ich allerdings:
Ich komme noch nicht ganz mit der Einstellung bei immunen Gegnern klar. Ich nutze den Bot mit einer FO/FB-Soso und möchte, dass generell bei nicht-immunen NUR der FO (unter Ausnutzung der vollen fcr) und bei immunen halt wahlweise FO oder FB benutzt wird. Irgendwie schnallt es der Bot aber noch nicht so richtig. Wie kann ich ihm das beibringen? Habe hier schon ein bisschen was zu dem Thema gefunden, aber irgendwie war nicht das dabei was ich brauche.
Im übrigen wäre es auch cool, wenn der Bot bei doppel-immunen Gegnern warten würde, bis der Merc den Gegner tot hat. Bei der Gräfin z.B. bricht er einfach den Kampf ab.
Gruß,
Das Fruchtsaftgetränk
|
|
|
01/23/2012, 14:24
|
#5399
|
elite*gold: 0
Join Date: Jan 2009
Posts: 7,310
Received Thanks: 2,205
|
Quote:
Originally Posted by jojojo912
Hallo ich wurde gerne Multi Boten habe 2 keys ! Habe auch schon geschafft 2 games gleichzeitig zu starten. Aber irgendwie bin ich zu doof die confics einzustellen. Leader char soll ein hammer, dia baal oder nur baal runs machen. Und leacher soll ne bowa sein. Hat das jemand ne Config für mich.
Danke 
|
ja da nimmst dein amazon script her
kopierst die baalleech nach die unter misc zu finden ist nach oben zu den bossen die du machen willt, und schreibst am ende dieser zeile den namen von deinem leader rein.
holst dir die skills die du für ne bowa brauchst aus dem ordner sdk-> sills.txt
stellst im manager den entry point auf NTBotleech.ntj
öffnest die ntbotleech.ntj und gibst den acc und den charnamen von deinem leader ein.
ich glaub das wars..
ah ja und für dein hämmerchen nimmst den entry point ntbot.ntj
config is eh soweit fertig fürn hammer... nur inventar einstellen und gut is und das baal script (das normale) hochkopieren...wenns ned scho oben is.
|
|
|
01/23/2012, 16:23
|
#5400
|
elite*gold: 0
Join Date: Feb 2010
Posts: 23
Received Thanks: 0
|
Quote:
Originally Posted by fghtrt
Läuft das Spiel in Englisch?
Ganz einfach.  Editiere im D2NT-Manager das Profil für deinen Botchar + mach ein Häkchen bei"direct txt" rein. Abspeichern nicht vergessen.
|
läuft auf englisch und hab auch das Häckchen rein! Bei mir kommt immer diese Fehler im Log
[AM] Status: not ready!
Was bedeutet das?
hat wohl was mit Automule zu tun! aber das hab ich eignetlich deaktiviert, dachte ich!
|
|
|
 |
|
Similar Threads
|
[Release] D2NT 3.1 1.13c
07/17/2016 - Diablo 2 - 91 Replies
hi,
hab eben den d2nt3.1 gefunden. ein neues baba script is dabei.
release thread eon
D2NT3.1
|
[Realease] Muddy's Waypoint Catcher
08/21/2013 - Diablo 2 Programming - 46 Replies
Moin zusammen,
hier mal die erste Release Version eines kleinen Scripts genannt Waypoint Catcher. Das ganze ist jetzt nichtmal 24h alt, dementsprechend sind vermutlich noch einige Bugs vorhanden. Hinweise dazu nehme ich gerne entgegen. ;)
Features:
- Suchen sämtlicher Wegpunkte mit Ausnahme, wobei in Akt ein durch Probleme im Jail Bereich nach dem Wegpunkt Outer Cloister abgebrochen wird
- Wahlweise auch mit TP an jedem gefundenen Wp, sodass man damit auch anderen (nicht-Bots) die...
|
[D2NT] Long Dia Release
05/10/2011 - Diablo 2 Programming - 28 Replies
Ein kleines Script für diablo, es startet beim eingang macht ein tp cleart den weg zum star macht am star noch ein tp dann läufts wie das normale nur cleart es schöner :)
hoffe euch gefällts ich habs noch nicht wirklich getestet (2-3 runs) bugs können gerne hier gepostet werden verbesserungs vorschläge auch :D
installation:
1.)Script in den Bot ordner kopieren
2.)Script im editor oder vergleichbaren öffnen
3.) Msg´s anpassen (ist nicht schwer)
4.) in der char config die zeile...
|
D2NT 3.0 Pickit release
10/22/2010 - Diablo 2 - 77 Replies
edit
|
Muddy's D2NT Help
07/29/2010 - Diablo 2 - 3 Replies
hi i just started to use the bot it work's great.
how do i set up the skill's i use on my Sorc and pick up itme's?
.....
if you reply to this post please use english
|
All times are GMT +1. The time now is 21:55.
|
|