Sokoban Level 2a

From NetHackWiki
Revision as of 16:33, 10 September 2021 by Konchog (talk | contribs) (vertical mirrors!)
Jump to navigation Jump to search

This level of Sokoban is often considered one of the hardest levels of the 8. There are 16 boulders and 12 holes.

0 boulder
^ hole
@ starting position/downstairs
< upstairs

(Note that the levels may be vertical mirrors in more recent versions of NetHack)!

 ----          -----------
--.@--------   |.........|
|..........|   |.........|
|.0-----0-.|   |.........|
|..|...|.0.|   |....<....|
|.0.0....0-|   |.........|
|.0..0..|..|   |.........|
|.----0.--.|   |.........|
|..0...0.|.--  |.........|
|.---0-...0.------------+|
|...|..0-.0.^^^^^^^^^^^^.|
|..0......----------------
-----..|..|
    -------


Strategy

The following solution solves the level with only placing three boulders in an immovable position. See this revision for a solution that solves the level without placing any boulders in an immovable position. Faster solutions exist. Finding and writing them up is left as an exercise to the reader. You can watch ttyrec of one solution here, or a faster ttyrec here which involves jumping down a hole, or a YouTube video.

All boulders are replaced by letters so they can be referred to. Moving the boulders is shortened to r for right, l for left, u for up, d for down. An asterisk is used to denote the last move filled a hole (and thus removed the boulder from the game). So N ddrr* means move boulder N two times down and two times to the right into a hole.

The key to this level is being able to walk around the shape in the bottom right. F, K and M prevent this in the starting layout, and P prevents you from getting near to that shape.

 ----          -----------
--.@--------   |.........|
|..........|   |.........|
|.A-----B-.|   |.........|
|..|...|.C.|   |....<....|
|.D.E....F-|   |.........|
|.G..H..|..|   |.........|
|.----I.--.|   |.........|
|..J...K.|.--  |.........|
|.---L-...M.------------+|
|...|..N-.O.^^^^^^^^^^^^.|
|..P......----------------
-----..|..|
    -------

Clear a space above F. I move B next to the bottom-right shape, but I'll move it away again soon.

B dd
C l

Move P so that I can get past, N to give me space to put K, and O and M so I can get up to F.

P rrru
O rr*
N d
M l
 ----          -----------
--.>--------   |.........|
|..........|   |.........|
|.A-----.-.|   |.........|
|..|...|C..|   |....<....|
|.D.E...BF-|   |.........|
|.C..H..|..|   |.........|
|.----I.--.|   |.........|
|..J...K.|.--  |.........|
|.---L-..M@.------------+|
|...|.P.-....^^^^^^^^^^^.|
|......N..----------------
-----..|..|
    -------

Clear enough space around the bottom-right shape so I can walk around it.

F u
B ll
K d
 ----          -----------
--.>--------   |.........|
|..........|   |.........|
|.A-----.-.|   |.........|
|..|...|CF.|   |....<....|
|.D.E.B...-|   |.........|
|.C..H..|..|   |.........|
|.----I.--.|   |.........|
|..J...@.|.--  |.........|
|.---L-K.M..------------+|
|...|.P.-....^^^^^^^^^^^.|
|......N..----------------
-----..|..|
    -------

Finish the bottom half (M, N, K, L, P, I and J).

M rdrr r*
N llll lrrr rrrr uu
 ----          -----------
--.>--------   |.........|
|..........|   |.........|
|.A-----.-.|   |.........|
|..|...|CF.|   |....<....|
|.D.E.B...-|   |.........|
|.G..H..|..|   |.........|
|.----I.--.|   |.........|
|..J.....|.--  |.........|
|.---L-K.N..------------+|
|...|.P.-@....^^^^^^^^^^.|
|.........----------------
-----..|..|
    -------
K dd
N rdrr rr*
L dd
P r
 ----          -----------
--.>--------   |.........|
|..........|   |.........|
|.A-----.-.|   |.........|
|..|...|CF.|   |....<....|
|.D.E.B...-|   |.........|
|.G..H..|..|   |.........|
|.----I.--.|   |.........|
|..J.....|.--  |.........|
|.---.-.....------------+|
|...|.@P-......^^^^^^^^^.|
|....L.K..----------------
-----..|..|
    -------
K rruu rdrr rrr*
P drru urdr rrrr rr*
L lllr rrrr rruu rdrr rrrr*
I drdd drru urdr rrrr rrr*
J rrrr dddr ruur drrr rrrr rr*
 ----          -----------
--.>--------   |.........|
|..........|   |.........|
|.A-----.-.|   |.........|
|..|...|CF.|   |....<....|
|.D.E.B...-|   |.........|
|.G..H..|..|   |.........|
|.----..--.|   |.........|
|........|.--  |.........|
|.---.-.....------------+|
|...|...-.........@.^^^^.|
|.........----------------
-----..|..|
    -------

Get into the space above B.

A u
G r
D u
E r
 ----          -----------
--.>--------   |.........|
|.A........|   |.........|
|..-----.-.|   |.........|
|.D|...|CF.|   |....<....|
|...@EB...-|   |.........|
|..G.H..|..|   |.........|
|.----..--.|   |.........|
|........|.--  |.........|
|.---.-.....------------+|
|...|...-...........^^^^.|
|.........----------------
-----..|..|
    -------

Finish B, E, H and G.

B dddr dddr ruur drrr rrrr rrr*
E rddd rddd rruu rdrr rrrr rrrr r*
H rrdd dddr ruur drrr rrrr rrrr r*
G rrrr dddd drru urdr rrrr rrrr rrrr*

The level is now finished, but you will still need to move the A or C blocks to walk between your finishing position (as well as the stairs up) and the stairs down. How to fix this depends on which direction you approach the blockage from as follows:

 ----          ----------- 
--.>--------   |.........| 
|.A........|   |.........|
|..-----.-.|   |.........| 
|.D|...|CF.|   |....<....| 
|.........-|   |.........| 
|.......|..|   |.........|
|.----..--.|   |.........|
|........|.--  |.........|
|.---.-.....------------+|
|...|...-.............@..|
|.........----------------
-----..|..|
    -------

If you start from < or @:

A r

If you start from >

C d
F l

Next level

After this level, you will face either of the following levels:

Sokoban Level 3a
  --------
---.|....|
|...0....|----------
|.-.00-00|.|.......|
|.00-......|.......|
|.-..0.|...|.......|
|....-0--0-|...<...|
|..00..0...|.......|
|.--...|...|.......|
|....-0|---|.......|
---..0.-----------+|
  |..0@^^^^^^^^^^^.|
  ------------------
Sokoban Level 3b
--------------------
|........|...|.....|
|.00..-00|.-.|.....|
|..|.0.0.|00.|.....|
|-.|..-..|.-.|..<..|
|...--.......|.....|
|...|.0.-...-|.....|
|.0.|0.|...--|.....|
|-0.|..-----------+|
|..0....^^^^^^^^^^.|
|...|.@-------------
--------

This page may need to be updated for the current version of NetHack.

It may contain text specific to NetHack 3.6.0. Information on this page may be out of date.

Editors: After reviewing this page and making necessary edits, please change the {{nethack-360}} tag to the current version's tag or {{noversion}} as appropriate.