From 68171ac6e71ed90cead929670c06efeec2882d7d Mon Sep 17 00:00:00 2001 From: Vince Weaver Date: Mon, 25 Jun 2018 15:59:53 -0400 Subject: [PATCH] tfv: start adding dialog support --- gr-sim/tfv/Makefile | 2 +- gr-sim/tfv/tfv_dialog.h | 180 ++++++++++++++++++++++++++++++++++++++ gr-sim/tfv/tfv_worldmap.c | 2 + 3 files changed, 183 insertions(+), 1 deletion(-) create mode 100644 gr-sim/tfv/tfv_dialog.h diff --git a/gr-sim/tfv/Makefile b/gr-sim/tfv/Makefile index d6291434..8bdb069e 100644 --- a/gr-sim/tfv/Makefile +++ b/gr-sim/tfv/Makefile @@ -106,7 +106,7 @@ tfv_textentry.o: tfv_textentry.c tfv_title.o: tfv_title.c ../tfv_utils.h tfv_backgrounds.h $(CC) $(CFLAGS) -c tfv_title.c -tfv_worldmap.o: tfv_worldmap.c tfv_mapinfo.h +tfv_worldmap.o: tfv_worldmap.c tfv_mapinfo.h tfv_dialog.h $(CC) $(CFLAGS) -c tfv_worldmap.c diff --git a/gr-sim/tfv/tfv_dialog.h b/gr-sim/tfv/tfv_dialog.h new file mode 100644 index 00000000..ad997310 --- /dev/null +++ b/gr-sim/tfv/tfv_dialog.h @@ -0,0 +1,180 @@ +#define ACTION_NONE 0 +#define ACTION_ITEM 1 +#define ACTION_TIME 2 + + +#define DIALOG_LIZ_WILL 0 + +struct dialog_words { + char *words; + int next; + int action; +}; + +struct dialog_type { + int count; + struct dialog_words statement[5]; +}; + +struct dialog_type dialog[100]={ + + [DIALOG_LIZ_WILL] = { + .statement[0].words="Let\'s discuss cool things in the lounge.", + .statement[0].next=0, + .statement[1].words="YES!", + .statement[1].next=0, + .statement[2].words="Sorry, need to do engineering homework.", + .statement[2].next=0, + /* FOUR HOURS PASS */ + .statement[2].action=ACTION_TIME, + }, + +#if 0 + + + PETE + YOUR JOURNEY MAY TAKE YOU TO DARKEST BEL AIR + PLOT! + KENJESU + HAVE YOU FOUND YOUR LOST GUINEA PIG + MATHEMAGICIAN + HAVE YOU TRIED FINDING THE EIGENVALUES + DARTH TATER + IN TALBOT 0101B + THERE LIVED A BIG GIANT BEE + +DINING HALL + OSCAR + BEWARE THE KILLER CRABS + THEY WANT TO MEET YOU + THEY WANT TO EAT YOU + NICOLE + CINDY + ELAINE + REMEMBER OHMS LAW + TWINKLE TWINKLE LITTLE STAR + V IS EQUAL TO IR + CAFETERIA LADY + HAPPY BIRTHDAY + +METRO STATION + METRO WORKER + WOULD YOU LIKE TO BUY A SMARTPASS + SORRY ALL TRAINS CANCELLED: SMARTTRIP + TINY CAPABARA + GRONK + GIANT GUINEA PIG + SQUEAK? + -> YES + -> NO + LARGE BIRD + WARK? + -> YES + -> NO + +FOUNTAIN -- drink from it restore heatlh? + MERMAID + Did ye put bubbles in yon fountain? + + + +BEL AIR + +CMW + NO ADMITTANCE WITHOUT TRENCHCOAT + +MALL + +MINIGOLF + CLOSED FOR THE SEASON + +JC + + + + VIDEO HOMEROOM + SISTER SCARYNUN + GUS I FOUND THIS + RAISTLIN + THIS MAY AID YOU ON YOUR JOURNEY + AMIGA + FORD + 557-0868 UTOPIA BBS IS REALLY GREAT + + AP CALCULUS, TEAM I-1 + PADRINO + I MET SOMEONE AT THE DOG SHOW + SHE WAS HOLDING MY LEFT ARM + JENNI + NEED TO GO TO ART ROOM + JEN JENNY JENNO AND JENN WAITING + MR. APPLEBY ROAR + KATHY + LOW D-HIGH LESS HIGH D-LOW + DRAW A LINE AND DOWN BELOW + DENOMINATOR SQUARED MUST GO + LIZBETH + BLUME + VINCE CON PATILLAS + DEUTSCH + AGENT G + AGENT AP + AGENT S + NIRE + FRAU: DER DIE DAS + + HOMEROOM + TRAPANI + WEAVE! + MAN THAT PARTY WAS SOMETHING ELSE + WARWICK + MARIOKART PARTY AT MY HOUSE + WARGO + WARWICK! AMAZING SWIMMER MUSCLES + *SWOON* + + MEAN LADY + + MATH OFFICE (ACADEMIC TEAM) + CAPTAIN STEVE + "REMEMBER REYERSON\'S RULE" + ANY GIVEN TEAM CAN BE BEATEN + ON ANY GIVEN DAY + BRIGHID + RACHAEL YRBK + AP BIO LAB PARTNERS + MUST STICK TOGETHER + MREE + "I\'M NOT EVIL" + NO ESTA AQUI + + PATRIOT ROOM + AGENT N + ACTING PRINCIPAL ROBOKNEE + SINCE WE HAVE NO ELECTRICITY WE HAVE NO LIGHTS + +PUZZLE: + + Need wire, + 670nm + 1.9ma V=IR + 9V, 4.7k + +WHICH LED? +WHICH RESISTOR? +WHICH BATTERY? + +ZAPPO, FREE THE GUINEA PIG + (in cage?) + show zapping through cloud of school + + GUINEA PIG joins your party + +Then RK attack + +#endif + +}; + + + diff --git a/gr-sim/tfv/tfv_worldmap.c b/gr-sim/tfv/tfv_worldmap.c index e27af69e..35ed2efa 100644 --- a/gr-sim/tfv/tfv_worldmap.c +++ b/gr-sim/tfv/tfv_worldmap.c @@ -13,6 +13,8 @@ #include "tfv_mapinfo.h" +#include "tfv_dialog.h" + unsigned char map_location=LANDING_SITE; /* Puzzle Room */