- Migrate from set_global/get_global to ctx_set/ctx_get - Replace if-else chains with match() expressions - Update inline pointer handling patterns - Improve GfxWorld and asset parsing structures - Clean up redundant code across 60+ definition files Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
32 lines
679 B
Plaintext
32 lines
679 B
Plaintext
type font [display="Font"]
|
|
{
|
|
const PTR_INLINE = -1;
|
|
|
|
i32 name_ptr;
|
|
ui("name_ptr", "Name Ptr");
|
|
|
|
i32 pixel_height;
|
|
ui("pixel_height", "Pixel Height");
|
|
|
|
i32 glyph_count;
|
|
ui("glyph_count", "Glyph Count");
|
|
|
|
i32 material_ptr;
|
|
ui("material_ptr", "Material Ptr");
|
|
|
|
i32 glow_material_ptr;
|
|
ui("glow_material_ptr", "Glow Material Ptr");
|
|
|
|
i32 glyphs_ptr;
|
|
ui("glyphs_ptr", "Glyphs Ptr");
|
|
|
|
// Inline data
|
|
inline cstring name when name_ptr [ui="Name", set_name];
|
|
inline material material when material_ptr;
|
|
inline material glow_material when glow_material_ptr;
|
|
|
|
if (glyphs_ptr == PTR_INLINE && glyph_count > 0) {
|
|
array[glyph_count] glyphs: glyph;
|
|
}
|
|
}
|