Game Modding | Call of Duty: Black Ops 3 | Scripting
bubba443:
Is it possible to add a sound when a player gets downed? Any links to mods/tutorials for this? Can't seem to find any.
eDeK:
{% highlight php %}{% raw %} callback::on_spawned( &sound_when_i_downed ); {% endraw %}{% endhighlight %} {% highlight php %}{% raw %} function sound_when_i_downed() { level flag::wait_till( "all_players_connected" ); level flag::wait_till( "initial_blackscreen_passed" );
wait 0.05;
level endon( "end_game" );
self endon( "disconnect" );
while(1)
{
self waittill( "player_downed" );
self PlaySound( "YOUR_SOUND" );
wait( 1 );
}
} {% endraw %}{% endhighlight %}
bubba443:
It works! Thank you so much!