Код
new Handle:hFile = OpenFile("maplist.txt", "r");
if (hFile == INVALID_HANDLE)
return;
new bool:bFound = false;
decl String:CurrentMap[125], String:Text[125];
GetCurrentMap(CurrentMap, 125);
while (!IsEndOfFile(hFile) && ReadFileLine(hFile, Text, 125))
{
if (TrimString(Text) > 0 && strcmp(Text, CurrentMap, true) == 0)
{
bFound = true;
break;
}
}
CloseHandle(hFile);
if (bFound)
{
// ..
}