I added the new things from incognito and this what i get
Код:
error 029: invalid expression, assumed zero
warning 215: expression has no effect
error 029: invalid expression, assumed zero
warning 215: expression has no effect
error 029: invalid expression, assumed zero
warning 215: expression has no effect
Код:
forward SendAudioToPlayer(playerid, audioid, volume, seconds);
public SendAudioToPlayer(playerid, audioid, volume, seconds)
{
if(IsPlayerConnected(playerid))
{
if(Audio_IsClientConnected(playerid))
{
new handleid = Audio_Play(playerid,audioid,false,false,false);
Audio_SetVolume(playerid, handleid, volume);
Audio_Setposition(playerid, handleid, seconds);
}
else
{
return 0;
}
}
return 1;
}
Picture:
http://i.imgur.com/RY163kW.png
Second part
Код:
SendAudioToRange(audioid, volume, seconds, Float:x, Float:y, Float:z, Float:distance)
{
if(audiohandleglobal >= 99)
{
audiohandleglobal = 0;
}
else
{
audiohandleglobal++;
}
foreach(Player, i)
{
if(IsPlayerConnected(i))
{
if(Audio_IsClientConnected(i))
{
if(IsPlayerInRangeOfPoint(i,distance,x,y,z))
{
new handleid = Audio_Play(i,audioid,false,false,false);
Audio_Set3DPosition(i, handleid, Float:x, Float:y, Float:z, Float:distance);
Audio_SetVolume(i, handleid, volume);
Audio_Setposition(i, handleid, seconds);
audiohandle[i][audiohandleglobal] = handleid;
}
}
}
}
return audiohandleglobal;
}
Picture:
http://i.imgur.com/8B6kghF.png
third one
Код:
stock SendAudioURLToRange(url[], volume, seconds, Float:x, Float:y, Float:z, Float:distance)
{
if(audiohandleglobal >= 99)
{
audiohandleglobal = 0;
}
else
{
audiohandleglobal++;
}
foreach(Player, i)
{
if(IsPlayerConnected(i))
{
if(Audio_IsClientConnected(i))
{
if(IsPlayerInRangeOfPoint(i,distance,x,y,z))
{
new handleid = Audio_PlayStreamed(i,url,false,false,false);
Audio_Set3DPosition(i, handleid, Float:x, Float:y, Float:z, Float:distance);
Audio_SetVolume(i, handleid, volume);
Audio_Setposition(i, handleid, seconds);
audiohandle[i][audiohandleglobal] = handleid;
}
}
}
}
return audiohandleglobal;
}
Picture:
http://i.imgur.com/nd0QPYx.png