callfunc()
¶
Warning
This page may contain outdated information, incompatible with the current version of Hercules and its coding standards.
Syntax¶
Description¶
This command lets you call up a function NPC. A function NPC can be called from
any script on any map server. Using the return
command it will come back to
the place that called it.
You can pass arguments to your function - values telling it what exactly to do -
which will be available there with getarg()
.
Notice that returning is not mandatory, you can end execution right there.
If you want to return a real value from inside your function NPC, it is better to write it in the function form, which will also work and will make the script generally cleaner.