[SOLVED] BASS template: How would I make the UI visible at all times?

Started by MiaWulf, Tue 08/10/2024 18:57:21

Previous topic - Next topic

MiaWulf

Hello,

I know that the point of the BASS template is to emulate Beneath A Steel Sky, but I'm working on something that would benefit from that style of UI and interaction that requires the UI to be shown at the top of the screen at all times.

I'm not the best with AGS script aside from the basics, and looking through TwoClickHandler.asc is not really helping me understand what i should change or delete to keep it visible and interactive at all times.

I'm also trying to move the action bar GUI to be in a box beneath the inventory, and I'm assuming that I can just tweak the left and top variables in the inspector.

Any help in this would be great, as I'm stumped.

Khris

Open TwoClickHandler.asc and remove lines 235-248.
Then open the gInventoryBar GUI and set PopupStyle to "Normal" and Visible to "True".

Quote from: MiaWulf on Tue 08/10/2024 18:57:21I'm also trying to move the action bar GUI to be in a box beneath the inventory, and I'm assuming that I can just tweak the left and top variables in the inspector.
Yes, exactly :)

MiaWulf

Quote from: Khris on Tue 08/10/2024 19:24:42Open TwoClickHandler.asc and remove lines 235-248.
Then open the gInventoryBar GUI and set PopupStyle to "Normal" and Visible to "True".

Unfortunately, this didn't work. I commented out the lines of code, but the numbers were a bit off. I'm assuming that this is due to a difference in AGS engine versions, but you can see the code that I commented out below:


And the changes to gInventoryBar:

Crimson Wizard

You need to disable following code:

Code: ags
  // Inventory GUI:
  if (interface_inv == null)
  {
    // pass
  }
  else if (interface_inv.Visible && check_hide_distance(mouse.y))
  {
    interface_inv.Visible = false;
  }
  else if (!IsGamePaused() && !interface_inv.Visible && check_show_distance(mouse.y))
  {
    // make visible when the game is not paused and the cursor is within the popup position
    interface_inv.Visible = true;
  }

MiaWulf

Crimson Wizard's solution worked perfectly. Going to mark this thread as solved, if I can figure out how this forum works

Khris

I used the BASS template that comes with AGS 3.6.1; I guess I should've posted the lines :-D

Anyway, simply edit your opening post to put [solved] in front of the subject.

SMF spam blocked by CleanTalk