anchor.diff:  
   
   function TKMScriptingIdCache.GetGroup(aUID: Integer): TKMUnitGroup;
  -var I: ShortInt;
  +var
  +  I: Integer;
   begin
     for I := Low(fGroupCache) to High(fGroupCache) do
     if fGroupCache[I].UID = aUID then
  
positive.code:   LoadStream.CheckMarker('ScriptingIdCache_Units');
    LoadStream.Read(fUnitLastAdded);
    for I := Low(fUnitCache) to High(fUnitCache) do
      LoadStream.Read(fUnitCache[I].UID); //Load only UID's, SyncLoad them after that, when all game assets are ready
  
    LoadStream.CheckMarker('ScriptingIdCache_Houses');
    LoadStream.Read(fHouseLastAdded);
    for I := Low(fHouseCache) to High(fHouseCache) do
      LoadStream.Read(fHouseCache[I].UID); //Load only UID's, SyncLoad them after that, when all game assets are ready
  
    LoadStream.CheckMarker('ScriptingIdCache_Groups');
    LoadStream.Read(fGroupLastAdded);
    for I := Low(fGroupCache) to High(fGroupCache) do
      LoadStream.Read(fGroupCache[I].UID); //Load only UID's, SyncLoad them after that, when all game assets are ready
  end;
  
  
  
negative.code: 
  { TKMScriptingIdCache }
  procedure TKMScriptingIdCache.CacheUnit(aUnit: TKMUnit; aUID: Integer);
  var
    I: Integer;
  begin
    for I := Low(fUnitCache) to High(fUnitCache) do
      //Update cache item if changed (also from / to nil)
      if fUnitCache[I].UID = aUID then
      begin
        if fUnitCache[I].U <> aUnit then
        begin
          gHands.CleanUpUnitPointer(fUnitCache[I].U);
          if aUnit <> nil then
            fUnitCache[I].U := aUnit.GetUnitPointer;
        end;
        Exit;
      end;
  
    //We need to release pointer if we remove unit from cache
    if fUnitCache[fUnitLastAdded].U <> nil then
  