From 6516b26acec2abd862a3c1f42886e749e2dfad5c Mon Sep 17 00:00:00 2001 From: kartofen Date: Fri, 14 Oct 2022 18:17:46 +0300 Subject: a little bit more user friendly --- src/markov.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/markov.h') diff --git a/src/markov.h b/src/markov.h index 2cb22ce..1c95775 100644 --- a/src/markov.h +++ b/src/markov.h @@ -11,8 +11,13 @@ extern int ITEMS; extern double chain[][ITEM_CAP]; extern char item_names[][64]; -void generate_chain(char *file_path) +void generate_chain() { + char *file_path = NULL; + #ifdef FILE_PATH + file_path = FILE_PATH; + #endif + FILE *fp = fopen(file_path, "r"); if(!fp) { fprintf(stderr, "ERROR: Could not open file %s\n", file_path); -- cgit v1.2.3