<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.kolmafia.us/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Theraze</id>
	<title>Kolmafia - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.kolmafia.us/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Theraze"/>
	<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Special:Contributions/Theraze"/>
	<updated>2026-04-25T03:19:46Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.44.0</generator>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Gametime_to_int&amp;diff=7474</id>
		<title>Gametime to int</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Gametime_to_int&amp;diff=7474"/>
		<updated>2011-07-09T16:54:50Z</updated>

		<summary type="html">&lt;p&gt;Theraze: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|gametime_to_int}}{{&lt;br /&gt;
#vardefine:return_type|int}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description=Returns the current KoL game time using milliseconds since rollover.|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Sample 1|&lt;br /&gt;
description=This code will tell you how many ms it took to list the gCLI commands.|&lt;br /&gt;
code=&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
int starttime = gametime_to_int();&lt;br /&gt;
CLI_EXECUTE(&amp;quot;help&amp;quot;);&lt;br /&gt;
print(&amp;quot;It took &amp;quot;+(gametime_to_int()-starttime)+&amp;quot; ms to list all gCLI commands.&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
&lt;br /&gt;
code2={{CodeSample|&lt;br /&gt;
title=Code Sample 2|&lt;br /&gt;
description=This code will tell you how many ms it has been since KoL&#039;s official rollover time.|&lt;br /&gt;
code=&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
print(&amp;quot;It has been &amp;quot;+gametime_to_int()+&amp;quot; ms since the rollover began.&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
&lt;br /&gt;
code3={{CodeSample|&lt;br /&gt;
title=Code Sample 3|&lt;br /&gt;
description=This code will tell you long since KoL&#039;s official rollover time began without hitting the server.|&lt;br /&gt;
code=&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
print(&amp;quot;It has been &amp;quot;+(gametime_to_int() / (86400000 / 24)) + &amp;quot;:&amp;quot; + ((gametime_to_int() / (86400000 / 1440)) % 60)+&amp;quot; since the rollover began.&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
&lt;br /&gt;
code4={{CodeSample|&lt;br /&gt;
title=Code Sample 4|&lt;br /&gt;
description=This code will tell you how long until KoL&#039;s next official rollover time.|&lt;br /&gt;
code=&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
print(&amp;quot;You have &amp;quot;+(23 - (gametime_to_int() / (86400000 / 24)))+&amp;quot;:&amp;quot;+(59 - ((gametime_to_int() / (86400000 / 1440)) % 60))+&amp;quot; left until rollover begins.&amp;quot;)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
{{SeeAlso|today_to_string|gameday_to_int|gameday_to_string|time_to_string|now_to_string}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous Functions]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Miscellaneous_Functions&amp;diff=1177</id>
		<title>Miscellaneous Functions</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Miscellaneous_Functions&amp;diff=1177"/>
		<updated>2011-07-09T16:54:20Z</updated>

		<summary type="html">&lt;p&gt;Theraze: /* Time Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{TOCright}}&lt;br /&gt;
== Chat Functions ==&lt;br /&gt;
{{Flink|void|chat_clan|string}}&lt;br /&gt;
{{Flink|void|chat_clan|string|string|desc=Sends a message to clan chat.}}&lt;br /&gt;
{{Flink|void|chat_macro|string|desc=Submits a chat macro to KoL.}}&lt;br /&gt;
{{Flink|void|chat_notify|string|string|desc=Sends a notification to the player&#039;s own chat.}}&lt;br /&gt;
{{Flink|void|chat_private|string|string|desc=Sends a private message to another player.}}&lt;br /&gt;
{{Flink|boolean|is_online|string|desc=Check to see if a player is online.}}&lt;br /&gt;
{{Flink|boolean [string]|who_clan|desc=Returns a list of whom is in your clan and if they are in chat.}}&lt;br /&gt;
&lt;br /&gt;
== Time Functions ==&lt;br /&gt;
{{Flink|int|gameday_to_int|desc=Returns the current KoL date as an integer.}}&lt;br /&gt;
{{Flink|string|gameday_to_string|desc=Returns the current KoL date as a string.}}&lt;br /&gt;
{{Flink|int|gametime_to_int|desc=Returns the current KoL time in ms as an integer.}}&lt;br /&gt;
{{Flink|string|now_to_string|string|desc=Returns current local time/date in SimpleDateFormat format.}}&lt;br /&gt;
{{Flink|string|time_to_string|desc=Returns the current local time in HH:mm:ss z format.}}&lt;br /&gt;
{{Flink|string|today_to_string|desc=Returns the current local day in ISO format.}}&lt;br /&gt;
&lt;br /&gt;
== Debugging Functions == &lt;br /&gt;
{{Flink|void|disable|string|desc=Disables the specified function.}}&lt;br /&gt;
{{Flink|void|enable|string|desc=Enables the specified function.}}&lt;br /&gt;
{{Flink|buffer|load_html|string|desc=Works like visit_url(), but for debugging.}}&lt;br /&gt;
{{Flink|string|make_url|string|boolean|boolean|desc=Crafts the URL to visit.}}&lt;br /&gt;
&lt;br /&gt;
== Map Management Functions ==&lt;br /&gt;
{{Flink|boolean|file_to_map|string|aggregate|desc=Loads a map from a tab-delimited text file.}}&lt;br /&gt;
{{Flink|boolean|map_to_file|aggregate|string|desc=Saves a map to a tab-delimited text file.}}&lt;br /&gt;
{{Flink|int|count|aggregate|desc=Returns the number of defined keys for the specified aggregate.}}&lt;br /&gt;
{{Flink|void|clear|aggregate|desc=Removes all keys from the specified aggregate.}}&lt;br /&gt;
&lt;br /&gt;
== Other Functions ==&lt;br /&gt;
{{Flink|void|abort|{{opt|string}}|desc=Aborts the current script with an optional message.}}&lt;br /&gt;
{{Flink|void|print|string|{{opt|string}}|desc=Prints to CLI and status line of Adventuring window, optionally in a specified color.}}&lt;br /&gt;
{{Flink|void|print_html|string|desc=Prints to CLI, parsing any included html.}}&lt;br /&gt;
{{Flink|void|logprint|string|desc=Prints to the session log.}}&lt;br /&gt;
{{Flink|boolean|cli_execute|string|desc=Executes the given command as if it were entered into the CLI.}}&lt;br /&gt;
{{Flink|void|wait|int}}&lt;br /&gt;
{{Flink|void|waitq|int|desc=Sleeps for the specified number of seconds.}}&lt;br /&gt;
{{Flink|boolean|user_confirm|string|desc=Allows user input in Y/N format.}}&lt;br /&gt;
{{Flink|string|get_property|string|desc=Gets a global or user preference as appropriate.}}&lt;br /&gt;
{{Flink|void|set_property|string|string|desc=Sets a global or user preference as appropriate.}}&lt;br /&gt;
{{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).}}&lt;br /&gt;
{{Flink|boolean|batch_close|desc=Used to mark the end of a block of functions to operate in batch mode (see page for details).}}&lt;br /&gt;
{{Flink|int|get_revision|desc=Returns the current KoLmafia revision number.}}&lt;br /&gt;
{{Flink|string|get_version|desc=Returns the most recent KoLmafia version.}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Gametime_to_int&amp;diff=7473</id>
		<title>Gametime to int</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Gametime_to_int&amp;diff=7473"/>
		<updated>2011-07-09T16:26:25Z</updated>

		<summary type="html">&lt;p&gt;Theraze: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|gametime_to_int}}{{&lt;br /&gt;
#vardefine:return_type|int}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description=Returns the current KoL game time using milliseconds since rollover.|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Sample 1|&lt;br /&gt;
description=This code will tell you how many MS it took to list the gCLI commands.|&lt;br /&gt;
code=&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
int starttime = gametime_to_int();&lt;br /&gt;
CLI_EXECUTE(&amp;quot;help&amp;quot;);&lt;br /&gt;
print(&amp;quot;It took &amp;quot;+(gametime_to_int()-starttime)+&amp;quot; MS to list all gCLI commands.&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
&lt;br /&gt;
code2={{CodeSample|&lt;br /&gt;
title=Code Sample 2|&lt;br /&gt;
description=This code will tell you how many MS it has been since KoL&#039;s official rollover time.|&lt;br /&gt;
code=&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
print(&amp;quot;It has been &amp;quot;+gametime_to_int()+&amp;quot; MS since the rollover began.&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
&lt;br /&gt;
code3={{CodeSample|&lt;br /&gt;
title=Code Sample 3|&lt;br /&gt;
description=This code will tell you long since KoL&#039;s official rollover time began without hitting the server.|&lt;br /&gt;
code=&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
print(&amp;quot;It has been &amp;quot;+(gametime_to_int() / (86400000 / 24)) + &amp;quot;:&amp;quot; + ((gametime_to_int() / (86400000 / 1440)) % 60)+&amp;quot; since the rollover began.&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
&lt;br /&gt;
code4={{CodeSample|&lt;br /&gt;
title=Code Sample 4|&lt;br /&gt;
description=This code will tell you how long until KoL&#039;s next official rollover time.|&lt;br /&gt;
code=&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
print(&amp;quot;You have &amp;quot;+(23 - (gametime_to_int() / (86400000 / 24)))+&amp;quot;:&amp;quot;+(59 - ((gametime_to_int() / (86400000 / 1440)) % 60))+&amp;quot; left until rollover begins.&amp;quot;)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
{{SeeAlso|today_to_string|gameday_to_int|gameday_to_string|time_to_string|now_to_string}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous Functions]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Gametime_to_int&amp;diff=7472</id>
		<title>Gametime to int</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Gametime_to_int&amp;diff=7472"/>
		<updated>2011-07-09T16:16:43Z</updated>

		<summary type="html">&lt;p&gt;Theraze: Created page with &amp;quot;{{ #vardefine:name|gametime_to_int}}{{ #vardefine:return_type|int}}{{  FunctionPage| name={{#var:name}}|  function1={{Function| name={{#var:name}}| aggregate={{#var:aggregate}}| ...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|gametime_to_int}}{{&lt;br /&gt;
#vardefine:return_type|int}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description=Returns the current KoL game time using milliseconds since rollover.|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Samples|&lt;br /&gt;
description=This code will tell you how many MS it took to list the gCLI commands.|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
int starttime = gametime_to_int();&lt;br /&gt;
CLI_EXECUTE(&amp;quot;help&amp;quot;);&lt;br /&gt;
print(&amp;quot;It took &amp;quot;+(gametime_to_int()-starttime)+&amp;quot; MS to list all gCLI commands.&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
code2={{CodeSample|&lt;br /&gt;
title=Code Samples|&lt;br /&gt;
description=This code will tell you how many MS it has been since KoL&#039;s official rollover time.|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
print(&amp;quot;It has been &amp;quot;+gametime_to_int()+&amp;quot; MS since the rollover began.&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
code3={{CodeSample|&lt;br /&gt;
title=Code Samples|&lt;br /&gt;
description=This code will tell you long since KoL&#039;s official rollover time began without hitting the server.|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
print((gametime_to_int() / (86400000 / 24)) + &amp;quot;:&amp;quot; + ((gametime_to_int() / (86400000 / 1440)) % 60))&lt;br /&gt;
 &lt;br /&gt;
17:34print(&amp;quot;It has been &amp;quot;+(gametime_to_int() / (86400000 / 24)) + &amp;quot;:&amp;quot; + ((gametime_to_int() / (86400000 / 1440)) % 60)+&amp;quot; since the rollover began.&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
code4={{CodeSample|&lt;br /&gt;
title=Code Samples|&lt;br /&gt;
description=This code will tell you how many MS it has been since KoL&#039;s official rollover time.|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
print(&amp;quot;You have &amp;quot;+(23 - (gametime_to_int() / (86400000 / 24)))+&amp;quot;:&amp;quot;+(59 - ((gametime_to_int() / (86400000 / 1440)) % 60))+&amp;quot; left until rollover begins.&amp;quot;)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
{{SeeAlso|today_to_string|gameday_to_int|gameday_to_string|time_to_string|now_to_string}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous Functions]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Miscellaneous_Functions&amp;diff=1176</id>
		<title>Miscellaneous Functions</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Miscellaneous_Functions&amp;diff=1176"/>
		<updated>2011-07-09T16:04:08Z</updated>

		<summary type="html">&lt;p&gt;Theraze: /* Time Functions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{TOCright}}&lt;br /&gt;
== Chat Functions ==&lt;br /&gt;
{{Flink|void|chat_clan|string}}&lt;br /&gt;
{{Flink|void|chat_clan|string|string|desc=Sends a message to clan chat.}}&lt;br /&gt;
{{Flink|void|chat_macro|string|desc=Submits a chat macro to KoL.}}&lt;br /&gt;
{{Flink|void|chat_notify|string|string|desc=Sends a notification to the player&#039;s own chat.}}&lt;br /&gt;
{{Flink|void|chat_private|string|string|desc=Sends a private message to another player.}}&lt;br /&gt;
{{Flink|boolean|is_online|string|desc=Check to see if a player is online.}}&lt;br /&gt;
{{Flink|boolean [string]|who_clan|desc=Returns a list of whom is in your clan and if they are in chat.}}&lt;br /&gt;
&lt;br /&gt;
== Time Functions ==&lt;br /&gt;
{{Flink|int|gameday_to_int|desc=Returns the current KoL date as an integer.}}&lt;br /&gt;
{{Flink|string|gameday_to_string|desc=Returns the current KoL date as a string.}}&lt;br /&gt;
{{Flink|int|gametime_to_int|desc=Returns the current KoL time in MS as an integer.}}&lt;br /&gt;
{{Flink|string|now_to_string|string|desc=Returns current local time/date in SimpleDateFormat format.}}&lt;br /&gt;
{{Flink|string|time_to_string|desc=Returns the current local time in HH:mm:ss z format.}}&lt;br /&gt;
{{Flink|string|today_to_string|desc=Returns the current local day in ISO format.}}&lt;br /&gt;
&lt;br /&gt;
== Debugging Functions == &lt;br /&gt;
{{Flink|void|disable|string|desc=Disables the specified function.}}&lt;br /&gt;
{{Flink|void|enable|string|desc=Enables the specified function.}}&lt;br /&gt;
{{Flink|buffer|load_html|string|desc=Works like visit_url(), but for debugging.}}&lt;br /&gt;
{{Flink|string|make_url|string|boolean|boolean|desc=Crafts the URL to visit.}}&lt;br /&gt;
&lt;br /&gt;
== Map Management Functions ==&lt;br /&gt;
{{Flink|boolean|file_to_map|string|aggregate|desc=Loads a map from a tab-delimited text file.}}&lt;br /&gt;
{{Flink|boolean|map_to_file|aggregate|string|desc=Saves a map to a tab-delimited text file.}}&lt;br /&gt;
{{Flink|int|count|aggregate|desc=Returns the number of defined keys for the specified aggregate.}}&lt;br /&gt;
{{Flink|void|clear|aggregate|desc=Removes all keys from the specified aggregate.}}&lt;br /&gt;
&lt;br /&gt;
== Other Functions ==&lt;br /&gt;
{{Flink|void|abort|{{opt|string}}|desc=Aborts the current script with an optional message.}}&lt;br /&gt;
{{Flink|void|print|string|{{opt|string}}|desc=Prints to CLI and status line of Adventuring window, optionally in a specified color.}}&lt;br /&gt;
{{Flink|void|print_html|string|desc=Prints to CLI, parsing any included html.}}&lt;br /&gt;
{{Flink|void|logprint|string|desc=Prints to the session log.}}&lt;br /&gt;
{{Flink|boolean|cli_execute|string|desc=Executes the given command as if it were entered into the CLI.}}&lt;br /&gt;
{{Flink|void|wait|int}}&lt;br /&gt;
{{Flink|void|waitq|int|desc=Sleeps for the specified number of seconds.}}&lt;br /&gt;
{{Flink|boolean|user_confirm|string|desc=Allows user input in Y/N format.}}&lt;br /&gt;
{{Flink|string|get_property|string|desc=Gets a global or user preference as appropriate.}}&lt;br /&gt;
{{Flink|void|set_property|string|string|desc=Sets a global or user preference as appropriate.}}&lt;br /&gt;
{{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).}}&lt;br /&gt;
{{Flink|boolean|batch_close|desc=Used to mark the end of a block of functions to operate in batch mode (see page for details).}}&lt;br /&gt;
{{Flink|int|get_revision|desc=Returns the current KoLmafia revision number.}}&lt;br /&gt;
{{Flink|string|get_version|desc=Returns the most recent KoLmafia version.}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Npc_price&amp;diff=7442</id>
		<title>Npc price</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Npc_price&amp;diff=7442"/>
		<updated>2011-05-19T13:48:29Z</updated>

		<summary type="html">&lt;p&gt;Theraze: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|npc_price}}{{&lt;br /&gt;
#vardefine:return_type|int}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
parameter1={{Param|item|shop_for}}|&lt;br /&gt;
p1desc={{Pspan|shop_for}} is the item to inquire on the npc price and availability of.|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description=Returns the current price of the given item from NPC shops, given availability to the player. This function runs a new check each time it is called, so if you call this function and then unlock a new NPC store, calling this function again will return the new availability state of the item.|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Sample|&lt;br /&gt;
description=Parse your inventory checking to see which NPC items are available to you.|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
foreach i in get_inventory()&lt;br /&gt;
{&lt;br /&gt;
  if (is_npc_item(i))&lt;br /&gt;
  {&lt;br /&gt;
    if (npc_price(i) == 0) print(i+&amp;quot; can be bought but not by you.&amp;quot;);&lt;br /&gt;
    else print(i+&amp;quot; can be bought for &amp;quot;+npc_price(i));&lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
&lt;br /&gt;
see_also={{SeeAlso|historical_price|buy|mall_price|retrieve_item}}|&lt;br /&gt;
special=Items not currently available will return 0. When not logged in, this function returns 0 for all items, as none of them are available to you at the time.|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Item Management]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Npc_price&amp;diff=7441</id>
		<title>Npc price</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Npc_price&amp;diff=7441"/>
		<updated>2011-05-19T13:48:02Z</updated>

		<summary type="html">&lt;p&gt;Theraze: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|npc_price}}{{&lt;br /&gt;
#vardefine:return_type|int}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
parameter1={{Param|item|shop_for}}|&lt;br /&gt;
p1desc={{Pspan|shop_for}} is the item to inquire on the npc price and availability of.|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description=Returns the current price of the given item from NPC shops, given availability to the player. This function runs a new check each time it is called, so if you call this function and then unlock a new NPC store, calling this function again will return the new availability state of the item.|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Sample|&lt;br /&gt;
description=Parse your inventory checking to see which NPC items are available to you.|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
foreach i in get_inventory()&lt;br /&gt;
{&lt;br /&gt;
  if (is_npc_item(i)) if (npc_price(i) == 0) print(i+&amp;quot; can be bought but not by you.&amp;quot;);&lt;br /&gt;
  else print(i+&amp;quot; can be bought for &amp;quot;+npc_price(i));&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
&lt;br /&gt;
see_also={{SeeAlso|historical_price|buy|mall_price|retrieve_item}}|&lt;br /&gt;
special=Items not currently available will return 0. When not logged in, this function returns 0 for all items, as none of them are available to you at the time.|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Item Management]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Npc_price&amp;diff=7440</id>
		<title>Npc price</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Npc_price&amp;diff=7440"/>
		<updated>2011-05-19T13:47:23Z</updated>

		<summary type="html">&lt;p&gt;Theraze: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|npc_price}}{{&lt;br /&gt;
#vardefine:return_type|int}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
parameter1={{Param|item|shop_for}}|&lt;br /&gt;
p1desc={{Pspan|shop_for}} is the item to inquire on the npc price and availability of.|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description=Returns the current price of the given item from NPC shops, given availability to the player. This function runs a new check each time it is called, so if you call this function and then unlock a new NPC store, calling this function again will return the new availability state of the item.|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Sample|&lt;br /&gt;
description=Parse your inventory checking to see which NPC items are available to you.|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
foreach i in get_inventory() { if (is_npc_item(i)) if (npc_price(i) == 0) print(i+&amp;quot; can be bought but not by you.&amp;quot;); else print(i+&amp;quot; can be bought for &amp;quot;+npc_price(i));  }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
&lt;br /&gt;
see_also={{SeeAlso|historical_price|buy|mall_price|retrieve_item}}|&lt;br /&gt;
special=Items not currently available will return 0. When not logged in, this function returns 0 for all items, as none of them are available to you at the time.|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Item Management]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Item_Management&amp;diff=4220</id>
		<title>Item Management</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Item_Management&amp;diff=4220"/>
		<updated>2011-05-19T13:44:13Z</updated>

		<summary type="html">&lt;p&gt;Theraze: /* Informational */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{TOCright}}&lt;br /&gt;
==Informational==&lt;br /&gt;
{{Flink|int|my_meat|desc=Returns the amount of meat you have on hand.}}&lt;br /&gt;
{{Flink|int|my_closet_meat|desc=Returns the amount of meat you have in your Colossal Closet.}}&lt;br /&gt;
{{Flink|int|pulls_remaining|desc=Returns the number of pulls you can make from storage, or 0 if not applicable.}}&lt;br /&gt;
{{Flink|boolean|have_chef|desc=Returns true if you have a chef-boxen at your campground.}}&lt;br /&gt;
{{Flink|boolean|have_bartender|desc=Returns true if you have a bartender-boxen at your campground.}}&lt;br /&gt;
{{Flink|int [item]|get_campground|desc=Returns a map of your campground items.}}&lt;br /&gt;
{{Flink|item|get_dwelling|desc=Returns the item corresponding with your dwelling.}}&lt;br /&gt;
{{Flink|boolean|have_mushroom_plot|desc=Returns true if and only if you&#039;ve purchased a mushroom plot this run.}}&lt;br /&gt;
{{Flink|int|stills_available|desc=Returns the number of Nash Crosby&#039;s Still uses left for the day (0 if not accessible).}}&lt;br /&gt;
{{Flink|string|item_type|item|desc=Returns the type of item specified.}}&lt;br /&gt;
{{Flink|int|item_amount|item}}&lt;br /&gt;
{{Flink|int|closet_amount|item}}&lt;br /&gt;
{{Flink|int|display_amount|item}}&lt;br /&gt;
{{Flink|int|equipped_amount|item}}&lt;br /&gt;
{{Flink|int|shop_amount|item}}&lt;br /&gt;
{{Flink|int|stash_amount|item|}}&lt;br /&gt;
{{Flink|int|storage_amount|item|desc=These 7 functions return the total number available of a given item in the respective section of your inventory.}}&lt;br /&gt;
{{Flink|int|available_amount|item|desc=Returns the total number available of a given item in all inventory sections accessible to your character based on current restrictions.}}&lt;br /&gt;
{{Flink|int|creatable_amount|item|desc=Returns the amount of the item that you are capable of creating given your current inventory and skills.}}&lt;br /&gt;
{{Flink|int [item]|get_ingredients|item|desc=Returns a map where each key is one of the required ingredients, with the integer value the number required. If you don&#039;t have the skills needed to make the item, it will return an empty map.}}&lt;br /&gt;
{{Flink|int [item]|get_inventory|desc=Returns a map where each key is an item in your inventory, with the integer value its quantity.}}&lt;br /&gt;
{{Flink|int [item]|get_related|item|string|desc=Returns associated items in a zap or fold group (see page for details).}}&lt;br /&gt;
[[File:Item category.png|frame|You can categorize items in KoL using [[is tradeable|is_tradeable()]], [[is giftable|is_giftable()]], and [[is displayable|is_displayable()]].]]&lt;br /&gt;
{{Flink|boolean|is_tradeable|item|desc=Returns whether the item can be placed in the mall.}}&lt;br /&gt;
{{Flink|boolean|is_giftable|item|desc=Returns whether the item can be traded in a gift package.}}&lt;br /&gt;
{{Flink|boolean|is_displayable|item|desc=Returns whether the item can be put in a display case (true for all but quest items).}}&lt;br /&gt;
{{Flink|boolean|have_shop|desc=Returns whether you have a mall store.}}&lt;br /&gt;
{{Flink|boolean|have_display|desc=Returns whether you have a display case.}}&lt;br /&gt;
{{Flink|boolean|is_npc_item|item|desc=Returns whether the item can be bought from an NPC store.}}&lt;br /&gt;
{{Flink|void|refresh_stash|desc=Takes a new look at the contents of your clan stash, as that section of inventory cannot be internally tracked due to access by others.}}&lt;br /&gt;
{{Flink|int|mall_price|item|desc=Returns the current (lowest) mall price of the given item.}}&lt;br /&gt;
{{Flink|int|npc_price|item|desc=Returns the current price of the given item if it can currently be bought from an NPC store.}}&lt;br /&gt;
{{Flink|int|historical_price|item|desc=Returns the most recently checked price for an item. This will never hit the server, unlike mall_price().}}&lt;br /&gt;
{{Flink|float|historical_age|item|desc=Returns the age of the most recently checked price for an item in days. This allows you to decide if you want to use historical_price() or mall_price().}}&lt;br /&gt;
{{Flink|int|autosell_price|item|desc=Returns the autosell price of the item (0 for items that cannot be autosold).}}&lt;br /&gt;
{{Flink|int|get_power|item|desc=Returns the power of the item (0 for items that don&#039;t have a power).}}&lt;br /&gt;
{{Flink|string|to_plural|item|desc=Returns the plural of an item as a string.}}&lt;br /&gt;
{{Flink|int|meat_drop|{{opt|monster}}|desc=Returns a certain monster&#039;s base meat drop.}}&lt;br /&gt;
{{Flink|int [item]|item_drops|{{opt|monster}}|desc=Returns an array of a certain monster&#039;s base item drops, keying item to drop rate. Has certain limitations detailed on individual page.}}&lt;br /&gt;
{{Flink|record [int]|item_drops_array|{{opt|monster}}|desc=Returns an array of records holding information regarding a certain monster&#039;s base item drops.}}&lt;br /&gt;
&lt;br /&gt;
==Moving Items Around==&lt;br /&gt;
{{Flink|boolean|put_closet|int|{{opt|item}}}}&lt;br /&gt;
{{Flink|boolean|put_display|int|item}}&lt;br /&gt;
{{Flink|boolean|put_stash|int|item}}&lt;br /&gt;
{{Flink|boolean|take_closet|int|{{opt|item}}}}&lt;br /&gt;
{{Flink|boolean|take_display|int|item}}&lt;br /&gt;
{{Flink|boolean|take_stash|int|item}}&lt;br /&gt;
{{Flink|boolean|take_storage|int|item|desc=Attempts to take or put the specified item in the appropriate section of your inventory, and returns its success.&amp;lt;br /&amp;gt;If the item parameter is omitted from put_closet() or take_closet(), meat is transferred instead of an item.}}&lt;br /&gt;
{{Flink|boolean|put_shop|int|int|{{opt|int}}|item|desc=Puts items in your store (see page for details).}}&lt;br /&gt;
&lt;br /&gt;
==Acquiring &amp;amp; Using Items==&lt;br /&gt;
{{Flink|boolean|retrieve_item|int|item|desc=Uses KoLmafia internal logic to gather items (see page for details).}}&lt;br /&gt;
{{Flink|boolean|hermit|int|item|desc=Trades worthless items (buying and using chewing gum if needed) to the hermit for specified items (see page for details).}}&lt;br /&gt;
{{Flink|boolean|use|int|item|desc=Attempts to use items as specified and reports success.}}&lt;br /&gt;
{{Flink|string|last_item_message|desc=Returns message that KoL reports in the event of error.}}&lt;br /&gt;
{{Flink|boolean|eatsilent|int|item}}&lt;br /&gt;
{{Flink|boolean|eat|int|item|desc=Attempts to eat items as specified and reports success.}}&lt;br /&gt;
{{Flink|boolean|overdrink|int|item}}&lt;br /&gt;
{{Flink|boolean|drink|int|item|desc=Attempts to drink items as specified and reports success.}}&lt;br /&gt;
{{Flink|boolean|create|int|item|desc=Attempts to create the specified items, following your KoLmafia settings regarding purchases to gather ingredients &amp;amp; require boxen.}}&lt;br /&gt;
{{Flink|boolean|buy|int|item}}&lt;br /&gt;
{{Flink|int|buy|int|item|int|desc=Tries to purchase the specified items (see page for details).}}&lt;br /&gt;
{{Flink|boolean|autosell|int|item|desc=Attempts to autosell the given items and reports success.}}&lt;br /&gt;
{{Flink|int|craft|string|int|item|item|desc=Raw crafting that obeys KoLmafia settings (see page for details).}}&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Npc_price&amp;diff=7439</id>
		<title>Npc price</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Npc_price&amp;diff=7439"/>
		<updated>2011-05-19T13:42:54Z</updated>

		<summary type="html">&lt;p&gt;Theraze: Created page with &amp;quot;{{ #vardefine:name|npc_price}}{{ #vardefine:return_type|int}}{{  FunctionPage| name={{#var:name}}|  function1={{Function| name={{#var:name}}| aggregate={{#var:aggregate}}| return...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|npc_price}}{{&lt;br /&gt;
#vardefine:return_type|int}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
parameter1={{Param|item|shop_for}}|&lt;br /&gt;
p1desc={{Pspan|shop_for}} is the item to inquire on the npc price and availability of.|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description=Returns the current price of the given item from NPC shops, given availability to the player. This function runs a new check each time it is called, so if you call this function and then unlock a new NPC store, calling this function again will return the new availability state of the item.|&lt;br /&gt;
&lt;br /&gt;
see_also={{SeeAlso|historical_price|buy|mall_price|retrieve_item}}|&lt;br /&gt;
special=Items not currently available will return 0. When not logged in, this function returns 0 for all items, as none of them are available to you at the time.|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Item Management]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Ash_Functions&amp;diff=2571</id>
		<title>Ash Functions</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Ash_Functions&amp;diff=2571"/>
		<updated>2011-05-19T13:36:58Z</updated>

		<summary type="html">&lt;p&gt;Theraze: /* n */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{TOCright}}&lt;br /&gt;
Master list of all ASH functions. All functions as of r8144 are listed; this list is intended to be kept current, but it is possible that some functions added since the above revision may be missing. (Please feel free to add in any you notice.)&lt;br /&gt;
===a===&lt;br /&gt;
{{Flink|void|abort|{{opt|string}}}}&lt;br /&gt;
{{Flink|void|add_item_condition|int|item}}&lt;br /&gt;
{{Flink|boolean|adv1|location|int|string}}&lt;br /&gt;
{{Flink|boolean|adventure|int|location|{{opt|string}}}}&lt;br /&gt;
{{Flink|float [monster]|appearance_rates|location}}&lt;br /&gt;
{{Flink|buffer|append|buffer|string}}&lt;br /&gt;
{{Flink|buffer|append_replacement|matcher|buffer|string}}&lt;br /&gt;
{{Flink|buffer|append_tail|matcher|buffer}}&lt;br /&gt;
{{Flink|buffer|attack}}&lt;br /&gt;
{{Flink|boolean|autosell|int|item}}&lt;br /&gt;
{{Flink|int|autosell_price|item}}&lt;br /&gt;
{{Flink|int|available_amount|item}}&lt;br /&gt;
===b===&lt;br /&gt;
{{Flink|boolean|batch_close}}&lt;br /&gt;
{{Flink|void|batch_open}}&lt;br /&gt;
{{Flink|boolean|black_market_available}}&lt;br /&gt;
{{Flink|boolean|boolean_modifier|string|{{opt|string}}}}&lt;br /&gt;
{{Flink|boolean|boolean_modifier|item|string}}&lt;br /&gt;
{{Flink|int|buffed_hit_stat}}&lt;br /&gt;
{{Flink|boolean|buy|int|item}}&lt;br /&gt;
{{Flink|int|buy|int|item|int}}&lt;br /&gt;
===c===&lt;br /&gt;
{{Flink|boolean|can_drink}}&lt;br /&gt;
{{Flink|boolean|can_eat}}&lt;br /&gt;
{{Flink|boolean|can_equip|item}}&lt;br /&gt;
{{Flink|boolean|can_interact}}&lt;br /&gt;
{{flink|boolean|canadia_available}}&lt;br /&gt;
{{Flink|int|ceil|float}}&lt;br /&gt;
{{Flink|boolean|chamber}}&lt;br /&gt;
{{Flink|boolean|change_mcd|int}}&lt;br /&gt;
{{Flink|string|char_at|string|int}}&lt;br /&gt;
{{Flink|void|chat_clan|string}}&lt;br /&gt;
{{Flink|void|chat_clan|string|string}}&lt;br /&gt;
{{Flink|void|chat_macro|string}}&lt;br /&gt;
{{Flink|void|chat_notify|string|string}}&lt;br /&gt;
{{Flink|void|chat_private|string|string}}&lt;br /&gt;
{{Flink|class|class_modifier|string|string}}&lt;br /&gt;
{{Flink|class|class_modifier|item|string}}&lt;br /&gt;
{{Flink|void|clear|aggregate}}&lt;br /&gt;
{{Flink|boolean|cli_execute|string}}&lt;br /&gt;
{{Flink|int|closet_amount|item}}&lt;br /&gt;
{{Flink|int|combat_mana_cost_modifier}}&lt;br /&gt;
{{Flink|float|combat_rate_modifier}}&lt;br /&gt;
{{Flink|boolean|contains_text|string|string}}&lt;br /&gt;
{{Flink|void|council}}&lt;br /&gt;
{{Flink|int|count|aggregate}}&lt;br /&gt;
{{Flink|boolean|craft|string|int|item|item}}&lt;br /&gt;
{{Flink|int|creatable_amount|item}}&lt;br /&gt;
{{Flink|boolean|create|int|item}}&lt;br /&gt;
{{Flink|matcher|create_matcher|string|string}}&lt;br /&gt;
{{Flink|stat|current_hit_stat}}&lt;br /&gt;
{{Flink|int|current_mcd}}&lt;br /&gt;
&lt;br /&gt;
===d===&lt;br /&gt;
{{Flink|item|daily_special}}&lt;br /&gt;
{{Flink|float|damage_absorption_percent}}&lt;br /&gt;
{{Flink|int|damage_reduction}}&lt;br /&gt;
{{Flink|buffer|delete|buffer|int|int}}&lt;br /&gt;
{{Flink|void|disable|string}}&lt;br /&gt;
{{flink|boolean|dispensary_available}}&lt;br /&gt;
{{Flink|int|display_amount|item}}&lt;br /&gt;
{{Flink|boolean|drink|int|item}}&lt;br /&gt;
&lt;br /&gt;
===e===&lt;br /&gt;
{{Flink|boolean|eat|int|item}}&lt;br /&gt;
{{Flink|boolean|eatsilent|int|item}}&lt;br /&gt;
{{Flink|effect|effect_modifier|string|string}}&lt;br /&gt;
{{Flink|effect|effect_modifier|item|string}}&lt;br /&gt;
{{Flink|float|elemental_resistance|element}}&lt;br /&gt;
{{Flink|float|elemental_resistance|{{opt|monster}}}}&lt;br /&gt;
{{Flink|void|enable|string}}&lt;br /&gt;
{{Flink|int|end|matcher|{{opt|int}}}}&lt;br /&gt;
{{Flink|boolean|enthrone_familiar|familiar}}&lt;br /&gt;
{{Flink|string|entity_decode|string}}&lt;br /&gt;
{{Flink|string|entity_encode|string}}&lt;br /&gt;
{{Flink|boolean|entryway}}&lt;br /&gt;
{{Flink|boolean|equip|{{opt|slot}}|item}}&lt;br /&gt;
{{Flink|int|equipped_amount|item}}&lt;br /&gt;
{{Flink|item|equipped_item|slot}}&lt;br /&gt;
{{Flink|int|expected_damage|{{opt|monster}}}}&lt;br /&gt;
{{Flink|float|experience_bonus}}&lt;br /&gt;
{{Flink|float|expression_eval}}&lt;br /&gt;
{{Flink|int [item]|extract_items|string}}&lt;br /&gt;
{{Flink|int|extract_meat|string}}&lt;br /&gt;
&lt;br /&gt;
===f===&lt;br /&gt;
{{Flink|item|familiar_equipment|familiar}}&lt;br /&gt;
{{Flink|item|familiar_equipped_equipment|familiar}}&lt;br /&gt;
{{Flink|int|familiar_weight|familiar}}&lt;br /&gt;
{{Flink|boolean|file_to_map|string|aggregate|[boolean]}}&lt;br /&gt;
{{Flink|boolean|find|matcher}}&lt;br /&gt;
{{Flink|int|floor|float}}&lt;br /&gt;
{{Flink|string|form_field|string}}&lt;br /&gt;
{{Flink|int|fullness_limit}}&lt;br /&gt;
===g===&lt;br /&gt;
{{Flink|boolean|galaktik_cures_discounted}}&lt;br /&gt;
{{Flink|int|gameday_to_int}}&lt;br /&gt;
{{Flink|string|gameday_to_string}}&lt;br /&gt;
{{Flink|int [item]|get_campground}}&lt;br /&gt;
{{Flink|string|get_ccs_action|int}}&lt;br /&gt;
{{Flink|int|get_auto_attack}}&lt;br /&gt;
{{Flink|string|get_counters|string|int|int}}&lt;br /&gt;
{{Flink|item|get_dwelling|}}&lt;br /&gt;
{{Flink|int [item]|get_ingredients|item}}&lt;br /&gt;
{{Flink|int [item]|get_inventory}}&lt;br /&gt;
{{Flink|monster [int]|get_monsters|location}}&lt;br /&gt;
{{Flink|int|get_power|item}}&lt;br /&gt;
{{Flink|string|get_property|string}}&lt;br /&gt;
{{Flink|int [item]|get_related|item, string}}&lt;br /&gt;
{{Flink|int|get_revision}}&lt;br /&gt;
{{Flink|string|get_version}}&lt;br /&gt;
{{flink|boolean|gnomads_available}}&lt;br /&gt;
{{Flink|string|group|matcher|{{opt|int}}}}&lt;br /&gt;
{{Flink|int|group_count|matcher}}&lt;br /&gt;
{{Flink|string [int, int]|group_string|string|string}}&lt;br /&gt;
{{Flink|item|guardians}}&lt;br /&gt;
{{Flink|boolean|guild_store_available}}&lt;br /&gt;
&lt;br /&gt;
===h===&lt;br /&gt;
{{Flink|boolean|have_bartender}}&lt;br /&gt;
{{Flink|boolean|have_chef}}&lt;br /&gt;
{{Flink|boolean|have_display}}&lt;br /&gt;
{{Flink|int|have_effect|effect}}&lt;br /&gt;
{{Flink|boolean|have_equipped|item}}&lt;br /&gt;
{{Flink|boolean|have_familiar|familiar}}&lt;br /&gt;
{{Flink|boolean|have_mushroom_plot}}&lt;br /&gt;
{{Flink|boolean|have_outfit|string}}&lt;br /&gt;
{{Flink|boolean|have_shop}}&lt;br /&gt;
{{Flink|boolean|have_skill|skill}}&lt;br /&gt;
{{Flink|boolean|hedgemaze}}&lt;br /&gt;
{{Flink|boolean|hermit|int|item}}&lt;br /&gt;
{{flink|boolean|hidden_temple_unlocked}}&lt;br /&gt;
{{Flink|boolean|hippy_store_available}}&lt;br /&gt;
{{Flink|float|historical_age|item}}&lt;br /&gt;
{{Flink|int|historical_price|item}}&lt;br /&gt;
&lt;br /&gt;
===i===&lt;br /&gt;
{{Flink|boolean|in_bad_moon}}&lt;br /&gt;
{{Flink|boolean|in_hardcore}}&lt;br /&gt;
{{Flink|boolean|in_moxie_sign}}&lt;br /&gt;
{{Flink|boolean|in_muscle_sign}}&lt;br /&gt;
{{Flink|boolean|in_mysticality_sign}}&lt;br /&gt;
{{Flink|int|index_of|string|string|{{opt|int}}}}&lt;br /&gt;
{{Flink|int|inebriety_limit}}&lt;br /&gt;
{{Flink|float|initiative_modifier}}&lt;br /&gt;
{{Flink|buffer|insert|buffer|int|string}}&lt;br /&gt;
{{Flink|boolean|is_displayable|item}}&lt;br /&gt;
{{Flink|boolean|is_giftable|item}}&lt;br /&gt;
{{Flink|boolean|is_goal|item}}&lt;br /&gt;
{{Flink|boolean|is_integer|string}}&lt;br /&gt;
{{Flink|boolean|is_npc_item|item}}&lt;br /&gt;
{{Flink|boolean|is_online|string}}&lt;br /&gt;
{{Flink|boolean|is_tradeable|item}}&lt;br /&gt;
{{Flink|int|item_amount|item}}&lt;br /&gt;
{{Flink|float|item_drop_modifier}}&lt;br /&gt;
{{Flink|int [item]|item_drops|{{opt|monster}}}}&lt;br /&gt;
{{Flink|record [int]|item_drops_array|{{opt|monster}}}}&lt;br /&gt;
{{Flink|string|item_type|item}}&lt;br /&gt;
===k===&lt;br /&gt;
{{flink|boolean|knoll_available}}&lt;br /&gt;
===l===&lt;br /&gt;
{{Flink|int|last_index_of|string|string|{{opt|int}}}}&lt;br /&gt;
{{Flink|monster|last_monster}}&lt;br /&gt;
{{Flink|int|length|string}}&lt;br /&gt;
{{Flink|buffer|load_html|string}}&lt;br /&gt;
{{Flink|void|logprint|string}}&lt;br /&gt;
===m===&lt;br /&gt;
{{Flink|string|make_url|string|boolean|boolean}}&lt;br /&gt;
{{Flink|int|mall_price|item}}&lt;br /&gt;
{{Flink|int|mana_cost_modifier}}&lt;br /&gt;
{{Flink|boolean|map_to_file|aggregate|string|[boolean]}}&lt;br /&gt;
{{Flink|float|max|float|float}}&lt;br /&gt;
{{Flink|int|max|int|int}}&lt;br /&gt;
{{Flink|int|maximize|string|boolean}}&lt;br /&gt;
{{Flink|int|maximize|string|int|int|boolean}}&lt;br /&gt;
{{Flink|int|meat_drop|{{opt|monster}}}}&lt;br /&gt;
{{Flink|float|meat_drop_modifier}}&lt;br /&gt;
{{Flink|float|min|float|float}}&lt;br /&gt;
{{Flink|int|min|int|int}}&lt;br /&gt;
{{Flink|int|mmg_bet_amount|int}}&lt;br /&gt;
{{Flink|string|mmg_bet_owner|int}}&lt;br /&gt;
{{Flink|int|mmg_bet_owner_id|int}}&lt;br /&gt;
{{Flink|string|mmg_bet_taker}}&lt;br /&gt;
{{Flink|string|mmg_bet_taker_id}}&lt;br /&gt;
{{Flink|int|mmg_bet_winnings}}&lt;br /&gt;
{{Flink|int|mmg_make_bet|int|boolean}}&lt;br /&gt;
{{Flink|int [int]|mmg_my_bets}}&lt;br /&gt;
{{Flink|int [int]|mmg_offered_bets}}&lt;br /&gt;
{{Flink|boolean|mmg_retract_bet|int}}&lt;br /&gt;
{{Flink|void|mmg_search|int|int}}&lt;br /&gt;
{{Flink|int|mmg_take_bet|int|boolean}}&lt;br /&gt;
{{Flink|void|mmg_visit}}&lt;br /&gt;
{{Flink|int|mmg_wait_event|int}}&lt;br /&gt;
{{Flink|float|modifier_eval|string}}&lt;br /&gt;
{{Flink|int|monster_attack|{{opt|monster}}}}&lt;br /&gt;
{{Flink|int|monster_defense|{{opt|monster}}}}&lt;br /&gt;
{{Flink|element|monster_element|{{opt|monster}}}}&lt;br /&gt;
{{Flink|float|monster_eval|{{opt|string}}}}&lt;br /&gt;
{{Flink|int|monster_hp|{{opt|monster}}}}&lt;br /&gt;
{{Flink|int|monster_level_adjustment}}&lt;br /&gt;
{{Flink|int|moon_light}}&lt;br /&gt;
{{Flink|int|moon_phase}}&lt;br /&gt;
{{Flink|int|mp_cost|skill}}&lt;br /&gt;
{{Flink|int|my_adventures}}&lt;br /&gt;
{{Flink|int|my_ascensions}}&lt;br /&gt;
{{Flink|int|my_basestat|stat}}&lt;br /&gt;
{{Flink|int|my_buffedstat|stat}}&lt;br /&gt;
{{Flink|class|my_class}}&lt;br /&gt;
{{Flink|int|my_closet_meat}}&lt;br /&gt;
{{Flink|int|my_daycount|}}&lt;br /&gt;
{{Flink|familiar|my_enthroned_familiar}}&lt;br /&gt;
{{Flink|familiar|my_familiar}}&lt;br /&gt;
{{Flink|int|my_fullness}}&lt;br /&gt;
{{Flink|string|my_hash}}&lt;br /&gt;
{{Flink|int|my_hp}}&lt;br /&gt;
{{Flink|string|my_id}}&lt;br /&gt;
{{Flink|int|my_inebriety}}&lt;br /&gt;
{{Flink|int|my_level}}&lt;br /&gt;
{{Flink|location|my_location}}&lt;br /&gt;
{{Flink|int|my_maxhp}}&lt;br /&gt;
{{Flink|int|my_maxmp}}&lt;br /&gt;
{{Flink|int|my_meat}}&lt;br /&gt;
{{Flink|int|my_mp}}&lt;br /&gt;
{{Flink|string|my_name}}&lt;br /&gt;
{{flink|string|my_path}}&lt;br /&gt;
{{Flink|stat|my_primestat}}&lt;br /&gt;
{{flink|string|my_sign}}&lt;br /&gt;
{{Flink|int|my_spleen_use}}&lt;br /&gt;
{{Flink|int|my_turncount}}&lt;br /&gt;
&lt;br /&gt;
===n===&lt;br /&gt;
{{Flink|float|now_to_string|string}}&lt;br /&gt;
{{Flink|int|npc_price|item}}&lt;br /&gt;
{{Flink|float|numeric_modifier|string|{{opt|string}}}}&lt;br /&gt;
{{Flink|float|numeric_modifier|item|string}}&lt;br /&gt;
{{Flink|float|numeric_modifier|effect|string}}&lt;br /&gt;
{{Flink|float|numeric_modifier|skill|string}}&lt;br /&gt;
{{Flink|float|numeric_modifier|familiar|string|int|item}}&lt;br /&gt;
&lt;br /&gt;
===o===&lt;br /&gt;
{{Flink|boolean|outfit|string}}&lt;br /&gt;
{{Flink|item [int]|outfit_pieces|string}}&lt;br /&gt;
{{Flink|boolean|overdrink|int|item}}&lt;br /&gt;
&lt;br /&gt;
===p===&lt;br /&gt;
{{Flink|void|print|string|{{opt|string}}}}&lt;br /&gt;
{{Flink|void|print_html|string}}&lt;br /&gt;
{{Flink|int|pulls_remaining}}&lt;br /&gt;
{{Flink|boolean|put_closet|int|{{opt|item}}}}&lt;br /&gt;
{{Flink|boolean|put_display|int|item}}&lt;br /&gt;
{{Flink|boolean|put_shop|int|int|{{opt|int}}|item}}&lt;br /&gt;
{{Flink|boolean|put_stash|int|item}}&lt;br /&gt;
===r===&lt;br /&gt;
{{Flink|int|random|int}}&lt;br /&gt;
{{Flink|int|raw_damage_absorption}}&lt;br /&gt;
{{Flink|boolean|refresh_stash}}&lt;br /&gt;
{{Flink|boolean|refresh_status}}&lt;br /&gt;
{{Flink|void|remove_item_condition|int|item}}&lt;br /&gt;
{{Flink|boolean|replace|buffer|int|int|string}}&lt;br /&gt;
{{Flink|string|replace_all|matcher|string}}&lt;br /&gt;
{{Flink|string|replace_first|matcher|string}}&lt;br /&gt;
{{Flink|buffer|replace_string|buffer|string|string}}&lt;br /&gt;
{{Flink|buffer|replace_string|string|string|string}}&lt;br /&gt;
{{Flink|matcher|reset|matcher|{{opt|string}}}}&lt;br /&gt;
{{Flink|boolean|restore_hp|int}}&lt;br /&gt;
{{Flink|boolean|restore_mp|int}}&lt;br /&gt;
{{Flink|boolean|retrieve_item|int|item}}&lt;br /&gt;
{{Flink|int|round|float}}&lt;br /&gt;
{{Flink|buffer|run_combat}}&lt;br /&gt;
{{Flink|buffer|runaway}}&lt;br /&gt;
&lt;br /&gt;
===s===&lt;br /&gt;
{{Flink|string [int]|session_logs|{{opt|string}}|int}}&lt;br /&gt;
{{Flink|void|set_auto_attack|int}}&lt;br /&gt;
{{Flink|void|set_length|buffer|int}}&lt;br /&gt;
{{Flink|void|set_location|location}}&lt;br /&gt;
{{Flink|void|set_property|string|string}}&lt;br /&gt;
{{Flink|int|shop_amount|item}}&lt;br /&gt;
{{Flink|int|spleen_limit}}&lt;br /&gt;
{{Flink|string [int]|split_string|string|{{opt|string}}}}&lt;br /&gt;
{{Flink|float|square_root|float}}&lt;br /&gt;
{{Flink|int|start|matcher|{{opt|int}}}}&lt;br /&gt;
{{Flink|int|stash_amount|item}}&lt;br /&gt;
{{Flink|stat|stat_bonus_today}}&lt;br /&gt;
{{Flink|stat|stat_bonus_tomorrow}}&lt;br /&gt;
{{Flink|stat|stat_modifier|effect|string}}&lt;br /&gt;
{{Flink|buffer|steal}}&lt;br /&gt;
{{Flink|int|stills_available}}&lt;br /&gt;
{{Flink|int|storage_amount|item}}&lt;br /&gt;
{{Flink|string|string_modifier|string}}&lt;br /&gt;
{{Flink|string|string_modifier|string|string}}&lt;br /&gt;
{{Flink|string|substring|string|int|{{opt|int}}}}&lt;br /&gt;
&lt;br /&gt;
===t===&lt;br /&gt;
{{Flink|boolean|take_closet|int|{{opt|item}}}}&lt;br /&gt;
{{Flink|boolean|take_display|int|item}}&lt;br /&gt;
{{Flink|boolean|take_stash|int|item}}&lt;br /&gt;
{{Flink|boolean|take_storage|int|item}}&lt;br /&gt;
{{Flink|int|tavern}}&lt;br /&gt;
{{Flink|buffer|throw_items|item|{{opt|item}}}}&lt;br /&gt;
{{Flink|buffer|time_to_string}}&lt;br /&gt;
{{Flink|boolean|to_boolean|any}}&lt;br /&gt;
{{Flink|class|to_class|string}}&lt;br /&gt;
{{Flink|effect|to_effect|int}}&lt;br /&gt;
{{Flink|effect|to_effect|string}}&lt;br /&gt;
{{Flink|effect|to_effect|skill}}&lt;br /&gt;
{{Flink|element|to_element|string}}&lt;br /&gt;
{{Flink|familiar|to_familiar|int}}&lt;br /&gt;
{{Flink|familiar|to_familiar|string}}&lt;br /&gt;
{{Flink|float|to_float|any}}&lt;br /&gt;
{{Flink|int|to_int|any}}&lt;br /&gt;
{{Flink|item|to_item|string}}&lt;br /&gt;
{{Flink|item|to_item|int}}&lt;br /&gt;
{{Flink|item|to_item|string|int}}&lt;br /&gt;
{{Flink|location|to_location|string}}&lt;br /&gt;
{{Flink|location|to_location|int}}&lt;br /&gt;
{{Flink|string|to_lower_case|string}}&lt;br /&gt;
{{Flink|monster|to_monster|string}}&lt;br /&gt;
{{Flink|string|to_plural|item}}&lt;br /&gt;
{{Flink|skill|to_skill|int}}&lt;br /&gt;
{{Flink|skill|to_skill|string}}&lt;br /&gt;
{{Flink|skill|to_skill|effect}}&lt;br /&gt;
{{Flink|slot|to_slot|item}}&lt;br /&gt;
{{Flink|stat|to_stat|string}}&lt;br /&gt;
{{Flink|string|to_string|any}}&lt;br /&gt;
{{Flink|string|to_upper_case|string}}&lt;br /&gt;
{{Flink|string|to_url|location}}&lt;br /&gt;
{{Flink|string|today_to_string}}&lt;br /&gt;
{{Flink|int|truncate|float}}&lt;br /&gt;
{{Flink|int|turns_per_cast|skill}}&lt;br /&gt;
{{Flink|int|turns_played}}&lt;br /&gt;
&lt;br /&gt;
===u===&lt;br /&gt;
{{Flink|string|url_decode|string}}&lt;br /&gt;
{{Flink|string|url_encode|string}}&lt;br /&gt;
{{Flink|boolean|use|int|item}}&lt;br /&gt;
{{Flink|boolean|use_familiar|familiar}}&lt;br /&gt;
{{Flink|boolean|use_skill|int|skill|{{opt|string}}}}&lt;br /&gt;
{{Flink|buffer|use_skill|skill}}&lt;br /&gt;
{{Flink|boolean|user_confirm|string}}&lt;br /&gt;
===v===&lt;br /&gt;
{{Flink|buffer|visit_url}}&lt;br /&gt;
{{Flink|buffer|visit_url|string}}&lt;br /&gt;
{{Flink|buffer|visit_url|string|boolean}}&lt;br /&gt;
{{Flink|buffer|visit_url|string|boolean|boolean}}&lt;br /&gt;
===w===&lt;br /&gt;
{{Flink|void|wait|int}}&lt;br /&gt;
{{Flink|void|waitq|int}}&lt;br /&gt;
{{Flink|int|weapon_hands|item}}&lt;br /&gt;
{{Flink|stat|weapon_type|item}}&lt;br /&gt;
{{Flink|int|weight_adjustment}}&lt;br /&gt;
{{Flink|boolean|white_citadel_available}}&lt;br /&gt;
{{Flink|boolean [string]|who_clan}}&lt;br /&gt;
{{Flink|boolean|will_usually_dodge}}&lt;br /&gt;
{{Flink|boolean|will_usually_miss}}&lt;br /&gt;
{{Flink|void|write|string}}&lt;br /&gt;
{{Flink|void|writeln|string}}&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Monster_eval&amp;diff=7382</id>
		<title>Monster eval</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Monster_eval&amp;diff=7382"/>
		<updated>2010-12-16T14:53:43Z</updated>

		<summary type="html">&lt;p&gt;Theraze: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|monster_eval}}{{&lt;br /&gt;
#vardefine:return_type|float}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
parameter1={{Param|string|expression}}|&lt;br /&gt;
p1desc={{pspan|expression}} is a mathematical expression to be solved.|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description= Evaluates an expression in the format used by variable monsters:&lt;br /&gt;
&lt;br /&gt;
* No spaces are allowed within the expression, except as part of a zone/location name.&lt;br /&gt;
* + - * / ( ) have their usual mathematical meaning and precedence.&lt;br /&gt;
* ^ is exponentiation, with the highest precedence.&lt;br /&gt;
* Functions available: ceil(x) floor(x) sqrt(x) min(x,y) max(x,y)&lt;br /&gt;
* Preferences function: pref(text)&lt;br /&gt;
** This must be used on preferences with a float value ONLY - merely retrieving an integer pref will corrupt it!&lt;br /&gt;
* There could be at most one of each text function in an expression.&lt;br /&gt;
** This is no longer the case however and multiple of the same text functions should now work properly.&lt;br /&gt;
* All upper-case letters are reserved for internally-used variables. The ones likely to be of use in user code are:&lt;br /&gt;
** A - player&#039;s ascension count&lt;br /&gt;
** MUS - player&#039;s adjusted muscle&lt;br /&gt;
** MYS - player&#039;s adjusted mysticality&lt;br /&gt;
** MOX - player&#039;s adjusted moxie&lt;br /&gt;
** ML - player&#039;s monster level adjustment&lt;br /&gt;
** MCD - player&#039;s MCD modifier&lt;br /&gt;
* This wrapper allows user-defined variables to be used as well, which must have names starting with a lower-case letter (or underscore) to distinguish them from built-in variables.  Variables are supplied as a float[string] map.&lt;br /&gt;
&amp;amp;nbsp;|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Sample|&lt;br /&gt;
description=This script expands monster_eval() to include support for user-defined variables. It is extremely complex, but it is extremely useful to anyone who wants to use monster_eval().|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
float eval(string expr, float[string] vars) {&lt;br /&gt;
   buffer b;&lt;br /&gt;
   matcher m = create_matcher( &amp;quot;\\b[a-z_][a-zA-Z0-9_]*\\b&amp;quot;, expr );&lt;br /&gt;
   while (m.find()) {&lt;br /&gt;
      string var = m.group(0);&lt;br /&gt;
      if (vars contains var) {&lt;br /&gt;
         m.append_replacement(b, vars[var].to_string());&lt;br /&gt;
      }&lt;br /&gt;
      // could implement functions, pref access, etc. here&lt;br /&gt;
   }&lt;br /&gt;
   m.append_tail(b);&lt;br /&gt;
   return monster_eval(b.to_string());&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Everything below this line shows how to make use of eval().&lt;br /&gt;
# TESTING:&lt;br /&gt;
&lt;br /&gt;
float[string] v;&lt;br /&gt;
v[&amp;quot;pi&amp;quot;] = 3.14159265;&lt;br /&gt;
v[&amp;quot;ten&amp;quot;] = 10;&lt;br /&gt;
print(eval(&amp;quot;2+3&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;max(pi^ten,ten^pi)&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;sqrt(pi)*L&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;undefined/2&amp;quot;, v));&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Math and Numbers]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Monster_eval&amp;diff=7381</id>
		<title>Monster eval</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Monster_eval&amp;diff=7381"/>
		<updated>2010-12-16T14:53:14Z</updated>

		<summary type="html">&lt;p&gt;Theraze: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|monster_eval}}{{&lt;br /&gt;
#vardefine:return_type|float}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
parameter1={{Param|string|expression}}|&lt;br /&gt;
p1desc={{pspan|expression}} is a mathematical expression to be solved.|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description= Evaluates an expression in the format used by variable monsters:&lt;br /&gt;
&lt;br /&gt;
* No spaces are allowed within the expression, except as part of a zone/location name.&lt;br /&gt;
* + - * / ( ) have their usual mathematical meaning and precedence.&lt;br /&gt;
* ^ is exponentiation, with the highest precedence.&lt;br /&gt;
* Functions available: ceil(x) floor(x) sqrt(x) min(x,y) max(x,y)&lt;br /&gt;
* Preferences function: pref(text)&lt;br /&gt;
** This must be used on preferences with a float value ONLY - merely retrieving an integer pref will corrupt it!&lt;br /&gt;
* There could be at most one of each text function in an expression.&lt;br /&gt;
** This is no longer the case however and multiple of the same text functions should now work properly.&lt;br /&gt;
* All upper-case letters are reserved for internally-used variables. The ones likely to be of use in user code are:&lt;br /&gt;
** A - player&#039;s ascension count&lt;br /&gt;
** MUS - player&#039;s adjusted muscle&lt;br /&gt;
** MYS - player&#039;s adjusted mysticality&lt;br /&gt;
** MOX - player&#039;s adjusted moxie&lt;br /&gt;
** ML - player&#039;s monster level adjustment&lt;br /&gt;
** MCD - player&#039;s MCD modifier&lt;br /&gt;
* This wrapper allows user-defined variables to be used as well, which must have names starting with a lower-case letter (or underscore) to distinguish them from built-in variables.  Variables are supplied as a float[string] map.&lt;br /&gt;
&amp;amp;nbsp;|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Sample|&lt;br /&gt;
description=This script expands monster_eval() to include support for user-defined variables. It is extremely complex, but it is extremely useful to anyone who wants to use monster_eval().|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
float eval(string expr, float[string] vars) {&lt;br /&gt;
   buffer b;&lt;br /&gt;
   matcher m = create_matcher( &amp;quot;\\b[a-z_][a-zA-Z0-9_]*\\b&amp;quot;, expr );&lt;br /&gt;
   while (m.find()) {&lt;br /&gt;
      string var = m.group(0);&lt;br /&gt;
      if (vars contains var) {&lt;br /&gt;
         m.append_replacement(b, vars[var].to_string());&lt;br /&gt;
      }&lt;br /&gt;
      // could implement functions, pref access, etc. here&lt;br /&gt;
   }&lt;br /&gt;
   m.append_tail(b);&lt;br /&gt;
   return modifier_eval(b.to_string());&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Everything below this line shows how to make use of eval().&lt;br /&gt;
# TESTING:&lt;br /&gt;
&lt;br /&gt;
float[string] v;&lt;br /&gt;
v[&amp;quot;pi&amp;quot;] = 3.14159265;&lt;br /&gt;
v[&amp;quot;ten&amp;quot;] = 10;&lt;br /&gt;
print(eval(&amp;quot;2+3&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;max(pi^ten,ten^pi)&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;sqrt(pi)*L&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;undefined/2&amp;quot;, v));&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Math and Numbers]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Expression_eval&amp;diff=7385</id>
		<title>Expression eval</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Expression_eval&amp;diff=7385"/>
		<updated>2010-12-16T14:48:46Z</updated>

		<summary type="html">&lt;p&gt;Theraze: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|expression_eval}}{{&lt;br /&gt;
#vardefine:return_type|float}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
parameter1={{Param|string|expression}}|&lt;br /&gt;
p1desc={{pspan|expression}} is a mathematical expression to be solved.|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description= Evaluates an expression using only the base components of the evaluator:&lt;br /&gt;
&lt;br /&gt;
* No spaces are allowed within the expression, except as part of a zone/location name.&lt;br /&gt;
* + - * / ( ) have their usual mathematical meaning and precedence.&lt;br /&gt;
* ^ is exponentiation, with the highest precedence.&lt;br /&gt;
* Functions available: ceil(x) floor(x) sqrt(x) min(x,y) max(x,y)&lt;br /&gt;
* Preferences function: pref(text)&lt;br /&gt;
** This must be used on preferences with a float value ONLY - merely retrieving an integer pref will corrupt it!&lt;br /&gt;
* There could be at most one of each text function in an expression.&lt;br /&gt;
** This is no longer the case however and multiple of the same text functions should now work properly.&lt;br /&gt;
* This wrapper allows user-defined variables to be used as well, which must have names starting with a lower-case letter (or underscore) to distinguish them from built-in variables.  Variables are supplied as a float[string] map.&lt;br /&gt;
&amp;amp;nbsp;|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Sample|&lt;br /&gt;
description=This script expands expression_eval() to include support for user-defined variables. It is extremely complex, but it is extremely useful to anyone who wants to use expression_eval().|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
float eval(string expr, float[string] vars) {&lt;br /&gt;
   buffer b;&lt;br /&gt;
   matcher m = create_matcher( &amp;quot;\\b[a-z_][a-zA-Z0-9_]*\\b&amp;quot;, expr );&lt;br /&gt;
   while (m.find()) {&lt;br /&gt;
      string var = m.group(0);&lt;br /&gt;
      if (vars contains var) {&lt;br /&gt;
         m.append_replacement(b, vars[var].to_string());&lt;br /&gt;
      }&lt;br /&gt;
      // could implement functions, pref access, etc. here&lt;br /&gt;
   }&lt;br /&gt;
   m.append_tail(b);&lt;br /&gt;
   return expression_eval(b.to_string());&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Everything below this line shows how to make use of eval().&lt;br /&gt;
# TESTING:&lt;br /&gt;
&lt;br /&gt;
float[string] v;&lt;br /&gt;
v[&amp;quot;pi&amp;quot;] = 3.14159265;&lt;br /&gt;
v[&amp;quot;ten&amp;quot;] = 10;&lt;br /&gt;
print(eval(&amp;quot;2+3&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;max(pi^ten,ten^pi)&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;sqrt(pi)*L&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;undefined/2&amp;quot;, v));&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Math and Numbers]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Modifier_eval&amp;diff=6417</id>
		<title>Modifier eval</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Modifier_eval&amp;diff=6417"/>
		<updated>2010-12-16T14:44:29Z</updated>

		<summary type="html">&lt;p&gt;Theraze: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|modifier_eval}}{{&lt;br /&gt;
#vardefine:return_type|float}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
parameter1={{Param|string|expression}}|&lt;br /&gt;
p1desc={{pspan|expression}} is a mathematical expression to be solved.|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description= Evaluates an expression in the format used by variable modifiers:&lt;br /&gt;
&lt;br /&gt;
* No spaces are allowed within the expression, except as part of a zone/location name.&lt;br /&gt;
* + - * / ( ) have their usual mathematical meaning and precedence.&lt;br /&gt;
* ^ is exponentiation, with the highest precedence.&lt;br /&gt;
* Functions available: ceil(x) floor(x) sqrt(x) min(x,y) max(x,y)&lt;br /&gt;
* Location functions: loc(text) zone(text)&lt;br /&gt;
** These have a value of 1 if the current adventure location or zone contains the specified text, 0 elsewhere.&lt;br /&gt;
* Familiar function: fam(text)&lt;br /&gt;
** This has a value of 1 if the player&#039;s familiar type contains the text, else 0.&lt;br /&gt;
* Preferences function: pref(text)&lt;br /&gt;
** This must be used on preferences with a float value ONLY - merely retrieving an integer pref will corrupt it!&lt;br /&gt;
* There could be at most one of each text function in an expression.&lt;br /&gt;
** This is no longer the case however and multiple of the same text functions should now work properly.&lt;br /&gt;
* All upper-case letters are reserved for internally-used variables. The ones likely to be of use in user code are:&lt;br /&gt;
** A - player&#039;s ascension count&lt;br /&gt;
** D - drunkenness&lt;br /&gt;
** F - fullness&lt;br /&gt;
** G - Grimace darkness (0..5)&lt;br /&gt;
** L - player level&lt;br /&gt;
** M - total moonlight (0..9)&lt;br /&gt;
** S - spleenness&lt;br /&gt;
** X - gender (-1=male, 1=female)&lt;br /&gt;
* This wrapper allows user-defined variables to be used as well, which must have names starting with a lower-case letter (or underscore) to distinguish them from built-in variables.  Variables are supplied as a float[string] map.&lt;br /&gt;
&amp;amp;nbsp;|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Sample|&lt;br /&gt;
description=This script expands modifier_eval() to include support for user-defined variables. It is extremely complex, but it is extremely useful to anyone who wants to use modifier_eval().|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
float eval(string expr, float[string] vars) {&lt;br /&gt;
   buffer b;&lt;br /&gt;
   matcher m = create_matcher( &amp;quot;\\b[a-z_][a-zA-Z0-9_]*\\b&amp;quot;, expr );&lt;br /&gt;
   while (m.find()) {&lt;br /&gt;
      string var = m.group(0);&lt;br /&gt;
      if (vars contains var) {&lt;br /&gt;
         m.append_replacement(b, vars[var].to_string());&lt;br /&gt;
      }&lt;br /&gt;
      // could implement functions, pref access, etc. here&lt;br /&gt;
   }&lt;br /&gt;
   m.append_tail(b);&lt;br /&gt;
   return modifier_eval(b.to_string());&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Everything below this line shows how to make use of eval().&lt;br /&gt;
# TESTING:&lt;br /&gt;
&lt;br /&gt;
float[string] v;&lt;br /&gt;
v[&amp;quot;pi&amp;quot;] = 3.14159265;&lt;br /&gt;
v[&amp;quot;ten&amp;quot;] = 10;&lt;br /&gt;
print(eval(&amp;quot;2+3&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;max(pi^ten,ten^pi)&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;sqrt(pi)*L&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;undefined/2&amp;quot;, v));&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
special=Note that modifier_eval &#039;&#039;&#039;never&#039;&#039;&#039; generates errors - a malformed expression will just print a message, and return an arbitrary value.|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Math and Numbers]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Expression_eval&amp;diff=7384</id>
		<title>Expression eval</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Expression_eval&amp;diff=7384"/>
		<updated>2010-12-16T14:39:41Z</updated>

		<summary type="html">&lt;p&gt;Theraze: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|expression_eval}}{{&lt;br /&gt;
#vardefine:return_type|float}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
parameter1={{Param|string|expression}}|&lt;br /&gt;
p1desc={{pspan|expression}} is a mathematical expression to be solved.|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function_description= Evaluates an expression... somehow.|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Sample|&lt;br /&gt;
description=This script expands expression_eval() to include support for user-defined variables. It is extremely complex, but it is extremely useful to anyone who wants to use expression_eval().|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
float eval(string expr, float[string] vars) {&lt;br /&gt;
   buffer b;&lt;br /&gt;
   matcher m = create_matcher( &amp;quot;\\b[a-z_][a-zA-Z0-9_]*\\b&amp;quot;, expr );&lt;br /&gt;
   while (m.find()) {&lt;br /&gt;
      string var = m.group(0);&lt;br /&gt;
      if (vars contains var) {&lt;br /&gt;
         m.append_replacement(b, vars[var].to_string());&lt;br /&gt;
      }&lt;br /&gt;
      // could implement functions, pref access, etc. here&lt;br /&gt;
   }&lt;br /&gt;
   m.append_tail(b);&lt;br /&gt;
   return expression_eval(b.to_string());&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Everything below this line shows how to make use of eval().&lt;br /&gt;
# TESTING:&lt;br /&gt;
&lt;br /&gt;
float[string] v;&lt;br /&gt;
v[&amp;quot;pi&amp;quot;] = 3.14159265;&lt;br /&gt;
v[&amp;quot;ten&amp;quot;] = 10;&lt;br /&gt;
print(eval(&amp;quot;2+3&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;max(pi^ten,ten^pi)&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;sqrt(pi)*L&amp;quot;, v));&lt;br /&gt;
print(eval(&amp;quot;undefined/2&amp;quot;, v));&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;}}|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Math and Numbers]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Item_Management&amp;diff=4216</id>
		<title>Item Management</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Item_Management&amp;diff=4216"/>
		<updated>2010-09-27T05:40:29Z</updated>

		<summary type="html">&lt;p&gt;Theraze: Changed mall_price from boolean to int, as it says in its own page. Boolean doesn&amp;#039;t make sense for this function, which is why I checked its page...&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{TOCright}}&lt;br /&gt;
==Informational==&lt;br /&gt;
{{Flink|int|my_meat|desc=Returns the amount of meat you have on hand.}}&lt;br /&gt;
{{Flink|int|my_closet_meat|desc=Returns the amount of meat you have in your Colossal Closet.}}&lt;br /&gt;
{{Flink|int|pulls_remaining|desc=Returns the number of pulls you can make from storage, or 0 if not applicable.}}&lt;br /&gt;
{{Flink|boolean|have_chef|desc=Returns true if you have a chef-boxen at your campground.}}&lt;br /&gt;
{{Flink|boolean|have_bartender|desc=Returns true if you have a bartender-boxen at your campground.}}&lt;br /&gt;
{{Flink|int [item]|get_campground|desc=Returns a map of your campground items.}}&lt;br /&gt;
{{Flink|boolean|have_mushroom_plot|desc=Returns true if and only if you&#039;ve purchased a mushroom plot this run.}}&lt;br /&gt;
{{Flink|int|stills_available|desc=Returns the number of Nash Crosby&#039;s Still uses left for the day (0 if not accessible).}}&lt;br /&gt;
{{Flink|string|item_type|item|desc=Returns the type of item specified.}}&lt;br /&gt;
{{Flink|int|item_amount|item}}&lt;br /&gt;
{{Flink|int|closet_amount|item}}&lt;br /&gt;
{{Flink|int|display_amount|item}}&lt;br /&gt;
{{Flink|int|equipped_amount|item}}&lt;br /&gt;
{{Flink|int|shop_amount|item}}&lt;br /&gt;
{{Flink|int|stash_amount|item|}}&lt;br /&gt;
{{Flink|int|storage_amount|item|desc=These 7 functions return the total number available of a given item in the respective section of your inventory.}}&lt;br /&gt;
{{Flink|int|available_amount|item|desc=Returns the total number available of a given item in all inventory sections accessible to your character based on current restrictions.}}&lt;br /&gt;
{{Flink|int|creatable_amount|item|desc=Returns the amount of the item that you are capable of creating given your current inventory and skills.}}&lt;br /&gt;
{{Flink|int [item]|get_ingredients|item|desc=Returns a map where each key is one of the required ingredients, with the integer value the number required. If you don&#039;t have the skills needed to make the item, it will return an empty map.}}&lt;br /&gt;
{{Flink|int [item]|get_inventory|desc=Returns a map where each key is an item in your inventory, with the integer value its quantity.}}&lt;br /&gt;
{{Flink|int [item]|get_related|item|string|desc=Returns associated items in a zap or fold group (see page for details).}}&lt;br /&gt;
[[File:Item category.png|frame|You can categorize items in KoL using [[is tradeable|is_tradeable()]], [[is giftable|is_giftable()]], and [[is displayable|is_displayable()]].]]&lt;br /&gt;
{{Flink|boolean|is_tradeable|item|desc=Returns whether the item can be placed in the mall.}}&lt;br /&gt;
{{Flink|boolean|is_giftable|item|desc=Returns whether the item can be traded in a gift package.}}&lt;br /&gt;
{{Flink|boolean|is_displayable|item|desc=Returns whether the item can be put in a display case (true for all but quest items).}}&lt;br /&gt;
{{Flink|boolean|have_shop|desc=Returns whether you have a mall store.}}&lt;br /&gt;
{{Flink|boolean|have_display|desc=Returns whether you have a display case.}}&lt;br /&gt;
{{Flink|boolean|is_npc_item|item|desc=Returns whether the item can be bought from an NPC store.}}&lt;br /&gt;
{{Flink|void|refresh_stash|desc=Takes a new look at the contents of your clan stash, as that section of inventory cannot be internally tracked due to access by others.}}&lt;br /&gt;
{{Flink|int|mall_price|item|desc=Returns the current (lowest) mall price of the given item.}}&lt;br /&gt;
{{Flink|int|historical_price|item|desc=Returns the most recently checked price for an item. This will never hit the server, unlike mall_price().}}&lt;br /&gt;
{{Flink|float|historical_age|item|desc=Returns the age of the most recently checked price for an item in days. This allows you to decide if you want to use historical_price() or mall_price().}}&lt;br /&gt;
{{Flink|int|autosell_price|item|desc=Returns the autosell price of the item (0 for items that cannot be autosold).}}&lt;br /&gt;
{{Flink|int|get_power|item|desc=Returns the power of the item (0 for items that don&#039;t have a power).}}&lt;br /&gt;
{{Flink|string|to_plural|item|desc=Returns the plural of an item as a string.}}&lt;br /&gt;
{{Flink|int|meat_drop|{{opt|monster}}|desc=Returns a certain monster&#039;s base meat drop.}}&lt;br /&gt;
{{Flink|int [item]|item_drops|{{opt|monster}}|desc=Returns an array of a certain monster&#039;s base item drops, keying item to drop rate. Has certain limitations detailed on individual page.}}&lt;br /&gt;
{{Flink|record [int]|item_drops_array|{{opt|monster}}|desc=Returns an array of records holding information regarding a certain monster&#039;s base item drops.}}&lt;br /&gt;
&lt;br /&gt;
==Moving Items Around==&lt;br /&gt;
{{Flink|boolean|put_closet|int|{{opt|item}}}}&lt;br /&gt;
{{Flink|boolean|put_display|int|item}}&lt;br /&gt;
{{Flink|boolean|put_stash|int|item}}&lt;br /&gt;
{{Flink|boolean|take_closet|int|{{opt|item}}}}&lt;br /&gt;
{{Flink|boolean|take_display|int|item}}&lt;br /&gt;
{{Flink|boolean|take_stash|int|item}}&lt;br /&gt;
{{Flink|boolean|take_storage|int|item|desc=Attempts to take or put the specified item in the appropriate section of your inventory, and returns its success.&amp;lt;br /&amp;gt;If the item parameter is omitted from put_closet() or take_closet(), meat is transferred instead of an item.}}&lt;br /&gt;
{{Flink|boolean|put_shop|int|int|{{opt|int}}|item|desc=Puts items in your store (see page for details).}}&lt;br /&gt;
&lt;br /&gt;
==Acquiring &amp;amp; Using Items==&lt;br /&gt;
{{Flink|boolean|retrieve_item|int|item|desc=Uses KoLmafia internal logic to gather items (see page for details).}}&lt;br /&gt;
{{Flink|boolean|hermit|int|item|desc=Trades worthless items (adventuring in the sewer if needed) to the hermit for specified items (see page for details).}}&lt;br /&gt;
{{Flink|boolean|use|int|item|desc=Attempts to use items as specified and reports success.}}&lt;br /&gt;
{{Flink|boolean|eatsilent|int|item}}&lt;br /&gt;
{{Flink|boolean|eat|int|item|desc=Attempts to eat items as specified and reports success.}}&lt;br /&gt;
{{Flink|boolean|overdrink|int|item}}&lt;br /&gt;
{{Flink|boolean|drink|int|item|desc=Attempts to drink items as specified and reports success.}}&lt;br /&gt;
{{Flink|boolean|create|int|item|desc=Attempts to create the specified items, following your KoLmafia settings regarding purchases to gather ingredients &amp;amp; require boxen.}}&lt;br /&gt;
{{Flink|boolean|buy|int|item}}&lt;br /&gt;
{{Flink|int|buy|int|item|int|desc=Tries to purchase the specified items (see page for details).}}&lt;br /&gt;
{{Flink|boolean|autosell|int|item|desc=Attempts to autosell the given items and reports success.}}&lt;br /&gt;
{{Flink|int|craft|string|int|item|item|desc=Raw crafting that obeys KoLmafia settings (see page for details).}}&lt;br /&gt;
[[Category:Scripting]]&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Condition&amp;diff=7139</id>
		<title>Condition</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Condition&amp;diff=7139"/>
		<updated>2010-09-03T06:23:34Z</updated>

		<summary type="html">&lt;p&gt;Theraze: Created page with &amp;#039;Help condition offers the following: condition* clear | check | add condition | set condition - modify your adventuring goals. goal* clear | check | add condition | set condition…&amp;#039;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Help condition offers the following:&lt;br /&gt;
condition* clear | check | add condition | set condition - modify your adventuring goals.&lt;br /&gt;
goal* clear | check | add condition | set condition - modify your adventuring goals.&lt;br /&gt;
objective* clear | check | add condition | set condition - modify your adventuring goals.&lt;br /&gt;
&lt;br /&gt;
condref - list conditions usable with if/while commands.&lt;br /&gt;
&lt;br /&gt;
if condition; commands - do commands once if condition is true (see condref).&lt;br /&gt;
elseif condition; commands - do if condition is true but preceding condition was false.&lt;br /&gt;
while condition; commands - do commands repeatedly while condition is true.&lt;br /&gt;
&lt;br /&gt;
Condition, Goal, and Objective are identical; Goal and Objective just being aliases for Condition.&lt;br /&gt;
&lt;br /&gt;
Condref will provide a list of conditions that can be applied with the if, elseif, or while commands.&lt;/div&gt;</summary>
		<author><name>Theraze</name></author>
	</entry>
</feed>