Hab das erst grad jetzt gelesen...Quote:
und dann noch ne eine: ist es möglich direkt in den bot scripten zu definieren mit welchem skill das angegebene target bearbeitet wird ohne die ntattack.ntl zu editieren?
Ich nehm an du meinst, dass beispielsweise Eldricht mit Nova gekillt wird, aber Mephi mit Blizzard?
Das könntest du per "Workaround" in die Scriptfiles kriegen, indem du da einfach die Attackconfig aus der Charconfig nochmal rein nimmst, also:
Code:
//------------------------------------------------------------------------------
// Attack Configuration
//------------------------------------------------------------------------------
NTConfig_AttackSkill[0] = 0; // First skill. Set to 0 if you won't
NTConfig_AttackSkill[1] = 59; // Primary skill to boss.
NTConfig_AttackSkill[2] = 55; // Primary untimed skill to boss. Set to 0 if you won't
NTConfig_AttackSkill[3] = 59; // Primary skill to others.
NTConfig_AttackSkill[4] = 55; // Primary untimed skill to others. Set to 0 if you won't
NTConfig_AttackSkill[5] = 48; // Secondary skill in case monster is immune to primary skill. Set to 0 if you won't
NTConfig_AttackSkill[6] = 48; // Secondary untimed skill. Set to 0 if you won't
NTConfig_AttackSkill[7] = 0; // Alternative untimed skill which is used if the target is immune to your untimed skill - mostly useful for FB/FO/Meteor sorcs or other sorcs that are using the same untimed Skills
NTConfig_ClearPosition = false; // Set to true if you want to clear area after killing boss.
Und dann kannst du da die Skills für jedes Script neu vertielen. Hoff das hat geholfen.
Btw an alle; Gibt ein XML Log Fix für Muddies. Hier die neue MWItemlogger.ntl
Code:
/** * This file was modified by [Only registered and activated users can see links. Click Here To Register...] * Check the programming section for updates and further scripts * Original Author: agor * Last Update: 09/04/2010 */ Include("libs/common/NTItemAlias.ntl"); function MWI_CheckLog() { var _dateString, _fhandle; _dateString = new Date().toLocaleFormat("%m-%d-%y"); _fhandle = FileOpen("logs/" + me.charname + "/" + _dateString + "_itemlog.xml", 2); if(_fhandle) { // Check if file already exists if(!_fhandle.ReadLine()) { Print("ÿc<Creating New Log File for "+me.charname+": " +_dateString+"_itemlog.xml"); // Creation of the new file _fhandle.WriteLine("<?xml version=\"1.0\" encoding=\"iso-8859-1\"?>"); _fhandle.WriteLine("<?xml-stylesheet href=\"itemlog.xsl\" type=\"text/xsl\"?>"); _fhandle.WriteLine("<itemlog>"); _fhandle.WriteLine("</itemlog>"); } _fhandle.Close(); return true; } return false; } // Writes items to itemlog.xml via E4X // http://developer.mozilla.org/en/Core_JavaScript_1.5_Guide/Processing_XML_with_E4X // item = Item Object // isEthereal = 1 if Item is Ethereal, 0 if not // mode = 0 -> Item Kept // mode = 1 -> Item Sold function MWI_WriteLog(item, isEthereal, mode, logStashed, whereAbouts) { var _fhandle, _filepath, _date, _content, _loops, _itemlog, _itemdesc, _location; var _content2, _content3; if(arguments.length < 4) { logStashed = false; whereAbouts = ""; } if(!item) { MWI_ErrorLog(null, 3); return false; } if(!logStashed && !MWI_CheckLog()) MWI_ErrorLog(item, 2); // Checks if there is already a (unid) item logged matching the current item object if(!logStashed && !(item.itemflag&0x10) && MWI_IsLogged(item)) { MWI_ErrorLog(item, 0); return false; } _date = new Date(); _content = ""; _loops = 0; if(logStashed) { _filepath = "logs/stashlogs/" + me.charname + "_StashedItems.xml"; _fhandle = FileOpen(_filepath, 2); if(_fhandle) { while(!_fhandle.eof) { if(++_loops > 2) // Skips XML header lines because they cause errors when creating the E4X object _content += _fhandle.ReadLine(); else _fhandle.ReadLine(); } _fhandle.Close(); } else { MWI_ErrorLog(item, 1); return false; } // Creation of the E4X Object _itemlog = new XML(_content); } else _filepath = "logs/"+ me.charname + "/Temp_itemlog"; if(item.itemdesc) { // Replaces all colors _itemdesc = item.itemdesc.replace(/ÿc(.)/g, ""); // Replaces new lines with spaces _itemdesc = _itemdesc.replace(/\n/g, '|'); // Skips the first part of the description _itemdesc = _itemdesc.replace((_itemdesc.split("|")[0] + "|"), ""); } else _itemdesc = "undefined"; //Add the last location that was saved if(logStashed) _location = whereAbouts; else _location = MWI_ReadLoc(item); if(logStashed) { // Creation of the file output, headers first and then the itemlog content _itemlog.item += <item id={_date.getTime()} char={me.charname} time={_date.toLocaleFormat("%a %m/%d/%y %H:%M:%S")} quality={item.quality} ethereal={isEthereal} mode={mode} name={(item.name)?item.name.split("\n")[0]:"undefined"} ilvl={item.itemlevel} location={_location} type={item.classid} typedesc={MWI_NameItem(item.classid)}>{_itemdesc}</item>; _content = "<?xml version=\"1.0\" encoding=\"iso-8859-1\"?>\n"; _content += "<?xml-stylesheet href=\"stashlog.xsl\" type=\"text/xsl\"?>\n"; _content += _itemlog.toXMLString(); } else { _content = "<item id=\"" + _date.getTime() + "\" char=\"" + me.charname + "\" time=\"" + _date.toLocaleFormat("%a %m/%d/%y %H:%M:%S") + "\" quality=\"" + item.quality + "\" ethereal=\"" + isEthereal + "\" mode=\"" + mode + "\" name=\"" + ((item.name) ? item.name.split("\n")[0] : "undefined") + "\" ilvl=\"" + item.itemlevel + "\" location=\"" + _location + "\" type=\"" + item.classid + "\" typedesc=\"" + MWI_NameItem(item.classid) + "\">"; _content2 = _itemdesc; _content3 = "</item>"; } if(logStashed) _fhandle = FileOpen(_filepath, 1); else _fhandle = FileOpen(_filepath, 2); if(!_fhandle) { MWI_ErrorLog(item, 1); return false; } _fhandle.WriteLine(_content); if (!logStashed) { _fhandle.WriteLine(_content2); _fhandle.WriteLine(_content3); } _fhandle.Close(); return true; } function MWI_WriteTempLogToXML() { var _buffer, _itemData, _XMLData, _tempDate, _timeStamp, _fhandle, _count, _countXML, _filecontent, _lines, _ticks; var _buffer2, _buffer3; var i, k; var lastIncomplete = false; _itemData = new Array(); _count = 0; _countXML = 0; _buffer = ""; _filecontent = ""; NTC_SendMsgToScript("MWBotGame.ntj", "STOP_STATUS_TEXT_UPDATE"); SetStatusText("ÿc8Updating Your XML Log..."); _ticks = GetTickCount(); _fhandle = FileOpen("logs/"+ me.charname + "/Temp_itemlog", 2); if(_fhandle) { //Print("Debug: Reading Temp File...") while(!_fhandle.eof) { if (!_fhandle.eof) _buffer = _fhandle.ReadLine(); if (!_fhandle.eof) _buffer2 = _fhandle.ReadLine(); if (!_fhandle.eof) _buffer3 = _fhandle.ReadLine(); //Print("Debug: Skip to next Item") while(!(_buffer.indexOf("<item id=") > -1 && !isNaN(_timeStamp = parseInt(_buffer.split(/"/g)[1]))) && !_fhandle.eof) { // Get first opening Tag _buffer = _buffer2; _buffer2 = _buffer3; _buffer3 = _fhandle.ReadLine(); } //Print("Debug: Check if all 3 lines are correct") // Check if other Tags match if (_buffer.indexOf("<item id=") > -1 && _buffer2.indexOf("<") == -1 && _buffer2.indexOf(">") == -1 && _buffer3.indexOf("</item>") >= -1) { //Print("Debug: They are!") // all is correct --> write lines _tempDate = new Date(_timeStamp); //Print("Debug: Put Item in Struct...") if(_tempDate) { for(i = 0; i < _itemData.length; i++) { if(_itemData[i][0] == _tempDate.toLocaleFormat("%m-%d-%y")) { _itemData[i].push(_buffer); _itemData[i].push(_buffer2); _itemData[i].push(_buffer3); break; } } if(i >= _itemData.length) { _itemData.push([_tempDate.toLocaleFormat("%m-%d-%y"), _buffer, _buffer2, _buffer3]); } } }else{ //Print("Debug Line1: " + _buffer); //Print("Debug Line2: " + _buffer2); //Print("Debug Line3: " + _buffer3); } } _fhandle.Close(); if(_itemData.length < 1) return false; for(i = 0; i < _itemData.length; i++) { _fhandle = FileOpen("logs/" + me.charname + "/" + _itemData[i][0] + "_itemlog.xml", 2); //Print("Debug: Reading Log File...") if(_fhandle) { _XMLData = new Array(); while(!_fhandle.eof) { if (!_fhandle.eof) _buffer = _fhandle.ReadLine(); if (!_fhandle.eof) _buffer2 = _fhandle.ReadLine(); if (!_fhandle.eof) _buffer3 = _fhandle.ReadLine(); //Print("Debug: Skipping to next Item in Log...") while(!(_buffer.indexOf("<item id=") > -1) && !_fhandle.eof) { // Get first opening Tag _buffer = _buffer2; _buffer2 = _buffer3; _buffer3 = _fhandle.ReadLine(); } //Print("Debug: If this is a correct Item put it into Struct...") if (_buffer.indexOf("<item id=") > -1 && _buffer2.indexOf("<") == -1 && _buffer2.indexOf(">") == -1 && _buffer3.indexOf("</item>") >= -1) { //Print("Correct Item read from Log"); _XMLData.push(_buffer); _XMLData.push(_buffer2); _XMLData.push(_buffer3); } //Print("Debug Line1: " + _buffer); //Print("Debug Line2: " + _buffer2); //Print("Debug Line3: " + _buffer3); } _fhandle.Close(); } _fhandle = FileOpen("logs/" + me.charname + "/" + _itemData[i][0] + "_itemlog.xml", 1); //Print("Debug: Writing Log File...") if(_fhandle) { _fhandle.WriteLine("<?xml version=\"1.0\" encoding=\"iso-8859-1\"?>"); _fhandle.WriteLine("<?xml-stylesheet href=\"itemlog.xsl\" type=\"text/xsl\"?>"); _fhandle.WriteLine("<itemlog>"); for(k = 0; k < _XMLData.length; k++) { if (k % 3 == 0) _countXML++; _fhandle.WriteLine(_XMLData[k]); } for(k = 1; k < _itemData[i].length; k++) { if (k % 3 == 0) _count++; _fhandle.WriteLine(" " + _itemData[i][k]); } _fhandle.WriteLine("</itemlog>"); _fhandle.Close(); } } Print("ÿc<ÿc8" + _count + " ÿc<Item" + ((_count > 1) ? "s were" : " was") + " successfully added to your XML Logfile. (" + (GetTickCount() - _ticks) + "ms) [Total XML Items: " + (_count + _countXML) + "]" ); NTC_SendMsgToScript("MWBotGame.ntj", "SET_DEFAULT_STATUS"); return _count > 0; } return false; } function MWI_ClearTempLog() { var _fhandle, _date; _fhandle = _fhandle = FileOpen("logs/" + me.charname + "/Temp_itemlog", 1); _date = new Date(); if(_fhandle && _date) { _fhandle.WriteLine("//* The Item Data below will be added to the matching XML file at the beginning of every game - Temp Logfile Created: " + _date.toLocaleFormat("%a %m/%d/%y %H:%M:%S") + " */"); _fhandle.Close(); return true; } else if(_fhandle) _fhandle.Close(); return false; } function MWI_WriteLoc(itemunit) { var _fhandle, _area; if(arguments.length < 1 || !itemunit) return; _fhandle = FileOpen("logs/loc/" + me.charname + "_loc.txt", 2); _area = GetArea(); if(_fhandle) { if(_area) _fhandle.WriteLine(itemunit.gid + "<>" + _area.name); else _fhandle.WriteLine(itemunit.gid + "<>" + "undefined"); _fhandle.Close(); } _fhandle = FileOpen("logs/loc/" + me.charname + "_simpleloc.txt", 1); if(_fhandle) { if(_area) _fhandle.WriteLine(_area.name); else _fhandle.WriteLine("undefined"); _fhandle.Close(); } } function MWI_ReadLoc(itemunit) { var _fhandle, _line, _loc; if(arguments.length < 1 || !itemunit) return "undefined"; _fhandle = FileOpen("logs/loc/" + me.charname + "_loc.txt", 2); if(_fhandle) { while(!_fhandle.eof) { _line = _fhandle.ReadLine(); if(_line && parseInt(_line.split("<>")[0]) == itemunit.gid) { _fhandle.Close(); _loc = _line.split("<>")[1]; return _loc; } } _fhandle.Close(); _fhandle = FileOpen("logs/loc/" + me.charname + "_simpleloc.txt", 2); if(_fhandle) { _loc = _fhandle.ReadLine(); _fhandle.Close(); if(_loc) return _loc; else return "undefined"; } } return "undefined"; } function MWI_ClearLoc() { var _fhandle; _fhandle = FileOpen("logs/loc/" + me.charname + "_loc.txt", 1); if(_fhandle) { _fhandle.WriteLine("gid<>location"); _fhandle.Close(); } } function MWI_NameItem(itemid) { if(itemid >= 610 && itemid <= 642) return "Rune"; if((itemid >= 509 && itemid <= 516) || (itemid >= 587 && itemid <= 596)) return "Potion"; if(itemid >= 518 && itemid <= 519) return "Tome"; if(itemid >= 529 && itemid <= 530) return "Scroll"; if((itemid >= 557 && itemid <= 586) || (itemid >= 597 && itemid <= 601)) return "Gem"; if((itemid >= 644 && itemid <= 657) || (itemid >= 544 && itemid <= 555)) return "Quest Item"; if(itemid == 653) return "Token"; if(itemid >= 654 && itemid <= 657) return "Essence"; if(!_NTIPIDToName[itemid]) return "Database Error"; else return _NTIPIDToName[itemid]; } function MWI_IsLogged(item) { var _checkTime, _itemdesc, _date, _fhandle, _templine, _XMLData, _dataSet; _itemdesc = ""; _date = new Date(); _XMLData = new Array(); switch(item.quality) { // _checkTime in minutes! case 1: // Low quality _checkTime = 15; break; case 2: // Normal switch(MWI_NameItem(item.classid)) { case "Rune": return false; break; case "Gem": return false; break; case "Quest Item:": return false; break; default: _checkTime = 20; } break; case 3: // Superior _checkTime = 30; break; case 4: // Magic _checkTime = 30; break; case 5: // Set _checkTime = 30; break; case 6: // Rare _checkTime = 60; break; case 7: // Unique _checkTime = 90; break; case 8: // Crafted _checkTime = 90; break; default: _checkTime = 20; break; } if(item.itemdesc) { _itemdesc = item.itemdesc.replace(/ÿc(.)/g, ""); _itemdesc = _itemdesc.replace(/\n/g, '|'); _itemdesc = _itemdesc.replace((_itemdesc.split("|")[0] + "|"), ""); } else _itemdesc = "Itemdesc undefined|"; _fhandle = FileOpen("logs/" + me.charname + "/" + _date.toLocaleFormat("%m-%d-%y") + "_itemlog.xml", 2); if(_fhandle) { while(!_fhandle.eof) { if(((_templine = _fhandle.ReadLine()) != "</itemlog>")) _XMLData.push(_templine); } _fhandle.Close(); _XMLData.pop(); _fhandle = FileOpen("logs/" + me.charname + "/Temp_itemlog", 2); if(_fhandle) { while(!_fhandle.eof) { _templine = _fhandle.ReadLine(); if(_templine.indexOf("//*") == -1) { if(!_templine) break; _XMLData.push(_templine); } } _fhandle.Close(); } } else return false; for(var i = _XMLData.length-1; i > 0; i--) { _dataSet = _XMLData[i].split(/"/g); if((_date.getTime() - parseInt(_dataSet[1])) < _checkTime*6E4) { if(parseInt(_dataSet[19]) == item.classid) // Check itemtype { if(parseInt(_dataSet[7]) == item.quality) // Check quality { if(parseInt(_dataSet[15]) == item.itemlevel) // Check itemlevel { if(_dataSet[13] == item.name.split("\n")[0]) // Check itemname { if(_XMLData[i].split(/">/g)[1].replace("</item>", "") == _itemdesc) // Check itemdesc return true; else continue; } else continue; } else continue; } else continue; } else continue; } else break; } return false; } // 0 = item already logged // 1 = filhandle error // 2 = error creating logfile // 3 = itemunit undefined function MWI_ErrorLog(item, errorcode) { var _dateString, _errorOutput, _fhandle; _dateString = new Date().toLocaleFormat("%a %m/%d/%y %H:%M:%S"); _errorOutput = "[" + _dateString + " <" + me.charname + "> ] "; switch(errorcode) { case 0: Print("ÿc8Itemlog Info: Item is already in log!"); _errorOutput += "Item Error: Item appears to be already logged (" + item.name.replace("\n", "") + ", " + MWI_NameItem(item.classid) + "[" + item.quality + "])"; break; case 1: Print("ÿc1Itemlog Error: Filehandle is null!"); _errorOutput += "File Error: Filehandle is null (Unable to log "+ item.name.replace("\n", "") + ", " + MWI_NameItem(item.classid) + "[" + item.quality + "])"; break; case 2: Print("ÿc1Itemlog Error: Logfile could not be created!"); _errorOutput += "File Error: Logfile could not be created (Unable to log "+ item.name.replace("\n", "") + ", " + MWI_NameItem(item.classid) + "[" + item.quality + "])"; break; case 3: Print("ÿc1Itemlog Error: Itemunit is undefined!"); _errorOutput += "File Error: Itemunit is undefined!"; break; default: _errorOutput += "Unknown Error"; break; } _fhandle = FileOpen("logs/ErrorLog.txt", 2); if(_fhandle) { _fhandle.WriteLine(_errorOutput); _fhandle.Close(); } } function MWI_GetGoldLogDate() { var _fhandle, _date, _templine; _fhandle = FileOpen("gamble/" + me.charname + "_GambleInfo.txt", 2); if(_fhandle) { _templine = _fhandle.ReadLine(); if(_templine) { for(var i = 0; i < 3; i++) _templine = _fhandle.ReadLine(); if(_templine) _date = _templine.split(": ")[1]; } _fhandle.Close(); return _date; } else return "Unknown"; } function MWI_GetGoldLogSessions() { var _fhandle, _sessions, _templine; _fhandle = FileOpen("gamble/" + me.charname + "_GambleInfo.txt", 2); if(_fhandle) { _templine = _fhandle.ReadLine(); if(_templine) { for(var i = 0; i < 2; i++) _templine = _fhandle.ReadLine(); if(_templine) _sessions = parseInt(_templine.split(": ")[1]); _fhandle.Close(); return _sessions; } _fhandle.Close(); return -1; } else return -1; } function MWI_LogGold(spentGold, count) { if(arguments.length < 2) count = false; var _fhandle, _fileTimeStamp, _currentTimeStamp, _total, _date, _gambleCount, _templine; _currentTimeStamp = new Date().getTime(); _date = new Date().toLocaleFormat("%a %m/%d/%y %H:%M:%S"); _total = 0; _gambleCount = 0; _fhandle = FileOpen("gamble/" + me.charname + "_GambleInfo.txt", 2); if(_fhandle) { _templine = _fhandle.ReadLine(); if(_templine) { _fileTimeStamp = parseInt(_templine.split(": ")[1]); if(true || _currentTimeStamp - _fileTimeStamp <= 3*60*60*1E3) { _templine = _fhandle.ReadLine(); if(_templine) _total = parseInt(_templine.split(": ")[1]); _templine = _fhandle.ReadLine(); if(_templine) _gambleCount = parseInt(_templine.split(": ")[1]); _templine = _fhandle.ReadLine(); if(_templine) _date = _templine.split(": ")[1]; } } _fhandle.Close(); _total += spentGold; _fhandle = FileOpen("gamble/" + me.charname + "_GambleInfo.txt", 1); if(_fhandle) { _fhandle.WriteLine("Timestamp: " + _currentTimeStamp ); _fhandle.WriteLine("Gold: " + _total); _fhandle.WriteLine("Gamble Counter: " + ((count) ? ++_gambleCount : _gambleCount)); _fhandle.WriteLine("File created: " + _date); _fhandle.Close(); } } else return -1; return _total; } function MWI_LogStashedItems(LogToTxt) { var _isEthereal, _whereabouts, _content, _items, _fhandle, _date, _logToTxt, _dataSet, _fileContent, _hasCube, _room; var j; _items = me.GetItems(); if(!_items) return false; if(arguments.length < 1) _logToTxt = MWConfig_LogStashToTxt; else _logToTxt = LogToTxt; if(!_logToTxt) { _fhandle = FileOpen("logs/stashlogs/" + me.charname + "_StashedItems.xml", 1); if(_fhandle) { _fhandle.WriteLine("<?xml version=\"1.0\" encoding=\"iso-8859-1\"?>"); _fhandle.WriteLine("<?xml-stylesheet href=\"stashlog.xsl\" type=\"text/xsl\"?>"); _fhandle.WriteLine("<itemlog>"); _fhandle.WriteLine("</itemlog>"); _fhandle.Close(); for(var i = 0 ; i < _items.length; i++) { if(!_items[i].itemloc && _items[i].mode == 2) continue; _isEthereal = (_items[i].itemflag & 0x400000) ? 1 : 0; _whereabouts = MWI_ItemLocationToName(_items[i]); if(!MWI_WriteLog(_items[i], _isEthereal, 0, true, _whereabouts)) return false; } return true; } return false; } else { _content = new Array(); _hasCube = false; _room = 88; // Inventory + Stash size without cube for(var i = 0 ; i < _items.length ; i++) { _whereabouts = MWI_ItemLocationToName(_items[i]); if(!_items[i].itemloc && _items[i].mode == 2) continue; if(_items[i].itemdesc) { _dataSet = new ItemData(_whereabouts, MWI_NameItem(_items[i].classid), MWI_QualityToName(_items[i].quality), _items[i].itemlevel, _items[i].itemdesc.replace(/ÿc(.)/g, ""),_items[i].xsize*_items[i].ysize, _items[i].classid); // Ignoring the size of equipped items if(_dataSet.location == "Inventory" || _dataSet.location == "Stash" || _dataSet.location == "Cube") _room -= _dataSet.size; if(_dataSet.classid == 549) { _hasCube = true; _room += 12; } for(j = 0; j < _content.length; j++) { if(_content[j].typename == _dataSet.typename && _content[j].qualityname == _dataSet.qualityname && _content[j].getGeneralDesc() == _dataSet.getGeneralDesc() && _content[j].classid == _dataSet.classid && _content[j].size == _dataSet.size) break; } if(j < _content.length) _content[j].amount++; else _content.push(_dataSet); } } _fileContent = ""; for(var i = 0; i < _content.length; i++) { _fileContent += "Location: " + me.charname + ((_content[i].amount == 1)?" (" + _content[i].location + ")":"") + "\n"; _fileContent += "Type: " + _content[i].typename + "\n"; _fileContent += "Quality: " + _content[i].qualityname + "\n"; if(_content[i].amount == 1) _fileContent += "Item Level: " + _content[i].level + "\n"; _fileContent += "Amount carried: " + _content[i].amount + "\n\n"; _fileContent += _content[i].desc; _fileContent += "\n----------------------------------------\n"; } if(!_fileContent) _fileContent = "Empty! :("; _date = new Date().toLocaleFormat("%a %m/%d/%y %H:%M:%S"); _fileContent = "----------------------------------------\n" + "----------------------------------------\n" + me.charname + "'s Stashlog (Level " + me.GetStat(12) + " " + MWC_CharClassIdToString(me.classid) + ")\nFile created: " + _date + "\nItems carried: " + _items.length + "\nGold carried: " + NTC_MyGold() + "\nFree room: " + _room +" of " +((_hasCube)?"96":"88")+ "\n" + "----------------------------------------\n" + "----------------------------------------\n" + _fileContent; _fhandle = FileOpen("logs/stashlogs/" + me.charname + "_StashedItems.txt", 1); if(_fhandle) { _fhandle.WriteLine(_fileContent); _fhandle.Close(); } else return false; return true; } } function MWI_ShowItemInfo() { var _items, _itemsInCube, _nipRes, _cubingRes; _itemsInCube = false; _items = me.GetItems(); if(_items) { NTCU_InitCubing(); for(var i = 0; i < _items.length; i++) { if(_items[i].itemloc == 3 && _items[i].mode == 0) { _nipRes = NTIPCheckItem(_items[i], 0, true); _cubingRes = NTCU_CheckItem(_items[i], _nipRes); Print("ÿc0Item Level of " + NTC_ItemQualityToD2Color[MWC_GetItemColorInt(_items[i])] + _items[i].name.split("\n")[0] + "ÿc0:ÿc8 " + _items[i].itemlevel + " ÿc0 <> NIPCheckID:ÿc8 " + _nipRes + " (" + _cubingRes + ")"); _itemsInCube = true; } } } if(!_itemsInCube) Print("Make sure the item you want to gather information about is placed in your cube ;)"); } function MWI_ItemLocationToName(itemunit) { if(arguments.length < 1 || !itemunit) return "Unknown"; if(!itemunit.itemloc && itemunit.mode == 2) return "Belt"; switch(itemunit.itemloc) { case 0: return "Inventory"; break; case 1: return "Head"; break; case 2: return "Amulet"; break; case 3: if(itemunit.mode == 1) return "Torso"; else return "Cube"; break; case 4: if(itemunit.mode == 1) return "Right Hand I"; else return "Stash"; break; case 5: return "Left hand I"; break; case 6: return "Right Ring"; break; case 7: return "Left Ring"; break; case 8: return "Belt"; break; case 9: return "Feet"; break; case 10: return "Gloves"; break; case 11: return "Right Hand II"; break; case 12: return "Left hand II"; break; default: return "Unknown"; break; } } function MWI_QualityToName(quality) { switch(quality) { case 1: return "Damaged"; break; case 2: return "Normal"; break; case 3: return "Superior"; break; case 4: return "Magic"; break; case 5: return "Set"; break; case 6: return "Rare"; break; case 7: return "Unique"; break; case 8: return "Crafted"; break; default: return "Unknown"; } } // Itemdata Class function ItemData(loc, typename, quality, ilvl, desc, size, classid) { this.location = loc; this.typename = typename; this.qualityname = quality; this.level = ilvl; this.desc = desc; this.size = size; this.classid = classid; this.amount = 1; this.getGeneralDesc = function() { return this.desc.replace(/Durability:\s.+\sof\s.+\s/i, ""); } }