C:\Documents and Settings\karu\My Documents\samp03e_svr_R2_win32\filterscripts\nosandjump.pwn(26) : error 010: invalid function or declaration
// ----------- Mady by: Ryox178 -----------//
//_______________________________________________________//
#define FILTERSCRIPT
#include <a_samp>
#define COLOR_NGREEN 0x00FF00FF
#if defined FILTERSCRIPT
public OnFilterScriptInit()
{
return 1;
}
public OnFilterScriptExit()
{
return 1;
}
#else
main()
{
#endif
)
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if (newkeys & KEY_CROUCH)
{
if(IsPlayerInAnyVehicle(playerid))
{
new
Float:x,
Float:y,
Float:z;
GetVehicleVelocity(GetPlayerVehicleID(playerid), x, y, z);
SetVehicleVelocity(GetPlayerVehicleID(playerid), x, y, z + 0.2);
}
}
if(GetPlayerState(playerid) != PLAYER_STATE_DRIVER || !CheckNitro(GetPlayerVehicleID(playerid))) return false; else if ((((newkeys & (4)) == (4)) && ((oldkeys & (4)) != (4)))) AddVehicleComponent(GetPlayerVehicleID(playerid), 1010); else if ((((newkeys & (4)) != (4)) && ((oldkeys & (4)) == (4)))) RemoveVehicleComponent(GetPlayerVehicleID(playerid), 1010);
return 1;
}
CheckNitro(vid)
{
new NoNitro[] = { 522,481,441,468,448,446,513,521,510,430,520,476,463 };
for(new f = 0; f < sizeof(NoNitro); f++) if(GetVehicleModel(vid) == NoNitro[f]) return false;
return true;
}
Hai, I got sum error, at line 26
I was testing my nitro script and BOOM: 1 error Pawn compiler: Код:
C:\Documents and Settings\karu\My Documents\samp03e_svr_R2_win32\filterscripts\nosandjump.pwn(26) : error 010: invalid function or declaration pawn Код:
|
// ----------- Mady by: Ryox178 -----------//
//_______________________________________________________//
#define FILTERSCRIPT
#include <a_samp>
#define COLOR_NGREEN 0x00FF00FF
public OnFilterScriptInit()
{
return 1;
}
public OnFilterScriptExit()
{
return 1;
}
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if (newkeys & KEY_CROUCH)
{
if(IsPlayerInAnyVehicle(playerid))
{
new
Float:x,
Float:y,
Float:z;
GetVehicleVelocity(GetPlayerVehicleID(playerid), x, y, z);
SetVehicleVelocity(GetPlayerVehicleID(playerid), x, y, z + 0.2);
}
}
if(GetPlayerState(playerid) != PLAYER_STATE_DRIVER || !CheckNitro(GetPlayerVehicleID(playerid))) return false; else if ((((newkeys & (4)) == (4)) && ((oldkeys & (4)) != (4)))) AddVehicleComponent(GetPlayerVehicleID(playerid), 1010); else if ((((newkeys & (4)) != (4)) && ((oldkeys & (4)) == (4)))) RemoveVehicleComponent(GetPlayerVehicleID(playerid), 1010);
return 1;
}
CheckNitro(vid)
{
new NoNitro[] = { 522,481,441,468,448,446,513,521,510,430,520,476,463 };
for(new f = 0; f < sizeof(NoNitro); f++) if(GetVehicleModel(vid) == NoNitro[f]) return false;
return true;
}