SpelunkyWiki

Push Block

A Push Block is terrain in Spelunky Classic, a loose stone block the player pushes along the floor at half a pixel a step, which falls when pushed over an edge.

Push blocks are made in the Mines' and the Temple's rooms, on tiles of their own and from some of the stone blocks the levels are built with, in Olmec's Lair from stone blocks, and in a graveyard level's crypt. Unlike any other block, the player can move one: walking into it pushes it along, and pushed over an edge it falls. Bombs and the Mattock break it like any block.

How it works

#
Replays it in the game, where you can take over.Replays it in the game, to pause and scrub.
Pushing a block. The player walks into a stone block and pushes it slowly along the floor to the edge of a drop; it falls, lands on the floor below, and he drops down after it.

The clip shows a block pushed off a ledge: the player walks into it, pushes it slowly along the floor to the edge, and it falls to the floor below [2].

Pushing

#

Walking into a push block on the ground, not ducking, the player pushes it: he presses against it, and the code that moves him moves the block a pixel for each pixel he moves into it, unless something solid is beyond it [3] [1]. In play that's half a pixel a step (15 a second), a block's width in 32 steps, where he walks at 3 pixels a step [2]. After a moment of it, he's drawn pushing [4]. Only the player pushes blocks: the code allows it to characters alone, not monsters [5].

A block stuck against something solid stops, but the player pushing it doesn't: he creeps into it, and once his middle is inside, he's crushed. That's Crushed by a pushed block.

Falling

#

Each step a push block has nothing solid under any part of it, it falls, gaining 0.6 pixels per step of speed a step, up to 8 pixels per step, and stops on the first solid thing below it, with a thud [6] [7]. In the clip it doesn't drop until it has been pushed wholly past the ledge. It only falls while it's in the view; one off screen hangs where it is until the view comes to it [8]. One that falls out of the level is gone [9].

In lava

#

A push block in Lava sinks a twentieth of a pixel a step, taking any push blocks stacked on it down with it [10] [11].

Locations

#
WhereHow
The MinesEach push block tile, with a 1 in 4 chance[12]
The TempleAs the Mines[13]
A graveyard levelBoth push block tiles of its crypt, always[14] [15]
Where there are stone blocks: the Mines, the Temple and Olmec's LairEach stone block standing on a brick, Temple stone or a hard block, and not beside lava, with a 1 in 4 chance[16]

The high scores room has the one the player pushes onto its reset button [17]. In custom levels it's the level editor's tile B [18].

Interactions

#

Tips

#
  • Pushing is slow, a sixth of walking pace: a block pushed across a room takes seconds.
  • Stop pushing once the block stops, or be crushed (Crushed by a pushed block).
  • A push block pushed into a pit or over a ledge makes a step to climb back up by.

Trivia

#
  • A push block is drawn with the stone block's picture, and level generation turns some stone blocks into push blocks once a level's walls are set up [16], so a stone block and a push block look the same until one is pushed.
  • The code that lets things push blocks says it lets only the player, and that it can be edited to let monsters push them too; it never was [5].

FAQ

#
How do you push blocks in Spelunky Classic?

By walking into one on the ground. It moves ahead of the player half a pixel a step, a block's width in about 32 steps, until something solid is in its way.

Can a push block crush you in Spelunky Classic?

Yes, if the player keeps pushing one that's stuck against something solid: the game moves him into the block anyway, and once his middle is inside it, he's crushed. That's Crushed by a pushed block.

What happens to a push block in lava in Spelunky Classic?

It sinks, very slowly, a twentieth of a pixel a step, taking whatever push blocks are stacked on it down with it.

Why are push blocks gold in the City of Gold?

In the City of Gold every push block is drawn in gold, and one broken there scatters gold rather than rubble: three Gold Chunks and a Gold Nugget.

See also

#

References

#
  1. scripts/moveTo.gml:39-93
  2. Clip push-block/push
  3. scripts/characterStepEvent.gml:138-176
  4. scripts/characterSprite.gml:57
  5. scripts/canPushMoveableSolids.gml:1-6
  6. scripts/gameStepEvent.gml:235-256
  7. objects/oMoveableSolid/create.gml:5
  8. scripts/gameStepEvent.gml:238-239
  9. objects/oPushBlock/other_outside.gml:1
  10. objects/oPushBlock/step.gml:3-9
  11. scripts/scrMoveableSolidRecurseDrop.gml:1-10
  12. scripts/scrRoomGen.gml:344
  13. scripts/scrRoomGen4.gml:341
  14. scripts/scrRoomGen2.gml:79-114
  15. scripts/scrRoomGen2.gml:353
  16. scripts/scrSetupWalls.gml:457-471
  17. Room rHighscores, as the room editor placed it
  18. scripts/scrCreateTileObj.gml:106-109
  19. objects/oSpearTrapTop/step.gml:21-28
  20. objects/oArrowTrapTest/collision_oMoveableSolid.gml:5-26
  21. scripts/moveTo.gml:57
  22. scripts/gameStepEvent.gml:236-256
  23. objects/oPushBlock/destroy.gml:1-11
  24. objects/oPushBlock/create.gml:5
  25. objects/oPushBlock/destroy.gml:12-23

Source code

#