Double Plus Maze
Part 6 - Writing Secrets

What Secrets Do Preparing the Secrets File Adding A Secret Using the Secret in the Maze Let's Stroll Through the Finished Maze

Quick Start Maze - MAIN MENU

What Secrets Do

While the Challenge Maze Software is mostly about being a format to present challenges in an engaging manner, 'Secrets' are mostly about creating complex labyrinthine mazes.   With 'Secrets' it is possible to open passages, close passages, and add passages in distant rooms.   These effects on passages happen based upon what a player does.   You can make a player search and search for creative ways to access new rooms, passages, and exits.   Since many people are more interested in simply having a format where a players efforts are geared solely towards solving challenges (not toward navigating mazes that are complex), I call the this part of the tutorial 'optional'.   That being said, complex mazes may help make things more interesting for players.

When writing a Secret in the Secrets.txt File there is an opportunity to define what the Secret will do to the maze when things happen with the Secret.   It is possible to write one Secret and use it in many maze rooms.   It is possible to write many Secrets and use each Secret in it's own maze room.

In the Challenge Maze Software, Secrets take the form of objects that can be 'recovered' by a player.   Secrets are automatically 'recovered' if a player enters a room with a Secret in it and the Secret has already been 'revealed'.  

Secrets can be in a room without being 'revealed' to a player.   This means a player can walk right through the room where the Secret is located and the player would not be able to 'recover' the Secret or perhaps not even know that the Secret was there.

When a Secret is 'recovered' by a player the Secret can take actions like making entries in maze files.   The entries are generally entries that control passages and CutScenes.   The entries add passages, remove passages, lock passages, or unlock passages.   The entries can also show CutScenes in rooms that are inside of a maze and rooms at the end of a maze.

A Secret is in a room if the Secret's name is written in the Secret Name Of The Secret Kept In This Room Entry and 'Here' is written in the Secret Status Entry.   Secrets are invisible to a player until the player has solved some pre-selected challenges.   Those Challenges are pre-selected by writing in the Secret Challenges Entry.   Once those Challenges have been solved the Secret becomes 'revealed'.   Once a Secret is 'revealed' the word 'Revealed' is written by the Challenge Maze Software to the Secret Challenges Entry.   Once a Secret is 'revealed', it is automatically 'recovered' when a player enters the room in which it is kept.

We will be writing one secret that is kept in 2 rooms and will affect 3 of the passages in our maze.

Preparing the Secrets File

To find the 'Secrets.txt' file, first look in the 'Double Plus Maze' folder...

...   and then in the 'Secrets Behavior' folder you find the 'Secrets.txt' file.

Before we get started writing let me tell you now that the 'Secrets.txt' file is different from the other files we have been using.   The 'Secrets.txt' can have different numbers of total lines as we add more secrets.   This will not cause errors with the Challenge Maze Software like it will for the other textfiles.   It is designed like this so that us Maze Makers can add as many secrets as we choose.   When we write a new secret we have to make sure to get the exact number of lines for each entry (3), and to include every single entry (10).   We must even include the entries we will not be using.

Look at the example below.   This is an example of what an 'empty' secrets file looks like.

This is what your 'Secrets.txt' file currently looks like because we copied it from the 'Empty Maze' template.

Also in the 'Secrets Behavior' folder is the ',SAMPLE SECRETS FILE WITH TWO SECRETS.txt' file.   If you look in the file you will find that it has two secrets.   One is called the 'Gold Orb' and one is called the 'Silver Orb'.   Together these secrets add 60 lines to the file.   When the Challenge Maze Software works with secrets, it first looks for the 'Secret Name' and then it can find the entries for that secret by looking in the 30 lines written for that secret.

Go ahead and copy the 'Silver Orb' section from the ',SAMPLE SECRETS FILE WITH TWO SECRETS.txt' to the 'Secrets.txt' file and edit all the entries so they are blank.   Now your 'Secrets.txt' file should look like this:

Adding A Secret

Adding a secret to the 'Secrets.txt' file means that the secret can then be used in a room by writing the 'Secret Name' in the room file on the line of the Name Of The Secret That Unlocks Passages In This Room Entry or the Secret Name Of The Secret Kept In This Room Entry.

Make the following entries in the 'Secrets.txt' file for the 'Double Plus Maze':

