Inebriety limit: Difference between revisions
Jump to navigation
Jump to search
imported>StDoodle mNo edit summary |
imported>Heeheehee m Nitpick... |
||
Line 27: | Line 27: | ||
overdrink(1 , favored_drink); | overdrink(1 , favored_drink); | ||
} | } | ||
int | int cirrhosis = inebriety_limit() + 10 - my_inebriety(); | ||
overdrink( | overdrink(cirrhosis , $item[green beer]); | ||
if (inebriety_limit() < 16) { | if (inebriety_limit() < 16) { | ||
print("Not... drunk... enough. Need... !... potion."); | print("Not... drunk... enough. Need... !... potion."); |
Revision as of 05:24, 28 March 2010
Function Syntax
int inebriety_limit()
Returns the maximum safe drunkenness of a character before becoming falling-down drunk.
For characters without Liver of Steel, this value is 14. With Liver of Steel, the value is 19.
Code Sample
This example drinks you silly on St. Sneaky Pete's Day:
void get_sneaky() {
item favored_drink = $item[grogtini];
while (my_inebriety() < inebriety_limit()) {
overdrink(1 , favored_drink);
}
int cirrhosis = inebriety_limit() + 10 - my_inebriety();
overdrink(cirrhosis , $item[green beer]);
if (inebriety_limit() < 16) {
print("Not... drunk... enough. Need... !... potion.");
}
}
See Also
Special
When not logged in, this function returns 14.