diff options
| -rw-r--r-- | src/menu.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/menu.cpp b/src/menu.cpp index 2021218..3d008bb 100644 --- a/src/menu.cpp +++ b/src/menu.cpp | |||
| @@ -629,6 +629,7 @@ void outer_draw() { | |||
| 629 | logf("font: reset (local entity change)"); | 629 | logf("font: reset (local entity change)"); |
| 630 | } | 630 | } |
| 631 | 631 | ||
| 632 | bool overlay_font = true; | ||
| 632 | if (!g_font) { | 633 | if (!g_font) { |
| 633 | static const char *families[] = { | 634 | static const char *families[] = { |
| 634 | "Liberation Sans", "DejaVu Sans", "Noto Sans", "Tahoma", | 635 | "Liberation Sans", "DejaVu Sans", "Noto Sans", "Tahoma", |
| @@ -649,16 +650,16 @@ void outer_draw() { | |||
| 649 | if (!font_ok) { | 650 | if (!font_ok) { |
| 650 | logf("outer_draw: no usable font"); | 651 | logf("outer_draw: no usable font"); |
| 651 | toastf(TOAST_ERROR, "No usable overlay font"); | 652 | toastf(TOAST_ERROR, "No usable overlay font"); |
| 652 | return; | 653 | overlay_font = false; |
| 653 | } | 654 | } |
| 654 | } | 655 | } |
| 655 | int panel = surf_get_embedded_panel(); | 656 | int panel = surf_get_embedded_panel(); |
| 656 | if (!panel) | 657 | if (!panel) |
| 657 | return; | 658 | return; |
| 658 | surf_push_make_current(panel, false); | 659 | surf_push_make_current(panel, false); |
| 659 | if (esp_on) | 660 | if (esp_on && overlay_font) |
| 660 | esp_draw(); | 661 | esp_draw(); |
| 661 | if (draw_test) { | 662 | if (draw_test && overlay_font) { |
| 662 | surf_draw_set_color(255, 0, 0, 255); | 663 | surf_draw_set_color(255, 0, 0, 255); |
| 663 | surf_draw_filled_rect(20, 20, 180, 60); | 664 | surf_draw_filled_rect(20, 20, 180, 60); |
| 664 | surf_draw_set_color(255, 255, 255, 255); | 665 | surf_draw_set_color(255, 255, 255, 255); |
