Skip to content

UI manager: show bitmaps #40

Description

@culacant

As part of the UI (a.o), we want to have the ability to show a bitmap on-screen.
Bitmaps come from the BSI/TEXBSI/GXA files and land in RGTexStore, where they can be retrieved based on palette/BSI number/image number/shader ID as unity Materials.

Background on script usage:
When a strenght potion is imbibed, it show a bitmap in the top-left corner for a while before hiding it again:
Image
In the Observatory, looking through the telescope shows a full-screen image of stars for 36 units of time (~3 seconds?):
Image

Implementation:
In UIManager, provide a function to show a bitmap at a position, it returns the index of the bitmap. Layer would be an integer to determine which bitmaps go on top of others.
int UIManager.ShowBitmap(Material mat, Vector2 position, int layer);
We also want a way to unshow a bitmap. hence the id above:
UIManager.HideBitmap(int id)

Further functions will be needed in MainUIScript. Quick outline of what I think is useful:

  • ShowGXA(GXAfile, UNKNOWN, duration) < shows a full-screen GXA file for duration
  • ShowBitmap(UNKNOWN, Id) < Show a bitmap in the top-left corner, UNKNOWN will probably be an index into some TEXBSI file, further investigation needed
  • UnshowBitmap(int Id) < and hides it again

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions