Monster element: Difference between revisions

From Kolmafia
Jump to navigation Jump to search
imported>Bale
answered RFI
imported>Bale
mNo edit summary
Line 5: Line 5:
FunctionPage|
FunctionPage|
name={{#var:name}}|
name={{#var:name}}|
function_category=Adventuring|
second_category=In-combat Consulting|


function1={{Function|
function1={{Function|
Line 31: Line 29:
special=If no monster is specified and no monster has been fought in this session, this function returns $element[none]. This is because mafia forgets the value of [[last_monster|last_monster()]] when it logs out.|
special=If no monster is specified and no monster has been fought in this session, this function returns $element[none]. This is because mafia forgets the value of [[last_monster|last_monster()]] when it logs out.|
}}
}}
[[Category:Adventuring]]|[[Category:In-combat Consulting]]

Revision as of 22:22, 21 May 2010

needs(code_samples);

Function Syntax

element monster_element()

element monster_element(monster check_me )

  • check_me is the (optional) monster to get the elemental alignment of

Returns the elemental alignment of the specified monster check_me. If check_me is not specified, it defaults to the last monster you encountered.

This function can be used from within an In-combat Consulting script to help determine your fight strategy. When used this way, it isn't necessary to specify a monster, as the function will default to the one currently being fought.

See Also

monster_attack() | monster_defense() | monster_hp()

Special

If no monster is specified and no monster has been fought in this session, this function returns $element[none]. This is because mafia forgets the value of last_monster() when it logs out.

|