MCPcopy Create free account
hub / github.com/OpenXcom/OpenXcom / play

Method play

src/Engine/AdlibMusic.cpp:120–131  ·  view source on GitHub ↗

* Plays the contained music track. * @param loop Amount of times to loop the track. -1 = infinite */

Source from the content-addressed store, hash-verified

118 * @param loop Amount of times to loop the track. -1 = infinite
119 */
120void AdlibMusic::play(int loop) const
121{
122#ifndef __NO_MUSIC
123 if (!Options::mute)
124 {
125 stop();
126 func_setup_music((unsigned char*)_data, _size);
127 func_set_music_volume(127 * _volume);
128 Mix_HookMusic(player, (void*)this);
129 }
130#endif
131}
132
133/**
134 * Custom audio player.

Callers 1

playerMethod · 0.45

Calls 2

func_setup_musicFunction · 0.85
func_set_music_volumeFunction · 0.85

Tested by

no test coverage detected