Crossfire Server, Trunk
|
#include "global.h"
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/stat.h>
#include "book.h"
#include "living.h"
#include "output_file.h"
#include "spells.h"
#include "assets.h"
#include "AssetsManager.h"
Go to the source code of this file.
Data Structures | |
struct | arttypename |
struct | title |
struct | titlelist |
Macros | |
#define | arraysize(arrayname) (sizeof(arrayname)/sizeof(*(arrayname))) |
#define | MAX_TITLE_CHECK 20 |
#define | MSGTYPE_ALCHEMY 4 |
#define | MSGTYPE_ARTIFACT 2 |
#define | MSGTYPE_GODS 5 |
#define | MSGTYPE_LIB 0 |
#define | MSGTYPE_MONSTER 1 |
#define | MSGTYPE_MSGFILE 6 |
#define | MSGTYPE_SPELLPATH 3 |
Functions | |
static void | add_author (object *op, int msgtype) |
static void | add_book (title *book, int type, const char *fname, int lineno) |
static void | add_book_to_list (const object *book, int msgtype) |
static StringBuffer * | artifact_describe (const artifact *art, const artifactlist *al, int message, int art_name, int separator) |
static StringBuffer * | artifact_msg (unsigned int level, size_t booksize) |
int | book_overflow (const char *buf1, const char *buf2, size_t booksize) |
static void | change_book (object *book, int msgtype) |
static void | do_monster (archetype *at) |
static void | do_spellpath_msg (archetype *at) |
static title * | find_title (const object *book, int msgtype) |
void | free_all_readable (void) |
static title * | get_empty_book (void) |
static titlelist * | get_empty_booklist (void) |
sstring | get_message_body (const GeneralMessage *message) |
const Face * | get_message_face (const GeneralMessage *message) |
sstring | get_message_title (const GeneralMessage *message) |
static object * | get_next_mon (const object *tmp) |
object * | get_random_mon (int level) |
const readable_message_type * | get_readable_message_type (object *readable) |
static titlelist * | get_titlelist (int i) |
static StringBuffer * | god_info_msg (int level, size_t booksize, object *book) |
static void | init_book_archive (void) |
static void | init_mon_info (void) |
void | init_readable (void) |
static void | make_formula_book (object *book, int level) |
static StringBuffer * | mon_desc (const object *mon) |
static StringBuffer * | mon_info_msg (int level, size_t booksize, object *book) |
static StringBuffer * | msgfile_msg (object *book, size_t booksize) |
static void | new_text_name (object *book, int msgtype) |
int | nstrtok (const char *buf1, const char *buf2) |
static StringBuffer * | spellpath_msg (int level, size_t booksize, StringBuffer *buf) |
char * | strtoktolin (const char *buf1, const char *buf2, char *retbuf, size_t size) |
void | tailor_readable_ob (object *book, int msg_type) |
const char * | trim (const char *buf) |
static int | unique_book (const object *book, int msgtype) |
void | write_book_archive (void) |
Variables | |
static const char *const | art_author [] |
static const char *const | art_book_name [] |
static const arttypename | art_name_array [] |
static const char *const | book_author [] |
static const char *const | book_descrpt [] |
static titlelist * | booklist = NULL |
static const char *const | formula_author [] |
static const char *const | formula_book_name [] |
static const char *const | gods_author [] |
static const char *const | gods_book_name [] |
static const char *const | heavy_book_name [] |
static const int | last_readable_subtype = arraysize(readable_message_types) |
static const char *const | light_book_name [] |
static const int | max_titles [6] |
static const char *const | mon_author [] |
static const char *const | mon_book_name [] |
static std::vector< object * > | monsters |
static int | need_to_write_bookarchive = 0 |
static const char *const | path_author [] |
static const char *const | path_book_name [] |
static const readable_message_type | readable_message_types [] |
struct { | |
size_t booksize | |
StringBuffer * buf | |
int did_first_sp | |
int done | |
int level | |
uint32_t pnum | |
int prayers | |
} | sp_params |
static const uint32_t | spellpathdef [NRSPELLPATHS] |
This file contains code relevant to the BOOKS hack – designed to allow randomly occuring messages in non-magical texts.
Definition in file readable.cpp.
#define arraysize | ( | arrayname | ) | (sizeof(arrayname)/sizeof(*(arrayname))) |
Returns the element size of an array.
arrayname | the array's name |
Definition at line 98 of file readable.cpp.
#define MAX_TITLE_CHECK 20 |
How many times to try to generate a unique name for a book.
Definition at line 76 of file readable.cpp.
#define MSGTYPE_ALCHEMY 4 |
Alchemy-related information.
Definition at line 87 of file readable.cpp.
#define MSGTYPE_ARTIFACT 2 |
Artifact-related information.
Definition at line 83 of file readable.cpp.
#define MSGTYPE_GODS 5 |
God-related information.
Definition at line 89 of file readable.cpp.
#define MSGTYPE_LIB 0 |
Message from the lib/messages file.
Definition at line 79 of file readable.cpp.
#define MSGTYPE_MONSTER 1 |
Monster-related information.
Definition at line 81 of file readable.cpp.
#define MSGTYPE_MSGFILE 6 |
Message from the lib/messages file.
Definition at line 91 of file readable.cpp.
#define MSGTYPE_SPELLPATH 3 |
Spellpath-related information.
Definition at line 85 of file readable.cpp.
|
static |
A lot like new_text_name() above, but instead chooses an author and sets op->title to that value
op | book to alter. |
msgtype | information we want. |
Definition at line 1023 of file readable.cpp.
References add_string(), arraysize, art_author, book_author, formula_author, gods_author, MAX_BUF, mon_author, MSGTYPE_ALCHEMY, MSGTYPE_ARTIFACT, MSGTYPE_GODS, MSGTYPE_MONSTER, MSGTYPE_MSGFILE, MSGTYPE_SPELLPATH, give::name, give::op, path_author, and RANDOM.
Referenced by change_book(), and make_formula_book().
|
static |
Appends a book to the booklist.
book | the book to add |
type | the book type |
fname | the file name; for error messages |
lineno | the line number; for error messages |
Definition at line 860 of file readable.cpp.
References titlelist::first_book, get_titlelist(), llevInfo, LOG(), title::next, titlelist::number, and is_valid_types_gen::type.
Referenced by init_book_archive().
|
static |
Adds a book to the list of existing books.
book | book to add. |
msgtype | what information the book contains. |
Definition at line 1095 of file readable.cpp.
References add_string(), object::arch, titlelist::first_book, get_empty_book(), get_titlelist(), object::level, llevDebug, llevError, LOG(), object::msg, object::name, archetype::name, need_to_write_bookarchive, titlelist::number, strtoint(), Floor::t, and object::title.
Referenced by change_book().
|
static |
Describe an artifact.
art | artifact to describe. |
al | list art is part of. |
message | if non zero, and the artifact has a suitable message, add it to the description. |
art_name | index in art_name_array the artifact is in. |
separator | if non zero, a separator is inserted at the start of the description. |
Definition at line 1400 of file readable.cpp.
References add_abilities(), artifact::allowed, archininventory::arch, art_name_array, BOOK_BUF, artifact::chance, describe_item(), find_archetype_by_object_name(), FLAG_IDENTIFIED, commongive::inv, artifact::item, llevError, LOG(), diamondslots::message, object::msg, give::name, object::name, object_free_drop_inventory(), object_new(), RANDOM, SET_FLAG, stringbuffer_append_printf(), stringbuffer_append_string(), stringbuffer_append_stringbuffer(), stringbuffer_finish(), stringbuffer_length(), stringbuffer_new(), Ice::tmp, artifactlist::total_chance, try_find_archetype(), artifactlist::type, object::type, and object::value.
Referenced by artifact_msg().
|
static |
Generate a message detailing the properties of 1-6 artifacts drawn sequentially from the artifact list.
level | level of the book. |
booksize | maximum length of the book. |
Definition at line 1483 of file readable.cpp.
References arraysize, art_name_array, artifact_describe(), booksize, find_artifactlist(), npc_dialog::index, artifact::item, artifactlist::items, level, diamondslots::message, object::msg, RANDOM, stringbuffer_append_printf(), stringbuffer_append_string(), stringbuffer_append_stringbuffer(), stringbuffer_delete(), stringbuffer_length(), stringbuffer_new(), is_valid_types_gen::type, and arttypename::type.
Referenced by tailor_readable_ob().
int book_overflow | ( | const char * | buf1, |
const char * | buf2, | ||
size_t | booksize | ||
) |
Checks if buf1 and buf2 can be combined.
buf1 | |
buf2 | buffer we plan on combining. |
booksize | maximum book size. |
Definition at line 719 of file readable.cpp.
References BOOK_BUF, booksize, and buf_overflow().
Referenced by write_note().
|
static |
Give a new, fancier name to generated objects of type BOOK and SPELLBOOK. Aug 96 I changed this so we will attempt to create consistent authour/title and message content for BOOKs. Also, we will alter books that match archive entries to the archival levels and architypes. -b.t.
book | book to alter. Should be of type BOOK. |
msgtype | what information the book contains. |
Definition at line 1137 of file readable.cpp.
References add_author(), add_book_to_list(), add_string(), arraysize, BOOK, book_descrpt, create_archetype(), find_title(), free_string(), get_titlelist(), object::level, llevDebug, llevError, LOG(), MAX_BUF, MAX_TITLE_CHECK, max_titles, object::msg, object::name, new_text_name(), titlelist::number, object_copy(), object_free_drop_inventory(), object_get_value(), object_set_msg(), object_set_value(), RANDOM, sstring, Floor::t, object::title, object::type, and unique_book().
Referenced by tailor_readable_ob().
|
static |
Definition at line 874 of file readable.cpp.
References archetype::clone, FLAG_CHANGING, FLAG_MONSTER, FLAG_UNAGGRESSIVE, archetype::head, MONSTER_EXCLUDE_FROM_READABLE_KEY, monsters, object_get_value(), and QUERY_FLAG.
Referenced by init_mon_info().
|
static |
Callback to write spells in messages
Definition at line 1568 of file readable.cpp.
References archetype::clone, living::grace, object::level, object::name, object::path_attuned, living::sp, sp_params, SPELL, object::stats, stringbuffer_append_string(), stringbuffer_length(), and object::type.
Referenced by spellpath_msg().
Search the titlelist (based on msgtype) to see if book matches something already there. IF so, return that title.
book | book we're searching. |
msgtype | message type. |
Definition at line 935 of file readable.cpp.
References titlelist::first_book, get_titlelist(), npc_dialog::index, llevDebug, LOG(), object::msg, strtoint(), and Floor::t.
Referenced by change_book().
void free_all_readable | ( | void | ) |
Free all readable-related information.
Definition at line 1974 of file readable.cpp.
References title::archname, title::authour, booklist, titlelist::first_book, free_string(), llevDebug, LOG(), title::name, title::next, and titlelist::next.
Referenced by cleanup().
|
static |
Creates a title.
Definition at line 593 of file readable.cpp.
References fatal(), OUT_OF_MEMORY, and Floor::t.
Referenced by add_book_to_list(), and init_book_archive().
|
static |
Creates a titlelist.
Definition at line 576 of file readable.cpp.
References fatal(), and OUT_OF_MEMORY.
Referenced by get_titlelist(), and init_book_archive().
sstring get_message_body | ( | const GeneralMessage * | message | ) |
Get a message's body.
message | message, must not be NULL. |
Definition at line 2077 of file readable.cpp.
References diamondslots::message.
Referenced by knowledge_message_detail().
const Face* get_message_face | ( | const GeneralMessage * | message | ) |
Get a message's face.
message | message, must not be NULL. |
Definition at line 2086 of file readable.cpp.
References diamondslots::message.
Referenced by knowledge_message_face().
sstring get_message_title | ( | const GeneralMessage * | message | ) |
Get a message's title.
message | message, must not be NULL. |
Definition at line 2068 of file readable.cpp.
References diamondslots::message.
Referenced by knowledge_message_summary().
This function returns the next monster after 'tmp' in the monster list.
tmp | monster. |
Definition at line 1320 of file readable.cpp.
References monsters, and Ice::tmp.
Referenced by mon_info_msg().
object* get_random_mon | ( | int | level | ) |
Returns a random monster selected from linked list of all monsters in the current game. Changed 971225 to be greater than equal to level passed. Also made choosing by level more random.
level | if non-zero, then only monsters greater than that level will be returned. |
Definition at line 1269 of file readable.cpp.
References llevError, LOG(), monsters, guildjoin::ob, and RANDOM.
Referenced by alchemy_failure_effect(), and mon_info_msg().
const readable_message_type* get_readable_message_type | ( | object * | readable | ) |
Get the readable type for an object (hopefully book).
readable | object for which we want the readable type. |
Definition at line 2055 of file readable.cpp.
References last_readable_subtype, readable_message_types, and object::subtype.
Referenced by apply_sign(), book_type_apply(), and spellbook_type_apply().
|
static |
Gets the ith titlelist.
Will create items if they don't exist.
i | index to get. |
Definition at line 611 of file readable.cpp.
References arraysize, booklist, get_empty_booklist(), llevInfo, LOG(), max_titles, and titlelist::next.
Referenced by add_book(), add_book_to_list(), change_book(), find_title(), unique_book(), and write_book_archive().
|
static |
Generate a message detailing the properties of a random god. Used by the book hack. b.t.
level | number of elements to give. |
booksize | desired length of the book. |
book | book we're writing the information to, for knowledge management. |
Definition at line 1822 of file readable.cpp.
References BOOK_BUF, booksize, buf, describe_god(), get_rand_god(), GOD_BLESSED, GOD_ENEMY, GOD_HOLYWORD, GOD_IMMUNITIES, GOD_PATHS, GOD_RESISTANCES, GOD_SACRED, llevError, LOG(), object::name, object_set_value(), RANDOM, stringbuffer_delete(), stringbuffer_length(), and stringbuffer_new().
Referenced by tailor_readable_ob().
|
static |
If not called before, initialize the info list.
This reads in the bookarch file into memory. bookarch is the file created and updated across multiple runs of the program.
Definition at line 738 of file readable.cpp.
References add_book(), add_string(), title::archname, arraysize, title::authour, booklist, buf, get_empty_book(), get_empty_booklist(), title::level, llevDebug, llevInfo, Settings::localdir, LOG(), MAX_BUF, max_titles, title::msg_index, title::name, titlelist::next, titlelist::number, settings, title::size, is_valid_types_gen::type, and autojail::value.
Referenced by init_readable().
|
static |
Creates the linked list of pointers to monster archetype objects if not called previously.
Definition at line 886 of file readable.cpp.
References archetypes_for_each(), do_monster(), llevDebug, LOG(), and monsters.
Referenced by init_readable().
void init_readable | ( | void | ) |
Initialize linked lists utilized by message functions in tailor_readable_ob()
This is the function called by the main routine to initialize all the readable information.
Definition at line 904 of file readable.cpp.
References init_book_archive(), init_mon_info(), llevDebug, and LOG().
Referenced by generate_map(), init_beforeplay(), ResourcesManager::load(), and main().
|
static |
Generate a message detailing the properties of a randomly selected alchemical formula.
book | book we write to. |
level | level for formulaes and such. |
knowledge marker
Definition at line 1642 of file readable.cpp.
References add_author(), recipe::arch_name, recipe::arch_names, arraysize, recipe::cauldron, recipe::chance, archetype::clone, disinfect::count, recipe::diff, find_archetype(), formula_book_name, free_string(), get_formulalist(), recipe::index, recipe::ingred, recipe::is_combination, recipelist::items, llevError, LOG(), MAX_BUF, MSGTYPE_ALCHEMY, give::name, object::name, new_text_name(), recipe::next, give::next, object_set_msg(), object_set_value(), query_name(), RANDOM, recipe_get_difficulty_string(), recipe::skill, stringbuffer_append_printf(), stringbuffer_append_string(), stringbuffer_finish(), stringbuffer_finish_shared(), stringbuffer_new(), guild_entry::text, recipe::title, object::title, and recipelist::total_chance.
Referenced by tailor_readable_ob().
|
static |
Returns a description of the monster. This really needs to be redone, as describe_item really gives a pretty internal description.
mon | monster to describe. |
Definition at line 1298 of file readable.cpp.
References describe_item(), object::lore, mon, object::name, stringbuffer_append_printf(), and stringbuffer_new().
Referenced by mon_info_msg().
|
static |
Generate a message detailing the properties of randomly monster(s), and add relevant knowledge markers.
level | book level. |
booksize | size (in characters) of the book we want. |
book | book in which we will put the information. |
Definition at line 1343 of file readable.cpp.
References booksize, free_string(), get_next_mon(), get_random_mon(), mon, mon_desc(), object_set_value(), sstring, stringbuffer_append_printf(), stringbuffer_append_string(), stringbuffer_append_stringbuffer(), stringbuffer_delete(), stringbuffer_finish_shared(), stringbuffer_length(), stringbuffer_new(), and Ice::tmp.
Referenced by tailor_readable_ob().
|
static |
Generate a message drawn randomly from lib/messages.
book | book to fill. |
booksize | length of the book we want. |
knowledge marker
Definition at line 1773 of file readable.cpp.
References booksize, animate::event, find_archetype(), FREE_AND_COPY, getManager(), HUGE_BUF, llevDebug, LOG(), AssetsManager::messages(), navar-midane_pickup::msg, object::name, object_create_arch(), object_insert_in_ob(), object_set_value(), Messages::random(), stringbuffer_append_string(), and stringbuffer_new().
Referenced by tailor_readable_ob().
|
static |
Only for objects of type BOOK. SPELLBOOK stuff is handled directly in change_book_name(). Names are based on text msgtype
This sets book book->name based on msgtype given. What name is given is based on various criteria
book | book we want to alter. |
msgtype | what information we want in the book. |
Definition at line 974 of file readable.cpp.
References add_string(), arraysize, art_book_name, BOOK, formula_book_name, free_string(), gods_book_name, heavy_book_name, light_book_name, mon_book_name, MSGTYPE_ALCHEMY, MSGTYPE_ARTIFACT, MSGTYPE_GODS, MSGTYPE_MONSTER, MSGTYPE_MSGFILE, MSGTYPE_SPELLPATH, give::name, object::name, path_book_name, RANDOM, object::type, and object::weight.
Referenced by change_book(), and make_formula_book().
int nstrtok | ( | const char * | buf1, |
const char * | buf2 | ||
) |
Simple routine to return the number of list items in buf1 as separated by the value of buf2
buf1 | items we want to split. |
buf2 | what to split by. |
Definition at line 642 of file readable.cpp.
References buf, MAX_BUF, and strlcpy().
Referenced by describe_god(), and strtoktolin().
|
static |
Generate a message detailing the member incantations/prayers (and some of their properties) belonging to a random spellpath.
level | level of the book. |
booksize | maximumlength of the book. |
buf | where to store the message. If not NULL, it is supposed to contain the message header. |
Definition at line 1602 of file readable.cpp.
References archetypes_for_each(), booksize, buf, do_spellpath_msg(), level, NRSPELLPATHS, python_init::path, RANDOM, sp_params, spellpathdef, spellpathnames, stringbuffer_append_printf(), stringbuffer_append_string(), stringbuffer_delete(), and stringbuffer_new().
Referenced by tailor_readable_ob().
char* strtoktolin | ( | const char * | buf1, |
const char * | buf2, | ||
char * | retbuf, | ||
size_t | size | ||
) |
Takes a string in buf1 and separates it into a list of strings delimited by buf2. Then returns a comma separated string w/ decent punctuation.
buf1 | buffer to split. |
buf2 | what to split buf1 by. |
retbuf | where to write the resulting string. |
size | length of retbuf. |
Definition at line 684 of file readable.cpp.
References buf, MAX_BUF, nstrtok(), strlcpy(), and trim().
Referenced by describe_god().
void tailor_readable_ob | ( | object * | book, |
int | msg_type | ||
) |
The main routine. This chooses a random message to put in given readable object (type==BOOK) which will be referred hereafter as a 'book'. We use the book level to de- termine the value of the information we will insert. Higher values mean the book will (generally) have better/more info. See individual cases as to how this will be utilized. "Book" name/content length are based on the weight of the document. If the value of msg_type is negative, we will randomly choose the kind of message to generate. -b.t. thoma s@as tro.p su.e du
book | the object we are creating into. Must be a book, can have a level. |
msg_type | if it is a positive value, we use that to determine the message type - otherwise a random value is used. |
Definition at line 1892 of file readable.cpp.
References arraysize, artifact_msg(), BOOK, BOOK_BUF, BOOKSIZE, change_book(), god_info_msg(), make_face_from_files::int, object::level, make_formula_book(), max_titles, diamondslots::message, mon_info_msg(), msgfile_msg(), MSGTYPE_ALCHEMY, MSGTYPE_ARTIFACT, MSGTYPE_GODS, MSGTYPE_LIB, MSGTYPE_MONSTER, MSGTYPE_SPELLPATH, object_set_msg(), RANDOM, spellpath_msg(), stringbuffer_append_string(), stringbuffer_finish(), and object::type.
Referenced by fix_generated_item().
const char* trim | ( | const char * | buf | ) |
Return buf without its leading spaces.
buf | what to trim. |
Definition at line 661 of file readable.cpp.
References buf.
Referenced by inja::Lexer::scan_body(), and strtoktolin().
|
static |
Check to see if the book title/msg is unique. We go through the entire list of possibilities each time. If we find a match, then unique_book returns true (because inst unique).
book | book we're searching. |
msgtype | type of information contained. |
Definition at line 1071 of file readable.cpp.
References title::authour, booklist, get_titlelist(), title::name, object::name, title::next, and object::title.
Referenced by change_book().
void write_book_archive | ( | void | ) |
Write out the updated book archive to bookarch file.
Definition at line 2005 of file readable.cpp.
References title::archname, title::authour, titlelist::first_book, get_titlelist(), npc_dialog::index, title::level, llevDebug, llevError, Settings::localdir, LOG(), MAX_BUF, title::msg_index, title::name, need_to_write_bookarchive, title::next, titlelist::next, of_close(), of_open(), SAVE_MODE, settings, and title::size.
Referenced by cleanup(), and do_specials().
|
static |
Used by artifact texts
Definition at line 245 of file readable.cpp.
Referenced by add_author().
|
static |
Book titles for artifact information.
Definition at line 227 of file readable.cpp.
Referenced by new_text_name().
|
static |
Artiface/item information.
if it isnt listed here, then art_attr_msg() will never generate a message for this type of artifact. -b.t.
Definition at line 207 of file readable.cpp.
Referenced by artifact_describe(), and artifact_msg().
|
static |
|
static |
Book descriptions.
Definition at line 458 of file readable.cpp.
Referenced by change_book().
|
static |
Buffer of books read in from the bookarch file. It's element size does not exceed arraysize(max_titles).
Definition at line 139 of file readable.cpp.
Referenced by free_all_readable(), get_titlelist(), init_book_archive(), and unique_book().
size_t booksize |
Definition at line 1564 of file readable.cpp.
Referenced by artifact_msg(), book_overflow(), god_info_msg(), mon_info_msg(), msgfile_msg(), and spellpath_msg().
StringBuffer* buf |
Definition at line 1565 of file readable.cpp.
Referenced by account_add_player_cmd(), account_char_load_from_file(), account_login_cmd(), account_new_cmd(), account_password(), account_play_cmd(), accounts_load(), add_abilities(), add_capacity(), add_me_cmd(), add_required_parameter(), adjust_sign_msg(), animate_weapon(), nlohmann::detail::dtoa_impl::append_exponent(), apply_anim_suffix(), apply_changes_to_player(), apply_check_race_restrictions(), apply_cmd(), apply_race_and_class(), ask_smooth_cmd(), assets_pack(), attack_message(), attempt_steal(), basic_emote(), can_pay(), cast_consecrate(), cf_get_maps_directory(), cf_log(), cf_object_get_string_property(), cf_random_map_set_variable(), cfapi_get_hooks(), cfapi_map_set_map_property(), cfapi_object_get_property(), cfapi_object_split(), cfapi_player_message(), cfapi_set_random_map_variable(), cfpython_globalEventListener(), check_loaded_object(), check_login(), check_path(), checkbanned(), checkdm(), choose_cult_monster(), command_addexp(), command_banish(), command_bowmode(), command_cointoss(), command_loadplugin(), command_loadtest(), command_me(), command_party(), command_players(), command_possess(), command_rename_item(), command_statistics(), command_title(), common_ob_describe(), compute_face_name(), convert_newline(), copy_file(), cost_approx_str(), cost_string_from_value(), costStringFromValue(), create_items_path(), create_overlay_pathname(), create_pathname(), create_player_cmd(), create_singularity(), create_template_pathname(), Crossfire_Object_Say(), decode_name_password(), delete_character(), describe_attacktype(), describe_god(), describe_item(), describe_monster(), describe_resistance(), describe_spellpath_attenuation(), display_motd(), do_pack(), do_tell(), doWrite(), dragon_ability_gain(), dragon_eat_flesh(), draw_ext_info_format(), draw_one_high_score(), dump_alchemy(), dump_alchemy_costs(), eat_common(), enter_exit(), enter_random_map(), esrv_draw_look(), esrv_send_inventory(), esrv_update_stats(), eventListener(), events_execute_global_event(), examine(), examine_cmd(), fill_json(), fill_reverse_maps(), food_type_apply(), forbid_play(), nlohmann::detail::dtoa_impl::format_buffer(), generate_monster(), generate_name(), generate_random_map(), getPluginProperty(), globalEventListener(), god_enchants_weapon(), god_examines_item(), god_info_msg(), gravestone_text(), nlohmann::detail::dtoa_impl::grisu2(), nlohmann::detail::dtoa_impl::grisu2_round(), hiscore_load(), hiscore_save(), infect_object(), init_attackmess(), init_book_archive(), init_experience(), init_formulae(), init_regions(), init_renderer_env(), init_server(), init_startup(), init_stats(), initPlugins(), inscribe_scroll_cmd(), key_change_class(), key_confirm_quit(), kill_object(), kill_player(), kill_player_not_permadeath(), kill_player_permadeath(), knowledge_add_probe_monster(), knowledge_alchemy_can_use_item(), knowledge_alchemy_detail(), knowledge_alchemy_summary(), knowledge_god_add(), knowledge_god_detail(), knowledge_god_face(), knowledge_god_summary(), knowledge_item_can_be_used_alchemy(), knowledge_message_detail(), knowledge_message_summary(), knowledge_monster_detail(), knowledge_monster_summary(), knowledge_process_incremental(), knowledge_show(), lamp_type_describe(), legacy_ob_describe(), ArtifactLoader::load(), FacesetLoader::load(), MessageLoader::load(), PngLoader::load(), FaceLoader::load(), QuestLoader::load(), TreasureLoader::load(), ResourcesManager::load(), load_map_header(), load_materials(), load_object_from_reader(), load_races(), load_settings(), load_table_float(), load_table_int(), FaceLoader::loadAnimationBlock(), TreasureLoader::loadTreasure(), LOG(), look_at_cmd(), main(), make_path_to_file(), metaserver2_init(), monster_find_enemy(), monster_format_say(), monster_npc_say(), move_cmd(), new_connection(), new_player_cmd(), npcSay(), nstrtok(), numb_ingred(), ob_describe(), pack_artifacts(), pack_formulae(), party_form(), party_join(), party_leave(), perceive_self(), pets_summon_golem(), pick_up_object(), place_exits(), place_special_exit(), player_get_title(), player_lvl_adj(), power_crystal_describe(), pray(), print_los(), put_score(), python_command_function(), query_base_name(), query_name(), query_short_name(), query_weight(), quest_write_condition(), read_ignore_list(), read_map_log(), read_type(), ready_map_name(), real_money_value(), remove_directory(), replace_unprintable_chars(), reply_cmd(), request_info_cmd(), resurrect_player(), ring_desc(), send_arch_info(), send_delayed_buffers(), send_file(), send_new_char_info(), send_news(), send_plugin_custom_message(), send_rules(), set_exception(), set_random_map_variable(), set_title(), set_up_cmd(), set_variable(), shop_inventory_type_apply(), spellbook_type_describe(), spellpath_msg(), ss_dump_statistics(), ss_dump_table(), START_TEST(), stringbuffer_append_int64(), stringbuffer_append_multiline_block(), strip_endline(), strtoint(), strtoktolin(), tailor_god_spell(), time_format_time(), trim(), verify_player(), version_cmd(), ArtifactWriter::write(), TreasureWriter::write(), MessageWriter::write(), FaceWriter::write(), FormulaeWriter::write(), ArchetypeWriter::write(), QuestWriter::write(), AnimationWriter::write(), FacesetWriter::write(), ModifiedAssetsManager< Animations >::write(), write_attribute_file(), write_attribute_index(), write_map_log(), write_map_parameters_to_string(), write_note(), write_rune(), Write_To_Socket(), write_type_file(), write_type_index(), writeItem(), Utils::writeLinkedChar(), writeRecipe(), Utils::writeStringArray(), and yy_scan_bytes().
int did_first_sp |
Definition at line 1561 of file readable.cpp.
int done |
Definition at line 1566 of file readable.cpp.
Referenced by cost_string_from_value(), and CREMainWindow::onReportQuests().
|
static |
This isn't used except for empty books.
Definition at line 356 of file readable.cpp.
Referenced by add_author().
|
static |
Alchemy (formula) information.
Definition at line 342 of file readable.cpp.
Referenced by make_formula_book(), and new_text_name().
|
static |
Used by gods texts.
Definition at line 321 of file readable.cpp.
Referenced by add_author().
|
static |
God book information.
Definition at line 304 of file readable.cpp.
Referenced by new_text_name().
|
static |
Name for big books.
Definition at line 397 of file readable.cpp.
Referenced by new_text_name().
|
static |
Number of elements in readable_message_types.
Definition at line 549 of file readable.cpp.
Referenced by get_readable_message_type().
int level |
Definition at line 1563 of file readable.cpp.
Referenced by artifact_msg(), cast_detection(), cast_polymorph(), caster_level(), cfapi_object_remove_depletion(), CREExperienceWindow::CREExperienceWindow(), Crossfire_Object_RemoveDepletion(), do_harvest(), examine_monster(), exp_level(), hideability(), init_attackmess(), init_library(), level_exp(), level_for_item(), log_message(), mimic_type_apply(), monsterFight(), mood_change(), CREMainWindow::onReportSummon(), reportSummon(), spellpath_msg(), spellsTable(), START_TEST(), and inja::Renderer::visit().
|
static |
Generic book information Used by msg file and 'generic' books.
Definition at line 378 of file readable.cpp.
Referenced by new_text_name().
|
static |
Number of titles for different name lists.
Definition at line 552 of file readable.cpp.
Referenced by change_book(), get_titlelist(), init_book_archive(), and tailor_readable_ob().
|
static |
Used by monster beastuary texts.
Definition at line 282 of file readable.cpp.
Referenced by add_author().
|
static |
Monster book information.
Definition at line 261 of file readable.cpp.
Referenced by new_text_name().
|
static |
Information on monsters.
Definition at line 142 of file readable.cpp.
Referenced by do_monster(), get_next_mon(), get_random_mon(), init_mon_info(), and CREMainWindow::onReportPlayer().
|
static |
If set then we have information to save.
Definition at line 144 of file readable.cpp.
Referenced by add_book_to_list(), and write_book_archive().
|
static |
Used by spellpath texts.
Definition at line 183 of file readable.cpp.
Referenced by add_author().
|
static |
Book names for path information.
Definition at line 173 of file readable.cpp.
Referenced by new_text_name().
uint32_t pnum |
Definition at line 1562 of file readable.cpp.
int prayers |
Definition at line 1560 of file readable.cpp.
|
static |
Each line of this array is a readable subtype. Be careful to keep the order. If you add readable subtype, add them at the bottom of the list. Never delete a subtype because index is used as subtype parameter in arch files!
Definition at line 485 of file readable.cpp.
Referenced by get_readable_message_type().
struct { ... } sp_params |
Referenced by do_spellpath_msg(), and spellpath_msg().
|
static |
Spellpath information.
Definition at line 149 of file readable.cpp.
Referenced by spellpath_msg().