Adoranda/include/talkable.h

21 lines
637 B
C
Raw Normal View History

#pragma once
#include "map.h"
2022-04-02 01:57:54 +02:00
#include "game.h"
struct Talkable {
/*the position of the tile*/
int x, y;
/*the name*/
char *name;
/*the text to display*/
char *text;
};
/*draw the dialog of a specified talkable tile*/
2022-04-02 01:57:54 +02:00
void draw_dialog(struct Game *game);
/*find the talkable tile using the player's position*/
2022-01-21 21:40:12 +01:00
struct Talkable* get_dialog_xy(struct Map *map, int x, int y);
2022-03-22 23:16:37 +01:00
char *word_boundary_before(char *str, char *limit);
2022-04-22 00:32:31 +02:00
char *skip_spaces(char *str);
2022-05-03 00:40:09 +02:00
void format_text(int x, int y, const int color, char const *format, ...);
void format_text_opt(int x, int y, int width, int height, const int color, char const *format, ...);