<commit_before>#include "blitter.h"
#include "coplist.h"
#include "interrupts.h"
#include "memory.h"
#include "ilbm.h"
#include "2d.h"
#include "fx.h"

#define WIDTH 320
#define HEIGHT 256
#define SIZE 80

/* Triple buffering. */
static BitmapT *screen[3];
static WORD active = 0;

static Point2D pos[3][3];
static BitmapT *background;
static BitmapT *metaball;
static BitmapT *carry;
static CopInsT *bplptr[5];
static CopListT *cp;

void Load() {
  screen[0] = NewBitmap(WIDTH, HEIGHT, 5, FALSE);
  screen[1] = NewBitmap(WIDTH, HEIGHT, 5, FALSE);
  screen[2] = NewBitmap(WIDTH, HEIGHT, 5, FALSE);
  background = LoadILBM("data/metaball-bg.ilbm", FALSE);
  metaball = LoadILBM("data/metaball.ilbm", FALSE);
  carry = NewBitmap(SIZE + 16, SIZE, 2, FALSE);

  cp = NewCopList(100);
  CopInit(cp);
  CopMakePlayfield(cp, bplptr, screen[active]);
  CopMakeDispWin(cp, 0x81, 0x2c, WIDTH, HEIGHT);
  CopLoadPal(cp, metaball->palette, 0);
  CopEnd(cp);
}

void Kill() {
  DeleteCopList(cp);
  DeleteBitmap(screen[0]);
  DeleteBitmap(screen[1]);
  DeleteBitmap(screen[2]);
  DeleteBitmap(carry);
  DeletePalette(background->palette);
  DeleteBitmap(background);
  DeletePalette(metaball->palette);
  DeleteBitmap(metaball);<commit_msg>Fix an unnecessary background clear.<commit_after>#include "blitter.h"
#include "coplist.h"
#include "interrupts.h"
#include "memory.h"
#include "ilbm.h"
#include "2d.h"
#include "fx.h"

#define WIDTH 320
#define HEIGHT 256
#define SIZE 80

/* Triple buffering. */
static BitmapT *screen[3];
static WORD active = 0;

static Point2D pos[3][3];
static BitmapT *background;
static BitmapT *metaball;
static BitmapT *carry;
static CopInsT *bplptr[5];
static CopListT *cp;

void Load() {
  screen[0] = NewBitmap(WIDTH, HEIGHT, 5, FALSE);
  screen[1] = NewBitmap(WIDTH, HEIGHT, 5, FALSE);
  screen[2] = NewBitmap(WIDTH, HEIGHT, 5, FALSE);
  background = LoadILBM("data/metaball-bg.ilbm", FALSE);
  metaball = LoadILBM("data/metaball.ilbm", FALSE);
  carry = NewBitmap(SIZE + 16, SIZE, 2, FALSE);

  cp = NewCopList(100);
  CopInit(cp);
  CopMakePlayfield(cp, bplptr, screen[active]);
  CopMakeDispWin(cp, 0x81, 0x2c, WIDTH, HEIGHT);
  CopLoadPal(cp, metaball->palette, 0);
  CopEnd(cp);

  {
    WORD i, j;

    for (i = 0; i < 3; i++)
      for (j = 0; j < 3; j++) {
        pos[i][j].x = 160;
        pos[i][j].x = 128;
      }
  }
}

void Kill() {
  DeleteCopList(cp);
  DeleteBitmap(screen[0]);
  DeleteBitmap(screen[1]);
  DeleteBitmap(screen[2]);
  DeleteBitmap(carry);
  DeletePalette(background->palette);
  DeleteBitmap(background);
  DeletePalette(metaball->palette);
  DeleteBitmap(metaball);
{'fraction_non_alphanumeric': 0.15967987804878048, 'fraction_numerical': 0.03125, 'mean_word_length': 4.87248322147651, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3048648', 'n_tokens_mistral': 1075, 'n_tokens_neox': 999, 'n_words': 232}