Go to the documentation of this file.
26 int text = 0, nrofmsg = 0;
38 while (cp >
buf && (cp[-1] ==
' ' || cp[-1] ==
'\t'))
45 if (
text && strncmp(
buf,
"ENDMSG", 6) == 0) {
47 LOG(
llevDebug,
"Warning: this string exceeded max book buf size:\n");
51 if (
tmp->identifier[0] !=
'\n' &&
tmp->title == NULL) {
68 }
else if (strcmp(
buf,
"TEXT") == 0) {
70 }
else if (strncmp(
buf,
"CHANCE ", 7) == 0) {
71 tmp->chance = atoi(
buf + 7);
72 }
else if (strncmp(
buf,
"TITLE ", 6) == 0) {
74 }
else if (strncmp(
buf,
"QUEST ", 6) == 0) {
76 }
else if (strncmp(
buf,
"FACE ", 5) == 0) {
82 }
else if (strncmp(
buf,
"MSG", 3) == 0) {
94 if (!
tmp->identifier) {
size_t bufferreader_current_line(BufferReader *br)
AssetsTracker * m_tracker
void LOG(LogLevel logLevel, const char *format,...)
MessageLoader(Messages *messages, AssetsTracker *tracker)
const Face * find_face(const char *name)
T * define(const Key &name, T *asset)
sstring add_string(const char *str)
virtual void assetDefined(const archetype *asset, const std::string &filename)
void fatal(enum fatal_error err)
static char msgbuf[HUGE_BUF]
virtual void load(BufferReader *reader, const std::string &filename) override
int buf_overflow(const char *buf1, const char *buf2, size_t bufsize)
char * bufferreader_next_line(BufferReader *br)