Skip to content
Techniques & Technology

Colour Clash

The Spectrum's curse

The ZX Spectrum stores colour per 8×8 cell, not per pixel, so anything drawn into a cell shares its two colours with whatever is already there. The period press called it "attribute problems" and reviewed games on how they handled it.

sinclair-zx-spectrumgraphicslimitationspectrum

The ZX Spectrum could display vibrant colours, but with a catch: each 8×8 pixel block shared one foreground (INK) and one background (PAPER) colour. When a sprite moved across block boundaries, it inherited the colours of whatever it overlapped. This “colour clash” defined the Spectrum’s visual character.

The attribute system

Component Size
Pixel data 6,144 bytes (256×192 monochrome)
Attributes 768 bytes (32×24 colour blocks)

Each attribute byte controls an 8×8 block:

  • Bits 0-2: INK colour (foreground, 0-7)
  • Bits 3-5: PAPER colour (background, 0-7)
  • Bit 6: BRIGHT — applies to both INK and PAPER, doubling the effective palette (15 distinct colours, since BRIGHT BLACK = NORMAL BLACK)
  • Bit 7: FLASH — alternates ink and paper every ~16 frames (~3 Hz), commonly used for cursors, alarms, and “press a key” prompts
Diagram of a Spectrum attribute byte: eight labelled fields, FLASH at bit 7, BRIGHT at bit 6, PAPER across bits 5 to 3, and INK across bits 2 to 0.
Diagram — the attribute byte. Nothing is ever 'taken' from anything: one byte governs all 64 pixels of its cell, whoever drew them.

Why it happens

When a sprite crosses attribute boundaries:

  1. Sprite pixels set in block A
  2. Sprite also overlaps block B
  3. Block B has different INK/PAPER
  4. Sprite inherits block B colours
  5. Visual discontinuity appears
Diagram, two panels on a character grid. Left: a white figure standing clear of a red brick wall. Right: the figure has moved three pixels right, and the two wall cells it now touches are drawn in white while the identical bricks beside them stay red.
Diagram — the whole of the artefact. The figure moves three pixels; two entire cells of wall change colour. Nothing was redrawn and no pixel of the wall moved — only the attribute governing those cells did.

The disproportion is the point. Movement is measured in pixels and colour in cells, so the smallest step a sprite can take repaints an area sixty-four times its size.

Which of the two things sharing the cell keeps its colour depends on what the game writes to the attribute, and both outcomes are called colour clash:

Diagram, two panels. Left: the figure keeps its white and the wall cells behind it turn white. Right: the wall keeps its red and the half of the figure inside those cells turns red, while the rest of it stays white.
Diagram — the same collision resolved two ways. Left, the intruder wins the cell and the standing art changes colour under it. Right, the standing art wins and the figure itself is recoloured, appearing in two colours at once with the break on the cell boundary.

The right-hand case is the one people remember, and the harder one to catch: the sprite is where the sprite should be, and only its colour is wrong. Here it is happening in a shipped game.

Both frames below come from one jump, six frames apart, in a single run from the tape. Nothing in the scene changes between them except where the sprite is.

A Spectrum platform screen: a green tree, a red hut on a yellow haystack, green grass, and a white sprite in mid-air clear of the scenery, drawn entirely in white.
Dizzy — The Ultimate Cartoon Adventure (Code Masters, 1987, ZX Spectrum). The airborne sprite is clear of the scenery, and every cell it occupies is its own white ink. Captured from the original tape.
The same screen six frames later: the sprite has drifted left to the edge of the red hut, and the part of it overlapping the hut's roof post is drawn in the hut's red rather than white.
Six frames later, the same sprite in the same jump. It has crossed into two cells already holding the hut's roof post, and in those two cells it is drawn in the hut's red — the rest of it still white. The break follows the character grid, not the sprite's outline.

The second frame is the artefact itself, and it is worth being precise about what changed. The sprite’s pixels are where the sprite put them; only their colour is the hut’s. The cell hands over its whole attribute byte too, so the sprite picks up the hut’s BRIGHT bit along with its ink and is drawn in the darker red, not the bright one. Later in the same jump it crosses the haystack and takes that cell’s non-bright yellow the same way — one sprite, three colours in a second and a half, none of them chosen by the game.

This is the direction of the artefact people remember: not the scenery changing colour, but the character changing colour as it moves across the scenery. It is also the harder one to see in a single frame, which is why the pair is here.

Mitigation strategies

Monochrome sprites

Many games used single-colour sprites:

  • No clash visible
  • Consistent appearance
  • Knight Lore
