The .amx file deletes it self when i compile?!?
#1

This have never happend to me before, but when i try to compile/run the .pwn file, the .amx file deletes it self

I get a few errors when i try to compile:

(3312) : warning 235: public function lacks forward declaration (symbol "Audio_OnSetPack")
(3365) : error 017: undefined symbol "Audio_Seek"
(3397) : error 017: undefined symbol "Audio_Seek"
(3375) : warning 203: symbol is never used: "seek"
(3427) : error 017: undefined symbol "Audio_Seek"
(3406) : warning 203: symbol is never used: "seek"
(16900) : error 017: undefined symbol "distance"
(16900) : warning 215: expression has no effect
(16900) : error 001: expected token: ";", but found ")"
(16900) : error 029: invalid expression, assumed zero
(16900) : fatal error 107: too many error messages on one line

If someone could have told me how to fix these, i would be happy
Reply
#2

If you get an error the compilation fails, so the .amx file isn't created.

Show the code and comment on which lines are which like so:

pawn Code:
public callback(args)
{
    func(params);
    var+=5;
    if(condition) return 1: // Line 1337
}
Reply
#3

ohh, so plzz give us ur script so that we can fix them. how would we know what have u done in your script
Reply
#4

Code:
public Audio_OnSetPack(audiopack[]) //3312
{
	foreach(Player, i)
	{
	    Audio_TransferPack(i);
	}
	return 1;
}
_________________________________________________________
forward SendAudioToPlayer(playerid, audioid, volume, seek);
public SendAudioToPlayer(playerid, audioid, volume, seek)
{
	if(IsPlayerConnected(playerid))
	{
		if(Audio_IsClientConnected(playerid))
		{
			new localhandle = Audio_Play(playerid,audioid,false,false,false);
			Audio_SetVolume(playerid, localhandle, volume);
			Audio_Seek(playerid, localhandle, seek); //3365
		}
		else
		{
		    return 0;
		}
	}
	return 1;
}

SendAudioToRange(audioid, volume, seek, Float:x, Float:y, Float:z, Float:range) //3375
{
	if(audiohandleglobal >= 99)
	{
	    audiohandleglobal = 0;
	}
	else
	{
	    audiohandleglobal++;
	}

	foreach(Player, i)
	{
	    if(IsPlayerConnected(i))
	    {
			if(Audio_IsClientConnected(i))
			{
                if(IsPlayerInRangeOfPoint(i,range,x,y,z))
                {
                    new localhandle = Audio_Play(i,audioid,false,false,false);
					Audio_Set3DPosition(i, localhandle, x, y, z, range);
					Audio_SetVolume(i, localhandle, volume);
					Audio_Seek(i, localhandle, seek); //3397
     				audiohandle[i][audiohandleglobal] = localhandle;
                }
			}
	    }
	}
	return audiohandleglobal;
}

stock SendAudioURLToRange(url[], volume, seek, Float:x, Float:y, Float:z, Float:range) //3406
{
    if(audiohandleglobal >= 99)
	{
	    audiohandleglobal = 0;
	}
	else
	{
	    audiohandleglobal++;
	}
	foreach(Player, i)
	{
	    if(IsPlayerConnected(i))
	    {
			if(Audio_IsClientConnected(i))
			{
                if(IsPlayerInRangeOfPoint(i,range,x,y,z))
                {
                    new localhandle = Audio_PlayStreamed(i,url,false,false,false);
					Audio_Set3DPosition(i, localhandle, x, y, z, range);
					Audio_SetVolume(i, localhandle, volume);
					Audio_Seek(i, localhandle, seek); //3427
     				audiohandle[i][audiohandleglobal] = localhandle;
                }
			}
	    }
	}
	return audiohandleglobal;
}
_________________________________________________________________________

HouseInfo[iIndex][hTextID] = CreateDynamic3DTextLabel(szFileStr, COLOR_GREEN, HouseInfo[iIndex][hExteriorX], HouseInfo[iIndex][hExteriorY], HouseInfo[iIndex][hExteriorZ]+0.5,30.0, .testlos = 1, .distance = 30.0); //16900 (This code was over 1000 lines long so i didnt take all of the code, only the error line.)
Reply
#5

$$inSane, so you suggest that i should release my script?
Reply
#6

A. Use [ pawn ] tags.
B. INDENT.
C. You likely don't have the audio streamer include.
Reply
#7

"Audio_Seek" has been renamed to "Audio_SetPosition" in latest version of the audio plugin, so change "Audio_Seek" to "Audio_OnSetPack" and recompile your script with the latest plugin include.
Reply
#8

I have tried to redownload the audio and added the audio streamer, but now i get this error:

(197) : fatal error 111: user error: "Old foreach.inc files are no longer compatible with YSI."

Quote:

#define VIPNUMMENU2 18765 //197

Reply
#9

Quote:
Originally Posted by Zack_Burton
View Post
I have tried to redownload the audio and added the audio streamer, but now i get this error:

(197) : fatal error 111: user error: "Old foreach.inc files are no longer compatible with YSI."
Update your foreach include, just like you updated your audio include.
Reply
#10

Update foreach
https://sampforum.blast.hk/showthread.php?tid=92679
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)