|
You last visited: Today at 13:13
Advertisement
runeword rolling?
Discussion on runeword rolling? within the Diablo 2 Programming forum part of the Diablo 2 category.
01/22/2012, 21:00
|
#1
|
elite*gold: 0
Join Date: Oct 2011
Posts: 690
Received Thanks: 130
|
runeword rolling?
hey hey ^^
wollte mal fragen ob es für muddy's ein script dafür gibt,
oder ob man das vom etal i.wie "übernehmen" kann?
|
|
|
01/24/2012, 18:23
|
#2
|
elite*gold: 0
Join Date: Oct 2011
Posts: 690
Received Thanks: 130
|
warum kann man das vom etal nicht einfach kopieren?
sind doch beides nt versionen...
|
|
|
01/24/2012, 18:36
|
#3
|
elite*gold: 0
Join Date: Jan 2009
Posts: 3,170
Received Thanks: 1,191
|
Den Gedanken hatte ich schon vor langer Zeit ins Spiel gebracht.
Im Ordner libs/common exitiert eine NTRunewords.ntl. Diese wirst wohl benötigen
Zu dem muss man sicher die NTCommon anpassen:
Code:
function NTC_IncludeLibs()
{
Include("libs/common/NTAttack.ntl");
Include("libs/common/NTCubing.ntl");
Include("libs/common/NTItemParser.ntl");
Include("libs/common/NTMove.ntl");
Include("libs/common/NTPrecast.ntl");
Include("libs/common/NTSnagIt.ntl");
Include("libs/common/NTTown.ntl");
Include("libs/common/NTTownManager.ntl");
Include("libs/common/NTTownMove.ntl");
Include("libs/common/MyCatchShrine.ntl");
Include("libs/common/NTUtilities.ntl");
Include("libs/common/NTTools.ntl");
Include("libs/common/NTRunewords.ntl");
Include("libs/common/LazyManCoding.ntl");
//Include("libs/common/NTVoyage.ntl");
Include("libs/common/NTItemlogger.ntl");
Include("libs/common/NTColorConverter.ntl");
switch (me.classid) {
case NTC_CHAR_CLASS_AMAZON:
Include("libs/common/NTAttackAmazon.ntl");
break;
case NTC_CHAR_CLASS_ASSASSIN:
Include("libs/common/NTAttackAssassin.ntl");
break;
case NTC_CHAR_CLASS_BARBARIAN:
Include("libs/common/NTAttackBarbarian.ntl");
break;
case NTC_CHAR_CLASS_DRUID:
Include("libs/common/NTAttackDruid.ntl");
break;
case NTC_CHAR_CLASS_NECROMANCER:
Include("libs/common/NTAttackNecromancer.ntl");
break;
case NTC_CHAR_CLASS_PALADIN:
Include("libs/common/NTAttackPaladin.ntl");
break;
case NTC_CHAR_CLASS_SORCERESS:
Include("libs/common/NTAttackSorceress.ntl");
break;
}
}
Ob das alleine reicht kann ich dir nicht genau sagen, dafür reiche meine Programmierkenntnisse nicht aus :/
Muddy hatte es von vorn herein nicht für notwendig gehalten solch eine Funktion zu adden.
|
|
|
01/24/2012, 19:40
|
#4
|
elite*gold: 0
Join Date: Oct 2011
Posts: 690
Received Thanks: 130
|
Quote:
Originally Posted by mirkoregge
Den Gedanken hatte ich schon vor langer Zeit ins Spiel gebracht.
Im Ordner libs/common exitiert eine NTRunewords.ntl. Diese wirst wohl benötigen
Zu dem muss man sicher die NTCommon anpassen:
Code:
function NTC_IncludeLibs()
{
Include("libs/common/NTAttack.ntl");
Include("libs/common/NTCubing.ntl");
Include("libs/common/NTItemParser.ntl");
Include("libs/common/NTMove.ntl");
Include("libs/common/NTPrecast.ntl");
Include("libs/common/NTSnagIt.ntl");
Include("libs/common/NTTown.ntl");
Include("libs/common/NTTownManager.ntl");
Include("libs/common/NTTownMove.ntl");
Include("libs/common/MyCatchShrine.ntl");
Include("libs/common/NTUtilities.ntl");
Include("libs/common/NTTools.ntl");
Include("libs/common/NTRunewords.ntl");
Include("libs/common/LazyManCoding.ntl");
//Include("libs/common/NTVoyage.ntl");
Include("libs/common/NTItemlogger.ntl");
Include("libs/common/NTColorConverter.ntl");
switch (me.classid) {
case NTC_CHAR_CLASS_AMAZON:
Include("libs/common/NTAttackAmazon.ntl");
break;
case NTC_CHAR_CLASS_ASSASSIN:
Include("libs/common/NTAttackAssassin.ntl");
break;
case NTC_CHAR_CLASS_BARBARIAN:
Include("libs/common/NTAttackBarbarian.ntl");
break;
case NTC_CHAR_CLASS_DRUID:
Include("libs/common/NTAttackDruid.ntl");
break;
case NTC_CHAR_CLASS_NECROMANCER:
Include("libs/common/NTAttackNecromancer.ntl");
break;
case NTC_CHAR_CLASS_PALADIN:
Include("libs/common/NTAttackPaladin.ntl");
break;
case NTC_CHAR_CLASS_SORCERESS:
Include("libs/common/NTAttackSorceress.ntl");
break;
}
}
Ob das alleine reicht kann ich dir nicht genau sagen, dafür reiche meine Programmierkenntnisse nicht aus :/
Muddy hatte es von vorn herein nicht für notwendig gehalten solch eine Funktion zu adden.
|
das ist aber schade 
gerade für ladderstart is das das beste...
will nicht wieder etal usen^^
aber wenn das bei muddy seinem nicht geht, dann muss ich es wohl :'(
ich hab leider auch nicht so die großen kenntnisse :/
|
|
|
02/01/2012, 18:18
|
#5
|
elite*gold: 0
Join Date: Oct 2011
Posts: 690
Received Thanks: 130
|
iso help
will nicht etal usen  muddys > etal
|
|
|
07/01/2012, 23:50
|
#6
|
elite*gold: 0
Join Date: Jun 2011
Posts: 285
Received Thanks: 185
|
Hallo zusammen,
ich habe mich an der Problematik mal versucht. Da ich selber programmieren nicht gelernt habe, habe ich das meiste zusammen kopiert und ein wenig ausprobiert (vielleicht auch ein wenig mehr probiert ^^).
Die nachfolgenden Änderungen habe ich bei mir eingearbeitet und bis dato läuft es mit Insights und Spirits sehr gut.
Die Datei "NTRunewords.ntl" muss im Verzeichnis "D2NT\scripts\libs\Common\" eingefügt werden:
Code:
function NTRW_CheckItem(item, checkonly)
{
if(!NTConfig_MakeRunewords)
return false;
if(arguments.length < 2)
checkonly = false;
var _baseitem;
var _needhel;
var _classid = item.classid;
for(var i = 0 ; i < NTConfig_Runeword.length ; i++)
{
_needhel = 1;
_items = me.GetItems(NTRW_AliasToClassid(NTConfig_Runeword[i][0]));
if(!_items || _items.length == 0)
continue;
for(var n = 0 ; n < _items.length ; n++)
{
if(_items[n].GetStat(194) == (NTConfig_Runeword[i].length - 1) && _items[n].quality < 4 && _items[n].mode == 0 && (_items[n].itemloc == 0 || _items
[n].itemloc == 4) && !(_items[n].itemflag&0x4000000))
{
_baseitem = _items[n];
break;
}
}
if(_baseitem)
{
for(var j = 1 ; j < NTConfig_Runeword[i].length ; j++)
{
if(NTRW_AliasToClassid(NTConfig_Runeword[i][j]) == 624)
_needhel++;
if(NTRW_AliasToClassid(NTConfig_Runeword[i][j]) == _classid)
{
if(NTRW_CheckItemNum(NTRW_AliasToClassid(NTConfig_Runeword[i][j])) < 1 || checkonly)
return true;
}
}
if(_classid == 624)
{
if(NTRW_CheckItemNum(624) < _needhel || checkonly)
return true;
}
}
}
return false;
}
function NTRW_CheckRunewords()
{
var checkrunes;
var checkbase = false;
var result = true
var _needhel;
for(var i = 0 ; i < NTConfig_Runeword.length ; i++)
{
checkbase = false;
checkrunes = true;
_needhel = 1;
for(var j = 0 ; j < NTConfig_Runeword[i].length ; j++)
{
if(j == 0)
{
_items = me.GetItems(NTRW_AliasToClassid(NTConfig_Runeword[i][0]));
if(!_items || _items.length == 0)
break;
for(var n = 0 ; n < _items.length ; n++)
{
if(_items[n].GetStat(194) == (NTConfig_Runeword[i].length - 1) && _items[n].quality < 4 && (_items[n].itemloc == 0 || _items[n].itemloc
== 4) && !(_items[n].itemflag&0x4000000))
{
checkbase = true;
break;
}
}
continue;
}
if(NTRW_CheckItemNum(NTRW_AliasToClassid(NTConfig_Runeword[i][j])) == 0)
checkrunes = false;
if(NTRW_AliasToClassid(NTConfig_Runeword[i][j]) == 624)
_needhel++;
if(NTRW_CheckItemNum(624) < _needhel)
checkrunes = false;
if(checkrunes && checkbase)
return true;
}
}
return false;
}
function NTRW_CheckItemNum(id)
{
var num = 0;
var _items;
_items = me.GetItems();
if(!_items)
return 0;
for(var i = 0 ; i < _items.length ; i++)
{
if(id == _items[i].classid)
num++;
}
return num;
}
function NTRW_MakeRuneword()
{
var _items;
var baseitem;
var haveitem;
var _helrune = me.GetItems(624);
var _needhel = 1;
if(!_helrune || _helrune.length < _needhel)
return false;
for(var i = 0 ; i < NTConfig_Runeword.length ; i++)
{
baseitem = false;
_needhel = 1;
haveitem = true;
for(var j = 0 ; j < NTConfig_Runeword[i].length ; j++)
{
if(NTRW_AliasToClassid(NTConfig_Runeword[i][j]) == 624)
_needhel++;
_items = me.GetItems(NTRW_AliasToClassid(NTConfig_Runeword[i][j]));
if(!_items || _items.length == 0)
{
haveitem = false;
break;
}
}
if(!_helrune || _helrune.length < _needhel)
haveitem = false;
if(haveitem)
{
for(var j = 0 ; j < NTConfig_Runeword[i].length ; j++)
{
_items = me.GetItems(NTRW_AliasToClassid(NTConfig_Runeword[i][j]));
for(var n = 0 ; n < _items.length ; n++)
{
if(_items[n].GetStat(194) == (NTConfig_Runeword[i].length - 1) && _items[n].quality < 4 && _items[n].mode == 0 && (_items[n].itemloc == 0
|| _items[n].itemloc == 4) && !(_items[n].itemflag&0x4000000))
{
baseitem = _items[n];
break;
}
}
if(j == 0)
continue;
if(!baseitem)
break;
if(!NTT_CheckSpace(baseitem.xsize, baseitem.ysize))
{
Print("Insufficient space");
return false;
}
NTC_ItemToCursor(_items[0]);
NTC_PingDelay(250);
if(!me.itemoncursor)
{
for(var c = 0 ; c < 3 ; c++)
{
NTC_ItemToCursor(_items[0]);
if(me.itemoncursor)
break;
}
}
me.ClickItem(0, baseitem.x, baseitem.y, baseitem.itemloc);
NTC_PingDelay(250);
}
if(baseitem)
{
var _result = 0;
for(var m = 0; m < NTConfig_KeepRuneword.length && !_result; m++)
_result = (MySI_MiniNTIPCheckItem(baseitem, NTConfig_KeepRuneword[m]) == 1);
if(!_result)
{
NTC_SendLogToOOG(NTC_LOG_ITEM, "Rerolling Runeword: " + NTC_ItemQualityToMGRColor[baseitem.quality] + baseitem.name.split("\n")[0]+ ";" +
baseitem.itemdesc + "\n " + "iLvl: " + baseitem.itemlevel);
me.Cancel(1);
NTRW_BuyTP();
NTTM_TownMove("stash");
var _stash = NTC_FindUnit(NTC_UNIT_OBJECT, NTC_UNIT_STASH, 5);
NTT_DoInteract(_stash);
NTRW_Reroll(baseitem);
NTTMGR_VisitStash(false);
}
else
NTC_SendLogToOOG(NTC_LOG_ITEM, "Kept Runeword: " + NTC_ItemQualityToMGRColor[baseitem.quality] + baseitem.name.split("\n")[0]+ ";" +
baseitem.itemdesc + "\n " + "iLvl: " + baseitem.itemlevel);
}
}
}
}
function MySI_MiniNTIPCheckItem(item, ntip) //taken from korean d2nt mod
{
var _result = 0;
var _identified = item.itemflag & _NTIPAliasFlag["identified"];
var _ntip = NTIP_ParseLineInt(ntip);
if (_ntip)
{
if (_ntip[0].length > 0)
{
if (eval(_ntip[0]))
{
if (_ntip[1].length > 0)
{
if (eval(_ntip[1]))
return 1;
else if (!_identified && _result == 0)
_result = -1;
}
else
return 1;
}
}
else if (_ntip[1].length > 0)
{
if (eval(_ntip[1]))
return 1;
else if (!_identified && _result == 0)
_result = -1;
}
}
return _result;
}
function NTRW_BuyTP()
{
var _npc;
var _items;
_items = me.GetItems(529);
if(_items.length > 0)
return false;
var _npcList = [["akara", NTC_NPC_ID_AKARA], ["drognan", NTC_NPC_ID_DROGNAN], ["ormus", NTC_NPC_ID_ORMUS], ["jamella", NTC_NPC_ID_JAMELLA], ["malah", NTC_NPC_ID_MALAH]];
NTTM_TownMove(_npcList[me.act-1][0]);
_npc = NTC_FindUnit(NTC_UNIT_NPC, _npcList[me.act-1][1], 5);
if(_npc)
NTT_DoInteract(_npc);
NTT_DoTrade(_npc);
for(var i = 0 ; i < 3 ; i++) {
_items = _npc.GetItems(529);
NTT_ShopItem(_items[0], _npc, 3);
_items = me.GetItems(529);
if(_items.length > 0)
break;
}
me.Cancel(1);
return true;
}
function NTRW_Reroll(item)
{
var _tpscroll = me.GetItems(529);
var _helrune = me.GetItems(624);
var _cube = me.GetItems(NTC_UNIT_CUBE);
NTCU_MoveItemToCubeInt(_cube[0], _tpscroll[0]);
NTCU_MoveItemToCubeInt(_cube[0], _helrune[0]);
NTCU_MoveItemToCubeInt(_cube[0], item);
NTCU_OpenCubeInt(_cube[0]);
Transmute();
NTC_PingDelay(800);
if(NTCU_CheckCubeInventoryInt() > 0)
{
if(NTCU_ClearCubeInt() < 1)
return false;
NTCU_CloseCubeInt();
}
me.Cancel(1);
}
function NTRW_AliasToClassid(input)
{
if(isNaN(input))
return _NTIPAliasClassID[input.replace(/\s+|;/g, "").toLowerCase()];
return input;
}
In die Datei "NTItemAlias.ntl" im Verzeichnis "D2NT\scripts\libs\Common\" folgende Zeile einfügen (bei mir Zeile 1137):
Code:
_NTIPAliasStat["meditationaura"]=[151,120];
In die CharConfig (bei mir nach Cubing) folgendes einfügen:
Code:
//------------------------------------------------------------------------------
// Runeword Cubing Configuration
//------------------------------------------------------------------------------
NTConfig_MakeRunewords = true;
//NTConfig_Runeword.push([498, 616, 619, 618, 620]); // Sacred Targe, Tal, Thul, Ort, Amn SPIRIT
NTConfig_KeepRuneword.push("[name] == sacredtarge # [fcr] >= 35");
//NTConfig_Runeword.push([447, 616, 619, 618, 620]); // Monarch, Tal, Thul, Ort, Amn SPIRIT
NTConfig_KeepRuneword.push("[name] == monarch # [fcr] >= 35");
//NTConfig_Runeword.push([29, 616, 619, 618, 620]); // Crystal Sword, Tal, Thul, Ort, Amn SPIRIT
NTConfig_KeepRuneword.push("[name] == crystalsword # [fcr] >= 35");
//NTConfig_Runeword.push([254, 617, 612, 616, 621]); // Colossus Voulge, Ral, Tir, Tal, Sol
NTConfig_KeepRuneword.push("[name] == ColossusVoulge # [meditationaura] >= 17");
//NTConfig_Runeword.push([255, 617, 612, 616, 621]); // Thresher, Ral, Tir, Tal, Sol
NTConfig_KeepRuneword.push("[name] == thresher # [meditationaura] >= 17");
//NTConfig_Runeword.push([256, 617, 612, 616, 621]); // Cryptic Axe, Ral, Tir, Tal, Sol
NTConfig_KeepRuneword.push("[name] == crypticaxe # [meditationaura] >= 17");
//NTConfig_Runeword.push([21, 627, 635, 630, 619]); // Flail, Ko, Vex, Pul, Thul
NTConfig_KeepRuneword.push("[name] == flail # [fcr] >= 40");
//NTConfig_Runeword.push([21, 620, 617, 632, 633, 636]); // Flail, Amn, Ral, Mal, Ist, Ohm
NTConfig_KeepRuneword.push("[name] == flail # [IAS] >= 40");
//NTConfig_Runeword.push([29, 620, 617, 632, 633, 636]); // Crystal Sword, Amn, Ral, Mal, Ist, Ohm
NTConfig_KeepRuneword.push("[name] == crystalsword # [IAS] >= 40");
und folgende Nip aktivieren:
Code:
NTConfig_NIPFilePath.push("private/Runeword.nip");
Die Datei "Runeword.nip" im Verzeichnis "D2NT\scripts\NTBot\item_configs\private\" angelegt:
Code:
[Name] == HoradricCube
[Type] == Weapon && [Flag] == Runeword
[Type] == Armor && [Flag] == Runeword
[Type] == Shield && [Flag] == Runeword
In der Datei "NTTownManager.ntl" im Verzeichnis "D2NT\scripts\libs\Common\" folgende Änderungen vornehmen:
Zeile 40 überschreiben:
Code:
_cubing = (!simple && (NTCU_CheckCubing() || NTRW_CheckRunewords()));
Zeile 137 überschreiben:
Code:
_cubing = (!simple && (NTCU_CheckCubing() || NTRW_CheckRunewords()));
Zeile 226 einfügen:
Code:
if(NTConfig_MakeRunewords)
NTRW_MakeRuneword();
In der Datei "NTCommon.ntl" im Verzeichnis "D2NT\scripts\libs\Common\" folgendes unter den "Common libraries" einfügen (Zeile 324):
Code:
Include("libs/common/NTRunewords.ntl");
In der Datei "NTConfig.ntl" im Verzeichnis "D2NT\scripts\NTBot\char_configs\" folgendes einfügen (bei mir Zeilen 91-93):
Code:
var NTConfig_MakeRunewords;
var NTConfig_Runeword = [];
var NTConfig_KeepRuneword = [];
Um ein Runenwort zu cuben, löscht man in der CharConfig die "//" vor der jeweiligen Zeile des Runenwortes:
Code:
//NTConfig_Runeword.push
Die Gegenstände, die er cuben soll müüsen in den Nips vorhanden sein. Die Runen werden automatisch gesammelt, bis auf die Hel-Rune. Gecubt wird erst, wenn alle Runen inkl. Hel-Rune vorliegen, daher empfehle ich hiervon ein paar über mit der Funktion "[MaxQuantity] == 2 &&" automatisch sammeln zu lassen.
Credits
Mein Dank geht an den/die Autor/en des etal bots, aus dem der Bärenanteil der obigen Änderungen stammt!
Danke natürlich auch an Muddy, der den herrlichen Bot zur Verfügung gestellt hat und jeden ermutigt selbst zu programmieren (auch wenn meine Änderungen weit von eigenständigem Programmieren entfernt sind...)!
Ich hoffe alles funktioniert und ich habe keine Änderung vergessen. Ich empfehle die Dateien vor Änderung zu sichern. ^^
LG und viel Spaß
Traycas
|
|
|
07/12/2012, 19:51
|
#7
|
elite*gold: 0
Join Date: May 2010
Posts: 5
Received Thanks: 0
|
Aloa, kurze frage... ich kenn mich mit sonem kram absolut nich aus, wollte aber gerne, dass mein bot runenwörtert erstellt ^^
hab eig. alles so gemacht wie vondir beschrieben, bekomme aber folgende Fehlermeldung :
...NTTownManager.ntl (40) : ReferenceError: NTRW_CheckRunewords is not defined
kann mir da evtl. jemand helfen ?
|
|
|
07/16/2012, 13:17
|
#8
|
elite*gold: 0
Join Date: Jun 2011
Posts: 285
Received Thanks: 185
|
Sorry, leider erst heute Deine Nachricht gesehen.
Der Fehler deutet auf zwei Sachen hin. Prüfe doch mal bitte, ob
1. die Datei "NTRunewords.ntl" im Verzeichnis "D2NT\scripts\libs\Common\" angelegt ist
2. in der Datei "NTCommon.ntl" im Verzeichnis "D2NT\scripts\libs\Common\" unter den "Common libraries" in Zeile 324:
Code:
Include("libs/common/NTRunewords.ntl");
eingefügt ist.
LG, Traycas
|
|
|
07/17/2012, 01:28
|
#9
|
elite*gold: 0
Join Date: May 2010
Posts: 5
Received Thanks: 0
|
es war letzteres, vielen dank
|
|
|
 |
