MCPcopy Create free account
hub / github.com/NetHack/NetHack / sound_matches_message

Function sound_matches_message

src/sounds.c:1628–1639  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1626}
1627
1628staticfn audio_mapping *
1629sound_matches_message(const char *msg)
1630{
1631 audio_mapping *snd = soundmap;
1632
1633 while (snd) {
1634 if (regex_match(msg, snd->regex))
1635 return snd;
1636 snd = snd->next;
1637 }
1638 return (audio_mapping *) 0;
1639}
1640
1641void
1642play_sound_for_message(const char *msg)

Callers 2

play_sound_for_messageFunction · 0.85
maybe_play_soundFunction · 0.85

Calls 1

regex_matchFunction · 0.50

Tested by

no test coverage detected