Register for your free account! | Forgot your password?

You last visited: Today at 06:15

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Release] Muddy's D2NT

Discussion on [Release] Muddy's D2NT within the Diablo 2 Programming forum part of the Diablo 2 category.

Reply
 
Old 06/28/2011, 20:12   #2371
 
elite*gold: 0
Join Date: Mar 2010
Posts: 539
Received Thanks: 418
Bottest du zufällig mit einer Cold/Fire-Sorc ohne Infinity?
TheCrazy11 is offline  
Thanks
1 User
Old 06/28/2011, 20:14   #2372
 
Amaru1338's Avatar
 
elite*gold: 11
Join Date: Oct 2009
Posts: 809
Received Thanks: 167
***, Fire/orb sorc ohne infinity... Aber woran liegt das dann? Er macht es nur bei der Gräfin. Kann ich das fixen? ich brauch die low runen =)
Amaru1338 is offline  
Old 06/28/2011, 20:21   #2373
 
elite*gold: 0
Join Date: Mar 2010
Posts: 539
Received Thanks: 418
Hier ist der Beitarg von Muddy, wie er es gelöst hat:


Ich habe es auch so gelöst, klappt ganz gut.
TheCrazy11 is offline  
Thanks
1 User
Old 06/28/2011, 20:32   #2374
 
elite*gold: 16
Join Date: Apr 2009
Posts: 40
Received Thanks: 1
hi,
ich will mit meinem hammerdin nun baalruns machen...wie bekomme ich es hin das er in meinem channel das nächste gaem ansagt? Bzw das er im aktuellen game sagt...Ng will be ***-01,02 etc?
mindplay is offline  
Old 06/28/2011, 20:41   #2375
 
Amaru1338's Avatar
 
elite*gold: 11
Join Date: Oct 2009
Posts: 809
Received Thanks: 167
Das kannst du in der NTBot.ntj einstellen
Amaru1338 is offline  
Old 06/28/2011, 22:39   #2376
 
elite*gold: 16
Join Date: Apr 2009
Posts: 40
Received Thanks: 1
und wie heißen die Befehle dazu? xD
mindplay is offline  
Old 06/28/2011, 22:47   #2377
 
elite*gold: 0
Join Date: May 2010
Posts: 212
Received Thanks: 40
Code:
// 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//%password in about %time seconds";			// Leave blank not to post a channel announcement
fred9x9 is offline  
Old 06/28/2011, 23:28   #2378
 
elite*gold: 160
Join Date: Apr 2011
Posts: 77
Received Thanks: 18
Eigentlich habe ich alles gemacht, wie unten beschrieben
Quote:
Originally Posted by GruenerApfel View Post
ah okay danke , dann gleich nochmal richtig...

also der entrypoint wäre:

Code:
//###################################################################
//###########################Einstellungen###########################
//###################################################################
	
var leaderAccountName          = "";
var leaderName                 = "";
var gamepassword               = "";
var JoinGameAgain              = false; // wenn der Bot nach chicken oder disconnect ins selbe Spiel nochmal gehen soll, auf true stellen

var UseCDKeyChangeTrick        = false; // Wenn der LeechBot mehrere CD Keys nutzen soll, dann auf true stellen.

var joinRandomChannel          = false;
var joinChannelInChat          = "";
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              = 180000;

// 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;

// Only for JoinBot (friend list delay, milliseconds)
var LeaderOfflineDelay         = 30000;
var LeaderInChatDelay          = 10000;
var GameIsFullDelay            = 30000;

//###################################################################
//###################################################################
//###############DO NOT CHANGE ANYTHING BELOW THIS###################
//###################################################################
//###################################################################

//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 chatActionsDone   = false;
var lastGameFailed     = false;
var sayChatMsgAfterGame = false;

Include("libs/controlInfo.ntl");

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()
{
    Delay(1000);

    var _ingame = false;

    controlData.clickDelay = clickDelay;
    controlData.textDelay = textDelay;
    controlData.clickDelayRandom = clickDelayRandom;
    controlData.textDelayRandom = textDelayRandom;

    while(1)
    {
        if(me.ingame)
        {
            _gamename = me.gamename;
            _gamepassword = me.gamepassword;

            if(!inGameAt)
                inGameAt = GetTickCount();

            if(!_ingame)
            {
                RunGC(); // run garbage collector between each game

                if(Load("NTBot/MWBotGame.ntj"))
                {
                    _ingame = true;

                    if(me.playtype > 0)
                        sendEventToOOG(D2NT_MGR_INGAME, "In Game[IP:" + me.gameserverip.split(".")[3] + "]", 0);
                    else
                        sendEventToOOG(D2NT_MGR_INGAME, "In Game", 0);

                    lastGameStatus = 2; // in game successful

                    // To exit game as soon as the leader quits
                    //Load("NTBot/NTCheckLeader.ntj");
                    // to party only the leader
                    //Load("NTBot/tools/NTTools_AutoPartyJoinFriendGames.ntj");
                }
            }

            Delay(1000);
        }
        else
        {
            if(_ingame)
            {
                _ingame = false;
                sayChatMsgAfterGame = true;

                sendEventToOOG(D2NT_MGR_READY, "", 0);
            }

            locationAction(controlData.getLocation());

            Delay(500);
        }
    }
}

