- vector iconcolor = ((autocvar_g_waypointsprite_iconcolor) ? '1 1 1' : rgb);
- string spr_icon = spritelookupicon(this, spriteimage);
- string pic = spr_icon;
- bool icon_found = !(!spr_icon || spr_icon == "");
- if (icon_found) // it's valid, but let's make sure it exists!
- {
- pic = strcat(hud_skin_path, "/", spr_icon);
- if(precache_pic(pic) == "")
- {
- pic = strcat("gfx/hud/default/", spr_icon);
- if(!precache_pic(pic))
- icon_found = false;
- }
- }
-
+ string pic = "";
+ bool is_text = true;
+ if (!autocvar_g_waypointsprite_text)
+ {
+ string spr_icon = spritelookupicon(this, spriteimage);
+ pic = spr_icon;
+ bool icon_found = !(!spr_icon || spr_icon == "");
+ if (icon_found) // it's valid, but let's make sure it exists!
+ {
+ pic = strcat(hud_skin_path, "/", spr_icon);
+ if(precache_pic(pic) == "")
+ {
+ pic = strcat("gfx/hud/default/", spr_icon);
+ if(!precache_pic(pic))
+ icon_found = false;
+ }
+ }
+ if (icon_found)
+ is_text = false;
+ }
+
+ vector sz;
+ vector txt_color;