Spelunky is © 2008, 2009 Derek Yu and Mossmouth, LLC, and is used under the [Spelunky User License v1.1b](https://spelunky.ai/LICENSE.txt). spelunky.ai is an unofficial fan project, not affiliated with or endorsed by Mossmouth. The game and its assets may not be sold.

Music by George Buzinkai and Jonathan Perry; sound effects made in SFXR. From Spelunky Classic 1.1, © 2008, 2009 Derek Yu and Mossmouth, LLC.

# Crushed by a pushed block

From the spelunky.ai wiki: <https://spelunky.ai/wiki/push-block-crush>. Verified against the spelunky.ai port [v0.1.12](https://github.com/851-labs/spelunky/releases/tag/v0.1.12) on 28 October 2026.

Crushed by a pushed block is a quirk of Spelunky Classic in which a player who keeps pushing a block that's stuck against a wall creeps into it and is crushed.

| Quirk     |                                                                                                                                                                                                                   |
| --------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Status    | GML + Oracle                                                                                                                                                                                                      |
| Where     | [`scripts/moveTo.gml:39-65`](https://spelunky.ai/wiki/source/scripts/moveTo#L39-L65)                                                                                                                              |
| Pinned by | `fidelity/replays/flow-highscores-reset-crush.txt`                                                                                                                                                                |
| Row       | [docs/quirks.md §1, Bugs and leftovers in the 1.1 source](https://github.com/851-labs/spelunky/blob/main/docs/quirks.md#1-bugs-and-leftovers-in-the-11-source): “Pushing a block into a wall crushes the player.” |

A push block moves a pixel at a time ahead of the player, until something solid is in its way. Then it should
stop him too. But the code that moves him only stops the block, so a player who keeps pushing creeps into it at
the pushing speed, and once his middle is inside it, he's crushed. In the
[high scores room](https://spelunky.ai/wiki/scoring#the-high-scores-room), its block stops right past the reset button, so that's where
it shows.

## What happens

In the high scores room, the player has pushed the block onto the reset button, and it has stopped against the
sign past it. He keeps pushing and creeps into the block until it crushes him: blood, and he's gone, but no game
over follows[^1].

**Clip: Crushed by the reset block.** In the high scores room, the player has pushed the block onto the reset button, and it has stopped against the sign past it. He keeps pushing and creeps into the block until it crushes him: blood, and he's gone, but no game over follows. ([video](https://spelunky.ai/wiki/media/clips/quirks/highscores-block-crush/clip.mp4))

## Why

`moveTo` moves the player a pixel at a time, and when a block that can be pushed is in his way, it moves the
block a pixel too, unless something solid is beyond it:

```gml scripts/moveTo.gml:46-55
      if object_get_parent(solidId.object_index)=oMoveableSolid and canPushMoveableSolids()
      {
        //we must move the moveable solid, unless there is another solid (moveable or non-moveable) in it's way
        with solidId
        {
          if place_meeting(x+1,y,oSolid)      //there will be a collision!
          {
            break
          }
          else
```

[`scripts/moveTo.gml:46-55`](https://spelunky.ai/wiki/source/scripts/moveTo#L46-L55), from `spelunky.gmk`, Spelunky Classic 1.1's source, © 2008, 2009 Derek Yu and Mossmouth, LLC ([Spelunky User License v1.1b](https://spelunky.ai/LICENSE.txt)).

The `break` is meant to stop the player's loop. But in GameMaker 8 a `break` inside `with` only leaves the
`with`, so the loop goes on and steps the player into the block anyway[^2]. Nothing else stops
him: the step keeps him pushing while a pushable block is beside him[^3][^4],
so he moves into it at the pushing speed, a pixel every other step, until his middle is inside it. Then his
step's crush check takes 99 hearts and hides him[^5]. In the high
scores room, the room's own guard puts his hearts back the next step[^6],
and the code that ends the game only runs on a level, so he's left invisible, with no game over[^7].

## Reproducing it

Push a block until it stops against something solid, and keep pushing. It's the same with any block and any
solid. In the high scores room, push the block onto the reset button and keep holding toward it: its only stop is
the sign just past the button. The replay of the clip does that: the block stops on the button (frame 835), and
the player, still pushing, is crushed ten steps later (845), invisible and with no game over, and his hearts are
back to 4 the step after[^8].

## In the port

The spelunky.ai port reproduces it exactly: it's in docs/quirks.md's list of the 1.1 source's bugs[^7], and the oracle's fingerprint of the replay pins the block's stop and the crush. No option
turns it off.

## FAQ

### Why did pushing a block kill me in Spelunky Classic?

The block was stuck against a wall, and the player kept pushing. The code that moves him stops the block but not him, so he creeps into it, and once his middle is inside it he's crushed, as anything solid crushes him.

### Does pushing the block onto the reset button in the high scores kill you?

It crushes the player if he keeps pushing once the block has stopped, against the sign just past the button. But the high scores room isn't a level: he's left invisible, with his hearts back the next step, and no game over follows.

### How long does it take to be crushed?

Pushing moves the player about a pixel every other step, so from touching the stuck block it takes the steps he needs to get his middle into it: in the high scores room, ten steps after the block stops.

## See also

- **Related:** [Scoring](https://spelunky.ai/wiki/scoring)

## References

[^1]: Clip quirks/highscores-block-crush

[^2]: Quirk 2 (docs/quirks.md)

[^3]: [`scripts/characterStepEvent.gml:106-107`](https://spelunky.ai/wiki/source/scripts/characterStepEvent#L106-L107)

[^4]: [`scripts/characterStepEvent.gml:158-168`](https://spelunky.ai/wiki/source/scripts/characterStepEvent#L158-L168)

[^5]: [`objects/oPlayer1/step.gml:1490-1511`](https://spelunky.ai/wiki/source/objects/oPlayer1/step#L1490-L1511)

[^6]: [`objects/oPlayer1/step.gml:1-7`](https://spelunky.ai/wiki/source/objects/oPlayer1/step#L1-L7)

[^7]: Quirk 1 (docs/quirks.md)

[^8]: Replay `fidelity/replays/flow-highscores-reset-crush.txt`

### Source code

- [`scripts/moveTo.gml`](https://spelunky.ai/wiki/source/scripts/moveTo)
- [`scripts/characterStepEvent.gml`](https://spelunky.ai/wiki/source/scripts/characterStepEvent)
- [`objects/oPlayer1/step.gml`](https://spelunky.ai/wiki/source/objects/oPlayer1/step)
