… | |
… | |
54 | auto (i, ht.find (str)); |
54 | auto (i, ht.find (str)); |
55 | |
55 | |
56 | if (i != ht.end ()) |
56 | if (i != ht.end ()) |
57 | return i->second; |
57 | return i->second; |
58 | |
58 | |
59 | //TODO: really fall back to face name? |
59 | if (strncmp (str, "sound/", sizeof ("sound/") - 1)) |
60 | char face[128]; |
60 | str = format ("sound/%s", str); |
61 | snprintf (face, 128, "sound/%s", str); |
61 | |
62 | return face_find (face); |
62 | return face_find (str); |
63 | } |
63 | } |
64 | |
64 | |
65 | void |
65 | void |
66 | sound_set (const char *str, faceidx face) |
66 | sound_set (const char *str, faceidx face) |
67 | { |
67 | { |