Gostaria de reagir a esta mensagem? Crie uma conta em poucos cliques ou inicie sessão para continuar.

Entrar

description[AJUDA] ERRO AO COMPILAR Empty[AJUDA] ERRO AO COMPILAR

more_horiz
Olá,

podem me ajudar com este erro.

C:\Users\Silvio\Desktop\FIVEBOTS\Silvio Radcliffe SAMP\gamemodes\BPS.pwn(42) : fatal error 100: cannot read from file: "/include/gl_common.inc"

Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase


1 Error.

Linha 42 do gm é esta: #include "/include/gl_common.inc" // for PlaySoundForPlayersInRange()

Ja fiz os seguintes prosscedimento.

Baixei o novo samp-server no site com as includes novas;
Já coloquei as include gl_common, na pasta include e pawno/include.
Ja coloquei "../include/gl_common.inc" e "./include/gl_common.inc"
Ja tentei #include <gl_common>
Ja troquei a include varias vezes e novas.

description[AJUDA] ERRO AO COMPILAR EmptyRe: [AJUDA] ERRO AO COMPILAR

more_horiz
cara se vc coloco as includes la não era para dar erro
se eu não me engano essa include é do grand larc
da uma olhada la e ve como o cara fez...

description[AJUDA] ERRO AO COMPILAR EmptyRe: [AJUDA] ERRO AO COMPILAR

more_horiz
Se não for possivel resolver esse jeito, fiz outra coisa deletei a linha Linha 42 do gm é esta: #include "/include/gl_common.inc" // for PlaySoundForPlayersInRange() e tirei os 42 warnings que apareceu e ficou esses.



C:\Users\Silvio\Desktop\FIVEBOTS\Silvio Radcliffe SAMP\pawno\include\streamer.inc(261) : warning 201: redefinition of constant/macro (symbol "OnGameModeInit")
C:\Users\Silvio\Desktop\FIVEBOTS\Silvio Radcliffe SAMP\pawno\include\OPSP.inc(254) : warning 201: redefinition of constant/macro (symbol "OnPlayerKeyStateChange")
C:\Users\Silvio\Desktop\FIVEBOTS\Silvio Radcliffe SAMP\pawno\include\YSI\internal\..\y_scriptinit.inc(237) : warning 209: function "GMExit" should return a value
C:\Users\Silvio\Desktop\FIVEBOTS\Silvio Radcliffe SAMP\pawno\include\YSI\internal\..\y_scriptinit.inc(244) : warning 201: redefinition of constant/macro (symbol "OnGameModeExit")
C:\Users\Silvio\Desktop\FIVEBOTS\Silvio Radcliffe SAMP\pawno\include\YSI\internal\..\internal\y_shortfunc.inc(157) : warning 219: local variable "v" shadows a variable at a preceding level
C:\Users\Silvio\Desktop\FIVEBOTS\Silvio Radcliffe SAMP\pawno\include\YSI\internal\..\internal\y_shortfunc.inc(172) : warning 219: local variable "v" shadows a variable at a preceding level
C:\Users\Silvio\Desktop\FIVEBOTS\Silvio Radcliffe SAMP\pawno\include\3DMenu.inc(71) : warning 219: local variable "box" shadows a variable at a preceding level
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase

Header size: 17200 bytes
Code size: 3336676 bytes
Data size: 3673432 bytes
Stack/heap size: 16384 bytes; estimated max. usage: unknown, due to recursion
Total requirements: 7043692 bytes

7 Warnings.


E não sao bugs das inc, pois ja troquei todas varias vezes.

description[AJUDA] ERRO AO COMPILAR EmptyRe: [AJUDA] ERRO AO COMPILAR

more_horiz

//----------------------------------------------------------
//
// GRAND LARCENY common functions include.
//
//----------------------------------------------------------

