Open DarkHorseDre opened 5 years ago
I also tried with 'true' instead of '2' and now it works very well^^
lol the config file says you should use true or false. The subject of this post, and the code shown states you can use "2" for the aforementioned reasons, and my question is whether it works as intended,
Yes. Setting it to 2 will open all the containers listed in that array. Alternatively, add any of those to the default array to add those to the open list; such as Evil Urn.
thanks @Zombenstein .. it doesnt seem to work tho :p
scratch that - just checked configs and the "2" isnt there ffs! will report back later :p
Works for me. :P Just note that, like the normal true setting, it only checks for containers along its path if the script itself calls the function. Check Pather.js to see which functions actually call it, then compare it to the scripts you're running.
haha nice! so now I know that, my main point for this thread is - THEY SHOULD PUT THIS IN THE CONFIG COMMENTS!!
as for your tip - thanks! but I thought pather always popped chests as it goes - my problem was that it was always the standard chests. why would it not just pop more if I set to 2/or expand the container list?
I did a quick grep: countess seems to do if (Config.OpenChests)
does that mean its looking for a true or a 1 and not a 2?
I don't see it referenced anywhere other than: countess, eldritch, meph, radament, tristram
are you saying I've got to add a similar entry to all other scripts just to pop as I go?! :\
Well, take a look at this function, for instance:
Side note - (condition) will return true if it is not 0 or false.
moveTo: function (x, y, retry, clearPath, pop) {
if (me.dead) { // Abort if dead
return false;
}
....
blahblah, normal JS stuff.
....
if (clearPath === undefined) {
clearPath = false;
}
if (pop === undefined) {
pop = false;
}
The parameters are (x, y, retry, clearPath, pop)
Notice the last little block here. If pop is undefined, it is false by default and will skip over nodes, such as shrines, barrels, chests, etc.
In the scripts, you should see something like:
Pather.moveTo(23466, 28956, 3, true, true);
This means it will move to the (23466, 28956) coords, try it 3 times if any fails occur, it will clear the path of monsters along the way, as well as pop nodes.
If it does not specify the last parameter as 'true' then it will not open nodes.
Hope that clears it up a bit more; atleast somewhat ;)
PS: This is just my understanding of what pop does within the function. If someone more experienced knows better, please correct me.. :)
If it does not specify the last parameter as 'true' then it will not open nodes.
Son of a beach! Thanks man - another script review to add to my list :/
it will clear the path of monsters along the way, as well as pop nodes.
my list has a task to have bot kill all uniques and champions along the way - could be a 'toofa! :) 👍
If you need some help, feel free to @ or PM me on the discord server. :) Zombie#4597
@Zombenstein thanks bro - will do
Does the discord have more activity than here? I kinda would prefer to not create issues to ask simple questions etc.
@DarkHorseDre Ehh, it's about even. The main deal with discord is that it's more widely known. Not a lot of people - especially newcomers - actually know about posting in github. :P
Also, that's exactly what the support channel on the server is for. ;) Replies are often a lot faster there, as well.
damn, I better create a discord account then - I've been doing it all wrong '#doh could you please share a link/name of the area for kolbot on discord?
I'm DarkHorseDre#0361 :)
as I understand: either you change it in misc.js to "true" or in charconfig to '2': Misc.js: if (Config.OpenChests === true) // instead of if (Config.OpenChests === 2) or YourCharConfig.YourCharname.js: Config.OpenChests = 2; // instead of Config.OpenChests = true;
a little bit confused atm 😕
Config.OpenChests = 2; // instead of Config.OpenChests = true;
This.
although zombiemiester also states that changes will need to be made per script to force the bot to actually look for the chests whilst pathing.. this I need to look at one of these days. I'm hoping it is not so and we can just enable and it will do it everywhere! :p
Yeah the character files do not contain every config parameters available, you'll have to check config.js and other scripts to find them all.
@Zombenstein From what I can see the only thing pop is doing is removing the last node from the path, meaning if you call moveTo with pop = true to a destination (x,y), it will go near (x,y) but not exactly on it.
The function popChest is called when NodeAction.go({clearPath: clearPath});
is called, which is at every node whether pop is true or false.
Config.OpenChests = 2; // instead of Config.OpenChests = true;
This.
although zombiemiester also states that changes will need to be made per script to force the bot to actually look for the chests whilst pathing.. this I need to look at one of these days. I'm hoping it is not so and we can just enable and it will do it everywhere! :p
ty 😄
Yeah the character files do not contain every config parameters available, you'll have to check config.js and other scripts to find them all.
@Zombenstein From what I can see the only thing pop is doing is removing the last node from the path, meaning if you call moveTo with pop = true to a destination (x,y), it will go near (x,y) but not exactly on it. The function popChest is called when
NodeAction.go({clearPath: clearPath});
is called, which is at every node whether pop is true or false.
hey @5noop!
yeah fosho but this isn't even a config parameter - config.open chests exists! What is missing is documentation in the only place they document all possible parameter values: comments of chars config!
function popChest is called when
NodeAction.go({clearPath: clearPath});
is called, which is at every node whether pop is true or false.
So what do I need to change to get 'poppin?! :) I'm gonna change the container list for starters
From what I see in pather:
// Open chests while pathing popChests: function () { if (!!Config.OpenChests) { Misc.openChests(20); } },
and in misc.js
, openchests is always called if config.openchests, correct?
.. found this in attack.js ffs:
ids = ["chest", "chest3", "weaponrack", "armorstand"];
guess I need to force that to use same list as misc.js?
Haha they wrote 2 openChests function, so yeah you better copy/past the full list there too.
So what do I need to change to get 'poppin?! :) I'm gonna change the container list for starters
Just put Config.OpenChests = 2;
as you said before, it should do the trick.
Thanks 5noop. I copied the container list in the end - i supposed I'll never want to do the reduced list.. unless when in somewhere dangerous lol
cant believe they duplicated that function! Although I guess they had better things to worry about lol
I found this in
misc.js
:This looks as if it lets the bot open more than the standard few objects but doesn't seem to be doing much. Has anyone ever set openchests top
2
instead oftrue
?