Tip of the day: If you still have users on plaintext port 6667, consider enabling Strict Transport Security to gently move users to SSL/TLS on port 6697. |
Dev:EFunction API
Registering EFunction
EFunctions are used to permit modules to define "core" functionality in Unreal. A example of this is the m_join core module - m_join registers the EFunc do_join against the EFunc type _do_join - whatever module implements the _do_join EFunc is responsible for handling the join functionality.
Generally, 3rd party modules do not need to add EFuncs and generally you can use command overrides or callbacks in place of EFuncs, but we provide them here for completeness.
EfunctionAdd
EfunctionAdd(module, cbtype, func)
- module - Module the EFunc resides in
- cbtype - The type of EFunc
- func - A pointer to the function to execute when this EFunction is called, of form int (*intfunc)()
Add the given EFunction associating it with the specified module.
EfunctionAddVoid
EfunctionAddVoid(module, cbtype, func)
- module - Module the EFunc resides in
- cbtype - The type of EFunc
- func - A pointer to the function to execute when this EFunction is called, of form void (*voidfunc)()
Add the given EFunction associating it with the specified module.
EfunctionAddPVoid
EfunctionAddPVoid(module, cbtype, func)
- module - Module the EFunc resides in
- cbtype - The type of EFunc
- func - A pointer to the function to execute when this EFunction is called, of form void *(*pvoidfunc)()
Add the given EFunction associating it with the specified module.
EfunctionAddPChar
EfunctionAddPChar(module, cbtype, func)
- module - Module the EFunc resides in
- cbtype - The type of EFunc
- func - A pointer to the function to execute when this EFunction is called, of form char *(*pcharfunc)()
Add the given EFunction associating it with the specified module.
EfunctionDel
Efunction* EfunctionDel(Efunction *cb)
- cb - EFunction object to be deleted
This deletes a given EFunction - keep in mind that should this be called, the EFunction should be immediately replaced with one from another module or behavior of the IRCd is undefined