stock LoadStaticVehiclesFromFile(const filename[])
{
new File:file_ptr;
new line[256];
new var_from_line[64];
new vehicletype;
new Float:SpawnX;
new Float:SpawnY;
new Float:SpawnZ;
new Float:SpawnRot;
new Color1, Color2;
new index;
new vehicles_loaded;

file_ptr = fopen(filename,filemode:io_read);
if(!file_ptr) return 0;

vehicles_loaded = 0;

while(fread(file_ptr,line,256) > 0)
{
index = 0;

// Read type
index = token_by_delim(line,var_from_line,',',index);
if(index == (-1)) continue;
vehicletype = strval(var_from_line);
if(vehicletype < 400 || vehicletype > 611) continue;

// Read X, Y, Z, Rotation
index = token_by_delim(line,var_from_line,',',index+1);
if(index == (-1)) continue;
SpawnX = floatstr(var_from_line);

index = token_by_delim(line,var_from_line,',',index+1);
if(index == (-1)) continue;
SpawnY = floatstr(var_from_line);

index = token_by_delim(line,var_from_line,',',index+1);
if(index == (-1)) continue;
SpawnZ = floatstr(var_from_line);

index = token_by_delim(line,var_from_line,',',index+1);
if(index == (-1)) continue;
SpawnRot = floatstr(var_from_line);

// Read Color1, Color2
index = token_by_delim(line,var_from_line,',',index+1);
if(index == (-1)) continue;
Color1 = strval(var_from_line);

index = token_by_delim(line,var_from_line,';',index+1);
Color2 = strval(var_from_line);

//printf("%d,%.2f,%.2f,%.2f,%.4f,%d,%d",vehicletype,SpawnX,SpawnY,SpawnZ,SpawnRot,Color1,Color2);

AddStaticVehicleEx(vehicletype,SpawnX,SpawnY,SpawnZ,SpawnRot,Color1,Color2,(30*60)); // respawn 30 minutes

/*new numplate_test[32+1];
format(numplate_test,32,"GRLC{44AA33}%d",vid);
SetVehicleNumberPlate(vid, numplate_test);*/

vehicles_loaded++;
}

fclose(file_ptr);
printf("Loaded %d vehicles from: %s",vehicles_loaded,filename);
return vehicles_loaded;
}

//----------------------------------------------------------

stock strtok(const string[], &index)
{
new length = strlen(string);
while ((index < length) && (string[index] <= ' '))
{
index++;
}

new offset = index;
new result[20];
while ((index < length) && (string[index] > ' ') && ((index - offset) < (sizeof(result) - 1)))
{
result[index - offset] = string[index];
index++;
}
result[index - offset] = EOS;
return result;
}

//------------------------------------------------

stock strrest(const string[], &index)
{
new length = strlen(string);
while ((index < length) && (string[index] <= ' '))
{
index++;
}
new offset = index;
new result[128];
while ((index < length) && ((index - offset) < (sizeof(result) - 1)))
{
result[index - offset] = string[index];
index++;
}
result[index - offset] = EOS;
return result;
}

//----------------------------------------------------------
// Tokenise by a delimiter
// Return string and index of the end determined by the
// provided delimiter in delim

stock token_by_delim(const string[], return_str[], delim, start_index)
{
new x=0;
while(string[start_index] != EOS && string[start_index] != delim) {
return_str[x] = string[start_index];
x++;
start_index++;
}
return_str[x] = EOS;
if(string[start_index] == EOS) start_index = (-1);
return start_index;
}

//----------------------------------------------------------

stock isNumeric(const string[])
{
new length=strlen(string);
if (length==0) return false;
for (new i = 0; i < length; i++)
{
if (
(string[i] > '9' || string[i] < '0' && string[i]!='-' && string[i]!='+') // Not a number,'+' or '-'
|| (string[i]=='-' && i!=0) // A '-' but not at first.
|| (string[i]=='+' && i!=0) // A '+' but not at first.
) return false;
}
if (length==1 && (string[0]=='-' || string[0]=='+')) return false;
return true;
}

//----------------------------------------------------------

stock IsKeyJustDown(key, newkeys, oldkeys)
{
if((newkeys & key) && !(oldkeys & key)) return 1;
return 0;
}

//----------------------------------------------------------

stock PlaySoundForAll(soundid, Float:x, Float:y, Float:z)
{
for(new i=0; i {
if(IsPlayerConnected(i))
{
PlayerPlaySound(i, soundid, x, y, z);
}
}
}

//----------------------------------------------------------

stock PlaySoundForPlayersInRange(soundid, Float:range, Float:x, Float:y, Float:z)
{
for(new i=0; i {
if(IsPlayerConnected(i) && IsPlayerInRangeOfPoint(i,range,x,y,z))
{
PlayerPlaySound(i, soundid, x, y, z);
}
}
}

//----------------------------------------------------------

#define RETURN_USER_FAILURE -1
#define RETURN_USER_MULTIPLE -2

stock ReturnUser(text[])
{
new pos = 0;
new userid = RETURN_USER_FAILURE;

while(text[pos] < 0x21) { // Strip out leading spaces
if(text[pos] == 0) return RETURN_USER_FAILURE; // No passed text
pos++;
}

if(isNumeric(text[pos])) { // Check whole passed string
userid = strval(text[pos]);
if(userid >=0 && userid < MAX_PLAYERS)
{
if(IsPlayerConnected(userid)) return userid;
return RETURN_USER_FAILURE;
}
}

// They entered [part of] a name or the id search failed (check names just incase)
new len = strlen(text[pos]);
new count = 0;
new name[MAX_PLAYER_NAME+1];

for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
GetPlayerName(i, name, sizeof(name));
if(strcmp(name, text[pos], true, len) == 0) // Check segment of name
{
if(len == strlen(name)) { // Exact match
return i;
}
else { // Partial match
count++;
userid = i;
}
}
}
}

if(!count) return RETURN_USER_FAILURE;
if(count > 1) return RETURN_USER_MULTIPLE;

return userid;
}

