My fullness: Difference between revisions
Jump to navigation
Jump to search
Added categories |
imported>Zarqon added example |
||
Line 1: | Line 1: | ||
[[int]] [[my_fullness()]] | |||
Returns the logged-in character's current fullness as an [[int]]. This can be used in tandem with [[fullness_limit()]] to eat as much of something as possible: | |||
eat | |||
<code> | |||
if ([[my_fullness()]] < ([[fullness_limit()]]-2)) | |||
[[eat()|eat]]([[floor()|floor]](([[fullness_limit()]]-[[my_fullness()]]) / 3), $[[item]][peach pie]); | |||
</code> | |||
[[Category:Your Character | My fullness()]] | [[Category:Your Character | My fullness()]] | ||
[[Category:Ash Functions |My fullness()]] | [[Category:Ash Functions | My fullness()]] | ||
When not logged in, this function returns 0. |
Revision as of 06:44, 29 January 2009
Returns the logged-in character's current fullness as an int. This can be used in tandem with fullness_limit() to eat as much of something as possible:
if (my_fullness() < (fullness_limit()-2))
eat(floor((fullness_limit()-my_fullness()) / 3), $item[peach pie]);
When not logged in, this function returns 0.