function locationAction(location)
{
    switch(location.id)
    {
    case 3: // Lobby Chat
        sendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);

        if(!chatActionsDone)
        {  
            Delay(Random(waitInChatBeforeActionsMin, waitInChatBeforeActionsMax));

            if(joinRandomChannel || joinChannelInChat != "")
            {
                Say("/join " + (joinRandomChannel ? getRandomString(Random(3,10)) : joinChannelInChat));
                Delay(1000);
            }

            if(firstJoinMessage)
            {
                Say(firstJoinMessage);
                Delay(200);
            }

            chatActionsDone = true;
        }

        if (chatMessageAfterGame && _gamename != "" && sayChatMsgAfterGame == true)
        {
            Say(chatMessageAfterGame);
            sayChatMsgAfterGame = false;
            Delay(200);
        }

        game = '';

        var _tick = GetTickCount();
        if ((_leaderOfflineTick < 0 || (_leaderOfflineTick + LeaderOfflineDelay) < _tick)
         && (_leaderInChatTick < 0 || (_leaderInChatTick + LeaderInChatDelay) < _tick)
         && (_GameIsFullTick < 0 || (_GameIsFullTick + GameIsFullDelay) < _tick))
        {
            DebugInOOG('Locating the leader : '+leaderAccountName);
            Say('/f l');
            Delay(1500);
        }

        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++;
                }
                if (msg.lastIndexOf(leaderName) >= 0)
                    DebugInOOG("yc8found him :;"+msg);

                // checking if the msg is a friendly whisper
                if (msg.lastIndexOf(leaderName + ' (*' +leaderAccountName+')') > -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.lastIndexOf(': '+leaderAccountName+',') > -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)
                        && (_leaderOfflineTick < 0 || (_leaderOfflineTick + LeaderOfflineDelay) < _tick))
                    {
                        DebugInOOG('Leader is offline, delay '+Math.round(LeaderOfflineDelay/1000)+' sec for next /f l.');
                        _leaderOfflineTick = GetTickCount();
                    }
                    else if (msg.match(regInChat)
                            && (_leaderInChatTick < 0 || (_leaderInChatTick + LeaderInChatDelay) < _tick))
                    {
                        DebugInOOG('Leader is in the chat "'+msg.replace(regInChat, "$2")+'", delay '+Math.round(LeaderInChatDelay/1000)+' sec for next /f l.');
                        _leaderInChatTick = GetTickCount();
                    }
                    else if (msg.match(regGameName)
                            && ((_leaderOfflineTick < 0 || (_leaderOfflineTick + LeaderOfflineDelay) < _tick)
                                && (_leaderInChatTick < 0 || (_leaderInChatTick + LeaderInChatDelay) < _tick)))
                    {
                        game = msg.replace(regGameName, "$2");
                    }
                    else if ((_leaderInChatTick < 0 || (_leaderInChatTick + LeaderInChatDelay) < _tick)
                            && (_leaderOfflineTick < 0 || (_leaderOfflineTick + LeaderOfflineDelay) < _tick))
                    {
                        // unhandled line, supposelly "In Realm"
                        DebugInOOG('The leader was in the the lobby but not in chat, delay '+Math.round(LeaderInChatDelay/1000)+' sec for next /f l.');
                        _leaderInChatTick = GetTickCount();
                    }

                    break;
                }
            }

            if (found_leader == false)
                DebugInOOG('I couldn\'t find the leader in my friend list!');

            if (game!="")
            {
                DebugInOOG('Leader is in the game "' + game + '"');
                //controlData.click(controlData.controls.lobby.button.join);
                //Delay(100);
								if(!JoinGameAgain)
								{
									if (game != samegame)
									{
									  if (UseCDKeyChangeTrick)
										{
											// increasing the number of runs in the OOG (for CDKey switch)
											// Problem : the gamename/gamepassword set in your OOG will be typed in the lobbyChat
											// this may output a red message in the lobby chat if you have a password set (not a real problem)
											// I recommend to set a gamename like "Run" and no gamepassword in your OOG. -> this will output "Run-01", "Run-02", etc in lobby chat before joining games
											sendEventToOOG(D2NT_MGR_CREATE_GAME, location.name, 0);
											Delay(1000);
										}

										controlData.click(controlData.controls.lobby.button.join);
										Delay (200);
										
									}
									else
										Delay(30000);
								}
								else
								{
								  if (UseCDKeyChangeTrick)
									{
										// increasing the number of runs in the OOG (for CDKey switch)
										// Problem : the gamename/gamepassword set in your OOG will be typed in the lobbyChat
										// this may output a red message in the lobby chat if you have a password set (not a real problem)
										// I recommend to set a gamename like "Run" and no gamepassword in your OOG. -> this will output "Run-01", "Run-02", etc in lobby chat before joining games
										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!');
            //DebugInOOG('You probably haven\'t added the lobby chat controlinfo coordinates!');
            Delay(30000);
        }
        
        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;
        }

        sendEventToOOG(D2NT_MGR_CREATE_GAME, location.name, 0);

        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
        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)
        {
            outputGameLength();
            controlData.click(controlData.gameTypes[me.playtype]);
        }
        else
            controlData.click(controlData.controls.mainMenu.button.gateway);
        break;

    case 9: // Login
        sendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name, 0);
        Delay(loginDelay);

        controlData.setText(controlData.controls.login.editBox.accountName, me.account);

        sendEventToOOG(D2NT_MGR_LOGIN, location.name, 0);

        locationTimeout(5000, location);
        break;

    case 10: // Login Error (this is a fatal error, so stop)
        sendEventToOOG(D2NT_MGR_RESTART, location.name, 10);
        Delay(3500);
        break;

    case 11: // Unable To Connect
        timeoutDelay(unableToConnectRetry*60*1000, location)
        controlData.click(controlData.controls.login.unableToConnect.button.ok);
        break;

    case 12: // Character Select
        var _time, _control;

        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;
            setNextGameMake();
        }
        else
        {
            controlData.click(controlData.controls.characterSelect.button.exit);
            timeoutDelay(realmDownRetry*60*1000, location);
        }
        break;

    case 13: // Realm Down - Character Select screen
        controlData.click(controlData.controls.characterSelect.button.exit);
        timeoutDelay(realmDownRetry*60*1000, location);
        break;

    case 14: // Character Select - Disconnected
        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(!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
        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(!locationTimeout(connectingToBnetTimeout, location))
            controlData.click(controlData.controls.mainMenu.connecting.button.cancel);
        break;

    case 22: // Login - Invalid Cdkey (classic or xpac)
        sendEventToOOG(D2NT_MGR_RESTART, location.name, 3600);
        Delay(3500);
        break;    

    case 23: // Character Select - Connecting
        if(!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(!locationTimeout(pleaseWaitTimeout, location))
            controlData.click(controlData.controls.lobby.pleaseWait.button.cancel);
        break;

    case 26: // Lobby - Game Name Exists
        sendEventToOOG(D2NT_MGR_PRINT_LOG, "yE00000Game already exists", 0);

        inGameAt = 0;
        lastGameStatus = 0;
        setNextGameMake();

        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;
        setNextGameMake();

        locationTimeout(gameDoesNotExistTimeout, location);
        break;
    default:
        DebugInOOG("Unhandled location : "+location.id);
        break;
    }
    DebugInOOG("Location : "+location.id);
}

