Next: GetNamedRoutinePointer - AurieFramework/YYToolkit GitHub Wiki
Retrieves a pointer to a named object.
Syntax
AurieStatus GetNamedRoutinePointer(
[in] const char* FunctionName,
[out] PVOID* FunctionPointer
);
Parameters
FunctionName
A pointer to the buffer containing the name of the object to look up. This parameter can refer to either a GameMaker built-in function, a GameMaker script, or a function name provided by extensions.
[!NOTE] This function is case-sensitive, meaning a script named
scr_my_Script
is different from a script namedscr_my_script
. This behavior is consistent for all types of lookups.
FunctionPointer
A pointer to a pointer-sized buffer that receives the address of the looked-up object. The object pointed-to by this variable is then dependant on the type of lookup used. As of version 3.0.1, the address written to the buffer can either be of a CScript
object if a script was found matching the name being looked up, or a TRoutine
if a built-in GameMaker function was found matching the name. The original contents of the buffer are guaranteed to be preserved if the function fails.
Return Value
Value | Description |
---|---|
AURIE_SUCCESS |
The named routine was found, and the pointer was written into the buffer. |
AURIE_MODULE_INTERNAL_ERROR |
The internal function needed is unavailable. |
AURIE_OBJECT_NOT_FOUND |
The named routine does not exist. |
AURIE_ACCESS_DENIED |
FunctionName refers to an extension function, or the script lookup function is not available. |
Requirements
Criterium | Value |
---|---|
Minimum YYTK Version | 3.0.0 |
Context | Any |