Slimy scripts!

tripwood

New member
Is it currently possible under the latest build to have Mafia auto use a chamois when the Coated in slime effect arrives at X turns remaining? I've been farming chamois for my clan and it's pretty boring not being able to automate it.

Thanks!
 

Bale

Minion
Almost certainly possible. Use something like...

set betweenBattleScript = chamois.ash
Code:
if(have_effect($effect[Coated in Slime]) < 8)
	visit_url("clan_slimetube.php?action=chamois&pwd");

Hmmm... That's a pretty good idea actually. I'll try this script out and let you know if it actually works.
 
I wrote a quick little script that will use a chamois, and abort if it fails. You can add it to your mood (triggering on gaining Coated in Slime), with this command:

if coated in slime < X; call chamois.ash

(Obviously, X is the minimum number of turns of Coated in Slime that you can survive.)
 

Attachments

  • chamois.ash
    299 bytes · Views: 227

Bale

Minion
Turns out that wasn't the best way to do this. Use this script:
Code:
// Change the 8 on this line to any other number.
if(have_effect($effect[Coated in Slime]) < 8 && have_effect($effect[Coated in Slime]) > 0)
	visit_url("clan_slimetube.php?action=chamois&pwd");

Then set an unconditional mood trigger to "call chamois.ash"

PS. bigevildan's method works perfectly well also. Maybe better.
 

Bale

Minion
Thanks to bigevildan for the CLI command to put into my mood. For what it is worth, the solution I'm currently using is this script:

Code:
if(have_effect($effect[Coated in Slime]) > 0) {
	print("Using chamois.", "blue");
	visit_url("clan_slimetube.php?action=chamois&pwd");
	}
if(have_effect($effect[Coated in Slime]) > 0)
	abort("Failed to use a chamois. You'll need to find some other way to clean yourself up.");

It is called by my mood
Trigger On: When an effect is gained
Check for: Coated in Slime
Command: if Coated in Slime < 8; call chamois.ash

Feel free to change the 8 in that command, to whatever level of "Coated in Slime" that is the most you want to endure.

The script has also been attached below for the sake of those who prefer it that way.
 

Attachments

  • chamois.ash
    281 bytes · Views: 410
Last edited:

matt.chugg

Moderator
i've been thinking about this too, not that i've written much still trying to figure out an optimum strategy, I can get ml +303 currently,(I don't have the right hobo trousers :( or any hardcore/oxy/bm ascension rewards) and as far as I can figure out the way to go is to (assuming the goal is to complete as fast as possible)

farm a few chamois with a lower ml and higher chamois drop rate

up ml and fight the harder ones

repeat

using chamois to remove the effect if it is 5 or below (I can manage to kill with 6 I think) but after that the damage will always be > max hp.

I think a script that did all that would be spoilerish at the moment, so i'll probably wait until mafia can adventure at the tube unaided. (by which I mean, in the zone list!)
 
Last edited:

matt.chugg

Moderator
guess I didn't have to wait long!

build 7436

Date: 2:21:40 AM, Wednesday, June 03, 2009
Message:
Slimy Location, Items, Monsters, Element!

The Slime Tube is now a normal location, although auto-adventuring there
currently requires scripting to use chamoix when appropriate (it's not
expressible in a mood). Both choice adventures are supported.

All currently known slime-related items are supported, except for the moist
sack (which still lacks an ID on the Wiki), although there are almost
certainly more to be discovered.
 

matt.chugg

Moderator
Get Slimy.ash

Will spend one adventure in the tube
will check for slimy effect and remove using chamois if number of turns are less than specified in minslimeturns (default 6)
if failed to remove using chamois and usevipbath==true will take a bath
if at this point the effect is still there it will abort.
if its safe (based on effect to adventure) it will check hp, and figure out how much you will lose in first slime hit based on number of turns and then abort if you don't have enough (it should probably use mafias ability to restore here, but that can be added later)

work in progress.
currently ignores slime resistance in expecteddamage calculation
 

Attachments

  • get slimy.ash
    1.7 KB · Views: 181
Last edited:
For what it is worth, the solution I'm currently using is this script:

Code:
if(have_effect($effect[Coated in Slime]) > 0) {
	print("Using chamois.", "blue");
	visit_url("clan_slimetube.php?action=chamois&pwd");
	}
if(have_effect($effect[Coated in Slime]) > 0)
	abort("Failed to use a chamois. You'll need to find some other way to clean yourself up.");

It is called by my mood
Trigger On: When an effect is gained
Check for: Coated in Slime
Command: if Coated in Slime < 8; call chamois.ash

Thanks to bigevildan for the CLI command to put into my mood.

Ohh, awesome, thanks for these scripts guys. The abort that's called by failure will stop auto-adventuring, right?
 

Bale

Minion
Hmmm... I didn't make it clear in that post, but naturally you can change the 8 to whatever level of Coated in Slime is the most you want to endure. You probably got that, but I want to make it clear.

Ohh, awesome, thanks for these scripts guys. The abort that's called by failure will stop auto-adventuring, right?
Yep, abort will stop auto-adventuring. Glad to help; you have my thanks for all the spading you do.
 

Bale

Minion
Here's a perfected chamois script. It will calculate the expected damage from Covered in Slime based on your slime resistance and level of slime.

It then compares this to your current HP and max HP. If you need healing to survive the slime, it will heal you. If the expected damage is greater than max HP, it will use a chamois. This is guaranteed to use the minimal number of chamois without getting you beaten up (as long as you can kill the slime).

It is called by your mood
Trigger On: When an effect is gained
Check for: Coated in Slime
Command: call chamois.ash
 

Attachments

  • chamois.ash
    1.4 KB · Views: 118
Last edited:

Immelan

New member
As much as I'm sure the other scripts out there work good too, this new script of yours is hands down my favorite. Simple and exactly what I needed because I already am able to have Mafia do the rest of the stuff I need it to do. Thank you.
 
Top