Jump to content
Aveyond Studios Community
Sign in to follow this  
Ant

Tutorial: The Journal Menu

Recommended Posts

HeroKit comes with an journal system. The system includes an Journal Menu, a Journal Item (hero property) and the following hero actions:

  • Add Journal Entry
  • Remove Journal Entry
  • Show Journal Menu
  • Hide Journal Menu
  • If (Journal Menu Open)

Note: HeroKit comes with a sample scene that has a fully-functional journal system. It's called Scene 29 - Journal Menu Example. You can search for it in the Project tab or you can navigate to it. If navigate to it, open the Project tab and go to HeroKit > HeroKit Samples > Sample Scenes > Scenes > Scene 29 - Journal Menu Example. 

Create a journal item

Spoiler

A journal item is a hero object with a hero property called Journal Item. The Journal Item comes with two fields, but you can change these fields very easily. Steps to do this are later in this tutorial. 

9htW0oP.png

This is how you create an journal item:

  1. Create a hero object (HeroKit > Create Hero Object (Asset))
  2. Open the hero object in the Hero Kit Editor.
  3. Click on Properties.
  4. In the Item Type field, choose Journal Item.
  5. These fields will now populate the Properties window. Enter information for them.
    • Entry - The name of the journal entry.
    • Icon - Icon associated with the journal entry.

Add a journal item to the Journal Menu

Spoiler

The Journal Menu is where a player can store quests that they collect in the game. HeroKit comes with one Journal Menu. We've kept it simple so that you can customize it or clone it to create your own custom menus.

E1obFqi.png

  1. Open the hero object that you want to use and navigate to the event that should add a journal entry to the Journal Menu.
  2. In the event, add an Add Journal Entry action.
  3. In the Item to add field, choose Value from the list and drag the hero object that represents the journal entry into the field on the right (ex. Get Treasure).

Remove a journal entry from the Journal Menu

Spoiler

You can remove a journal entry from the Journal Menu with the Remove Journal Entry action. 

    hhnPxXS.png

    1. Open the hero object that you want to use and navigate to the event that should remove a journal entry from the Journal Menu.
    2. In the event, add a Remove Journal Entry action.
    3. In the Item to remove field, choose Value from the list and drag the hero object that represents the journal entry into the field on the right (ex. Get Treasure).

      Show the Journal Menu

      Spoiler

      To show the Journal Menu, use the Show Journal Menu action. I would add this action to an event on a hero object that is watching for user input (ex. right-mouse click).

      qHJFmFc.png

       

      Hide the Journal Menu

      Spoiler

      To hide the Journal Menu, use the Hide Journal Menu action. I would add this action to an event on a hero object that is watching for user input (ex. right-mouse click).

      GafhuNS.png

      Toggle the Journal Menu

      Spoiler

      If you want to use the same user input to open and close the Journal Menu, you can do this. There are a couple of options here, but an easy one is to use the If (Journal Menu Open) action. 

      H3hFK4I.png

      Add, remove, or change fields for journal entries

      Spoiler

      The default journal entry has two fields: Name and Icon. You don't have to be stuck with these fields forever. You can change them. To change the fields for a journal entry, open the Journal Item hero property in the Hero Kit Editor. This file is located here: 

      rxuw5d5.png

      iE70d9R.png

      Notes:

      • If you need help editing this hero property, check out this topic.
      • After you edit the hero property, you need refresh your hero objects (specifically, any hero objects that are used as inventory items). To do this, open any hero object in the Hero Kit Editor, click the menu icon (right of hero object's name at top), and tap the Refresh Hero Objects button.

      Warnings:

      • If you remove fields or rename fields, you'll need to update the Journal Menu itself. Specifically, you'll need to modify Journal Slot (prefab) and Journal Slot Controller (hero object). 
      • If you want to make drastic changes to journal entries, I advise you duplicate the menu prefabs, hero property, and hero actions associated with the default journal system.

       

      Share this post


      Link to post
      Share on other sites
      Sign in to follow this  

      ×