|
You last visited: Today at 14:49
Advertisement
[Release] Muddy's D2NT
Discussion on [Release] Muddy's D2NT within the Diablo 2 Programming forum part of the Diablo 2 category.
07/21/2011, 18:48
|
#2581
|
elite*gold: 0
Join Date: Oct 2009
Posts: 798
Received Thanks: 165
|
hab versucht nen shrine catcher zum laufen zu bringen aber irgendwie funktioniert das nicht wirklich... hab alle ntbotgame.ntj in mwbotgame.ntj geändert wie es in alles anderen files auch der fall ist... aber mhhhhhh funkt alles nicht -.-
|
|
|
07/21/2011, 19:00
|
#2582
|
elite*gold: 0
Join Date: Aug 2009
Posts: 435
Received Thanks: 159
|
welchen shrine catcher, also wo haste das original her, vlt einfach mal in ner Code-Box posten, dann kann man dir eher helfen :P
|
|
|
07/21/2011, 19:39
|
#2583
|
elite*gold: 0
Join Date: Oct 2009
Posts: 798
Received Thanks: 165
|
Code:
function NTMain()
{
Include("libs/common/NTCommon.ntl");
NTC_IncludeLibs();
NTC_IncludeConfig("NTBot/char_configs");
NT_LoadConfig();
NTSI_LoadNIPFiles("NTBot/item_configs");
NTA_Initialize();
if(!NTTM_CheckAct())
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTTM_CheckAct()");
return;
}
NTTMGR_TownManager();
if(!NTTM_TownMove("waypoint"))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTTM_TownMove()");
return;
}
if(!NTM_TakeWaypoint(3))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_TakeWaypoint()");
return;
}
FindShrines();
if(me.areaid != 1)
{
if(!NTM_MoveToPresetUnit(2, NTC_UNIT_OBJECT, 83))
NTM_MoveToPresetUnit(2, NTC_UNIT_OBJECT, 2);
FindShrines();
}
if(me.areaid != 1)
{
if(!NTM_MoveToStair(3, 9))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_MoveToStair()");
return;
}
if(!NTM_MoveToStair(4, 10))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_MoveToStair()");
return;
}
FindShrines();
}
if(me.areaid != 1)
{
if(!NTM_MoveToStair(4, 10))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_MoveToStair()");
return;
}
if(!NTM_TakeStair(10))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_TakeStair()");
return;
}
if(!NTM_MoveToStair(10, 5))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_MoveToStair()");
return;
}
if(!NTM_TakeStair(5))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_TakeStair()");
return;
}
FindShrines();
}
if(me.areaid != 1)
{
if(!NTM_MoveToStair(6, 11))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_MoveToStair()");
return;
}
FindShrines();
}
NTC_SendMsgToScript("MWBotGame.ntj", "SCRIPT_END");
}
function FindShrines()
{
var ShrineIds = [2, 83, 85, 86, 93, 96, 97, 109, 116, 120, 123, 124, 133, 134, 135, 136, 150, 151, 172, 173, 184, 190, 191, 197, 199, 200, 201, 226, 231, 232, 260, 275, 276, 277, 278, 279, 282, 299, 300, 303, 325, 361, 414, 415, 421, 422, 423, 427, 428, 464, 465, 472, 479, 483, 484, 488, 491, 492, 495, 497, 499, 503, 509, 512, 520, 521, 522];
var ShrineLocs = [];
var unit = GetPresetUnits(me.areaid);
if(unit)
{
for (var j = 0; j < unit.length; j++){
for (var c = 0; c < ShrineIds.length; c++){
if (ShrineIds[c] == unit[j].id){
ShrineLocs.push([unit[j].roomx*5+unit[j].x + 3,unit[j].roomy*5+unit[j].y])
}
}
}
}
while(ShrineLocs.length > 0)
{
ShrineLocs.sort(SortRoomInt);
var _room = ShrineLocs.shift();
NTM_MoveTo(me.areaid, _room[0], _room[1], 9, 0);
var shrine = NTC_FindUnit(NTC_UNIT_OBJECT, "shrine");
if(shrine){
do{
if(GetDistance(me.x,me.y,shrine.x,shrine.y)<10){
if(shrine.shrinetype == 15)
{
NTM_MakeTP();
NTA_ClearPosition(20);
NTM_UsePortal("BluePortal");
break;
}
}
}while(shrine.GetNext());
}
if(me.areaid != 1)
break;
}
}
function SortRoomInt(a, b)
{
if(GetDistance(me.x, me.y, a[0], a[1]) < GetDistance(me.x, me.y, b[0], b[1]))
return -1;
return 1;
}
den hier. alles schon auf Muddys abgeändert, würde gerne noch mehr scripts und so benutzen aber Muddys scheint so stark verändert zu sein das ich nichtmal eine Early Ladder pickit benutzen kann... schade eigentlich....
ich hab mit müh und not geschafft mir nen hammerdin eq und nen echt extrem billiges Sorc Equip zusammen zu traden, und hab auch soweit nun alles für die beiden, bloß hab halt sonst NIX, und ne andere pickit die nicht so "krass" perfekten kram aufhebt ist halt mein nächstes großes ziel. sonst finde ich Speziell das Sorc händling von Muddys einfach perfekt, nie so gutes ausweichen gesehen, und meine Sorc hat wie gesagt echt verflucht schelchtes Gear an, kann trotzdem ohne probleme Hell botten ^^
|
|
|
07/22/2011, 09:04
|
#2584
|
elite*gold: 0
Join Date: Aug 2009
Posts: 435
Received Thanks: 159
|
hmm das einzige was mir auffält, es müsste am Anfang MWC_Initialize heißen und nicht NTA_... aber das sollte es eigentlich nicht am laufen hindern
was gibt er denn für ne Fehlermeldung aus? Hast du es schon mit Manager-Restart nach dem einfügen der neuen Scripte versucht?
Und was die NIPFiles angeht, da hat sich bei Muddy fast nix geändert, ich glaub nur MaxMana anstatt MaxMP bin mir da aber nicht ganz sicher
Edit: also bei mir läuft er, auch mit NTA_Initialize keine Ahnung warum er das bei dir nicht tut
|
|
|
07/22/2011, 12:57
|
#2585
|
elite*gold: 0
Join Date: Oct 2009
Posts: 798
Received Thanks: 165
|
mit der weile bin ich auf den etal umgestiegen... find das leech script und alles sehr nett bei dem :> wobei das handling für fire UND ice imune ziemlich kacke ist *g*. naja MW version is immernoch für MF besser, Etal für Baal, und für baal brauch ich ja das shrine script also hat sich das erledigt.
Find btw ziemlich lustig das fast JEDE D2NT version Muddy Waters in den Credits erwähnt :>
|
|
|
07/22/2011, 13:21
|
#2586
|
elite*gold: 0
Join Date: Jul 2011
Posts: 43
Received Thanks: 0
|
hey der Bot ist echt super nur habe da zwei Probleme.
1. Der Bot nimmt keine Goldenen Gegenstände auf nur Set kram
2.Der Bot verkauft all meine Gegenstände die er findet und er nimmt Blaue Gegenstände auf um sie zu verkaufen aber das will ich auch nicht 
hoffe ihr könnt mir helfen.
|
|
|
07/22/2011, 13:37
|
#2587
|
Administrator
elite*gold: 41364
Join Date: Jan 2010
Posts: 22,727
Received Thanks: 12,652
|
Quote:
Originally Posted by Thomas Gürtler
gibts bei muddys d2nt version eigentlich ein codia baal script oder muss man da mit anderem botscript aushelfen ? hätte nix gefunden oder macht der das automatisch.
spiel mit nem hdin und ner light soso, aber da die soso immer mitten in die Monster reitelt mit Bluebirds d2nt möchte ich muddys verwenden, oder geht das nicht.
bzw, wenns nicht geht kennt wer einen BOT der für dia und baalruns optmiert ist un mit ner light soso und hdin funzt? weil kuk funkt ja nur mit hdins was ich so gelesen habe oder?
|
Also meine Version ist dafür definitiv nicht optimiert, ich denke da müsstest du dir mit Scripten von Dritten aushelfen.
Quote:
Originally Posted by TheCrazy11
Ich weiß jetzt aus dem Kopf keine Funktion.
Man kann es schlampig über die NTC_InMyParty(LeaderName) machen, wenn jedoch die for-Schleife zu lange läuft, verliert man auch einiges an Zeit.
Also machen wir einfach eine neue Funktion auf Basis der NTC_InMyParty(playerName):
Code:
function NTC_InMyGame(playerName)
{
var _player;
_player = GetPlayerUnit();
if(arguments.length < 1 || !playerName)
return false;
if(_player)
{
do
{
if(_player.name.toLowerCase() == playerName.toLowerCase())
return true;
} while(_player.GetNext());
}
return false;
}
Diese einfach in die NTCommon.ntl einfügen und in den Scripts verwenden.
|
Wo genau siehst du dort denn einen größeren Zeitverlust? Die einfach verkettete Liste _player kann maximal aus 8 PlayerUnits bestehen, ansonsten wird in der Schleife wenig gemacht und Delays gibt es auch keine.
Ich denke selbst im schlimmsten Fall sollte die Laufzeit der Funktion bei deutlich unter 50ms liegen, insofern würde ich das Zeitproblem nicht sehen.
Quote:
Originally Posted by Talltree
Code:
function NTMain()
{
Include("libs/common/NTCommon.ntl");
NTC_IncludeLibs();
NTC_IncludeConfig("NTBot/char_configs");
NT_LoadConfig();
NTSI_LoadNIPFiles("NTBot/item_configs");
NTA_Initialize();
if(!NTTM_CheckAct())
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTTM_CheckAct()");
return;
}
NTTMGR_TownManager();
if(!NTTM_TownMove("waypoint"))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTTM_TownMove()");
return;
}
if(!NTM_TakeWaypoint(3))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_TakeWaypoint()");
return;
}
FindShrines();
if(me.areaid != 1)
{
if(!NTM_MoveToPresetUnit(2, NTC_UNIT_OBJECT, 83))
NTM_MoveToPresetUnit(2, NTC_UNIT_OBJECT, 2);
FindShrines();
}
if(me.areaid != 1)
{
if(!NTM_MoveToStair(3, 9))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_MoveToStair()");
return;
}
if(!NTM_MoveToStair(4, 10))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_MoveToStair()");
return;
}
FindShrines();
}
if(me.areaid != 1)
{
if(!NTM_MoveToStair(4, 10))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_MoveToStair()");
return;
}
if(!NTM_TakeStair(10))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_TakeStair()");
return;
}
if(!NTM_MoveToStair(10, 5))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_MoveToStair()");
return;
}
if(!NTM_TakeStair(5))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_TakeStair()");
return;
}
FindShrines();
}
if(me.areaid != 1)
{
if(!NTM_MoveToStair(6, 11))
{
NTC_SendMsgToScript("MWBotGame.ntj", "NTM_MoveToStair()");
return;
}
FindShrines();
}
NTC_SendMsgToScript("MWBotGame.ntj", "SCRIPT_END");
}
function FindShrines()
{
var ShrineIds = [2, 83, 85, 86, 93, 96, 97, 109, 116, 120, 123, 124, 133, 134, 135, 136, 150, 151, 172, 173, 184, 190, 191, 197, 199, 200, 201, 226, 231, 232, 260, 275, 276, 277, 278, 279, 282, 299, 300, 303, 325, 361, 414, 415, 421, 422, 423, 427, 428, 464, 465, 472, 479, 483, 484, 488, 491, 492, 495, 497, 499, 503, 509, 512, 520, 521, 522];
var ShrineLocs = [];
var unit = GetPresetUnits(me.areaid);
if(unit)
{
for (var j = 0; j < unit.length; j++){
for (var c = 0; c < ShrineIds.length; c++){
if (ShrineIds[c] == unit[j].id){
ShrineLocs.push([unit[j].roomx*5+unit[j].x + 3,unit[j].roomy*5+unit[j].y])
}
}
}
}
while(ShrineLocs.length > 0)
{
ShrineLocs.sort(SortRoomInt);
var _room = ShrineLocs.shift();
NTM_MoveTo(me.areaid, _room[0], _room[1], 9, 0);
var shrine = NTC_FindUnit(NTC_UNIT_OBJECT, "shrine");
if(shrine){
do{
if(GetDistance(me.x,me.y,shrine.x,shrine.y)<10){
if(shrine.shrinetype == 15)
{
NTM_MakeTP();
NTA_ClearPosition(20);
NTM_UsePortal("BluePortal");
break;
}
}
}while(shrine.GetNext());
}
if(me.areaid != 1)
break;
}
}
function SortRoomInt(a, b)
{
if(GetDistance(me.x, me.y, a[0], a[1]) < GetDistance(me.x, me.y, b[0], b[1]))
return -1;
return 1;
}
den hier. alles schon auf Muddys abgeändert, würde gerne noch mehr scripts und so benutzen aber Muddys scheint so stark verändert zu sein das ich nichtmal eine Early Ladder pickit benutzen kann... schade eigentlich....
ich hab mit müh und not geschafft mir nen hammerdin eq und nen echt extrem billiges Sorc Equip zusammen zu traden, und hab auch soweit nun alles für die beiden, bloß hab halt sonst NIX, und ne andere pickit die nicht so "krass" perfekten kram aufhebt ist halt mein nächstes großes ziel. sonst finde ich Speziell das Sorc händling von Muddys einfach perfekt, nie so gutes ausweichen gesehen, und meine Sorc hat wie gesagt echt verflucht schelchtes Gear an, kann trotzdem ohne probleme Hell botten ^^
|
Ich würde mal vermuten, du hast nach dem Einfügen des neuens Scripts einfach keinen Neustart des Managers gemacht, denn der ist in diesem Fall immer notwendig, weil dem Script ansonsten kein Objekt zugeordnet ist und es im folgenden nicht gefunden werden kann.
Zu den Nips:
Dort habe ich tatsächlich nicht viel verändert, an sich sollten die gängigen Nip Sammlungen durchweg kompatibel sein, im Zweifelsfall einfach mal per Nip Checker aus dem Startpost prüfen.
Quote:
Originally Posted by Talltree
mit der weile bin ich auf den etal umgestiegen... find das leech script und alles sehr nett bei dem :> wobei das handling für fire UND ice imune ziemlich kacke ist *g*. naja MW version is immernoch für MF besser, Etal für Baal, und für baal brauch ich ja das shrine script also hat sich das erledigt.
Find btw ziemlich lustig das fast JEDE D2NT version Muddy Waters in den Credits erwähnt :>
|
Letzteres wird daran liegen, dass ich meine Sachen stets selbst entwickelt und keine Probleme durch bloßes Googlen gelöst habe. Dadurch haben viele meiner Funktionen und Scripte eine gewisse Originalität behalten.
Quote:
Originally Posted by muh999
hey der Bot ist echt super nur habe da zwei Probleme.
1. Der Bot nimmt keine Goldenen Gegenstände auf nur Set kram
2.Der Bot verkauft all meine Gegenstände die er findet und er nimmt Blaue Gegenstände auf um sie zu verkaufen aber das will ich auch nicht 
hoffe ihr könnt mir helfen.
|
1. Dann passe deine Nips entsprechend an, eine kleine Einweisung findest du etwa  .
2. Initialisiere die Variable MWConfig_PickUpMoneymakers in der globalen Config mit false.
LG
Muddy
|
|
|
07/22/2011, 13:49
|
#2588
|
elite*gold: 0
Join Date: Oct 2009
Posts: 798
Received Thanks: 165
|
Quote:
Originally Posted by Muddy_Waters
Letzteres wird daran liegen, dass ich meine Sachen stets selbst entwickelt und keine Probleme durch bloßes Googlen gelöst habe. Dadurch haben viele meiner Funktionen und Scripte eine gewisse Originalität behalten.
LG
Muddy
|
find ich total cool :> gibt wenige leute die sich damit genug beschäftigen das sie so viel selbst coden, es gibt bestimmt noch einige sachen die man machen könnte (z.B automatisierte Quests) aber deine Scripts haben halt einen großen wiedererkennungswert
|
|
|
07/22/2011, 13:50
|
#2589
|
elite*gold: 0
Join Date: Aug 2009
Posts: 435
Received Thanks: 159
|
Hatte jetzt grade wieder ein Problem...
Hatte heute morgen ein neues Bot-script eingefügt, zu Testzwecken. Habe danach den Manager gestartet, und die Soso mit der NTBot.ntj das Shrinecatcher script getestet, funktionierte auch soweit...
Als ich gerade eben wieder starten wollte hatte ich das script aus der Config wieder rausgenommen. Starte also wieder den Manager und meine 3 Bots, der Pala mit der NTBot.ntj und die Soso und der Dudu, mit der NTBotLeech.ntj. Jetzt blieben aber beide Bots mit der NTBotLeech.ntj beim Splash schrim hängen und im Manager stand "ewig" Loading.
Gut dachte ich mir, kenn ich ja schon das Problem, also Manager wieder ausgemacht, Botscript entfernt und alles war wieder wunderbar. Aber merkwürdig ist das schon... irgendeine Idee?
hier mal die verwendete NTBotLeech.ntj:
Code:
//###################################################################
//###########################Einstellungen###########################
//###################################################################
var LeaderAccountName = "Zensiert";
var LeaderName = "Zensiert";
var GamePassword = "";
var JoinGameAgain = false; // wenn der Bot nach chicken oder disconnect ins selbe Spiel nochmal gehen soll, auf true stellen
var UseCDKeyChangeTrick = true; // Wenn der LeechBot mehrere CD Keys nutzen soll, dann auf true stellen.
var JoinRandomChannel = false;
var JoinChannelInChat = "OP ePvPBaal";
var FirstJoinMessage = ""; // Soll der Leechbot etwas sagen, wenn er in den Chat kommt, dann hier eintragen
var ChatMessageAfterGame = ""; // Soll der Leechbot etwas sagen, wenn er aus dem Spiel kommt, dann hier eintragen
//###################################################################
//##############################Delays###############################
//###################################################################
var GameMinLength = 240000;
// realm delays (minutes)
var UnableToConnectRetry = 2;
var RealmDownRetry = 60;
var DisconnectedRetry = 2;
var CdKeyInUseRetry = 2;
// interface delays (milliseconds)
var ConnectingToBnetTimeout = 20000;
var CharacterScreenTimeout = 10000;
var PleaseWaitTimeout = 10000;
var CreateGameThreshold = 10000;
var CreateGameThresholdRandom = 1000;
var CreateGameTimeout = 15000;
var WaitInLineTimeout = 15000;
var CharacterSelectDelay = 1000;
var LoginDelay = 1000;
var ClickDelay = 500;
var TextDelay = 500;
var ClickDelayRandom = 500;
var TextDelayRandom = 500;
var GameDoesNotExistDelayMin = 600000;
var GameDoesNotExistDelayMax = 900000;
var GameDoesNotExistTimeout = 30000;
var WaitBeforeEnterChatMin = 1000;
var WaitBeforeEnterChatMax = 2000;
var WaitInChatBeforeActionsMin = 2000;
var WaitInChatBeforeActionsMax = 3000;
var UseFileBackupTimeMax = 30;
var GameAnnouncementDelayRandom = 500;
var GameAnnouncementDelay = 5000;
var GameAnnouncement = "Creating %game%counter in about %time seconds";
// Only for JoinBot (friend list delay, milliseconds)
var LeaderOfflineDelay = 30000;
var LeaderInChatDelay = 10000;
var GameIsFullDelay = 30000;
// Mule Settings
var UsePremadeMuleAccounts = false; // 'true' uses NTConfig_AutoMule.ntl, 'false' uses NTConfig_FullAuto.ntl
var JoinRetries = 5; // How many Attempts before giving up the Mule game?
var JoinRetryDelay = 55; // Seconds to wait between Retry Attempts
var TimeBeforeMuleGame = 3; // Minutes to wait before creating the MuleGame
var TimeAfterMule = 3; // Minutes to wait before logging back to Bot Account
//###################################################################
//###################################################################
//###############DO NOT CHANGE ANYTHING BELOW THIS###################
//###################################################################
//###################################################################
// AutoMule Variables and Stuff
var isMuling = false;
var preventRecover = false;
var isWaiting = false;
var MuleState = "notmuling";
var DGCurrentAcc = 0;
DGDebug = false;
// Creat New Account Variables
var createNewAccount = false;
var CharCreateNumber = -1;
var RegMail = "";
var muleFull = false;
var _NewAccName;
var _NewAccPW;
var AccPrefix;
var MuleAccSuffix;
var NewAccPW;
var DGNipFiles;
var UseNumbers;
var isLadder;
var isHC;
var isClassic;
var RandomNameLength;
var MuleGame;
var MuleGamePassword;
var DGMuleAccs;
var DGMulePws;
var DGNipFiles;
var MuleCharLocation;
// Auto Mule Variables
var JoinBug;
var NewCharBug = 0;
if (UsePremadeMuleAccounts)
Include("NTBot/mule_configs/NTConfig_AutoMule.ntl");
else
Include("NTBot/mule_configs/NTConfig_FullAuto.ntl");
NT_LoadMuleConfig();
Include("libs/common/NTMuleFunctions.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 SayChatMsgAfterGame = true;
var JoinedChannel = false;
var JustJoined = true;
var MadeAnnouncement = false;
Include("libs/controlInfo.ntl");
Include("libs/common/NTCommon.ntl");
// This is for recovering purpose, delete mulestate file is you get stuck
ReadMuleStats();
var ControlData = new controlInfo();
var SameGame = "";
var OldGame = "";
var Game = "";
var _gamename = "";
var _gamepassword = "";
var _leaderOfflineTick = -LeaderOfflineDelay;
var _leaderInChatTick = -LeaderInChatDelay;
var _GameIsFullTick = -GameIsFullDelay;
var Debug = false;
var JoinChatAfterGame = true;
function NTMain()
{
var _ingame;
Delay(1000);
_ingame = false;
ControlData.ClickDelay = ClickDelay;
ControlData.TextDelay = TextDelay;
ControlData.ClickDelayRandom = ClickDelayRandom;
ControlData.TextDelayRandom = TextDelayRandom;
RegisterEvent(EVENT_SCRIPTMSG, NT_MuleMsgEvents);
while(true)
{
if(me.ingame)
{
if(!InGameAt)
InGameAt = GetTickCount();
if(!_ingame)
{
if(isMuling)
{
if (DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "[Debug] Joined Mule Game");
switch (MuleState)
{
case "notmuling": //Done or not yet started
// No... we really are not supposed to be here
isMuling = 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
_Script = "NTBot/bots/NTPermGameandMule.ntj";
break;
case "mule": //Muleing
_Script = "NTBot/bots/NTPickStuff.ntj";
break;
case "mulefull": // Mule Full
_Script = "NTBot/bots/NTPickStuff.ntj";
break;
case "done": // Next Account
_Script = "NTBot/bots/NTPickStuff.ntj";
break;
case "recover": // Recovering
_Script = "NTBot/bots/NTRecover.ntj";
break;
default:
_Script = "NTBot/NTPermGameandMule.ntj";
break;
}
if (DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "Debug: Load " + _Script);
if(Load(_Script))
{
_ingame = true;
JoinBug = 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 (isWaiting)
{
Delay(1000);
}
else
{
if(_ingame)
{
_ingame = false;
NT_SendEventToOOG(D2NT_MGR_READY, "", 0);
}
if(isMuling)
DG_DoMuleNT_LocationAction()
else
NT_LocationAction(ControlData.getLocation());
Delay(500);
}
}
}
}
function NT_LocationAction(location)
{
var _randomChannel;
switch(location.id)
{
case 3: // Lobby Chat
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
if(!ChatActionsDone)
{
ChatActionsDone = true;
Delay(Random(WaitInChatBeforeActionsMin, WaitInChatBeforeActionsMax));
if(JoinRandomChannel || JoinChannelInChat != "")
{
SetStatusText("ÿc8Joining channel...");
Say("/join " + (JoinRandomChannel ? getRandomString(Random(3,10)) : JoinChannelInChat));
Delay(2000);
}
if(FirstJoinMessage)
{
Say(FirstJoinMessage);
Delay(1000);
}
}
if (SayChatMsgAfterGame == true)
{
if(ChatMessageAfterGame && OldGame != "")
Say(ChatMessageAfterGame);
SetStatusText("ÿc8Checking friendlist...");
Say("/f l");
SayChatMsgAfterGame = false;
Delay(1500);
}
Game = "";
if(chat = ControlData.get(ControlData.controls.lobby.chat.textBox.channelText))
{
var found_leader = false;
lines = chat.GetText();
for (var line_id = lines.length - 1; line_id > -1; line_id--)
{
if (found_leader) // useless... :/
break;
if (lines[line_id].substring(0,1) == " ")
continue;
// retrieving the whole message
var msg = lines[line_id].replace(/^\s+|\s+$/, "");
var msglines = 1;
while (lines[line_id+msglines] != undefined && lines[line_id+msglines].substring(0,2) == " ")
{
msg += " " + lines[line_id+msglines].replace(/^\s+|\s+$/, "");
msglines++;
}
// checking if the msg is a friendly whisper
if (msg.toLowerCase().lastIndexOf(LeaderName.toLowerCase() + " (*" + LeaderAccountName.toLowerCase() + ")") > -1)
{
var regGameNameWhispered=/^.*(game|partie|spiel|partita|partida).*(nomm[^\s]*|called|chiamata)\s*([\w\s-]*\w)\s*\.\s*$/gi;
if (msg.match(regGameNameWhispered))
Game = msg.replace(regGameNameWhispered, "$3");
if (Game != "")
{
found_leader = true;
break;
}
}
// checking if the msg is from the friend list
if (msg.toLowerCase().lastIndexOf(": " + LeaderAccountName.toLowerCase() + ",") > -1)
{
found_leader = true;
var regOffline=/^.*(offline|desconectado).*$/gi;
var regInChat=/^.*(channel|canale?)\s*([\w\s-]*\w)\.?\s*$/gi;
var regGameName=/^.*(game|partie|spiel|partita|partida)\s*([\w\s-]*\w)\s*\(priv[^\)]*\)\.\s*$/gi;
if (msg.match(regOffline))
SetStatusText("ÿc8Leader is currently offline.");
else if (msg.match(regInChat))
SetStatusText("ÿc8Waiting for leader to create a game.");
else if (msg.match(regGameName))
Game = msg.replace(regGameName, "$2");
break;
}
}
if (found_leader == false)
{
DebugInOOG("I couldn\'t find the leader in my friend list!");
SetStatusText("ÿc8Leader not found.");
}
if (Game != "")
{
DebugInOOG('Leader is in the game "' + Game + '"');
//ControlData.click(ControlData.controls.lobby.button.join);
//Delay(100);
if(!JoinGameAgain)
{
if (Game != SameGame)
{
SetStatusText("ÿc8Joining Game: " + Game);
if (UseCDKeyChangeTrick)
{
NT_SendEventToOOG(D2NT_MGR_CREATE_GAME, location.name, 0);
Delay(1000);
}
ControlData.click(ControlData.controls.lobby.button.join);
Delay (200);
}
else
SetStatusText("ÿc8Waiting for next game...");
}
else
{
SetStatusText("ÿc8Joining Game: " + Game);
if (UseCDKeyChangeTrick)
{
NT_SendEventToOOG(D2NT_MGR_CREATE_GAME, location.name, 0);
Delay(1000);
}
ControlData.click(ControlData.controls.lobby.button.join);
Delay (200);
}
}
}
else
{
DebugInOOG("I can\'t read the chat!");
}
if(Game != "")
SameGame = Game;
break;
case 1: // Lobby
if(location.id == 1 && JoinChatAfterGame)
{
Delay(Random(WaitBeforeEnterChatMin, WaitBeforeEnterChatMax));
ControlData.click(ControlData.controls.lobby.button.enterChat);
break;
}
break;
case 2: // Waiting In Line
if(GetTickCount()-LastGameMade > WaitInLineTimeout)
ControlData.click(ControlData.controls.lobby.inLine.button.cancel);
break;
case 4: // Create Game
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);
break;
}
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 (Game)
{
ControlData.setText( ControlData.controls.lobby.join.editBox.gameName, Game);
Delay (100);
ControlData.setText( ControlData.controls.lobby.join.editBox.password, GamePassword);
Delay (100);
ControlData.click(ControlData.controls.lobby.join.button.joinGame);
RunGC(); // run garbage collector between each game
NT_LocationTimeout(5000, location);
LastGameStatus = 1; // pending join
}
else
{
DebugInOOG("No game to join : cancelling");
me.Cancel(1);
Delay(1000);
}
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, "yE00000Game already exists", 0);
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;
default:
DebugInOOG("Unhandled location : "+location.id);
break;
}
//DebugInOOG("Location : "+location.id);
}
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()
{
if(InGameAt)
{
duration = GetTickCount() - InGameAt;
InGameAt = (duration < GameMinLength ? GameMinLength - duration : 0);
}
}
function NT_LocationTimeout(time, location)
{
endtime = GetTickCount() + time;
while(ControlData.getLocation().id == location.id && endtime > GetTickCount())
{
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " (" + parseInt((endtime-GetTickCount())/1000) + "s)", 0);
Delay(500);
}
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 getRandomString(_length)
{
_retString = "";
_charSet = "0123456789abcdefghijklmnopqrstuvwxyz";
while(_length--)
{
_retString += _charSet.charAt(Random(0, _charSet.length-1));
Delay(1);
}
return _retString;
}
function DebugInOOG(logString)
{
if (Debug)
return SendCopyData("D2NT Manager", null, 9<<16, "-- Debug : " + logString);
else
return false;
}
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_IsChannelUser()
{
for(var i = 0; i < ChannelUsers.length; i++)
{
if(me.account.toLowerCase() == ChannelUsers[i].toLowerCase() || me.charname.toLowerCase() == ChannelUsers[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(isLeecher)
MaximumLocationLoops = 900;
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_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_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;
}
|
|
|
07/22/2011, 15:18
|
#2590
|
elite*gold: 0
Join Date: Feb 2008
Posts: 24
Received Thanks: 0
|
Hallo,
Bei mir Macht der Bot (der ansonsten einwandfrei läuft) probleme beim Verwenden von key.mpq's . Er benutzt sie sozusagen gar nicht. Habe es mit mehreren verschiedenen versucht. Er benutzt immer die Keys mit denen Dia installiert ist, was zur folge hat, dass ich keine 2 Instanzen von Diablo laufen lassen kann wegen "Der Key wird schon verwendet".
Mir ist aufgefallen, das D2NT nicht meckert, wenn ich absichtlich einen Key.mpq namen angebe, den es gar nicht gibt. Er startet einfach und ohne murren mit den installierten d2 keys.
Ich hoffe ihr könnt mir meinen Fehler zeigen.
Danke ssseeer
|
|
|
07/22/2011, 15:18
|
#2591
|
elite*gold: 0
Join Date: Jul 2011
Posts: 43
Received Thanks: 0
|
Jetzt klappt es das mein Bot Grüne und Goldene Gegenstände aufnimmt aber immer nur 1 und den rest lässt er liegen. wodrann kann das liegen?
|
|
|
07/22/2011, 15:25
|
#2592
|
elite*gold: 0
Join Date: Aug 2009
Posts: 435
Received Thanks: 159
|
vlt sind es einfach nur die falschen grünen/goldenen Sachen, die gar nicht in deinen Pickits auftauchen, weil sie eventuell zu low sind? weil soviel grün/gold droppt nun auch nicht :P
|
|
|
07/22/2011, 17:21
|
#2593
|
elite*gold: 0
Join Date: Feb 2008
Posts: 24
Received Thanks: 0
|
Kann mir hier wirklich niemand weiterhelfen? Das mag ich fast nicht glauben, da mir dieses Forum sonst als überaus kompetent erscheint.
Ich habe inzwischen noch einmal das Internet durchkämmt, jedoch nichts gefunden, was wirklich meinem Problem entspricht. Ich fand lediglich viele ähnlich geartete Probleme, deren lösungsansätze mir jedoch auch nicht weiterhalfen.
Der Versuch die Problematik zu umgehen, indem ich den gesammten D2 ordner kopiere und dann mit Sandys Key Changer den Key ändere, scheiterte daran, das sich Sandys bei diesem Versuch immer wieder aufhängt.
Ich wäre immer noch dankbar für Lösungsansätze
|
|
|
07/22/2011, 17:39
|
#2594
|
elite*gold: 0
Join Date: Mar 2010
Posts: 539
Received Thanks: 418
|
Quote:
Originally Posted by The_Mog
Kann mir hier wirklich niemand weiterhelfen? Das mag ich fast nicht glauben, da mir dieses Forum sonst als überaus kompetent erscheint.
Ich habe inzwischen noch einmal das Internet durchkämmt, jedoch nichts gefunden, was wirklich meinem Problem entspricht. Ich fand lediglich viele ähnlich geartete Probleme, deren lösungsansätze mir jedoch auch nicht weiterhalfen.
Der Versuch die Problematik zu umgehen, indem ich den gesammten D2 ordner kopiere und dann mit Sandys Key Changer den Key ändere, scheiterte daran, das sich Sandys bei diesem Versuch immer wieder aufhängt.
Ich wäre immer noch dankbar für Lösungsansätze 
|
Ich schätze mal, du verwendet Serby's Keychanger! 
Hast du bei wirklich den kompletten Namen der MPQ-Files im Loader angegeben z.B. Key1.mpq?
Auch ganz sicher, dass die Keyfiles nicht Key1.mpq.mpq heißen?
Und der Loader verwendet die Keyfiles nur, wenn du sie komplett richtig einträgst, wenn er das Keyfile nicht findet, verwendet er den Installationskey!
|
|
|
07/22/2011, 17:42
|
#2595
|
Administrator
elite*gold: 41364
Join Date: Jan 2010
Posts: 22,727
Received Thanks: 12,652
|
Quote:
Originally Posted by DeathFromHeaven
Hatte jetzt grade wieder ein Problem...
Hatte heute morgen ein neues Bot-script eingefügt, zu Testzwecken. Habe danach den Manager gestartet, und die Soso mit der NTBot.ntj das Shrinecatcher script getestet, funktionierte auch soweit...
Als ich gerade eben wieder starten wollte hatte ich das script aus der Config wieder rausgenommen. Starte also wieder den Manager und meine 3 Bots, der Pala mit der NTBot.ntj und die Soso und der Dudu, mit der NTBotLeech.ntj. Jetzt blieben aber beide Bots mit der NTBotLeech.ntj beim Splash schrim hängen und im Manager stand "ewig" Loading.
Gut dachte ich mir, kenn ich ja schon das Problem, also Manager wieder ausgemacht, Botscript entfernt und alles war wieder wunderbar. Aber merkwürdig ist das schon... irgendeine Idee?
hier mal die verwendete NTBotLeech.ntj:
Code:
//###################################################################
//###########################Einstellungen###########################
//###################################################################
var LeaderAccountName = "Zensiert";
var LeaderName = "Zensiert";
var GamePassword = "";
var JoinGameAgain = false; // wenn der Bot nach chicken oder disconnect ins selbe Spiel nochmal gehen soll, auf true stellen
var UseCDKeyChangeTrick = true; // Wenn der LeechBot mehrere CD Keys nutzen soll, dann auf true stellen.
var JoinRandomChannel = false;
var JoinChannelInChat = "OP ePvPBaal";
var FirstJoinMessage = ""; // Soll der Leechbot etwas sagen, wenn er in den Chat kommt, dann hier eintragen
var ChatMessageAfterGame = ""; // Soll der Leechbot etwas sagen, wenn er aus dem Spiel kommt, dann hier eintragen
//###################################################################
//##############################Delays###############################
//###################################################################
var GameMinLength = 240000;
// realm delays (minutes)
var UnableToConnectRetry = 2;
var RealmDownRetry = 60;
var DisconnectedRetry = 2;
var CdKeyInUseRetry = 2;
// interface delays (milliseconds)
var ConnectingToBnetTimeout = 20000;
var CharacterScreenTimeout = 10000;
var PleaseWaitTimeout = 10000;
var CreateGameThreshold = 10000;
var CreateGameThresholdRandom = 1000;
var CreateGameTimeout = 15000;
var WaitInLineTimeout = 15000;
var CharacterSelectDelay = 1000;
var LoginDelay = 1000;
var ClickDelay = 500;
var TextDelay = 500;
var ClickDelayRandom = 500;
var TextDelayRandom = 500;
var GameDoesNotExistDelayMin = 600000;
var GameDoesNotExistDelayMax = 900000;
var GameDoesNotExistTimeout = 30000;
var WaitBeforeEnterChatMin = 1000;
var WaitBeforeEnterChatMax = 2000;
var WaitInChatBeforeActionsMin = 2000;
var WaitInChatBeforeActionsMax = 3000;
var UseFileBackupTimeMax = 30;
var GameAnnouncementDelayRandom = 500;
var GameAnnouncementDelay = 5000;
var GameAnnouncement = "Creating %game%counter in about %time seconds";
// Only for JoinBot (friend list delay, milliseconds)
var LeaderOfflineDelay = 30000;
var LeaderInChatDelay = 10000;
var GameIsFullDelay = 30000;
// Mule Settings
var UsePremadeMuleAccounts = false; // 'true' uses NTConfig_AutoMule.ntl, 'false' uses NTConfig_FullAuto.ntl
var JoinRetries = 5; // How many Attempts before giving up the Mule game?
var JoinRetryDelay = 55; // Seconds to wait between Retry Attempts
var TimeBeforeMuleGame = 3; // Minutes to wait before creating the MuleGame
var TimeAfterMule = 3; // Minutes to wait before logging back to Bot Account
//###################################################################
//###################################################################
//###############DO NOT CHANGE ANYTHING BELOW THIS###################
//###################################################################
//###################################################################
// AutoMule Variables and Stuff
var isMuling = false;
var preventRecover = false;
var isWaiting = false;
var MuleState = "notmuling";
var DGCurrentAcc = 0;
DGDebug = false;
// Creat New Account Variables
var createNewAccount = false;
var CharCreateNumber = -1;
var RegMail = "";
var muleFull = false;
var _NewAccName;
var _NewAccPW;
var AccPrefix;
var MuleAccSuffix;
var NewAccPW;
var DGNipFiles;
var UseNumbers;
var isLadder;
var isHC;
var isClassic;
var RandomNameLength;
var MuleGame;
var MuleGamePassword;
var DGMuleAccs;
var DGMulePws;
var DGNipFiles;
var MuleCharLocation;
// Auto Mule Variables
var JoinBug;
var NewCharBug = 0;
if (UsePremadeMuleAccounts)
Include("NTBot/mule_configs/NTConfig_AutoMule.ntl");
else
Include("NTBot/mule_configs/NTConfig_FullAuto.ntl");
NT_LoadMuleConfig();
Include("libs/common/NTMuleFunctions.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 SayChatMsgAfterGame = true;
var JoinedChannel = false;
var JustJoined = true;
var MadeAnnouncement = false;
Include("libs/controlInfo.ntl");
Include("libs/common/NTCommon.ntl");
// This is for recovering purpose, delete mulestate file is you get stuck
ReadMuleStats();
var ControlData = new controlInfo();
var SameGame = "";
var OldGame = "";
var Game = "";
var _gamename = "";
var _gamepassword = "";
var _leaderOfflineTick = -LeaderOfflineDelay;
var _leaderInChatTick = -LeaderInChatDelay;
var _GameIsFullTick = -GameIsFullDelay;
var Debug = false;
var JoinChatAfterGame = true;
function NTMain()
{
var _ingame;
Delay(1000);
_ingame = false;
ControlData.ClickDelay = ClickDelay;
ControlData.TextDelay = TextDelay;
ControlData.ClickDelayRandom = ClickDelayRandom;
ControlData.TextDelayRandom = TextDelayRandom;
RegisterEvent(EVENT_SCRIPTMSG, NT_MuleMsgEvents);
while(true)
{
if(me.ingame)
{
if(!InGameAt)
InGameAt = GetTickCount();
if(!_ingame)
{
if(isMuling)
{
if (DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "[Debug] Joined Mule Game");
switch (MuleState)
{
case "notmuling": //Done or not yet started
// No... we really are not supposed to be here
isMuling = 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
_Script = "NTBot/bots/NTPermGameandMule.ntj";
break;
case "mule": //Muleing
_Script = "NTBot/bots/NTPickStuff.ntj";
break;
case "mulefull": // Mule Full
_Script = "NTBot/bots/NTPickStuff.ntj";
break;
case "done": // Next Account
_Script = "NTBot/bots/NTPickStuff.ntj";
break;
case "recover": // Recovering
_Script = "NTBot/bots/NTRecover.ntj";
break;
default:
_Script = "NTBot/NTPermGameandMule.ntj";
break;
}
if (DGDebug)
NTC_SendLogToOOG(NTC_LOG_COMMON, "Debug: Load " + _Script);
if(Load(_Script))
{
_ingame = true;
JoinBug = 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 (isWaiting)
{
Delay(1000);
}
else
{
if(_ingame)
{
_ingame = false;
NT_SendEventToOOG(D2NT_MGR_READY, "", 0);
}
if(isMuling)
DG_DoMuleNT_LocationAction()
else
NT_LocationAction(ControlData.getLocation());
Delay(500);
}
}
}
}
function NT_LocationAction(location)
{
var _randomChannel;
switch(location.id)
{
case 3: // Lobby Chat
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
if(!ChatActionsDone)
{
ChatActionsDone = true;
Delay(Random(WaitInChatBeforeActionsMin, WaitInChatBeforeActionsMax));
if(JoinRandomChannel || JoinChannelInChat != "")
{
SetStatusText("ÿc8Joining channel...");
Say("/join " + (JoinRandomChannel ? getRandomString(Random(3,10)) : JoinChannelInChat));
Delay(2000);
}
if(FirstJoinMessage)
{
Say(FirstJoinMessage);
Delay(1000);
}
}
if (SayChatMsgAfterGame == true)
{
if(ChatMessageAfterGame && OldGame != "")
Say(ChatMessageAfterGame);
SetStatusText("ÿc8Checking friendlist...");
Say("/f l");
SayChatMsgAfterGame = false;
Delay(1500);
}
Game = "";
if(chat = ControlData.get(ControlData.controls.lobby.chat.textBox.channelText))
{
var found_leader = false;
lines = chat.GetText();
for (var line_id = lines.length - 1; line_id > -1; line_id--)
{
if (found_leader) // useless... :/
break;
if (lines[line_id].substring(0,1) == " ")
continue;
// retrieving the whole message
var msg = lines[line_id].replace(/^\s+|\s+$/, "");
var msglines = 1;
while (lines[line_id+msglines] != undefined && lines[line_id+msglines].substring(0,2) == " ")
{
msg += " " + lines[line_id+msglines].replace(/^\s+|\s+$/, "");
msglines++;
}
// checking if the msg is a friendly whisper
if (msg.toLowerCase().lastIndexOf(LeaderName.toLowerCase() + " (*" + LeaderAccountName.toLowerCase() + ")") > -1)
{
var regGameNameWhispered=/^.*(game|partie|spiel|partita|partida).*(nomm[^\s]*|called|chiamata)\s*([\w\s-]*\w)\s*\.\s*$/gi;
if (msg.match(regGameNameWhispered))
Game = msg.replace(regGameNameWhispered, "$3");
if (Game != "")
{
found_leader = true;
break;
}
}
// checking if the msg is from the friend list
if (msg.toLowerCase().lastIndexOf(": " + LeaderAccountName.toLowerCase() + ",") > -1)
{
found_leader = true;
var regOffline=/^.*(offline|desconectado).*$/gi;
var regInChat=/^.*(channel|canale?)\s*([\w\s-]*\w)\.?\s*$/gi;
var regGameName=/^.*(game|partie|spiel|partita|partida)\s*([\w\s-]*\w)\s*\(priv[^\)]*\)\.\s*$/gi;
if (msg.match(regOffline))
SetStatusText("ÿc8Leader is currently offline.");
else if (msg.match(regInChat))
SetStatusText("ÿc8Waiting for leader to create a game.");
else if (msg.match(regGameName))
Game = msg.replace(regGameName, "$2");
break;
}
}
if (found_leader == false)
{
DebugInOOG("I couldn\'t find the leader in my friend list!");
SetStatusText("ÿc8Leader not found.");
}
if (Game != "")
{
DebugInOOG('Leader is in the game "' + Game + '"');
//ControlData.click(ControlData.controls.lobby.button.join);
//Delay(100);
if(!JoinGameAgain)
{
if (Game != SameGame)
{
SetStatusText("ÿc8Joining Game: " + Game);
if (UseCDKeyChangeTrick)
{
NT_SendEventToOOG(D2NT_MGR_CREATE_GAME, location.name, 0);
Delay(1000);
}
ControlData.click(ControlData.controls.lobby.button.join);
Delay (200);
}
else
SetStatusText("ÿc8Waiting for next game...");
}
else
{
SetStatusText("ÿc8Joining Game: " + Game);
if (UseCDKeyChangeTrick)
{
NT_SendEventToOOG(D2NT_MGR_CREATE_GAME, location.name, 0);
Delay(1000);
}
ControlData.click(ControlData.controls.lobby.button.join);
Delay (200);
}
}
}
else
{
DebugInOOG("I can\'t read the chat!");
}
if(Game != "")
SameGame = Game;
break;
case 1: // Lobby
if(location.id == 1 && JoinChatAfterGame)
{
Delay(Random(WaitBeforeEnterChatMin, WaitBeforeEnterChatMax));
ControlData.click(ControlData.controls.lobby.button.enterChat);
break;
}
break;
case 2: // Waiting In Line
if(GetTickCount()-LastGameMade > WaitInLineTimeout)
ControlData.click(ControlData.controls.lobby.inLine.button.cancel);
break;
case 4: // Create Game
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);
break;
}
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 (Game)
{
ControlData.setText( ControlData.controls.lobby.join.editBox.gameName, Game);
Delay (100);
ControlData.setText( ControlData.controls.lobby.join.editBox.password, GamePassword);
Delay (100);
ControlData.click(ControlData.controls.lobby.join.button.joinGame);
RunGC(); // run garbage collector between each game
NT_LocationTimeout(5000, location);
LastGameStatus = 1; // pending join
}
else
{
DebugInOOG("No game to join : cancelling");
me.Cancel(1);
Delay(1000);
}
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, "yE00000Game already exists", 0);
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;
default:
DebugInOOG("Unhandled location : "+location.id);
break;
}
//DebugInOOG("Location : "+location.id);
}
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()
{
if(InGameAt)
{
duration = GetTickCount() - InGameAt;
InGameAt = (duration < GameMinLength ? GameMinLength - duration : 0);
}
}
function NT_LocationTimeout(time, location)
{
endtime = GetTickCount() + time;
while(ControlData.getLocation().id == location.id && endtime > GetTickCount())
{
NT_SendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " (" + parseInt((endtime-GetTickCount())/1000) + "s)", 0);
Delay(500);
}
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 getRandomString(_length)
{
_retString = "";
_charSet = "0123456789abcdefghijklmnopqrstuvwxyz";
while(_length--)
{
_retString += _charSet.charAt(Random(0, _charSet.length-1));
Delay(1);
}
return _retString;
}
function DebugInOOG(logString)
{
if (Debug)
return SendCopyData("D2NT Manager", null, 9<<16, "-- Debug : " + logString);
else
return false;
}
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_IsChannelUser()
{
for(var i = 0; i < ChannelUsers.length; i++)
{
if(me.account.toLowerCase() == ChannelUsers[i].toLowerCase() || me.charname.toLowerCase() == ChannelUsers[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(isLeecher)
MaximumLocationLoops = 900;
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_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_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;
}
|
Also ich kann es ehrlich gesagt nicht ganz nachvollziehen, was dort falsch laufen könnte. Die Entry Points sind definitiv richtig?
Quote:
Originally Posted by The_Mog
Hallo,
Bei mir Macht der Bot (der ansonsten einwandfrei läuft) probleme beim Verwenden von key.mpq's . Er benutzt sie sozusagen gar nicht. Habe es mit mehreren verschiedenen versucht. Er benutzt immer die Keys mit denen Dia installiert ist, was zur folge hat, dass ich keine 2 Instanzen von Diablo laufen lassen kann wegen "Der Key wird schon verwendet".
Mir ist aufgefallen, das D2NT nicht meckert, wenn ich absichtlich einen Key.mpq namen angebe, den es gar nicht gibt. Er startet einfach und ohne murren mit den installierten d2 keys.
Ich hoffe ihr könnt mir meinen Fehler zeigen.
Danke ssseeer
|
Eigentlich sollte das ohne weiteres Funktionieren, wenn du MPQs angibst.
Hier mal ein Kontrollbildchen, in etwa so sollte das bei dir auch aussehen:
Quote:
Originally Posted by The_Mog
Kann mir hier wirklich niemand weiterhelfen? Das mag ich fast nicht glauben, da mir dieses Forum sonst als überaus kompetent erscheint.
Ich habe inzwischen noch einmal das Internet durchkämmt, jedoch nichts gefunden, was wirklich meinem Problem entspricht. Ich fand lediglich viele ähnlich geartete Probleme, deren lösungsansätze mir jedoch auch nicht weiterhalfen.
Der Versuch die Problematik zu umgehen, indem ich den gesammten D2 ordner kopiere und dann mit Sandys Key Changer den Key ändere, scheiterte daran, das sich Sandys bei diesem Versuch immer wieder aufhängt.
Ich wäre immer noch dankbar für Lösungsansätze 
|
Das fragst du nach 2 Stunden? 
Es ist eigentlich für Foren durchaus üblich, Tage auf eine passende Antwort zu warten, darum würde ich nicht direkt nach wenigen Stunden ungeduldig werden.
Wie dem auch sei, bitte stell erstmal sicher, dass nach obigen Bild alles soweit passt, ansonsten müssen wir mal witere Möglichkeiten in Erwägung ziehen, wobei mir dazu gerade nichts einfällt.
LG
Muddy
|
|
|
 |
|
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 14:49.
|
|