Faxbot: Difference between revisions
Jump to navigation
Jump to search
imported>Vorzer Created page with "{{ #vardefine:name|faxbot}}{{ #vardefine:return_type|boolean}}{{ FunctionPage| name={{#var:name}}| function1={{Function| name={{#var:name}}| return_type={{#var:return_type}}..." |
imported>Pineapple of Despair Bot name is a string, not a dedicated object. Confirmed by looking at the source code. |
||
(3 intermediate revisions by 2 users not shown) | |||
Line 10: | Line 10: | ||
return_type={{#var:return_type}}| | return_type={{#var:return_type}}| | ||
parameter1={{Param|monster|m}}|| | parameter1={{Param|monster|m}}|| | ||
}}| | }}| | ||
function2={{Function| | |||
name={{#var:name}}| | |||
return_type={{#var:return_type}}| | |||
parameter1={{Param|monster|m}}|| | |||
parameter2={{Param|string|n}}|| | |||
p1desc={{Pspan|m}} is the monster of which to request a fax.| | |||
p2desc={{Pspan|n}} is the name of the supported bot from to request a fax. If not specified, mafia will traverse its list of faxbots and pick the first one that is online and has your monster.| | |||
}}| | |||
function_description=Requests the specified monster from one of mafia's known faxbots (as of r19492 this is just EasyFax or CheeseFax).| | |||
code1={{CodeSample| | code1={{CodeSample| | ||
Line 25: | Line 34: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
}}| | }}| | ||
see_also={{SeeAlso|can_faxbot|is_online}}| | |||
special=The chat must be open for this function to successfully work, just as for other mafia fax interfaces. | special=The chat must be open for this function to successfully work, just as for other mafia fax interfaces. | ||
}} | }} | ||
[[Category:Miscellaneous Functions]] |
Latest revision as of 10:36, 21 August 2019
Function Syntax
boolean faxbot(monster m ,string n )
- m is the monster of which to request a fax.
- n is the name of the supported bot from to request a fax. If not specified, mafia will traverse its list of faxbots and pick the first one that is online and has your monster.
Requests the specified monster from one of mafia's known faxbots (as of r19492 this is just EasyFax or CheeseFax).
Code Samples
This will acquire a copy of a scary pirate if you're able to get a fax.
if ((get_property("_photocopyUsed")=="false")&&(item_amount($item[photocopied monster])==0)) {
faxbot($monster[scary pirate]);
}
See Also
Special
The chat must be open for this function to successfully work, just as for other mafia fax interfaces.