Game Modding | Call of Duty: Black Ops 3 | General Discussion
ModmeBot:
Thread By: Fil he Modder
is it possible for a 2d sound to play when the power is turned on? BUT only one player can hear it and no one else, is that possible?
ModmeBot:
Reply By: mathfag
#using scripts\zm\_zm_utility;
function sound_on_power()
{
level waittill("power_on");
foreach(player in GetPlayers())
{
if(zm_utility::get_player_index(player) == 2) //0, 1, 2, 3
{
player PlayLocalSound("");
}
}
}
or instead of
if(zm_utility::get_player_index(player) == 2)
you can use
if(player.characterindex == 2)