Difference between revisions of "Miscellaneous Functions"

From Kolmafia
Jump to navigation Jump to search
(Add "gCLI Command Functions" section)
 
(226 intermediate revisions by more than 100 users not shown)
Line 1: Line 1:
[http://sub-sibl.ifrance.com/web/giochini-on/ giochini on line gratis] [http://chool-karlik.ifrance.com/new/vuego-scan/ vuego scan] [http://kuet-enigma.ifrance.com/new/suse-linux4.htm suse linux 9 2] [http://kuet-enigma.ifrance.com/new/sector-orologio.htm sector orologio] [http://kuet-enigma.ifrance.com/new/thermaltake-silent5.htm thermaltake silent purepower 680] [http://sub-sibl.ifrance.com/web/arriva-tazio/ arriva tazio] [http://zar-serwantik.ifrance.com/view/sbloccare-il/ sbloccare il nec e228] [http://alex-cherkes.ifrance.com/small/nikon-en11/ nikon en el5] [http://ati-life.ifrance.com/small/tessuto-sociale.htm tessuto sociale] [http://kuet-enigma.ifrance.com/new/masterizzatore-dvd90.htm masterizzatore dvd pioneer slim] [http://chool-karlik.ifrance.com/new/vanishing-point/ vanishing point] [http://sub-sibl.ifrance.com/web/hilton/ hilton] [http://alex-cherkes.ifrance.com/index1_1000.html map] [http://alex-cherkes.ifrance.com/small/i-pacchi/ i pacchi vostri] [http://ati-life.ifrance.com/small/milano-calibro.htm milano calibro 9] [http://chool-karlik.ifrance.com/new/calcinato/ calcinato] [http://alex-cherkes.ifrance.com/small/francese/ francese] [http://zar-serwantik.ifrance.com/view/auguri-frasi/ auguri frasi] [http://sub-sibl.ifrance.com/web/agriturismo-ferrara/ agriturismo ferrara] [http://sub-sibl.ifrance.com/index0_250.html url] [http://alex-cherkes.ifrance.com/small/copertina-buoni4/ copertina buoni o cattivi 2004] [http://alex-cherkes.ifrance.com/small/trust-hires/ trust hires wb 3400t] [http://zar-serwantik.ifrance.com/view/ramstein-living/ ramstein living in amerika] [http://alex-cherkes.ifrance.com/small/ina-assitalia1/ ina assitalia roma] [http://kuet-enigma.ifrance.com/new/valentina-andreatini.htm valentina andreatini] [http://alex-cherkes.ifrance.com/small/forzare-altrui/ forzare altrui volonta sinonimo] [http://alex-cherkes.ifrance.com/small/www-singole/ www singole it] [http://alex-cherkes.ifrance.com/small/christine-/ christine  la porno storia di christine] [http://zar-serwantik.ifrance.com/view/siti-prono/ siti prono gratuiti] [http://kuet-enigma.ifrance.com/index2_500.html link] [http://chool-karlik.ifrance.com/new/verve-remixed/ verve remixed 2] [http://alex-cherkes.ifrance.com/small/mutuo-sposi/ mutuo sposi] [http://chool-karlik.ifrance.com/new/televisore-irradio/ televisore irradio] [http://kuet-enigma.ifrance.com/new/richard-ashcroft2.htm richard ashcroft check the meaning (single)] [http://sub-sibl.ifrance.com/web/scarpe-donna21/ scarpe donna con tacco alto sergio rossi] [http://ati-life.ifrance.com/small/plavis.htm plavis] [http://chool-karlik.ifrance.com/new/linksys-modem2/ linksys modem] [http://kuet-enigma.ifrance.com/new/remove.htm remove] [http://sub-sibl.ifrance.com/web/liberatorie-modulistica/ liberatorie modulistica] [http://kuet-enigma.ifrance.com/new/garmin-v1.htm garmin v de] [http://alex-cherkes.ifrance.com/small/diritto-tributario/ diritto tributario] [http://sub-sibl.ifrance.com/web/vulcan/ vulcan] [http://kuet-enigma.ifrance.com/new/pannolini-piscina.htm pannolini piscina] [http://sub-sibl.ifrance.com/web/adsl-ethernet8/ adsl ethernet usb] [http://chool-karlik.ifrance.com/new/musica-siriana/ musica siriana] [http://zar-serwantik.ifrance.com/view/filatura/ filatura] [http://alex-cherkes.ifrance.com/small/diva-futura4/ diva futura] [http://kuet-enigma.ifrance.com/new/scaricare-canzone1.htm scaricare canzone] [http://alex-cherkes.ifrance.com/index1_1000.html map] [http://zar-serwantik.ifrance.com/view/note-buyer/ note buyer] [http://chool-karlik.ifrance.com/new/ringo-star/ ringo star] [http://alex-cherkes.ifrance.com/small/nightshift/ nightshift] [http://zar-serwantik.ifrance.com/index2_1000.html site] [http://alex-cherkes.ifrance.com/small/phakic-refractive/ phakic refractive lens] [http://chool-karlik.ifrance.com/new/desktop-pentium2/ desktop pentium] [http://alex-cherkes.ifrance.com/small/tainted-love/ tainted love] [http://kuet-enigma.ifrance.com/new/profumo-occitane.htm profumo occitane] [http://sub-sibl.ifrance.com/web/corporate-housing1/ corporate housing san diego] [http://kuet-enigma.ifrance.com/new/grand-barrys.htm grand barrys] [http://zar-serwantik.ifrance.com/view/gioco-festa/ gioco festa bambino] [http://alex-cherkes.ifrance.com/small/carolyn-s/ carolyn s] [http://chool-karlik.ifrance.com/new/heater-graham/ heater graham] [http://alex-cherkes.ifrance.com/small/machine-per/ machine per salumi] [http://kuet-enigma.ifrance.com/ kuet-enigma.ifrance.com] [http://zar-serwantik.ifrance.com/view/cerco-ballerino/ cerco ballerino] [http://kuet-enigma.ifrance.com/ kuet-enigma.ifrance.com] [http://kuet-enigma.ifrance.com/new/aciclovir-eg2.htm aciclovir eg crema 10 g] [http://ati-life.ifrance.com/small/lifted-by.htm lifted by love] [http://chool-karlik.ifrance.com/new/usb15/ usb 54] [http://ati-life.ifrance.com/small/nude-in9.htm nude in pubblic] [http://alex-cherkes.ifrance.com/small/jaime-pressley/ jaime pressley] [http://alex-cherkes.ifrance.com/small/mail-aziende/ mail aziende taranto] [http://kuet-enigma.ifrance.com/new/biciclette-atala.htm biciclette atala] [http://alex-cherkes.ifrance.com/small/baffo/ baffo] [http://ati-life.ifrance.com/small/le-mantellate.htm le mantellate] [http://chool-karlik.ifrance.com/new/webcam-philips/ webcam philips toucam ii pro] [http://kuet-enigma.ifrance.com/new/uccisione-ostaggio4.htm uccisione ostaggio americano] [http://zar-serwantik.ifrance.com/view/gentiana/ gentiana] [http://ati-life.ifrance.com/small/prestito-emilia1.htm prestito emilia] [http://alex-cherkes.ifrance.com/small/senza-alcuna/ senza alcuna difesa una donna sola] [http://alex-cherkes.ifrance.com/small/mandra-floare/ mandra floare trandafir] [http://alex-cherkes.ifrance.com/small/nicola-savino3/ nicola savino imitazioni] [http://sub-sibl.ifrance.com/index1_500.html index] [http://ati-life.ifrance.com/small/sanyo-sanyo.htm sanyo sanyo] [http://chool-karlik.ifrance.com/new/piumino-giubbino/ piumino giubbino] [http://alex-cherkes.ifrance.com/small/gradi-militari/ gradi militari] [http://alex-cherkes.ifrance.com/small/car-charger4/ car charger asus] [http://ati-life.ifrance.com/small/provincia-asti.htm provincia asti] [http://ati-life.ifrance.com/small/poi.htm poi] [http://alex-cherkes.ifrance.com/small/agente/ agente 007] [http://sub-sibl.ifrance.com/web/video-musicales/ video musicales] [http://chool-karlik.ifrance.com/new/nemuro/ nemuro] [http://kuet-enigma.ifrance.com/index0_250.html index] [http://sub-sibl.ifrance.com/web/fate-of/ fate of awakening love] [http://alex-cherkes.ifrance.com/small/noleggio-molise/ noleggio molise] [http://kuet-enigma.ifrance.com/new/nokia-404.htm nokia 7610 e tomtom] [http://sub-sibl.ifrance.com/web/boris-novkovic1/ boris novkovic] [http://alex-cherkes.ifrance.com/small/juegos-flash/ juegos flash xxx] [http://chool-karlik.ifrance.com/new/osanna-mid/ osanna mid] [http://kuet-enigma.ifrance.com/new/alibaba.htm alibaba] [http://www.hiidenkivenpaivakoti.fi/help/new/oepodd.html Noleggio auto autista] [http://www.startonlineweb.com/help/new/hxsvpf.html Geotermia] [http://www.ccrs.uzh.ch/user/root/maqmgv.html Porno alena seredova] [http://www.worthwhilehosting.com/banners/auto/ajngpc.html Club hardball] [http://www.worthwhilehosting.com/banners/auto/ubsenh.html Degustazione vino castello] [http://www.ccrs.uzh.ch/user/root/lkqjjm.html Figa pelosa video] [http://www.ccrs.uzh.ch/user/root/ndedbf.html Chat libero] [http://www.ccrs.uzh.ch/user/root/gxegcg.html Visura protesto gratis] [http://www.worthwhilehosting.com/banners/auto/ouhixo.html Cernobbio] [http://www.hiidenkivenpaivakoti.fi/help/new/wltajb.html Sapphic erotica evelyn deny] [http://www.ccrs.uzh.ch/user/root/fupebg.html Escort trans] [http://www.ccrs.uzh.ch/user/root/mesonl.html Claudia antonelli video porno] [http://www.worthwhilehosting.com/banners/auto/nacpvt.html Collegare ccd microscopio] [http://www.hiidenkivenpaivakoti.fi/help/new/jmwwap.html Chat mtv] [http://www.hiidenkivenpaivakoti.fi/help/new/aflriw.html Albergo losanna] [http://www.startonlineweb.com/help/new/hngobo.html Ginecologo on line] [http://www.ccrs.uzh.ch/user/root/uxtqkn.html Carta divinazione] [http://www.worthwhilehosting.com/banners/auto/ldkefd.html Unipol banca] [http://www.worthwhilehosting.com/banners/auto/lqclol.html Tasso fisso] [http://www.worthwhilehosting.com/banners/auto/vixiuk.html Cytherea falls] [http://www.startonlineweb.com/help/new/drpahj.html Sexi coppie] [http://www.ccrs.uzh.ch/user/root/qjhppl.html Sandalo uomo] [http://www.startonlineweb.com/help/new/nepocm.html Campeggio di maratea] [http://www.worthwhilehosting.com/banners/auto/lwnrwe.html Occasione auto] [http://www.ccrs.uzh.ch/user/root/nplvfr.html Campeggio versilia] [http://www.ccrs.uzh.ch/user/root/genrpl.html Kurenai hentai porno] [http://www.hiidenkivenpaivakoti.fi/help/new/tmkgrv.html Foto mignotte] [http://www.startonlineweb.com/help/new/qdwkvm.html Creare suoneria pe cellulare] [http://www.hiidenkivenpaivakoti.fi/help/new/fimsjf.html Spyware nuker] [http://www.ccrs.uzh.ch/user/root/exuagm.html Video orgasmi] [http://www.hiidenkivenpaivakoti.fi/help/new/hmndfw.html Comune di legnano] [http://www.startonlineweb.com/help/new/renrie.html Storia pallacanestro] [http://www.startonlineweb.com/help/new/xifqjd.html Frosinone calcio] [http://www.worthwhilehosting.com/banners/auto/tipcnv.html Lottoced] [http://www.worthwhilehosting.com/banners/auto/uwvodb.html Katy saunders] [http://www.worthwhilehosting.com/banners/auto/ologps.html Cassano] [http://www.hiidenkivenpaivakoti.fi/help/new/tbqavb.html Prestito ascoli] [http://www.worthwhilehosting.com/banners/auto/duwnhv.html Anal dildo sex] [http://www.ccrs.uzh.ch/user/root/cdwhhd.html Free sat adsl] [http://www.worthwhilehosting.com/banners/auto/rkthls.html Feto] [http://www.worthwhilehosting.com/banners/auto/warxki.html Hotel capitol bucarest] [http://www.startonlineweb.com/help/new/vgncij.html Miss italia] [http://www.hiidenkivenpaivakoti.fi/help/new/deprxb.html Medicina alternative] [http://www.startonlineweb.com/help/new/srooac.html Villaggi ischia] [http://www.worthwhilehosting.com/banners/auto/gfmdfs.html Bambola] [http://www.ccrs.uzh.ch/user/root/okbtwf.html Inviare mms da internet] [http://www.worthwhilehosting.com/banners/auto/glxitf.html Emelunga] [http://www.startonlineweb.com/help/new/vljoim.html Denise pipitone] [http://www.worthwhilehosting.com/banners/auto/bqhojc.html Franchino] [http://www.worthwhilehosting.com/banners/auto/hcfnus.html Rod stewart] [http://www.worthwhilehosting.com/banners/auto/tkxaca.html Squirting%2bcytherea] [http://www.hiidenkivenpaivakoti.fi/help/new/lfxixr.html Testi gianni vezzosi] [http://www.hiidenkivenpaivakoti.fi/help/new/ifsbff.html Sesso coppia] [http://www.worthwhilehosting.com/banners/auto/hxoodv.html Donne grasse it] [http://www.hiidenkivenpaivakoti.fi/help/new/jluvgq.html Cercasi fidanzata palermo] [http://www.startonlineweb.com/help/new/hdrbst.html Filmati porno on line] [http://www.ccrs.uzh.ch/user/root/jniucg.html Poltrona gonfiabili] [http://www.hiidenkivenpaivakoti.fi/help/new/cjcxnc.html Ortensia] [http://www.worthwhilehosting.com/banners/auto/wmmfua.html Ragazze nude] [http://www.worthwhilehosting.com/banners/auto/ejqbld.html Mr brico] [http://www.worthwhilehosting.com/banners/auto/fdecar.html Cielo stellato] [http://www.ccrs.uzh.ch/user/root/dqpmwt.html Valentino finanza online] [http://www.ccrs.uzh.ch/user/root/pwruts.html Assicurazione generali auto] [http://www.hiidenkivenpaivakoti.fi/help/new/xiejna.html Prenotazioni hotel sestriere] [http://www.hiidenkivenpaivakoti.fi/help/new/wjjlwg.html Buy ultram] [http://www.startonlineweb.com/help/new/spjmhb.html Emulatore nintendo ds] [http://www.startonlineweb.com/help/new/tbdiru.html Pronostico totocalcio ultimo concorso] [http://www.hiidenkivenpaivakoti.fi/help/new/clcqkq.html Pps sexi] [http://www.worthwhilehosting.com/banners/auto/quoiht.html Progressive slot] [http://www.worthwhilehosting.com/banners/auto/qeieak.html Acquisto mobili ufficio usati] [http://www.startonlineweb.com/help/new/iaadbk.html Troiette xxx] [http://www.worthwhilehosting.com/banners/auto/drgrlf.html Nave crociera msc] [http://www.startonlineweb.com/help/new/pfawfd.html Imballaggio industriali] [http://www.startonlineweb.com/help/new/letseq.html Hotel arbatax] [http://www.worthwhilehosting.com/banners/auto/ivthxa.html Donne mature con ragazzi] [http://www.hiidenkivenpaivakoti.fi/help/new/lludhk.html Prestito on line] [http://www.hiidenkivenpaivakoti.fi/help/new/wmkbud.html Racchetta tennis head] [http://www.ccrs.uzh.ch/user/root/wgushu.html Cucine componibili] [http://www.hiidenkivenpaivakoti.fi/help/new/golgmq.html Corso massaggio bologna bologna bologna] [http://www.worthwhilehosting.com/banners/auto/onvivt.html Hawai big island cose fare] [http://www.startonlineweb.com/help/new/njtinh.html Dvd lupin] [http://www.worthwhilehosting.com/banners/auto/jhuntp.html Ventotene it] [http://www.hiidenkivenpaivakoti.fi/help/new/kwigox.html Panasonic centralini] [http://www.hiidenkivenpaivakoti.fi/help/new/auvlkn.html Video gallery sesso bizzarro] [http://www.worthwhilehosting.com/banners/auto/ftuqbt.html Pianoforte] [http://www.worthwhilehosting.com/banners/auto/bvbmpx.html Cracovia viaggi gruppo] [http://www.startonlineweb.com/help/new/jvahio.html Testo canzone tranquillo dei sottotono] [http://www.hiidenkivenpaivakoti.fi/help/new/enfqpu.html Pompino video] [http://www.ccrs.uzh.ch/user/root/qhqqgm.html Vendita bicicletta] [http://www.ccrs.uzh.ch/user/root/hdcptq.html Sismi] [http://www.worthwhilehosting.com/banners/auto/jwcdxk.html foto di giovani gay nudi] [http://www.hiidenkivenpaivakoti.fi/help/new/plleao.html Phantom f12] [http://www.startonlineweb.com/help/new/huapct.html Volo soggiorno tunisia] [http://www.ccrs.uzh.ch/user/root/gpwfid.html Testi canzoni luca dirisio] [http://www.ccrs.uzh.ch/user/root/vpbvil.html Rimini trattoria tonino lurido] [http://www.ccrs.uzh.ch/user/root/aljurd.html Haiducii midi file] [http://www.worthwhilehosting.com/banners/auto/cevlop.html Fioristi] [http://www.startonlineweb.com/help/new/betsee.html Albergo con centro congresso firenze] [http://www.ccrs.uzh.ch/user/root/hgjmqa.html Cofanetto pantera rosa] [http://www.startonlineweb.com/help/new/rnnwxk.html Gestione tornei calcio] == Part 7 - Miscellaneous ==
+
{{TOCright}}
<p><em>Mostly internal stuff. Some good for everyone, some only for ASH wizards.</em></p>
+
== Chat Functions ==
 +
{{Flink|void|chat_clan|string}}
 +
{{Flink|void|chat_clan|string|string|desc=Sends a message to clan chat.}}
 +
{{Flink|void|chat_macro|string|desc=Submits a chat macro to KoL.}}
 +
{{Flink|void|chat_notify|string|string|desc=Sends a notification to the player's own chat.}}
 +
{{Flink|void|chat_private|string|string|desc=Sends a private message to another player.}}
 +
{{Flink|boolean|is_online|string|desc=Check to see if a player is online.}}
 +
{{Flink|boolean [string]|who_clan|desc=Returns a list of whom is in your clan and if they are in chat.}}
 +
{{Flink|boolean|can_faxbot|monster|desc=Check to see if a monster can be faxed.}}
 +
{{Flink|boolean|faxbot|monster|desc=Attempts to receive a fax of a given monster.}}
  
<p><strong>void print( string helloworld )</strong><br />
+
== Debugging Functions ==
Prints the given string to the graphical CLI window and to the status line of the main Adventuring window</p>
+
{{Flink|void|disable|string|desc=Disables the specified function.}}
 +
{{Flink|void|enable|string|desc=Enables the specified function.}}
 +
{{Flink|buffer|load_html|string|desc=Works like visit_url(), but for debugging.}}
 +
{{Flink|string|make_url|string|boolean|boolean|desc=Crafts the URL to visit.}}
  
<p><strong>boolean cli_execute( string command )</strong><br />
+
== File Input/Output Functions ==
Executes the given command as if it were entered into the graphical CLI window. This can be used for CLI commands or, if you
+
{{FunctionEmbed|buffer_to_file|format=signature|desc=yes}}
 +
{{FunctionEmbed|file_to_array|format=signature|desc=yes}}
 +
{{FunctionEmbed|file_to_buffer|format=signature|desc=yes}}
 +
{{Flink|boolean|file_to_map|string|aggregate|desc=Loads a map from a tab-delimited text file.}}
 +
{{Flink|boolean|map_to_file|aggregate|string|desc=Saves a map to a tab-delimited text file.}}
 +
 
 +
== gCLI Command Functions ==
 +
{{FunctionEmbed|cli_execute|format=signature|desc=yes}}
 +
{{FunctionEmbed|cli_execute_output|format=signature|desc=yes}}
 +
 
 +
== Map Management Functions ==
 +
''Note: Information about maps (including creating, assigning, and removing keys, can be found at [[Data Structures#Maps|Map Data Structures]].''
 +
 
 +
{{Flink|int|count|aggregate|desc=Returns the number of defined keys for the specified aggregate.}}
 +
{{Flink|void|clear|aggregate|desc=Removes all keys from the specified aggregate.}}
 +
 
 +
== Time Functions ==
 +
{{Flink|string|format_date_time|string|string|string|desc=Reformats dates.}}
 +
{{Flink|int|gameday_to_int|desc=Returns the current KoL date as an integer.}}
 +
{{Flink|string|gameday_to_string|desc=Returns the current KoL date as a string.}}
 +
{{Flink|int|gametime_to_int|desc=Returns the current KoL time in ms as an integer.}}
 +
{{Flink|string|now_to_string|string|desc=Returns current local time/date in SimpleDateFormat format.}}
 +
{{Flink|string|time_to_string|desc=Returns the current local time in HH:mm:ss z format.}}
 +
{{Flink|string|today_to_string|desc=Returns the current local day in ISO format.}}
 +
 
 +
== SVN Functions ==
 +
''There is much additional information in the [[SVN Primer]]''.
 +
{{Flink|boolean|svn_exists|string|desc=Returns true if a valid working copy named projectname exists in the svn/ folder.}}
 +
{{Flink|boolean|svn_at_head|string|desc=Returns true if projectname exists, is a valid working copy, and is currently at the same revision number as the repository.}}
 +
{{Flink|record|svn_info|string|desc=Returns a record containing additional information about the given projectname: svnurl, last author, last revision, last change date.}}
 +
 
 +
== User Interaction ==
 +
{{Flink|void|print|string|{{opt|string}}|desc=Prints to CLI and status line of Adventuring window, optionally in a specified color.}}
 +
{{Flink|void|print_html|string|desc=Prints to CLI, parsing any included html.}}
 +
{{Flink|void|logprint|string|desc=Prints to the session log.}}
 +
{{Flink|void|wait|int}}
 +
{{Flink|void|waitq|int|desc=Sleeps for the specified number of seconds.}}
 +
{{Flink|boolean|user_confirm|string|desc=Allows user input in Y/N format.}}
 +
 
 +
== Property Functions ==
 +
{{Flink|boolean [string]|get_all_properties|string|boolean|desc=Returns a map of all user or global properties.}}
 +
{{FunctionEmbed|property_exists|format=signature|desc=yes}}
 +
{{FunctionEmbed|property_has_default|format=signature|desc=yes}}
 +
{{FunctionEmbed|property_default_value|format=signature|desc=yes}}
 +
{{Flink|string|get_property|string}}
 +
{{Flink|string|get_property|string|boolean|desc=Gets a global or user preference as appropriate.}}
 +
{{Flink|void|set_property|string|string|desc=Sets a global or user preference as appropriate.}}
 +
{{FunctionEmbed|remove_property|format=signature|desc=yes}}
 +
{{FunctionEmbed|rename_property|format=signature|desc=yes}}
 +
 
 +
== Other Functions ==
 +
{{FunctionEmbed|abort|format=signature|desc=yes}}
 +
{{FunctionEmbed|all_monsters_with_id|format=signature|desc=yes}}
 +
{{Flink|void|batch_open|desc=Used to mark the beginning of a block of functions to operate in batch mode (see page for {{f|batch_close}} for details).}}
 +
{{Flink|boolean|batch_close|desc=Used to mark the end of a block of functions to operate in batch mode (see page for details).}}
 +
{{Flink|int|get_revision|desc=Returns the current KoLmafia revision number.}}
 +
{{Flink|string|get_version|desc=Returns the most recent KoLmafia version.}}
 +
{{Flink|string|get_player_id|string|desc=Returns the user id number of a given player.}}
 +
{{FunctionEmbed|is_dark_mode|format=signature|desc=yes}}
 +
{{Flink|string|to_json|aggregate|desc=Converts a simple aggregate into JSON.}}
 +
 
 +
Additional functions that are considered not really to be ash functions are available in [[Miscellaneous ASH Features#Special Syntax Functions|Misc ASH Features]]
 +
 
 +
[[Category:Scripting]]

Latest revision as of 14:55, 23 December 2020

Chat Functions

void chat_clan( string )

void chat_clan( string, string )

Sends a message to clan chat.

void chat_macro( string )

Submits a chat macro to KoL.

void chat_notify( string, string )

Sends a notification to the player's own chat.

void chat_private( string, string )

Sends a private message to another player.

boolean is_online( string )

Check to see if a player is online.

boolean [string] who_clan()

Returns a list of whom is in your clan and if they are in chat.

boolean can_faxbot( monster )

Check to see if a monster can be faxed.

boolean faxbot( monster )

Attempts to receive a fax of a given monster.


Debugging Functions

void disable( string )

Disables the specified function.

void enable( string )

Enables the specified function.

buffer load_html( string )

Works like visit_url(), but for debugging.

string make_url( string, boolean, boolean )

Crafts the URL to visit.


File Input/Output Functions

boolean buffer_to_filebuffer, string )

Saves a buffer to a text file. Returns true on success, false on failure.

string [int] file_to_arraystring )

Reads data from a text file and returns a map of strings containing each line.

buffer file_to_bufferstring )

Loads the entire contents of a text file into a buffer.

boolean file_to_map( string, aggregate )

Loads a map from a tab-delimited text file.

boolean map_to_file( aggregate, string )

Saves a map to a tab-delimited text file.


gCLI Command Functions

boolean cli_executestring )

Executes a string as a gCLI command. Returns true on success, false on failure.

string cli_execute_outputstring )

Executes a gCLI command, capturing and returning the gCLI output.

Map Management Functions

Note: Information about maps (including creating, assigning, and removing keys, can be found at Map Data Structures.

int count( aggregate )

Returns the number of defined keys for the specified aggregate.

void clear( aggregate )

Removes all keys from the specified aggregate.


Time Functions

string format_date_time( string, string, string )

Reformats dates.

int gameday_to_int()

Returns the current KoL date as an integer.

string gameday_to_string()

Returns the current KoL date as a string.

int gametime_to_int()

Returns the current KoL time in ms as an integer.

string now_to_string( string )

Returns current local time/date in SimpleDateFormat format.

string time_to_string()

Returns the current local time in HH:mm:ss z format.

string today_to_string()

Returns the current local day in ISO format.


SVN Functions

There is much additional information in the SVN Primer.

boolean svn_exists( string )

Returns true if a valid working copy named projectname exists in the svn/ folder.

boolean svn_at_head( string )

Returns true if projectname exists, is a valid working copy, and is currently at the same revision number as the repository.

record svn_info( string )

Returns a record containing additional information about the given projectname: svnurl, last author, last revision, last change date.


User Interaction

void print( string, [string] )

Prints to CLI and status line of Adventuring window, optionally in a specified color.

void print_html( string )

Prints to CLI, parsing any included html.

void logprint( string )

Prints to the session log.

void wait( int )

void waitq( int )

Sleeps for the specified number of seconds.

boolean user_confirm( string )

Allows user input in Y/N format.


Property Functions

boolean [string] get_all_properties( string, boolean )

Returns a map of all user or global properties.

boolean property_existsstring, boolean? )

Checks whether a property exists.

boolean property_has_defaultstring )

Checks if a property has a built-in default value.

string property_default_valuestring )

Returns the default value of a property, or an empty string if a default value does not exist.

string get_property( string )

string get_property( string, boolean )

Gets a global or user preference as appropriate.

void set_property( string, string )

Sets a global or user preference as appropriate.

string remove_propertystring, boolean? )

Removes or resets a property and returns its previous value.

boolean rename_propertystring, string )

Renames a property. Returns true on success, false on failure.

Other Functions

void abortstring? )

Immediately halts the current script and all queued functions.

boolean [monster] all_monsters_with_id()

Returns a map of all monsters that have a non-zero monster ID.

void batch_open()

Used to mark the beginning of a block of functions to operate in batch mode (see page for batch_close() for details).

boolean batch_close()

Used to mark the end of a block of functions to operate in batch mode (see page for details).

int get_revision()

Returns the current KoLmafia revision number.

string get_version()

Returns the most recent KoLmafia version.

string get_player_id( string )

Returns the user id number of a given player.

boolean is_dark_mode()

Checks if the current KoLmafia theme is dark mode.

string to_json( aggregate )

Converts a simple aggregate into JSON.


Additional functions that are considered not really to be ash functions are available in Misc ASH Features