function sendEventToOOG(locationId, statusString, pendingTime)
{
    return SendCopyData("D2NT Manager", null, (locationId<<16)|pendingTime, statusString);
}

function setNextGameMake()
{
    lastGameMade = GetTickCount();
    nextGameMake = lastGameMade + createGameThreshold + Random(0-createGameThresholdRandom, createGameThresholdRandom) + inGameAt;
    inGameAt = 0;
    chatActionsDone = false;
}

function outputGameLength()
{
    if(inGameAt)
    {
        duration = GetTickCount() - inGameAt;

        inGameAt = (duration < gameMinLength ? gameMinLength - duration : 0);
    }
}

function locationTimeout(time, location)
{
    endtime = GetTickCount() + time;

    while(controlData.getLocation().id == location.id && endtime > GetTickCount())
    {
        sendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " (" + parseInt((endtime-GetTickCount())/1000) + "s)", 0);
        Delay(500);
    }

    return (controlData.getLocation().id != location.id);
}

function timeoutDelay(time, location)
{
    endtime = GetTickCount() + time;

    while(endtime > GetTickCount())
    {
        sendEventToOOG(D2NT_MGR_PRINT_STATUS, location.name + " (" + parseInt((endtime-GetTickCount())/1000) + "s)", 0);
        Delay(1000);
    }
}

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;
}
das baalleechscript

Code:
function NTMain()
{
	Include("libs/common/NTCommon.ntl");
	NTC_IncludeLibs();
	NTC_IncludeConfig("NTBot/char_configs");
	
	NT_LoadConfig();
	NTSI_LoadNIPFiles("NTBot/item_configs");

	NTA_Initialize();

	RegisterEvent(EVENT_GAMEMSG, NT_GameMsgEvents);

	if(!NTTM_CheckAct())
	{
		NTC_SendMsgToScript("MWBotGame.ntj", "NTTM_CheckAct()");
		return;
	}

	if(me.areaid != 109)
	{
		if(!NTTM_TownMove("waypoint"))
		{
			NTC_SendMsgToScript("MWBotGame.ntj", "NTTM_TownMove()");
			return;
		}

		if(!NTM_TakeWaypoint(109))
		{
			NTC_SendMsgToScript("MWBotGame.ntj", "NTM_TakeWaypoint()");
			return;
		}
	}

	NTTMGR_TownManager();

	NTTM_TownMove("portalspot");

	for(i = 0; i <= 200; i++)
	{
		if(NTC_InMyParty(NTConfig_Leader))
			break;

		Delay(200);
	}   

	while(me.areaid == 109 && NTC_InMyParty(NTConfig_Leader))
	{
		if(NTConfig_LeechTPMsg == "")
			NTM_UsePortal("BluePortal", 131, NTConfig_Leader); // 50

		Delay(2000);
	}
	
	NTM_MoveTo(me.areaid, 15118, 5002);
	NTP_DoPrecast(true);

	while(NTC_InMyParty(NTConfig_Leader) && NTC_FindUnit(NTC_UNIT_MONSTER, 543))
		Delay(500);

	var _portal = NTC_FindUnit(NTC_UNIT_OBJECT, 563, 2);

	if(!_portal)
	{
		NTC_SendMsgToScript("MWBotGame.ntj", "NTC_FindUnit()");
			return;
	}
	
	NTM_MoveTo(me.areaid, 15095, 5028);
	NTM_MoveTo(me.areaid, 15092, 5010);
		
	if(!NTM_UsePortal("Portal", 132, null, _portal))
	{
		NTC_SendMsgToScript("MWBotGame.ntj", "NTM_UsePortal()");
		return;
	}

	var _baal = NTC_FindUnit(NTC_UNIT_MONSTER, 544);

	while(NTC_InMyParty(NTConfig_Leader) && NTA_IsValidMonster(_baal))
		Delay(2500);

	Delay(2000);

	NTC_SendMsgToScript("MWBotGame.ntj", "SCRIPT_END");
}

function NT_GameMsgEvents(msg, type)
{
	if(type == 0 && msg.indexOf(NTConfig_Leader) != -1 && msg.indexOf(NTConfig_LeechTPMsg) != -1 && NTConfig_LeechTPMsg != "")
	{
		while(me.areaid == 109)
		{
			NTM_UsePortal("BluePortal", 131, NTConfig_Leader);	
		}
	}
}
das baalleechfightscript

