Ash Master Function List

I know "ashref" in CLI will give me a master function list; however, this information doesn't include if the function inputs are optional. Is there another source for a function list that would include what parameters (if any) are optional for all the functions?
 

MCroft

Developer
Staff member
So it sorta does. It does this by showing you all the acceptable variants of a function.
Rich (BB code):
> ashref adv1

boolean adv1( location, int, string )
boolean adv1( location, int )
boolean adv1( location )

You can send adv1 with either a location, a location and an int, or a location, an int, and a string. What those mean can be read in the > ashwiki adv1 documentation.

But the answer to your question is that documentation is here, and it's outdated. I'm looking at doing an update, and contributions are welcome.
 

MCroft

Developer
Staff member
Excellent work finishing the wiki update, and thanks!

Did you script it? Is is a script we could put in the talk page to replace the 13 year old one?
 
I asked because I was in the process of updating the wiki based on the ashref functions, but I realized they didn't tell which variables were optional ones. It appears you have to deduce it based on the different combinations available.

Yes I scripted it. I am in the process of cleaning the code and writing a guide to it.
 
Last edited:

MCroft

Developer
Staff member
The page you linked is the source that registers all the library functions. It is compiled into the executable and is how ash knows what a function is. Looking at in in a particular blob is going to show you the version of that file as of Veracity's fix to get_location();

If you want whatever the latest version is, you could use https://github.com/kolmafia/kolmafi...urceforge/kolmafia/textui/RuntimeLibrary.java

This will be the latest code on the main branch

I'm calling a script from the command line myself, but I didn't write any kind of transform, just compared it to the wiki source. Got about to the Hs and came back to do more and it wasn't necessary.
 
Added the guide to the wiki and linked it to the master function list. Feel free to make any changes or move it or whatever. Wiki editing / making things look pretty is not my strong suit.

I ended up keeping my current method as I figured it had less potential for changes and it was already written and only has one extra step.
 
Last edited:
Top