The 'Secret Challenges' entry tells the Challenge Maze Software that the challenges in Room 5 and Room 10 must be solved before the secret will be 'revealed'.

The 'Passages to Add When All Recovered ' entry tells the Challenge Maze Software that it should add passages to two room files when the all secrets of the 'Silver Orb' type are 'recovered'.   The entry tells the Challenge Maze Software that the passages will be added to the files of Room 7 and Room 2.   If you look closely you will see that both of these passages represent one passage on the map plan.   They represent the passage that goes between room 7 and 2.

The 'Total Number Of All To Recover' entry tells the Challenge Maze Software that the total number of 'Silver Orbs' is 2.   This means that any of the actions the Challenge Maze Software is supposed to take if all of the 'Silver Orbs' are 'recovered', will happen if 2 'Silver Orbs' are 'recovered'.

The 'CutScene - Secret Is In A Room But Is Not Revealed' entry, is a way of giving a hint to a player.   If you do not want to tell a player that they have entered a room with a secret that is not yet 'revealed', then you do not have to.   You can just leave this entry blank and they will never know unless they explore the room after the secret has been 'revealed'.

The 'CutScene - All Recovered' entry is also like a of hint to a player.   It can tell the player that the secret they just 'recovered' is the last of it's type hidden in the maze.   This would be to let the player know that something has changed in the maze because a secret type can make changes to a maze when it is fully 'recovered'.

The 'CutScene - Ending If All Of This Secret Recovered' entry simply gives us the option to show a CutScene to the player at the end of the maze if they recover all of the 'Silver Orbs'.

Using the Secret in the Maze

Now, since we wrote a 'Secrets.txt' entry that will add a passage between Room 2 and 7, we will erase some of the entries that made the passage in the room '0002.txt' file so that only the secret will grant us the ability to go through the passage:

We will do the same to the room '0007.txt' file:

Now we will tell the Challenge Maze Software to keep the secret in a room.   Make the following entries in the '0008.txt' file:

We will also keep this secret in Room 6 and will tell the Challenge Maze Software to add another passage.   However, this time the passage will be added when the secret in Room 6 is 'recovered' whether or not any other secrets have been 'recovered'.   Make the following entries in the '0006.txt' file:

Now that we will be adding another passage between rooms, we will make the following adjustment to some of the entries where we have already created the same passage.   In the room '0004.txt' file adjust the following entries to look like this:

In the room '0009.txt' file adjust the following entries to look like this:

For the last entry, let's add secrets to the ending tjs_scene order in the 'Single Maze Finish And Start.txt' file so we can see the ending tjs_scene for us 'recovering' all the 'Silver Orb' secrets:

Let's Stroll Through the Finished Maze

Yup, that's it! If this works (keep your fingers crossed), we will be done.   The first room should still be the same, so let's start with Room 4.   If we walk from Room 1 to Room 4 it should now look like this:

Room 5 should still be the same so let's go to Room 6.   If we walk from Room 5 to Room 6 it should now look like this until the text hint we wrote disappears:

If we walk from Room 6 to Room 7 it should now look like this:

If we walk from Room 7 to Room 8 it should now look like this until the hint we wrote disappears:

Since we already solved the challenge in Room 5, let's go 'reveal' the secret by solving the Challenge in Room 10.   Right after the Spirit Wizard drops, you should see the text 'You have revealed a secret'.   Other than that Room 10 is the same.   Do not exit the Maze, instead let's go to Room 6 again.   It will now show this:

Keep walking forward until you get to Room 4 again.   It will look like the image below and we will not be able to walk through the closed door or portal passages yet because we wrote that the door and portal would be locked.   We also wrote that the secret that unlocks the doors is the 'Silver Orb' and we haven't 'recovered' all the 'Silver Orbs' yet.   These passages will only get unlocked when we get both of the orbs.   The new portal passage is already showing up because we 'recovered' a secret in Room 6 and that room had an entry telling the Challenge Maze Software to add the portal if any secret was 'recovered' in that room.

Let's go recover that secret in Room 8 now, it should look like this:

Now go back to Room 7 and you will see the added southern door from the entry we wrote in the 'Secrets.txt' file:

We are now free to walk into all the rooms of the maze once more and if you exit the maze you will even see an ending tjs_scene for the secret.

To get a more complete understanding of how Secrets work, you can visit the Secrets Page now or after you finish this tutorial.

Quick Start Maze - MAIN MENU