anchor.diff:  end;
   
   
  -procedure TTextManager.LoadTranslation(aTextPath: string; TranslationID: Integer);
  -var
  -  SL:TStringList;
  -  i,ID,firstDelimiter:integer;
  -  Line:string;
  +procedure TTextManager.LoadText(aTextPath: string; TranslationID: Integer);
  +var
  +  SL: TStringList;
  +  B: Boolean;
  +  I, ID, firstDelimiter, T: Integer;
  +  Line: string;
   begin
     SL := TStringList.Create;
     SL.LoadFromFile(aTextPath);
   
  -  SetLength(fTexts, 3000);
  -  for I := 0 to 3000 - 1 do
  -    SetLength(fTexts[I], fLocalesCount);
  -
  -  for i := 0 to SL.Count - 1 do
  -  begin
  -    Line := Trim(SL[i]);
  -
  -    firstDelimiter := Pos(':', Line);
  -    if firstDelimiter = 0 then continue;
  -    if not TryStrToInt(TrimLeft(LeftStr(Line, firstDelimiter-1)), ID) then continue;
  -
  -    Line := RightStr(Line, Length(Line) - firstDelimiter);
  -    //Required characters that can't be stored in plain text
  -    Line := StringReplace(Line, '\n', eol, [rfReplaceAll, rfIgnoreCase]); //EOL
  -    Line := StringReplace(Line, '\\', '\', [rfReplaceAll, rfIgnoreCase]); //Slash
  -
  -    fTexts[ID, TranslationID] := Line;
  +  B := False;
  +  for I := 0 to SL.Count - 1 do
  +  begin
  +    Line := Trim(SL[I]);
  +    if Pos('MaxID:', Line) = 1 then
  +    begin
  +      B := TryStrToInt(TrimLeft(Copy(Line, 7, Length(Line))), T);
  +      Break;
  +    end;
  +  end;
  +
  +  //Make sure we've got valid TextCount
  +  if B then
  +  begin
  +    if (fTextsCount <> 0) and (fTextsCount <> T) then
  +    begin
  +      ShowMessage(aTextPath + ' MaxID is inconsistent with other files');
  +      B := False;
  +    end
  +    else
  +      fTextsCount := T;
  +  end
  +  else
  +  begin
  +    ShowMessage(aTextPath + ' has no MaxID entry');
  +    B := False;
  +  end;
  +
  +  if B then
  +  begin
  +    SetLength(fTexts, fTextsCount);
  +    for I := 0 to fTextsCount - 1 do
  +      SetLength(fTexts[I], fLocalesCount);
  +
  +    for I := 0 to SL.Count - 1 do
  +    begin
  +      Line := Trim(SL[I]);
  +
  +      firstDelimiter := Pos(':', Line);
  +      if firstDelimiter = 0 then continue;
  +      if not TryStrToInt(TrimLeft(LeftStr(Line, firstDelimiter-1)), ID) then continue;
  +
  +      Line := RightStr(Line, Length(Line) - firstDelimiter);
  +      //Required characters that can't be stored in plain text
  +      Line := StringReplace(Line, '\n', eol, [rfReplaceAll, rfIgnoreCase]); //EOL
  +      Line := StringReplace(Line, '\\', '\', [rfReplaceAll, rfIgnoreCase]); //Slash
  +
  +      fTexts[ID, TranslationID] := Line;
  +    end;
     end;
   
     SL.Free;
  
positive.code: end;
  
  
  procedure TTextManager.ScanAvailableTranslations(aTextPath: string);
  var
    SearchRec: TSearchRec;
  begin
    fDefaultLocale := 0; //Default in case there is no eng
    fLocalesCount := 0;
    FindFirst(Format(aTextPath, ['*']), faDirectory, SearchRec);
    repeat
      if (SearchRec.Name <> '.') and (SearchRec.Name <> '..')
      and (SearchRec.Attr and faDirectory <> faDirectory) then
      begin
          SetLength(fLocales, fLocalesCount + 1);
          //text.***.libx
          fLocales[fLocalesCount] := Copy(SearchRec.Name, 6, 3);
          if fLocales[fLocalesCount] = 'eng' then
            fDefaultLocale := fLocalesCount;
          Inc(fLocalesCount);
        end;
    until (FindNext(SearchRec) <> 0);
  end;
  
  
negative.code: end;
  
  
  procedure TTextManager.LoadConsts(aConstPath: string);
  var
    SL: TStringList;
    Line: string;
    I, CenterPos: Integer;
  begin
    SL := TStringList.Create;
    SL.LoadFromFile(aConstPath);
  