Difference between revisions of "Elemental resistance"
Jump to navigation
Jump to search
imported>Alhifar m |
imported>StDoodle m |
||
Line 1: | Line 1: | ||
− | {{#vardefine:name|elemental_resistance}} | + | {{ |
− | {{#vardefine:return_type|float}} | + | #vardefine:name|elemental_resistance}}{{ |
+ | #vardefine:return_type|float}}{{ | ||
− | + | FunctionPage| | |
name={{#var:name}}| | name={{#var:name}}| | ||
function_category=Your Character| | function_category=Your Character| |
Revision as of 15:00, 8 March 2010
Function Syntax
float elemental_resistance(element )
- The parameter of element is invoked using $element. Valid elements are hot ($element[hot]), cold, stench, spooky, sleaze.
Returns your current resistance for a specified element in the form of a floating point integer.
Code Samples
Checks that you have a resistance greater than 20 for the element "hot".
boolean hot_check() {
if(elemental_resistance($element[hot]) > 20) {
return true;
}
return false;
}
Special
When not logged in the function returns 0.0