diff --git a/include/arm11/acl.h b/include/arm11/acl.h new file mode 100644 index 0000000..dc22b22 --- /dev/null +++ b/include/arm11/acl.h @@ -0,0 +1,68 @@ +#ifndef _ANOD_CHEAT_LIBRARY_ +#define _ANOD_CHEAT_LIBRARY_ + +#include + +#define INPUT(type) type +#define OUTPUT(type) type* + +#define ACL_ENTRY_HOLE 1 +#define ACL_ENTRY_KEY 2 + +typedef int acl_error_t; +typedef void * acl_lib_t; +typedef void * acl_list_t; +typedef void * acl_bundle_t; +typedef void * acl_entry_t; +typedef const char* acl_text_t; +typedef uint8_t acl_boolean_t; +typedef uint8_t acl_cheatid_t; +typedef uint32_t acl_entryid_t; +typedef uint8_t acl_entrytype_t; +typedef uint16_t acl_entrylen_t; +typedef uint16_t acl_index_t; +typedef uint32_t acl_armcode_t; + +acl_error_t acl_open_lib( + INPUT(acl_text_t) path_for_cht_file, + OUTPUT(acl_lib_t) library_instance +); + +acl_error_t acl_select_game( + INPUT(acl_lib_t) library_instance, + INPUT(acl_text_t) code_for_game, + INPUT(acl_boolean_t) check_language_for_code, + OUTPUT(acl_list_t) cheat_list_instance +); + +acl_error_t acl_load_cheat( + INPUT(acl_list_t) cheat_list_instance, + INPUT(acl_cheatid_t) cheat_id, + OUTPUT(acl_bundle_t) bundle_instance +); + +acl_error_t acl_visit_bundle( + INPUT(acl_bundle_t) bundle_instance, + INPUT(acl_entryid_t) entry_id, + OUTPUT(acl_entry_t) entry_instance +); + +acl_entrytype_t acl_entry_type( + INPUT(acl_entry_t) entry_instance +); + +acl_entrylen_t acl_entry_length( + INPUT(acl_entry_t) entry_instance +); + +acl_text_t acl_entry_label( + INPUT(acl_entry_t) entry_instance, + INPUT(acl_index_t) index_of_entry +); + +acl_armcode_t acl_entry_value( + IPUT(acl_entry_t) entry_instance, + INPUT(acl_index_t) index_of_entry +); + +#endif//_ANOD_CHEAT_LIBRARY_ \ No newline at end of file