Boolean modifier: Difference between revisions
imported>Heeheehee mNo edit summary |
imported>Heeheehee No edit summary |
||
Line 1: | Line 1: | ||
boolean_modifier | {{#vardefine:name|boolean_modifier}} | ||
{{#vardefine:return_type|boolean}} | |||
{{FunctionPage| | |||
name={{#var:name}}| | |||
function_category=Your Character| | |||
Softcore Only, Single Equip, Never Fumble, Weakens Monster, Free Pull, Variable, Nonstackable Watch, Cold Immunity, Hot Immunity, Sleaze Immunity, Spooky Immunity, Stench Immunity, Cold Vulnerability, Hot Vulnerability, Sleaze Vulnerability, Spooky Vulnerability, Stench Vulnerability, Moxie Controls MP, Moxie May Control MP, Four Songs, Additional Song, Adventure Underwater, Underwater Familiar | function1={{Function| | ||
name={{#var:name}}| | |||
aggregate={{#var:aggregate}}| | |||
return_type={{#var:return_type}}| | |||
return_also={{#var:return_also}}| | |||
parameter1={{Param|string|str}}| | |||
p1desc={{pspan|str}} is the modifier name| | |||
}}| | |||
function2={{Function| | |||
name={{#var:name}}| | |||
aggregate={{#var:aggregate}}| | |||
return_type=int| | |||
return_also={{#var:return_also}}| | |||
parameter1={{Param|item|it}}| | |||
parameter2={{Param|string|str}}| | |||
p1desc={{pspan|it}} is the item in question| | |||
p2desc={{pspan|str}} is the modifier name| | |||
}}| | |||
function_description=Accesses fields of your current modifiers for all of your current equipment and effects. This is the same mechanism that lets mafia decide whether you can adventure underwater, or how many songs you can keep in your head. <br /><br /> | |||
Here is the current list of fields you can inquire about: <br /> | |||
Softcore Only, Single Equip, Never Fumble, Weakens Monster, Free Pull, Variable, Nonstackable Watch, Cold Immunity, Hot Immunity, Sleaze Immunity, Spooky Immunity, Stench Immunity, Cold Vulnerability, Hot Vulnerability, Sleaze Vulnerability, Spooky Vulnerability, Stench Vulnerability, Moxie Controls MP, Moxie May Control MP, Four Songs, Additional Song, Adventure Underwater, Underwater Familiar| | |||
code1={{CodeSample| | code1={{CodeSample| | ||
Line 18: | Line 43: | ||
{{SeeAlso|numeric_modifier}}| | {{SeeAlso|numeric_modifier}}| | ||
}} |
Revision as of 19:42, 6 March 2010
Function Syntax
boolean boolean_modifier(string str )
- str is the modifier name
int boolean_modifier(item it ,string str )
- it is the item in question
- str is the modifier name
Accesses fields of your current modifiers for all of your current equipment and effects. This is the same mechanism that lets mafia decide whether you can adventure underwater, or how many songs you can keep in your head.
Here is the current list of fields you can inquire about:
Softcore Only, Single Equip, Never Fumble, Weakens Monster, Free Pull, Variable, Nonstackable Watch, Cold Immunity, Hot Immunity, Sleaze Immunity, Spooky Immunity, Stench Immunity, Cold Vulnerability, Hot Vulnerability, Sleaze Vulnerability, Spooky Vulnerability, Stench Vulnerability, Moxie Controls MP, Moxie May Control MP, Four Songs, Additional Song, Adventure Underwater, Underwater Familiar
Simple Example
Tells you if you can adventure underwater or not.
if(!(boolean_modifier("Adventure Underwater"))||!(boolean_modifier("Underwater Familiar"))) {
print("You can't adventure underwater. Either you won't be able to breathe, or your familiar won't.","red");
exit;
}
print("You can adventure underwater.")
See Also