Abridged Dictionary - version 1.3! (last updated May 4)

Tirian

Member
Here's a cute little script that gets and uses the Abridged Dictionary for you. It pulls the elements of the pirate costume out of Hagnk's if necessary and adventures for any missing pieces. In addition, it should complete the meatcar, dinghy, and rusty screwdriver quests if you haven't done those yet, and change you back to the outfit you were wearing at the start of the script.

Edited to add: We're up to version 1.3 of the script. Scroll down for the latest report on it.
 

Attachments

  • dictionary.ash
    4.2 KB · Views: 207
  • microquests.ash
    7.3 KB · Views: 186
  • TirianLib.ash
    17.7 KB · Views: 196

Tirian

Member
Re: Abridged Dictionary

I've been doing a lot of scripting over the past weekend, but it's a bit tricky to keep up with the 7.2 beta testing AND make sure that the scripts are good enough to show off to colleagues. Anyway, here is the first of a few shiny-new scripts.

Buoyed by Veracity's description of the "unequip hat" CLI command, the script now handles the case that you were wearing a part of the pirate outfit before running the script. It unequips all of your accessories in the fear that one of them might be the stuffed shoulder parrot.

Even more excitingly, I figured out how to save custom outfits using CLI, so the script takes a snapshot of what you were wearing at the beginning of the script and puts it back on when you have acquired the unabridged dictionary. If you don't feel like poring through TirianLib.ash to see the command, here it is for you:

inv_equip.php?which=2&action=customoutfit&outfitname=<foo>

I presume that you'll want to use %20's in place of spaces (or maybe +'s, I didn't bother to find out), but perhaps things would be better if you didn't use spaces at all. Deleting custom outfits is beyond the scope of CLI at this phase, so either do that by hand or keep reusing the same outfit name in your scripts. (Mine is "Mafia_QuickChange" -- feel free to use that as long as you don't mind if someone else overwrites it between scripts.)

Finally, the script will complete the Rusty Screwdriver quest if it finds that untinkering didn't give you the bridge like you expected. To be honest, I haven't been through this path of the code yet, since I'm addicted to mushroom wine. So let me know if you try it and don't like it!
 

arrggg

Member
Re: Abridged Dictionary

tried it... didn't work for me. First I didn't have the island unlocked so it bombed.

Also I had the rare case that I had an "Enchanted Eyepatch" that could be untinkered for the eyepatch (the only piece I was missing.)

Then after I had the island, and the outfit it still seemed to not run correctly, it would unequip everything then stop. (and still no abridged dictionary goodness)

Please continue to work on this script, this is one of the places I HATE to do manually.
 

Tirian

Member
Re: Abridged Dictionary

Thanks for the feedback. As you may have guessed, I haven't bothered making the situation very hard on myself, as 90% of my ascensions are softcore runs where I already have the pieces in storage.

When 7.2 is released, I'll be able to do a more pleasant job of handling your equipped items. At the moment, you wouldn't know if you had the parrot in your inventory except by removing all of your accessories, and if you had to do some adventuring afterward to pick up the parrot, then I can see how having no accessories equipped might be a bummer. But Veracity has put some great support for seeing what items you have equipped, so the test to see what items you need will be much less destructive.

I hadn't thought about people using enchanted eyepatches. I'm a moxie whore myself, no matter what class I'm adventuring with. But, yeah, untinkering and retinkering is no problem, so I can add that support as well.

I hope that not having the dirty dinghy did something a little less menacing than "bombing". :) I run a separate script to make the dinghy which is it's own kind of complexity -- heck, if I make it to level 9 without getting beaten up then I probably haven't even made the meatcar yet. :) I haven't experimented with tying all the scripts together because I assumed that the import statement wouldn't play well with others. I'll look into it.
 

Tirian

Member
Re: Abridged Dictionary -- version 1.3! (last updated May 4)

Okay, new version time at the top of the thread. This is pretty major, and I don't have a character of the proper level to test it all out today. Tomorrow for sure, and I know that arrggg will take a swing at it as well.

You'll notice the new library. Microquests is where I'm dumping all my quest stuff and otherwise content-specific stuff. As with TirianLib, you're free to use it for your own stuff as long as you keep it all together. If you do use Microquests, you'll need to also use TirianLib and import BOTH of them from whatever script you're writing. (ASH doesn't currently have an #ifndefine pragma, and having the same library imported by two scripts is a fatal bug.) On the plus side, Microquests does have things like the meatcar, screwdriver, and dinghy quests written already as well as a few others and plenty more to come.