Code:
function NTMain()
{
   
   Include("libs/common/NTCommon.ntl");
   NTC_IncludeLibs();
   NTC_IncludeConfig("NTBot/char_configs");

   NT_LoadConfig();
   NTSI_LoadNIPFiles("NTBot/item_configs");

   NTA_Initialize(); 
   
   RegisterEvent(EVENT_GAMEMSG, NT_GameMsgEvents);

   if(!NTTM_CheckAct())
   {
      NTC_SendMsgToScript("MWBotGame.ntj", "NTTM_CheckAct()");
      return;
   }

   if(me.areaid != 109)
   {
   if(!NTTM_TownMove("waypoint"))
   {
      NTC_SendMsgToScript("MWBotGame.ntj", "NTTM_TownMove()");
      return;
   }

   if(!NTM_TakeWaypoint(109))
   {
      NTC_SendMsgToScript("MWBotGame.ntj", "NTM_TakeWaypoint()");
      return;
   }
   }
       
   NTTMGR_TownManager();

if(NTConfig_precast)
{
   NTM_TakeWaypoint(129)
   NTP_DoPrecast(true);
   Delay(500)
   NTM_TakeWaypoint(109)
}   

   
   NTTM_TownMove("portalspot");

   for(i = 0; i <= 100; i++)
   {
      if(NTC_InMyParty(NTConfig_Leader))
         break;

      Delay(200);
   }

   while(me.areaid == 109 && NTC_InMyParty(NTConfig_Leader))
   {
			if(NTConfig_CoLeechTPMsg == "")
				NTM_UsePortal("BluePortal", 131, NTConfig_Leader); // 50
      Delay(1000);
       
   }
if(!NTConfig_precast)
	NTM_MakeTP();
	NTP_DoPrecast(true);
	NTA_ClearPosition(20, true, 2);
if(NTConfig_precast)
	NTA_ClearPosition(20, true, 2);
	NTM_MakeTP();


   while(NTC_InMyParty(NTConfig_Leader))
   {
   
   NT_ClearThroneInt();

   while(1)
   {
      if(me.classid == NTC_CHAR_CLASS_PALADIN || me.classid == NTC_CHAR_CLASS_BARBARIAN)
         NTM_MoveTo(me.areaid, 15092, 5028);
      else
         NTM_MoveTo(me.areaid, 15089, 5010);

      if(me.GetState(2))
         NTC_PutSkill(109, NTC_HAND_RIGHT);

      for(i = 0 ; i < 6 ; i++)
      {
         _wave = NT_ThroneCheckInt();
         if(_wave > 0)
            break;

         NTC_Delay(500);
      }

      _starttick = GetTickCount();

      while(_wave == 0)
      {
         if(!NT_ThronePreAttackInt())
            NTC_Delay(200);

         if(GetTickCount()-_starttick > 15000)
         {
            NT_ClearThroneInt();

            _starttick = GetTickCount();
         }

         _wave = NT_ThroneCheckInt();
      }

      switch(_wave)
      {
      case 1: 
         NTA_ClearPosition(40, true, 2); 
         NTP_DoPrecast(true); 
         break; 
      case 2: 
         NTM_MoveTo(me.areaid, me.x, me.y-1); 
         NTA_ClearPosition(40, true); 
         NTTMGR_CheckSafe(NTConfig_CheckSelfSafe, NTConfig_CheckMercSafe); 
         break; 
      case 3: 
         NTM_MoveTo(me.areaid, me.x, me.y-1); 
         NTA_ClearPosition(40, true, 2); 
         NTSI_PickItems();
         NT_CheckHydraInt(); 
         break; 
      case 4: 
         NTM_MoveTo(me.areaid, me.x, me.y-1); 
         NTA_ClearPosition(40, true, 2); 
         break; 
      case 5: 
         NTM_MoveTo(me.areaid, me.x, me.y-1); 
         NTA_ClearPosition(40, true, 2); 
         break;
      default:
         NTA_ClearPosition(40, true, 1);
         break;
      }

      if(_wave == 5)
         break;
   }

   if(NTConfig_KillBaal)
   {
      var _portal;

      if(!NTTMGR_CheckSafe(NTConfig_CheckSelfSafe, NTConfig_CheckMercSafe))
      {
         NTC_SendMsgToScript("MWBotGame.ntj", "NTTMGR_CheckSafe()");
         return;
      }

      NTM_MoveTo(me.areaid, 15092, 5010);

      NTP_DoPrecast(true);

      while(NTC_FindUnit(NTC_UNIT_MONSTER, 543))
         NTC_Delay(500);

      _portal = NTC_FindUnit(NTC_UNIT_OBJECT, 563, 1);

      if(!_portal)
      {
         NTC_SendMsgToScript("MWBotGame.ntj", "NTC_FindUnit()");
         return;
      }

      if(!NTM_UsePortal("Portal", 132, null, _portal))
      {
         NTC_SendMsgToScript("MWBotGame.ntj", "NTM_UsePortal()");
         return;
      }

      NTM_MoveTo(me.areaid, 15138, 5916);
			NTA_Initialize()
			
      if(!NTA_KillMonster(544))
      {
         NTC_SendMsgToScript("MWBotGame.ntj", "NTA_KillMonster()");
         return;
      }

      NTSI_PickItems();
   }

   }

   NTC_SendMsgToScript("MWBotGame.ntj", "SCRIPT_END");

}


