public OnPlayerWeaponShot(playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ)
{
new Float:x, Float:y, Float:z;
new Float:x2, Float:y2, Float:z2;
GetPlayerPos(playerid, x, y, z);
GetPlayerPos(hitid, x2, y2, z2);
if(playerid, 23, 1, BULLET_HIT_TYPE_PLAYER, hitid, x2, y2, z2)
{
PlaySoundForPlayersInRange(6003, 14.0, x, y, z);
}
return 1;
}
public OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid)
{
PlayerPlaySound(playerid, 17802, 0.0, 0.0, 0.0); // Ding Sound
return 1;
}

public OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid)
{
if(GetPlayerWeapon(playerid) == 23)
{
PlaySoundForPlayersInRange(6003, 14.0, x, y, z);
}
return 1;
}
|
What i'm trying to do is make it play a noise with only a certain weapon so... would i do this
Код:
public OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid)
{
if(GetPlayerWeapon(playerid) == 23)
{
PlaySoundForPlayersInRange(6003, 14.0, x, y, z);
}
return 1;
}
|
|
What i'm trying to do is make it play a noise with only a certain weapon so... would i do this
Код:
public OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid)
{
if(GetPlayerWeapon(playerid) == 23)
{
PlaySoundForPlayersInRange(6003, 14.0, x, y, z);
}
return 1;
}
|