open-manifold / Open-Manifold

A free and open-source clone of Rhythm 'n' Face for PC.
Other
10 stars 1 forks source link

Support button icons in `draw_text()` #29

Open SuperFromND opened 1 year ago

SuperFromND commented 1 year ago

Right now, we can only draw literal text using draw_text(), and even then only a specific subset of characters:

 !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~

I think it'd be very neat, at least for Tutorial mode (and possibly the Options menu for rebinding buttons) to have some way of drawing button icons as well. There's only twelve, so making art for them wouldn't be hard:

enum controller_buttons {
    NONE, // represents a lack of input, no graphic needed
    UP,
    DOWN,
    LEFT,
    RIGHT,
    CROSS,
    CIRCLE,
    SQUARE,
    TRIANGLE,
    LB,
    RB,
    START,
    SELECT,
};

The tricky parts would be: