Inebriety limit: Difference between revisions

From Kolmafia
Jump to navigation Jump to search
imported>Metraxis
New Page
 
imported>Metraxis
m Spelling
Line 1: Line 1:
[[int]] [[inebriety_limit()]]
[[int]] [[inebriety_limit()]]


This function returns the minimum drunkenness at which the logged-in character's will become falling-down drink as an [[int]].  For characters without a Liver of Steel, this value will be 15.  For those characters with a Liver of Steel, this value is 20.
This function returns the minimum drunkenness at which the logged-in character will become falling-down drink as an [[int]].  For characters without a Liver of Steel, this value will be 15.  For those characters with a Liver of Steel, this value is 20.


An example:
An example:

Revision as of 07:35, 23 January 2007

int inebriety_limit()

This function returns the minimum drunkenness at which the logged-in character will become falling-down drink as an int. For characters without a Liver of Steel, this value will be 15. For those characters with a Liver of Steel, this value is 20.

An example:

void get_sneaky() {
  item FavoredDrink = $item[grogtini];
  while(my_inebriety() < inebriety_limit()) {
    drink(1,FavoredDrink);
  }
  int cirrosis = inebriety_limit() + 10 - my_inebriety();
  drink(cirrosis,$item[green beer]);
  if(inebriety_limit() < 16) {
    print("Not ... drunk ... enough.  Need ... ! ... potion");
  }
}