I'm using this page as my own personal sandbox :) Please contribute your comments, opinions, and ideas in the talk page.
--PhilmASTErpLus 02:36, 21 June 2010 (UTC)
Moving Datatype Constants to Data Types
"Datatype constants" are literals that begin with a dollar sign($), such as
$effect, etc. Types of data, such as
int, are called Data Types.
That is true, and deserves fixing; but please don't do so in a way that breaks a massive amount of links, ktx. --StDoodle (#1059825) 04:18, 21 June 2010 (UTC)
Heh, that's okay (re: discussion on Datatype Constants). For most pages it isn't a huge issue, but that one... it requires fixing in quite a few places, some of which unfortunately won't be automatically be fixed by redirects during a page move (this seems to happen when some of the links are from templates, which this page has a massive number of). For reference, this wiki has problems with both the "design by committee" philosophy & the "legacy problems" philosophy. Originally, the stuff here was simply copy & pasted from an guide that had been hosted elsewhere, which itself was about 2/3 original material and 1/3 copied from Hola's old reference material. That led to the problem of pages having inappropriate names, as by the time the issue was given thought, they were deeply ingrained in the wiki structure. Then there's the "committee" issue, which resulted in some over-elaborate templates. For the most part, the last issue doesn't present any issues with searching and display, but does up the learning curve for "proper" page editing in some places (mostly on the function pages). In the end, I'm glad to have another person interested in helping; but please, before making any massive-scale (many pages) edits, or moving pages, a discussion would be appreciated. As you now know, there are "methods in the madness" for some of this stuff... ;) Also, if you want to help with getting Datatype Constants corrected, I'd be happy to jot down some notes on what needs to be done in the next day or so. --StDoodle (#1059825) 15:51, 21 June 2010 (UTC)
P.S. User pages such as this are the perfect places for sandboxing & discussion; you can even make sub-pages in your own wiki-space by linking to them from here, with a "/" as the first character of the page name. Since user pages are outside of the normal search parameters, feel free to use them however you wish.
- Add information on directly accessing kolmafia data files--equipment.txt, pulverize.txt, etc. => see file_to_map()
- would go nicely in the pages for Item Management-related functions.
- To anyone who cares: the image above was created in Microsoft PowerPoint. You can get it here.
ASH Quirks and Hacks
- print() displays a blank line when given a string starting with a slash (
/). To prevent this, the text color must be explicitly given. Easy to bypass, but weird.
- "Anonymous" closures: ASH does not seem to accept anonymous closures by default.
However, you can use a workaround with a if-clause.
As for where stuff like this could be used...I'm using it for initializing ASH scripts without creating any unnecessary functions or variables in the "namespace".
- Technically NOT ASH-related, but KoLmafia has difficulty understanding haiku combat. In particular, as of r8611, it cannot detect acquisition of s from the adventure. Therefore you must NOT use a goal and auto-adventure to get one. Let the adventurer beware!