From e1ab732903dfe22c39701d9508095d4c3669c9b4 Mon Sep 17 00:00:00 2001 From: terceranexus6 Date: Thu, 26 Jan 2023 16:03:40 +0100 Subject: [PATCH] added a new scenary and new elements for conditionals in each scenary --- MYDATA/Alien/BACKPACK | 2 - MYDATA/Alien/SAVING_CARTRIDGE_Alien | 2 +- MYDATA/Alien/been_there_done_that | 2 - MYDATA/Alien/thought_that | 0 game.sh | 80 +++++++++++++++++++++++++++-- 5 files changed, 78 insertions(+), 8 deletions(-) create mode 100644 MYDATA/Alien/thought_that diff --git a/MYDATA/Alien/BACKPACK b/MYDATA/Alien/BACKPACK index d66fd9d..7c0142d 100644 --- a/MYDATA/Alien/BACKPACK +++ b/MYDATA/Alien/BACKPACK @@ -8,5 +8,3 @@ Food packets Clothes Camera black device -black device -black device diff --git a/MYDATA/Alien/SAVING_CARTRIDGE_Alien b/MYDATA/Alien/SAVING_CARTRIDGE_Alien index 36c6659..81d85cd 100644 --- a/MYDATA/Alien/SAVING_CARTRIDGE_Alien +++ b/MYDATA/Alien/SAVING_CARTRIDGE_Alien @@ -1 +1 @@ -episode5 +episode6 diff --git a/MYDATA/Alien/been_there_done_that b/MYDATA/Alien/been_there_done_that index 9929891..7a171f3 100644 --- a/MYDATA/Alien/been_there_done_that +++ b/MYDATA/Alien/been_there_done_that @@ -1,3 +1 @@ MAP_A -MAP_A -MAP_A diff --git a/MYDATA/Alien/thought_that b/MYDATA/Alien/thought_that new file mode 100644 index 0000000..e69de29 diff --git a/game.sh b/game.sh index 9a7fbf0..06a8b87 100755 --- a/game.sh +++ b/game.sh @@ -451,7 +451,9 @@ episode6(){ clear echo -e "$SPACE" - echo -e "$SPA_C EPISODE6" + #echo -e "$SPA_C EPISODE6" + #continue_ + SCENARY_B episode6 # save_it "episode7" # episode7 $PERSONALITY $NAME @@ -476,8 +478,76 @@ episode6(){ SCENARY_B(){ + echo -e "$SPA_C ${bli_blue}[MAP: LOADING POSITION...ARRIVED AT DESTINATION]${NC}\n\n" #A - echo "TODO" + #echo "TODO" + ep="$1" + + #clear + #echo -e "$SPACE" + + have_the_radio="no" + # I'm thinking of cleaning this by using the loop to set this variable above. + + echo -e "$SPA_C It's impossible to reach. When you are arriving near the spot you" + echo -e "$SPA_C realize there's no way possible to reach there. What was the " + echo -e "$SPA_C researching team thinking? Maybe the landscape changed, you " + echo -e "$SPA_C suddenly think. After all the storms and the violent weather could " + echo -e "$SPA_C have changed it.\n\n" + + continue_ + + #check if you own the radio + while read -r line; do + if [ "$line" == "radio device" ]; then + have_the_radio="yes" + fi + done < BACKPACK + + # if you do, you could have thought of using it in the past or not + if [ "$have_the_radio" == "yes" ]; then + echo -e "$SPA_C But you might be able to do something, just in case." + echo -e "$SPA_C You search on your bag, looking for the radio devide.\n\n" + + echo -e "$SPA_C You send the signal, which you don't understand. You wait patiently\n\n" + echo -e "$SPA_C Time passes.\n\n" + echo -e "$SPA_C You are about to give up when you suddenly receive a reply. The sound " + echo -e "$SPA_C still means nothing to you, but the screen of the radio device is showing " + echo -e "$SPA_C some symbols." + + continue_ + + echo -e "$SPA_C SYMBOLS" + echo -e "$SPA_C SYMBOLS\n\n" + + while read -r line3; do + if [ "$line3" == "MAP_A" ]; then + echo -e "$SPA_C This... this is familiar to you. It reminds you of the symbols in the black device you" + echo -e "$SPA_C found buried in the snow.\n\n" + else + echo -e "$SPA_C This doesn't seem familiar. Maybe you will disover soon.\n\n" + fi + done < been_there_done_that + + + else + # if you went to the place where the radio + #you could have taken it or not + + while read -r line2; do + if [ "$line2" == "SCENARY_C" ]; then + echo -e "$SPA_C Maybe it's better to just get going then." + else + echo -e "$SPA_C maybe... I mean maybe it just changed. But what if... I could send " + echo -e "$SPA_C a radio signal?" + fi + done < been_there_done_that + fi + + + continue_ + + } SCENARY_A(){ @@ -487,6 +557,10 @@ SCENARY_A(){ clear echo -e "$SPACE" + echo -e "$SPA_C The coordinates were pretty clear, although you are a bit confused. Nothing" + echo -e "$SPA_C seems to be there. You slowly walk around the spot, trying to figure out " + echo -e "$SPA_C what's going on. \n\n" + #B if [ "$ep" == "ep5" ]; then echo -e "$SPA_C You spot something shiny under the snow. At first it seemed like " @@ -931,7 +1005,7 @@ elif [ "$1" = "--continue-game" ]; then current=$(cat MYDATA/$NA/SAVING_CARTRIDGE_$NA | head -n1 ) cd MYDATA/$NA user_perso=$(sed -n 2p CHARACTER_DETAILS) - $current $user_perso $NA + $current "$user_perso" "$NA" else echo "Oops! something went wrong, try again" fi -- 2.45.2