anchor.diff:        gHands[fOwner].Deliveries.Queue.AddDemand(Self, nil, wt_Gold, fGoldMaxCnt - Max(OldGoldMax, fGoldCnt), dtOnce, diNorm);
       end;
     end;
  -
  -////    TryRemoveDemand
  -//    for I := OldGoldMaxCnt to fGoldMaxCnt - 1 do
  -//      gHands[fOwner].Deliveries.Queue.RemOffer(Self, wt_Gold, aCount);
  -
   end;
   
   
  
positive.code: 
    SaveStream.Write(fGoldCnt);
    SaveStream.Write(fGoldMaxCnt);
  //  SaveStream.Write(fGoldDeliveryCount);
  end;
  
  
  
negative.code: 
  
  procedure TKMHouseTownHall.ResAddToIn(aWare: TWareType; aCount: Integer = 1; aFromScript: Boolean = False);
  begin
    Assert(aWare = wt_Gold, 'Invalid resource added to TownHall');
  
    // Allow to enlarge GoldMaxCnt from script (either from .dat or from .script)
    if aFromScript and (fGoldMaxCnt < fGoldCnt + aCount) then
      SetGoldMaxCnt(fGoldCnt + aCount, True);
  
    fGoldCnt := EnsureRange(fGoldCnt + aCount, 0, High(Word));
    if aFromScript then
      gHands[fOwner].Deliveries.Queue.TryRemoveDemand(Self, aWare, aCount);
  end;
  
  
  