Forum rules - please read before posting.

Subtitles: changing the space between text and the box's borders.

Hi!
I'm customizing the UI, and I was wondering if it's possible to change the size of the space between the text displayed in the SubsLineLabel field and the border of the box that contains it.
I've tried fiddling with the settings, but no matter what I did, the SubsLineLabel box always perfectly fits the lines of text. In other terms, there is no space between the text displayed and the borders of the box. I'd like to change that, because with the current settings the text looks crammed inside the box, and it's not very good looking.
Is this possible to do by changing some settings?

One of the solutions I've thought was creating four menu elements, set their background texture as the same of the SubsLineLabel, placing them around the SubsLineLabel box, and then change their size according to the space I'd like to create, like a frame. Before doing this, though, I'd like to know if there are other more "by the book" solutions to my issue.

thanks!

Comments

  • P.s. and in case my "frame" workaround is the only solution, what would be the best Element type to choose for the four menu elements?

  • In the case that you're using Adventure Creator to render your menus: if an element's Position property is set to Aligned, then the border around it can be set by the menu's Element spacing (%) slider. The shape of the menu itself will adjust automatically if its Size property is set to Automatic. You can try this on the default Pause menu, which has the same settings.

    Otherwise, you can set the element's Position to Relative to menu size or AbsolutePixels to control its position within the menu directly.

    However, do note that the Adventure Creator option for the menu's Source field is best used for prototyping and building your UI quickly. When it comes to properly styling your interface, it is recommended to instead rely on Unity Ui Prefab mode, which causes your menu rendering to be deferred to Unity UI canvases, which offer much greater control over their appearance.

    More on this topic can be found in the Manual's "Unity UI menus" chapter, and a tutorial can be found here. For further examples, each of the default interface's menus have a Unity UI variant.

  • Thank you very much! I've tried the first one, and it worked perfectly!

    Thanks for the hint about the Unity UI Prefab mode, I'll look into it for my next game (the one I'm doing right now is fine with the UI setting of Adventure Creator)!

  • I've got another question (unrelated to this issue): in terms of size of the final game file, which one weighs the most: a 10-page "Document", or 10 rooms? (might sound like a silly question, but I need to keep the filesize as small as possible)

  • Document as in from the Inventory Manager? That'll be smaller, I'd imagine, but the size of a scene is down to its complexity.

    There won't be much difference though, since you're really just dealing with text. The major factors to a game's size are texture and audio compression.

  • Thank you!

  • But is it possible to create a custom Document menu for every document? One that displays not one, but two pages of the same document at once, and both pages can be turned with a button? What I was thinking about is a menu background texture representing an open book, and two different pages displayed over the menu. Clicking on one of the buttons in the lower part of the menu turns both pages.

  • There's no need to create a separate menu for each Document, as the document elements will display the contents of the "active" Document. You can, however, set them to a specific Document through scripting.

    To show two pages of a Document at once, you can create another Journal element in the Menu with a Journal type of Display Existing Journal, and then fill in the fields so that it references the other Journal element (which displays the single page) with an offset of 1 (so that it shows the page after whichever is open).

    You can then set your Button elements that shift the active page to shift by 2 pages, instead of 1.

  • Thanks, the instructions worked perfectly!

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.