// Internal function
function NT_ClearThroneInt()
{
	var _attackpos = [15112, 5068, 15085, 5065, 15114, 5045, 15114, 5012, 15095, 5024, 15078, 5013, 15092, 5040];

	for(var i = 0 ; i < _attackpos.length ; i += 2)
	{
		NTM_MoveTo(me.areaid, _attackpos[i], _attackpos[i+1]);

		NTA_ClearPosition(30, true, 2);
	}
	NTM_MoveTo(me.areaid, 15093, 5041);
	NTA_ClearPosition(50, true, 2);
}

function NT_ThroneCheckInt()
{
	var _monster;

	if(!NTC_FindUnit(NTC_UNIT_MONSTER, 543))
		return 5;

	_monster = NTC_FindUnit(NTC_UNIT_MONSTER);

	if(_monster)
	{
		do
		{
			if(NTA_IsValidMonster(_monster))
			{
				if(_monster.classid == 23 || _monster.classid == 62)
					return 1;

				if(_monster.classid == 105 || _monster.classid == 381)
					return 2;

				if(_monster.classid == 557)
					return 3;

				if(_monster.classid == 558)
					return 4;

				if(_monster.classid == 571)
					return 5;
			}
		} while(_monster.GetNext());
	}

	return 0;
}

function NT_ThronePreAttackInt()
{
	if(me.classid == NTC_CHAR_CLASS_SORCERESS)
	{
		if(NTConfig_AttackSkill[3] == 56 || NTConfig_AttackSkill[3] == 59)
			return NTC_CastSkill(NTConfig_AttackSkill[3], 0, 15092, 5028);
	}
	else if(me.classid == NTC_CHAR_CLASS_PALADIN)
	{
		if(NTConfig_AttackSkill[3] == 112)
		{
			if(NTConfig_AttackSkill[4] > 0)
				NTC_PutSkill(NTConfig_AttackSkill[4], NTC_HAND_RIGHT);

			return NTC_CastSkill(NTConfig_AttackSkill[3], 2);
		}
	}
	return false;
}

function NT_CheckHydraInt()
{
	var _hydra1, _hydra2, _hydra3;

	_hydra1 = NTC_FindUnit(NTC_UNIT_MONSTER, 351);
	_hydra2 = NTC_FindUnit(NTC_UNIT_MONSTER, 352);
	_hydra3 = NTC_FindUnit(NTC_UNIT_MONSTER, 353);

	if((_hydra1 && _hydra1.GetStat(172) != 2 && _hydra1.GetState(105))
		|| (_hydra2 && _hydra2.GetStat(172) != 2 && _hydra2.GetState(105))
		|| (_hydra3 && _hydra3.GetStat(172) != 2 && _hydra3.GetState(105)))
	{
		NTM_MoveTo(me.areaid, 15118, 5002);

		if(me.GetState(2))
			NTC_PutSkill(109, NTC_HAND_RIGHT);

		NTC_PingDelay(5000);
	}
}

function NT_GameMsgEvents(msg, type)
{
	if(type == 0 && msg.indexOf(NTConfig_Leader) != -1 && msg.indexOf(NTConfig_CoLeechTPMsg) != -1 && NTConfig_CoLeechTPMsg != "")
	{
		while(me.areaid == 109)
		{
			NTM_UsePortal("BluePortal", 131, NTConfig_Leader);	
		}
	}
}
das dialeechfightscript
- hier is zu beachten das die leecher syncron zum run mitlaufen müssen, vorher andy killen und dann den run joinen is also net... da sobald die leechfighter net in der nähe der siegel sind wenn diese geöffnet werden sich mehr oder weniger aufhängen(zu ~90%), müsste man bei gelegenheit mal ne bedingung reinschreiben das nach 5 versuchen oder so zum nächsten siegel gegangen wird .... demnächst

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;
	}
	
	if(me.areaid != 103)
	{
		if(!NTTM_TownMove("waypoint"))
		{
			NTC_SendMsgToScript("MWBotGame.ntj", "NTTM_TownMove()");
			return;
		}

		if(!NTM_TakeWaypoint(103))
		{
			NTC_SendMsgToScript("MWBotGame.ntj", "NTM_TakeWaypoint()");
			return;
		}
	}


	NTTMGR_TownManager();

   NTTM_TownMove("portalspot");

   for(i = 0; i <= 100; i++)
   {
      if(NTC_InMyParty(NTConfig_Leader))
         break;

      Delay(200);
   }   

   while(me.areaid == 103 && NTC_InMyParty(NTConfig_Leader))
   {
		if(NT_GetLeader(NTConfig_Leader).areaid >= 129)
		{
			NTC_SendMsgToScript("MWBotGame.ntj", "SCRIPT_END");
			return;
		}
		NTM_UsePortal("BluePortal", 108, NTConfig_Leader); // 50
		Delay(1000);
       
   }
		
		NTP_DoPrecast(true);
		NTA_ClearPosition(10, true);
		NTM_MoveTo(me.areaid, 7792, 5291);
		NTA_ClearPosition(20, true);
		NTM_MoveTo(me.areaid, 7792, 5291);
		NTA_ClearPosition(30, true);

		
		if(!NT_OpenSealsInt())
		{
			NTC_SendMsgToScript("MWBotGame.ntj", "NT_OpenSealsInt()");
			return;
		}
	
		if(NTConfig_PublicMode)
			Say(NTConfig_KillDiaMsg);

		NTM_MoveTo(me.areaid, 7792, 5292);
		NTP_DoPrecast(true);
		NTC_FindUnit(NTC_UNIT_MONSTER, 243, 100);


		NTA_KillMonster(243);
		NTSI_PickItems();
		Say(NTConfig_DiaNxtGame);
		NTC_SendMsgToScript("MWBotGame.ntj", "SCRIPT_END");