Similar Threads
|
ich möchte runeword generator für die 1.13
07/16/2010 - Diablo 2 - 12 Replies
hilfe bitte
|
Rolling back to 4.5.8
12/20/2008 - Dekaron - 8 Replies
I tried rolling back 4.6.2 to 4.5.8 and used 4.5.8 no_CRC.... Everything looked like it worked, It logged in to my char selection but it won't log in to the server.
|
2Moons rolling back
12/10/2007 - Dekaron - 9 Replies
My question is simple my current version is 2.8.18 and it causes mad lagg and dc's i usually get dc'd after about 3 mins of game time...this has never happened to me when i was at 2.8.17 so my question, How can i stop 2Moons from updating to 2.8.18 and keep it at 2.8.17?
|
Rolling Trick
07/27/2006 - WoW Guides & Templates - 12 Replies
|
Loot rolling Bug
01/12/2006 - WoW Exploits, Hacks, Tools & Macros - 10 Replies
Hab da was herausgefunden:
Nehmen wir mal an es dropped ein blauer Gegenstand alle bis auf einen würfeln Bedarf und er würfelt Gier. Jetzt steht zwar dran dass es einer von den gewonnen hat der Bedarf gewürfelt hat aber es is lootbar von jedem an dem Mob der es gedropped hat :D
If a group found an item and roll need and someone rolls geed then the item will shown as won by an person who roll need but the item will be always in the corpse of the mob and will be lootable for everyone.
|
All times are GMT +1. The time now is 13:13.
|
|