![]() |
Crossfire Server, Trunk
1.75.0
|
Go to the source code of this file.
Data Structures | |
| struct | ob_methods |
| This struct stores function pointers for actions that can be done to objects. More... | |
Macros | |
| #define | METHOD_ERROR 2 |
| #define | METHOD_OK 0 |
| #define | METHOD_SILENT_ERROR 3 |
| Player was warned she can't use the item for now. More... | |
| #define | METHOD_UNHANDLED 1 |
Typedefs | |
| typedef method_ret(* | apply_func) (object *, object *, int) |
| Typedefs for ob_methods. More... | |
| typedef void(* | describe_func) (const object *, const object *, int use_media_tags, char *buf, size_t size) |
| typedef char | method_ret |
| Define some standard return values for callbacks which don't need to return any other results. More... | |
| typedef method_ret(* | move_on_func) (object *, object *, object *) |
| typedef method_ret(* | process_func) (object *) |
| typedef method_ret(* | trigger_func) (object *, object *, int) |
Object type functions and variables.
Definition in file ob_methods.h.
| #define METHOD_ERROR 2 |
Definition at line 17 of file ob_methods.h.
| #define METHOD_OK 0 |
Definition at line 15 of file ob_methods.h.
| #define METHOD_SILENT_ERROR 3 |
Player was warned she can't use the item for now.
Definition at line 18 of file ob_methods.h.
| #define METHOD_UNHANDLED 1 |
Definition at line 16 of file ob_methods.h.
| typedef method_ret(* apply_func) (object *, object *, int) |
Typedefs for ob_methods.
Also used in ob_types.c for storing the pointers temporarily. As a convention, callbacks parameters should begin with "ob_methods *context, object *ob", and return method_ret unless it needs to return something else.
Definition at line 30 of file ob_methods.h.
| typedef void(* describe_func) (const object *, const object *, int use_media_tags, char *buf, size_t size) |
Definition at line 32 of file ob_methods.h.
| typedef char method_ret |
Define some standard return values for callbacks which don't need to return any other results.
Later this might be expanded into a more complex return value system if necessary
Definition at line 14 of file ob_methods.h.
| typedef method_ret(* move_on_func) (object *, object *, object *) |
Definition at line 33 of file ob_methods.h.
| typedef method_ret(* process_func) (object *) |
Definition at line 31 of file ob_methods.h.
| typedef method_ret(* trigger_func) (object *, object *, int) |
Definition at line 34 of file ob_methods.h.