// Internal function
function NT_OpenSealsInt()
{
	var i, _unit;
	var _result;

	_unit = GetPresetUnits(me.areaid, NTC_UNIT_OBJECT);

	if(!_unit)
		return false;

	_result = false;

	for(i = 0 ; i < _unit.length ; i++)
	{
		if(_unit[i].id == 396)
		{
			if(_unit[i].roomy*5 + _unit[i].y == 5275)
				_result = NT_OpenVizierSealInt(1);
			else
				_result = NT_OpenVizierSealInt(2);

			break;
		}
	}

	if(!_result)
		return false;
		
	NTA_ClearPosition(30, true, 2);
	NTP_DoPrecast(false);

	_result = false;

	for(i = 0 ; i < _unit.length ; i++)
	{
		if(_unit[i].id == 394)
		{
			if(_unit[i].roomx*5 + _unit[i].x == 7773)
				_result = NT_OpenDeSeisSealInt(1);
			else
				_result = NT_OpenDeSeisSealInt(2);

			break;
		}
	}

	if(!_result)
		return false;

	NTA_ClearPosition(30, true, 2);
	NTP_DoPrecast(true);

	_result = false;

	for(i = 0 ; i < _unit.length ; i++)
	{
		if(_unit[i].id == 392)
		{
			if(_unit[i].roomx*5 + _unit[i].x == 7893)
				_result = NT_OpenVenomSealInt(1);
			else
				_result = NT_OpenVenomSealInt(2);

			break;
		}
	}

	return _result;
}

function NT_OpenVizierSealInt(type)
{

var _monstername = GetLocaleString(2851);
var i, n;

	var i, n;
	var _attackpos = [7740, 5300, 7792, 5291, 7740, 5280, 7720, 5280, 7720, 5300];
	

	for(i = 0 ; i < _attackpos.length ; i += 2)
	{
		NTM_MoveTo(me.areaid, _attackpos[i], _attackpos[i+1]);

		NTA_ClearPosition(25, true, 2);
	}
	
	NTM_MoveTo(me.areaid, 7735, 5291);
	NTA_ClearPosition(40, true, 2);

	for(i = 0 ; i < 3 ; i++)
	{
		if(type == 1)
		{
			NTM_MoveTo(me.areaid, 7695, 5293);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7664, 5314);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7673, 5293);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7662, 5276);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7676, 5294);
			NTA_ClearPosition(60, true, 2);	
			
			if(me.classid == NTC_CHAR_CLASS_PALADIN)
				NTM_MoveTo(me.areaid, 7678, 5292);
		}
		else
		{
			NTM_MoveTo(me.areaid, 7695, 5316);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7664, 5314);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7654, 5281);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7695, 5316);
			NTA_ClearPosition(60, true, 2);
			
			if(me.classid == NTC_CHAR_CLASS_PALADIN)
				NTM_MoveTo(me.areaid, 7676, 5320);
		}

		for(n = 0 ; n < 10 ; n++)
		{
			NTC_Delay(200);

			if(NTA_KillMonster(_monstername))
			{
				NTA_ClearPosition(40);
				NTSI_PickItems();

				return NTM_MoveTo(me.areaid, 7792, 5291);
			}
		}
	}
	return false;
}

function NT_OpenDeSeisSealInt(type)
{
	var i, n;
	var _monstername = GetLocaleString(2852);

	var _attackpos = [7780, 5255, 7800, 5255, 7800, 5235, 7780, 5235, 7774, 5214];
	var _monstername = GetLocaleString(2852);

	for(i = 0 ; i < _attackpos.length ; i += 2)
	{
		NTM_MoveTo(me.areaid, _attackpos[i], _attackpos[i+1]);

		NTA_ClearPosition(25, true, 2);
	}
	
	NTM_MoveTo(me.areaid, 7790, 5244);
	NTA_ClearPosition(40, true, 2);


	for(i = 0 ; i < 3 ; i++)
	{
		if(type == 1)
		{
			NTM_MoveTo(me.areaid, 7773, 5194);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7813, 5188);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7809, 5155);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7777, 5155);
			NTA_ClearPosition(60, true, 2);			
			
			if(me.classid == NTC_CHAR_CLASS_PALADIN)
				NTM_MoveTo(me.areaid, 7768, 5206);
			else
				NTM_MoveTo(me.areaid, 7774, 5220);
		}
		else
		{
			NTM_MoveTo(me.areaid, 7810, 5202);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7774, 5180);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7785, 5153);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7809, 5154);
			NTA_ClearPosition(60, true, 2);			
			
			if(me.classid == NTC_CHAR_CLASS_PALADIN)
				NTM_MoveTo(me.areaid, 7773, 5178);
			else
				NTM_MoveTo(me.areaid, 7788, 5192);
		}

		for(n = 0 ; n < 10 ; n++)
		{
			NTC_Delay(200);

			if(NTA_KillMonster(_monstername))
			{
				NTA_ClearPosition(40);
				NTSI_PickItems();

		NTP_DoPrecast(false);
		return NTM_MoveTo(me.areaid, 7792, 5291);
			}
		}
	}
	return false;
}