//----------------------------------------------------------

description[AJUDA] ERRO AO COMPILAR EmptyRe: [AJUDA] ERRO AO COMPILAR

more_horiz
Resolvi todos que consigui, agora ficou esses ta bem dificil


C:\Users\Silvio\Desktop\FIVEBOTS\BRL-RPG\BRL-RPG\pawno\include\streamer.inc(334) : warning 201: redefinition of constant/macro (symbol "OnGameModeInit")
C:\Users\Silvio\Desktop\FIVEBOTS\BRL-RPG\BRL-RPG\pawno\include\OPSP.inc(254) : warning 201: redefinition of constant/macro (symbol "OnPlayerKeyStateChange")
C:\Users\Silvio\Desktop\FIVEBOTS\BRL-RPG\BRL-RPG\pawno\include\YSI\internal\..\y_scriptinit.inc (237) : warning 209: function "GMExit" should return a value
C:\Users\Silvio\Desktop\FIVEBOTS\BRL-RPG\BRL-RPG\pawno\include\YSI\internal\..\y_scriptinit.inc (244) : warning 201: redefinition of constant/macro (symbol "OnGameModeExit")
C:\Users\Silvio\Desktop\FIVEBOTS\BRL-RPG\BRL-RPG\pawno\include\YSI\internal\..\internal\y_short func.inc(157) : warning 219: local variable "v" shadows a variable at a preceding level
C:\Users\Silvio\Desktop\FIVEBOTS\BRL-RPG\BRL-RPG\pawno\include\YSI\internal\..\internal\y_short func.inc(172) : warning 219: local variable "v" shadows a variable at a preceding level
C:\Users\Silvio\Desktop\FIVEBOTS\BRL-RPG\BRL-RPG\pawno\include\3DMenu.inc(71) : warning 219: local variable "box" shadows a variable at a preceding level
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase

Header size: 16816 bytes
Code size: 3336196 bytes
Data size: 3674204 bytes
Stack/heap size: 16384 bytes; estimated max. usage: unknown, due to recursion
Total requirements: 7043600 bytes

7 Warnings.

description[AJUDA] ERRO AO COMPILAR EmptyRe: [AJUDA] ERRO AO COMPILAR

more_horiz
AJUDA AEE SO FICOU ESSES.


C:\Users\Silvio\Desktop\SILVIO-RPG\pawno\include\streamer.inc(334) : warning 201: redefinition of constant/macro (symbol "OnGameModeInit")
C:\Users\Silvio\Desktop\SILVIO-RPG\pawno\include\OPSP.inc(254) : warning 201: redefinition of constant/macro (symbol "OnPlayerKeyStateChange")
C:\Users\Silvio\Desktop\SILVIO-RPG\pawno\include\YSI\internal\..\y_scriptinit.inc (245) : warning 201: redefinition of constant/macro (symbol "OnGameModeExit")
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase

Header size: 16848 bytes
Code size: 3337228 bytes
Data size: 3675148 bytes
Stack/heap size: 16384 bytes; estimated max. usage: unknown, due to recursion
Total requirements: 7045608 bytes

3 Warnings.


Linha: 245 do y_scriptinit.inc

#define OnGameModeExit ScriptInit_OnGameModeExit

240 á 285 do y_scriptinit.inc

#if defined _ALS_OnGameModeExit
#undef OnGameModeExit
#else
#define _ALS_OnGameModeExit
#endif
#define OnGameModeExit ScriptInit_OnGameModeExit

#if defined _ALS_OnFilterScriptExit
#undef OnFilterScriptExit
#else
#define _ALS_OnFilterScriptExit
#endif
#define OnFilterScriptExit ScriptInit_OnFilterScriptExit

forward ScriptInit_OnFilterScriptExit();
forward ScriptInit_OnGameModeExit();
#endif

#define OnScriptInit ScriptInit_OnScriptInit
forward OnScriptInit();

#define OnScriptExit ScriptInit_OnScriptExit
forward OnScriptExit();

public _ScriptInit_FixState() <_script_init_fix_state : true>
{
}

public _ScriptInit_FixState() <_script_init_fix_state : false>
{
}

description[AJUDA] ERRO AO COMPILAR EmptyRe: [AJUDA] ERRO AO COMPILAR

more_horiz
privacy_tip Permissões neste sub-fórum
Não podes responder a tópicos
power_settings_newInicie sessão para responder