The dictionary quest currently takes care of all of the pre-quest stuff like making sure that you've got the dinghy to make it to the island. Also, as requested, it will make some effort to untinker and retinker an enchanted eyepatch for the quest.

A few known issues:

- The meatcar quest is a little delicate at the moment. It assumes that you either have the last two pieces in your inventory or in Hagnk's. I am increasingly unsatisfied with that, especially since pulling the meat engine is a waste if you ascended under a muscle sign. You're probably best off making sure that you have the car before you start for now.

- The script saves your outfit and puts it back on you if you need to adventure for more pieces. I'm a little scared of what would happen if you were wearing an enchanted eyepatch and didn't have at least one of the other pieces. I figure it would untinker your eyepatch and then get upset because it couldn't put on your saved outfit. Again, be gentle for now if you want to ensure good workage. :)
 

arrggg

Member
Doh! --
No closing '"' found at line 181 in file microquests.ash *But I fixed that*
No closing '"' found at line 45 in file scripts\dictionary.ash *But I fixed that*
')' Expected at line 73 in file scripts\dictionary.ash *Couldn't find where to fix fo I took out the the whole IF statement*

from the CLI
Code:
Need to visit the hermit. 
[31137 scroll] does not match anything in the item database. 
Beginning 1 turnips to Sewer: Sewer With Clovers... 
Visit to Sewer: Sewer With Clovers in progress... 
Ran out of ten-leaf clovers. 
Not enough resources to fish for trinkets.

Had plenty of money... but no clovers.
Could it:
Convert all but 1000(and change) to dense meat stacks, try to buy one from the mall, check for a clover, if I don't have one do normal sewer?
 

Tirian

Member
Huh. I am trying to play nice with my sewer-fishing script to allow it to handle lucky fishing, but it still doesn't seem like it should be following that path in the logic. Just maybe $location[sewer] is matching the lucky sewer adventure. :'( But I made overdrastic changes just to be on the safe side:

Code:
boolean sewer_fishing(boolean feeling_lucky_punk)
{
	item gum = $item[chewing gum on a string];

	while (worthless_amount()==0)
	{
		if (item_amount(gum)==0) if (!buy(1,gum)) return false;
		if (!adventure(1, $location[unlucky sewer])) return false;
	}
	return true;
}

See if replacing the code already in TirianLib with this takes care of the problem.
 

arrggg

Member
just ran it again... go a little worries when it hit 25 turns at the degrassi knoll, but it was just RNG screwage....

Works good.
 

Attachments

  • dictionary.ash
    4 KB · Views: 111
  • microquests.ash
    7.3 KB · Views: 109

Jaxia

New member
I get this error when I try to run the micro script:

undefined reference zodiac_to_stat at line 74 in file scripts\microquests.ash

I get this error when I try to run the dictionary script:

undefined reference shore at line 187 in file microquests.ash

Any ideas?
Thanks!
 

Nightmist

Member
[quote author=Jaxia link=topic=92.msg2514#msg2514 date=1160687991]
I get this error when I try to run the micro script:
[/quote]
Make sure you also downloaded the "TirianLib.ash" file (in the first post).
 

Jaxia

New member
I have several of Tirian's scripts, so there are different version of that file around the site. It's hard for me to tell which one is the most recent.

I will try running the scripts with the one in this post. Hopefully it will not mess up the other scripts.

Thanks for your help!
 

Nightmist

Member
[quote author=Jaxia link=topic=92.msg2523#msg2523 date=1160756285]
Hopefully it will not mess up the other scripts.
[/quote]
Perhaps you should put them in separate folders. (You would need to edit any of the "import<filepath>;" commands in the ash scripts but apart from that it shouldn't require any editing and all the imports will be in the first few lines of the script.)

Adding it to a "Abridged Dictionary" folder in the scripts folder would mean simply changing the currently existing "import<filename>;" to something like "import<Abridged Dictionary\filename>;"
 

Nightmist

Member
[quote author=Jaxia link=topic=92.msg2566#msg2566 date=1161231248]
The dictionary script works for me now, but the micro script still doesn't. Any ideas?
[/quote]
The micro script doesn't do anything by itself (Infact it even has its "import" of the Lib file commented out).
If the dictionary script works, then its all good, it imports the micro script before running.
 

Jaxia

New member
Ahh! Thanks for the clarification. Since I read that it does handle a few quests, I thought I had to run it on its own.
 
Top