function NT_OpenVenomSealInt(type)
{
	var i, n;
	var _monstername = GetLocaleString(2853);

	var _attackpos = [7835, 5280, 7835, 5300, 7855, 5300, 7855, 5280];
	

	for(i = 0 ; i < _attackpos.length ; i += 2)
	{
		NTM_MoveTo(me.areaid, _attackpos[i], _attackpos[i+1]);

		NTA_ClearPosition(25, true, 2);
	}
	
	NTM_MoveTo(me.areaid, 7843, 5292);
	NTA_ClearPosition(40, true, 2);
	
	for(i = 0 ; i < 3 ; i++)
	{
		if(type == 1)
		{
			NTM_MoveTo(me.areaid, 7871, 5293);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7893, 5307);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7912, 5280);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7931, 5293);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7908, 5293);
			NTA_ClearPosition(60, true, 2);
			
			if(me.classid == NTC_CHAR_CLASS_PALADIN)
				NTM_MoveTo(me.areaid, 7892, 5298);
		}
		else
		{
			NTM_MoveTo(me.areaid, 7893, 5274);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7927, 5280);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7930, 5308);
			NTA_ClearPosition(25, true, 2);
			NTM_MoveTo(me.areaid, 7929, 5294);
			NTA_ClearPosition(60, true, 2);
			
			if(me.classid == NTC_CHAR_CLASS_PALADIN)
				NTM_MoveTo(me.areaid, 7927, 5275);
		}

		for(n = 0 ; n < 10 ; n++)
		{
			NTC_Delay(200);

			if(NTA_KillMonster(_monstername))
			{
				NTSI_PickItems();
				NTA_ClearPosition(40, true, 2);
			}


			
			if(NTC_PutSkill(124, NTC_HAND_RIGHT))
				NTC_PingDelay(1000);
		}
		return true;
	}
	return false;
}

function NT_GetLeader(_name)  
{
				_player = GetPlayerUnit();

				if(_player)
				{
					while(_player.GetNext())
					{
					if(_player.name == _name) 
						{ return _player; }
					}
				}
}
}

und dann noch für die charconfig

Code:
NTConfig_Leader = "" // Name vom Leader-Char, Groß- und Kleinschreibung beachten!
MWConfig_Script.push(["name der datei", 5]); 
NTConfig_KillBaal = true; NTConfig_precast = true;
NTConfig_CoLeechTPMsg = ""; // Bei dieser Message vom Leader geht der Bot ins TP. Wenn er jederzeit rein gehen soll, leer lassen.
NTConfig_KillDiaMsg = "Dia" ; NTConfig_DiaNxtGame = "Ng" ;
sry nochmal für die unannehmlichkeiten letzte nacht, war schon spät
jetzt sollte es aber, sofern richtig eingebunden, funzen
Aber ich bekomme immer diesen Fehler, wenn ich den Entrypoint auswähle und der Bot startet:
Jemand 'ne Idee, woran das liegen könnte?
Zeile 812 sieht bei mir so aus:
Code:
control = this.get( ControlData.controls.mainMenu.button.gateway );

MfG
DjCybo is offline  
Old 06/29/2011, 00:27   #2379
 
elite*gold: 0
Join Date: Apr 2008
Posts: 4
Received Thanks: 0
super Script Muddy bist der beste
Noreia is offline  
Old 06/29/2011, 00:47   #2380
 
elite*gold: 0
Join Date: Mar 2010
Posts: 539
Received Thanks: 418
Quote:
Originally Posted by DjCybo View Post
Eigentlich habe ich alles gemacht, wie unten beschriebenAber ich bekomme immer diesen Fehler, wenn ich den Entrypoint auswähle und der Bot startet:
Jemand 'ne Idee, woran das liegen könnte?
Zeile 812 sieht bei mir so aus:
Code:
control = this.get( ControlData.controls.mainMenu.button.gateway );

MfG
Die Schreibweise von ControlData muss immer einheitlich sein, nicht mal ControlData und dann wieder alles klein geschrieben als controldata.

Am besten einfach auf "Ersetzen" (Kürzel ist meist STRG+H) gehen, controldata eingeben, ersetzen durch ControlData und dann auf "Alles ersetzen".
TheCrazy11 is offline  
Thanks
2 Users
Old 06/29/2011, 02:59   #2381
 
tyrael_pl's Avatar
 
elite*gold: 0
Join Date: Jun 2011
Posts: 28
Received Thanks: 15
Can someone please tell me how to make status bars width higher?

i managed to add colorful ping depending on its value and current server ip, basically its just modified display ping option
however the status bar's size seems to be of nearly constant value so to display all the info is impossible.
can i use the extra 1/3 of the bar's width?? how?
tyrael_pl is offline  
Old 06/29/2011, 10:08   #2382
Administrator
 
Muddy Waters's Avatar
 
elite*gold: 41364
Join Date: Jan 2010
Posts: 22,727
Received Thanks: 12,652
Quote:
Originally Posted by tyrael_pl View Post
Can someone please tell me how to make status bars width higher?

i managed to add colorful ping depending on its value and current server ip, basically its just modified display ping option
however the status bar's size seems to be of nearly constant value so to display all the info is impossible.
can i use the extra 1/3 of the bar's width?? how?
Not a chance, the maximum length of a string to be displayed in status text bar is 39 characters. As this is determined in the D2NT Core, there is nothing to be done to change that.

Kind Regards
Muddy
Muddy Waters is offline  
Thanks
1 User
Old 06/29/2011, 10:16   #2383
 
Naruto™'s Avatar
 
elite*gold: 0
Join Date: Oct 2009
Posts: 300
Received Thanks: 24
Danke, gutgelungen
Naruto™ is offline  
Old 06/29/2011, 19:28   #2384
 
tyrael_pl's Avatar
 
elite*gold: 0
Join Date: Jun 2011
Posts: 28
Received Thanks: 15
Exclamation

Quote:
Originally Posted by Muddy_Waters View Post
Not a chance, the maximum length of a string to be displayed in status text bar is 39 characters. As this is determined in the D2NT Core, there is nothing to be done to change that.