A Knight Lore room: isometric stone arches and a standing figure, every part of the playfield drawn in the same green ink on black.
Knight Lore (Ultimate Play The Game, 1984, ZX Spectrum). The entire room — architecture, blocks and the player — is one ink on black. Nothing can clash with anything, because there is only ever one colour to inherit. Captured from the original tape.

The cost is stated in the picture. A machine sold on its colour is being asked to draw in one, and the room’s colour changes only between rooms, never within one.

Careful level design

Design backgrounds to minimise contrast:

  • Similar colours in adjacent blocks
  • Black backgrounds common
  • Strategic colour placement
A Sabre Wulf screen: a dense border of multicoloured jungle foliage surrounding a completely black central arena.
Sabre Wulf (Ultimate Play The Game, 1984, ZX Spectrum). The colour is pushed out to an impassable border and the playfield left black, so moving sprites never share an attribute cell with coloured scenery. Captured from the original tape.

Set the two side by side and they are the same studio, months apart, answering the same hardware question two different ways — Sabre Wulf keeps the colour and gives up the space; Knight Lore keeps the space and gives up the colour. Neither game is “avoiding” a bug. Both are designs built around a known constraint.

Sprite masking

Give the sprite a black surround wide enough to cover the cells it is entering, and it never shares one:

Diagram, two panels. Left: an unmasked figure overlapping a red brick wall, the overlapping half of it drawn in red. Right: the same figure carrying a black surround, which has blanked the wall around it; the figure is entirely white and the wall has a hole in it.
Diagram — masking. The black surround blanks whatever the figure approaches, so the cells it occupies hold nothing but the figure and there is nothing left to inherit its ink. It stays one colour, and the scenery it passes is punched out around it.

This is the only mitigation that keeps both a coloured background and a freely-moving sprite, and it is not free: the cost has moved from the sprite’s colour to the scenery’s continuity. A masked figure walks through a wall in a travelling hole the shape of itself.

The technique took its English name from one game. Your Sinclair had already noticed the effect on sight in 1986, in a preview: “Look at the size of that mask — no attribute problems here. A Mike Singleton game?” By 1989 the magazine was using the title as the generic term, in a review of something else entirely — the characters “are all protected from colour clash by a thick black Dark Sceptre mask”.

A Dark Sceptre screen: a large white skeletal warrior, about a third of the screen tall, standing in front of a green vine arch which is interrupted by black around his outline.
Dark Sceptre (Maelstrom Games for Beyond, 1987, ZX Spectrum). The figure is nearly a third of the screen tall and stays a single white against coloured scenery. The green arch behind him does not pass behind him — it stops at a black margin that follows his outline. Captured from the original tape.

Where the technique spread after that is not settled here. It is associated with later Spanish releases, and that association is not sourced in this entry: the magazine holdings behind it are British, and the British press is the wrong place to establish what Spanish studios did or what they called it.

Small sprites

Sprites smaller than 8×8:

  • Stay within single attribute
  • Limited visual impact
  • Restricts game design

Attribute-aligned movement

Move sprites in 8-pixel increments:

  • Always aligned to blocks
  • Jerky movement
  • Not suitable for action games

What the press called it

The phrase was a game before it was a term. CRASH’s first issue, in February 1984, lists a 16K Romik game called Colour Clash. The word the reviews used for the effect itself was attribute problems: Pedro, in May 1984, had “a few attribute problems with colour”; by November the magazine’s comments box had a fixed “Use of colour” line, and its editorial that month complained of “games that are prevented from being graphically better than anything on the 64 because of the colour attribute problems. I’ve lost count of the times that a CRASH review has said, lacks colour, but this avoids…”

The same issue shows the line working in both directions. Avalon’s playing area “is quite simple and avoids messy attribute problems”; Daley Thompson’s Decathlon has none; Zombie Zombie’s colour “has made the game look livelier, but has unfortunately introduced some attribute problems along with it”.

“Attribute clash” is in Legend’s advance publicity for Komplex in 1985, promising “full colour graphics without attribute clash” — a claim the review answered with “excellent once you accept the attribute problems”. “Colour clash” as the name of the effect is in Your Sinclair by 1989.

Against the Commodore 64

The comparison the editorial draws is the one that mattered commercially. The C64 also colours its playfield per cell, but its hardware sprites carry their own colours and never inherit the background’s, so a game that would clash on the Spectrum does not on the 64. That is why Spectrum reviews had a “Use of colour” line at all.

See also

Not yet fact-checked. This entry was drafted by an AI and nobody has verified it. The dates, figures and technical details may be wrong. Use it to find your bearings, then confirm anything that matters against a primary source.