-
Notifications
You must be signed in to change notification settings - Fork 166
S2DEX Text Engine
Gregory Heskett edited this page Aug 12, 2024
·
4 revisions
- High Quality 64x64 text for your ROM hack
- Full ASCII Support (Including control characters like
\t
,\n
, and\v
) - Custom Font Support
- In
Makefile
, setTEXT_ENGINE
tos2dex_text_engine
(Permalink here) - Set your font in
src/s2d_engine/config.h
; Valid font names are located insrc/s2d_engine/fonts
- The easiest use case would be to call
s2d_print_alloc(x, y, "your message");
- Use Modifiers like
SCALE "(number less than 100)"
orDROPSHADOW
in your string. - To set a base scale value (e.g. if your font is too big by default), head to
src/s2d_engine/config.h
s2d_print_alloc(50, 10, SCALE "25" "This is text scaled to 25!\n" "Wow! New Line!" DROPSHADOW "Super Mario Galaxy\n"
SCALE "30" SEPARATOR "9 times out of 10 you dont need to use SEPARATOR\n"
"but if the next string starts with a number then it will make sure\n"
"the number doesnt mess up your calculations.\n"
COLOR "255 0 0 255" "Also text colors!\n" RESET "Finally, use RESET to return to the initial state."
);