Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to drink antidote potions before Lilith in OrgTorch #2232

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

jmichelsen
Copy link

Having the option to give a little bit of insurance to my smiter against Lilith lets me sleep better at night :)

Also requested in #1913 . Linking them in case that user cares to use the feature

@Tekmat
Copy link

Tekmat commented Mar 4, 2020

i added it and the part to my char config didn't work, So i manually drink them

Config.OrgTorch.AntidotesToChug = 4; // Chug x antidotes before Lilith. Each antidote gives +50 poison res and +10 max poison for 30 seconds. The duration stacks. 4 potions == 2 minutes

@jmichelsen
Copy link
Author

Does your char have enough room for the amount you wanted to chug?

@jmichelsen
Copy link
Author

@Tekmat check the latest commit. It's a fix for a bug that I forgot to push to this repo. This Pr is already merged into the new active kolbot repo at https://github.com/blizzhackers/kolbot

If you pull master there, you'll get this

@kolirio
Copy link

kolirio commented Dec 31, 2020

Hello guys! I found this very usefull and tried to add it for more scripts. So far succesfull to get it to drink antidote potions in any script
ie for BaalAssistant i defined in var
Chug = Config.BaalAssistant.Chug,
chugs;
Then added this function right after the //start comment
```
if (Chug) {
if (Config.BaalAssistant.Chug) {
Town.buyAntidotes(Config.BaalAssistant.Chug);
for (chugs = 0; chugs < Config.BaalAssistant.Chug; chugs++) {
delay(500);
print("glug glug");
let antidote = me.getItem("wms");
if (antidote) {
antidote.interact();
}
}
Town.move("stash");
}
delay(100);
}


Which works great. But then I tried to make it drink thrawing potions, for doing so I defined in Town.js the following function

buyThawings: function (quantity) {
let i,
thawing,
npc = this.initNPC("Shop", "buy Thawing");

	if (!npc) {
		return false;
	}

	thawing = npc.getItem("wms");

	if (!thawing) {
		return false;
	}

	try {
		for (i = 0; i < quantity; i++) {
			thawing.buy(false);
		}
	} catch (e) {
		print(e.message);

		return false;
	}

	return true;
},
Now I went in some bot script: 
Town.doChores();
	if (Chug) {
		Town.buyThawings(Config.DiabloHelper.Chug);
		for (chugs = 0; chugs < Config.DiabloHelper.Chug; chugs++) {
			delay(500);
			print("glug glug");
			let thawing= me.getItem(517);
			if (thawing) {
				thawing.interact();
			}
		}
		Town.move("stash");
	delay(100);
}
But the bot just buys the potions, says "glug glug" a 'chugs' times but doesnt drink the thawing potion.
Also tried with getItem("wms"); and getItem("81") (iirc, saw that number somewhere else...) but none of these work.
If you guys have some idea of what am I missing out i'd very grateful.

		

@Alexflu
Copy link

Alexflu commented Mar 17, 2021

would it be viable to add option for merc as well?
also I noticed it tp's from matrons den to go drink potions then runs back to red portal. shouldn't it reuse its original cast portal to prevent stacking errors?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants