Hey Leute ich hab wieder mal ein Problem unzwar bekomm ich diese Fehler Meldung
Code
(760) : error 004: function "ini_GetKey" is not implemented
(760) : error 033: array must be indexed (variable "key")
(761) : error 004: function "ini_GetValue" is not implemented
(761) : error 033: array must be indexed (variable "val")
.
.
.
usw..
Bei folgenden Zeilen
Code
public OnPlayerCarLogin(playerid)
{
for(new x = 0; x < MaxVeh; x++)
{
if(!Dtc_PlayerHaveCar[playerid][x])
{
new string2[128];
new playername2[MAX_PLAYER_NAME];
GetPlayerName(playerid, playername2, sizeof(playername2));
format(string2, sizeof(string2), "/Autos/%s%d.dtcar", playername2,x);
new File: UserFile = fopen(string2, io_read);
if (UserFile)
{
Dtc_PlayerHaveCar[playerid][x] = 1;
new key[ 256 ] , val[ 256 ];
new Data[ 256 ];
while ( fread( UserFile , Data , sizeof( Data ) ) )
{
key = ini_GetKey( Data );
if( strcmp( key , "CarId" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarId] = strval( val ));
if( strcmp( key , "CarModel" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarModel] = strval( val ));
if( strcmp( key , "CarPos_x" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarPos_x] = floatstr( val ));
if( strcmp( key , "CarPos_y" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarPos_y] = floatstr( val ));
if( strcmp( key , "CarPos_z" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarPos_z] = floatstr( val ));
if( strcmp( key , "CarRotate" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarRotate] = floatstr( val ));
if( strcmp( key , "CarNitro" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarNitro] = strval( val ));
if( strcmp( key , "CarHyd" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarHyd] = strval( val ));
if( strcmp( key , "CarWheel" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarWheel] = strval( val ));
if( strcmp( key , "CarAusp" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarAusp] = strval( val ));
if( strcmp( key , "CarSideL" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarSideL] = strval( val ));
if( strcmp( key , "CarSideR" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarSideR] = strval( val ));
if( strcmp( key , "CarFB" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarFB] = strval( val ));
if( strcmp( key , "CarRB" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarRB] = strval( val ));
if( strcmp( key , "CarSpoiler" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarSpoiler] = strval( val ));
if( strcmp( key , "CarRoof" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarRoof] = strval( val ));
if( strcmp( key , "CarHood" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarHood] = strval( val ));
if( strcmp( key , "CarVents" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarVents] = strval( val ));
if( strcmp( key , "CarLamps" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarLamps] = strval( val ));
if( strcmp( key , "CarPJ" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarPJ] = strval( val ));
if( strcmp( key , "CarC1" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarC1] = strval( val ));
if( strcmp( key , "CarC2" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarC2] = strval( val ));
if( strcmp( key , "Preis" , true ) == 0 ) ( val = ini_GetValue( Data ); PlayerCar[playerid][x][CarPreis] = strval( val ));
}
fclose(UserFile);
PlayerCarSpawn(playerid,x);
}
}
}
}
Alles anzeigen
Obwohl ich eine Funktion habe
Code
stock ini_GetKey( line[] )
{
new keyRes[256];
keyRes[0] = 0;
if ( strfind( line , "=" , true ) == -1 ) return keyRes;
strmid( keyRes , line , 0 , strfind( line , "=" , true ) , sizeof( keyRes) );
return keyRes;
}
stock ini_GetValue( line[] )
{
new valRes[256];
valRes[0]=0;
if ( strfind( line , "=" , true ) == -1 ) return valRes;
strmid( valRes , line , strfind( line , "=" , true )+1 , strlen( line ) , sizeof( valRes ) );
return valRes;
}
Alles anzeigen
Das versteh ich einfach nicht