Kind Regards
Muddy
oh... not much can be done in that case, thx for reply

can you please review this part of MWBotGame.ntj and possibly optimize parts i changed?
Code:
function MW_SetStatusText()
{
	var _seconds, _minutes, _script, _timeString, _textString, _color, _colorp;
	
	if(!_MWBG_ShowStatusText)
		return;
	
	_script = NTC_FindScript(MWConfig_Script[_MWBG_CurScriptIndex][0]);
	_seconds = MW_GetScriptRuntimeSeconds();
	_minutes = MW_GetScriptRuntimeMinutes();
	_timeString = "";
		
	if(_script && _script.running)
	{
		_textString = "ÿc2Running ÿc4" + MWConfig_Script[_MWBG_CurScriptIndex][0];
		
		if(_minutes == 0 && _seconds <= 5)	
		{
			if(_seconds % 2 == 1)
				_color = "ÿc8";
			else
				_color = "ÿc4";

			if(isNaN(MWConfig_Script[_MWBG_CurScriptIndex][1]) || MWConfig_Script[_MWBG_CurScriptIndex][1] <= 0)
				_timeString = _color + " [+Inf]";
			else
			{
				_timeString = _color + " [";
				
				if(MWConfig_Script[_MWBG_CurScriptIndex][1] < 10)
					_timeString += "0";
				
				_timeString += MWConfig_Script[_MWBG_CurScriptIndex][1] + ":00]";
			}
		}
		else
		{
			if(MWConfig_Script[_MWBG_CurScriptIndex][1] != 0)
			{
				if(_minutes >= MWConfig_Script[_MWBG_CurScriptIndex][1] || _minutes >= MWConfig_Script[_MWBG_CurScriptIndex][1] - 1 && _seconds >= 50)
					_timeString = "ÿc1";
				else if(_minutes >= MWConfig_Script[_MWBG_CurScriptIndex][1] - 1)
					_timeString = "ÿc8";
			}
			_timeString += " [" + MWC_ConvertTicksToTimeString(GetTickCount() - _MWBG_CurScriptStartTick) + "]"
			
				{
					if(me.ping <= 99)
					_colorp = "ÿc4";
						if(me.ping >= 100 && me.ping <= 149)
						_colorp = "ÿc9 ";
							if(me.ping >= 150 && me.ping <= 199)
							_colorp = "ÿc8";
								if(me.ping >= 200)
								_colorp = "ÿc1";

				}
			if(_MWBG_ShowCurrentPing)
				_timeString = _colorp + " (" +  me.ping + ")" + " ÿc9[ip:" +  me.gameserverip.split(".")[3] + "]ÿc4" + _timeString;
		}
	}
	else
	{
		_textString = "ÿc1Stopped ÿc4" + MWConfig_Script[_MWBG_CurScriptIndex][0];
		
		if(_MWBG_ShowCurrentPing)
			_timeString = _colorp + " (" +  me.ping + ")";
	}
		
	MWC_SetStatusText(_textString, _timeString);
}
also is this the only and good part to edit wait time after soj is sold?
Code:
			if(!_MWBG_WorldEventData.Loop.Running)
			{
				_MWBG_WorldEventData.Loop.Runtime = _MWBG_WorldEventData.Count.Message*20*60E3;
				_MWBG_WorldEventData.Loop.Mode = 1;
			}
			else if(_MWBG_WorldEventData.Loop.Mode == 1)
				_MWBG_WorldEventData.Loop.Runtime = _MWBG_WorldEventData.Count.Message*10*60E3;
if not plz point me to the part where this 10min after 1st soj sold can be changed (and +5min after next as well).
did read my previous post?
tyrael_pl is offline  
Old 06/29/2011, 21:40   #2385
 
elite*gold: 0
Join Date: Apr 2008
Posts: 4
Received Thanks: 0
Hey Muddi da zuviele Köche den Brei verderben frag ich dich nun einfach selber direkt. Wenn ich ne FB / FO / Metero Sorc laufen lasse und Baal / Diaruns machen will welches Gear sollte ich anstreben im Inventar. Denn gesucht hab ich jetzt schon einige Stunden aber jeder sagtw as andres. Ich habe schon so viel wertvolles Zeug vertradet um an einige szu kommen was sich dann als Sch... entpuppt hat.

Wär nett wenn du mir nen kleinen Tipp dazu geben kannst, weil ich mag nicht mehr so viel sterben , bzw nur Lowruns laufen

Anderes Prob ist. Seit ich dien Bot benutze find ich kaum noch was, was eventuell auch an der extremen MF Verlust meiner Sorc liegt. Hab das beste MF Gear zusammen gehabt aber damit nichts down bekommen, darum jetzt auf Schaden gechanged. Jetzt laufe ich Lowruns ohne MF, ändert sich das sobald ich auf Baaldia umsteig, oder soll ich lieber wieder ne MF Sorc machen und Lowruns durchziehn?

Weitere Frage ist wegen der Gräfin hab dazu den Beitrag gefunden in dem gsagt wird wie du das löst. Da seh ich aber dass du andre Angriffsskills nutzt. Hast du nun eine FB / FO Meteor skillung oder nutzt du nun doch eine andre. Ich würd den Bot gern als Sorc so nutzen wie du sonst bringt mir das leider nix. Und kann ich die Files von der Gräfin einfach so überschreiben wie du sie gemacht hast um den Fehler zu beheben auch wenn ich eine andre Skillung nutze?

Hoffe du hast Zeit zu antworten würd mi freuen,
Noreia is offline  
Reply


Similar Threads 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 06:16.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.