Forum rules - please read before posting.

How to display narration text when viewing Inventory

Is it possible to display narration dialogue text and keep the inventory (that pauses gameplay) open? I am trying to use dialogue narration text as the Examine interaction of inventory items, but it seems that the inventory must be closed in order for the text to display (in my game, inventory is opened/closed via input).

Comments

  • What's your Inventory menu's "Appear type" set to?

    The dialogue system can't be used while the game is paused, though an ActionList that triggers it can be made to unpause the game while it runs via its Unfreeze 'pause' menus? property.

    If it's not so strict that the game be paused while viewing Inventory, you could look into disabling movement and interactions while its on with the Engine: Manage systems Action.

    Otherwise, it may be a case of storing such text in a global String variable, and displaying it in a Menu that pops up when an item is clicked.

  • The appear type is On Input Key.

    Since parts of my game have combat involved the game must remain paused, so with that in mind displaying a string variable seems like the way to go - as long as the inventory can stay open while an additional menu is displayed.

  • Wait, does this mean I'd need a separate menu for every item description though? Maybe there is a way around that using the document/journal system, as in, the examine action list for the inventory item opens a specific document that just displays that descriptive text?

  • Wait, does this mean I'd need a separate menu for every item description though?

    No, hence my mention of using a global String variable. You can have a Menu Label display a variable's value (either using tokens, or setting its "Label type" to "Global Variable"), and then update that variable's value before turning the menu on.

  • Yeah I got it working in the end, thanks for the advice. I am having a bit of an issue with how the text is displayed though, it seems to get cut off.

    https://imgur.com/a/XCbTwN1

    This should say "Can be used as a light source." The menu source is Adventure Creator btw.

  • Make sure both the Label element and Menu are either large enough to display it, or set to "Automatic" size.

    It may be that you need to rely on Unity UI's Content Size Fitter component, however.

  • I set the Menu & Label to Absolute Pixels of 1000 each, and it seems to work. I'm not sure how that will scale on different screens / resolutions though, I admit I'm quite ignorant of that side of things.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.