the cursor and position marks
Where the game is pointing when it asks for a position. NetHack 3.7 colors the squares you may pick.
Builtneeds review1 change builtSeen all the timeLast touched November 27, 2026: a change of its own was written or changed. Commit 9e2ad7c97.
In the terminal
The tty moves the cursor to the hero whenever the screen is flushed (curs_on_u) and shows it only while waiting for a key (term_curs_set(1) in tty_nhgetch, hidden otherwise). At a getpos prompt the cursor moves with the keys (hjkl and HJKL by 8, '@' back to self, '<' '>' '_' and other symbols to the next such feature, m/o/d/x/a/z to monsters, objects, doors, unexplored, anything, valid spots) and autodescribe prints what is under it on the message line.
With bgcolors on (the default), valid squares start with a bright blue background (map_frame_color = HI_ZAP) behind their normal glyphs; each '$' steps the cycle: no marking, then bright blue '$' glyphs on every valid square, then the background again. With bgcolors off nothing is marked until '$' shows the '$' glyphs. Autodescribe adds "(invalid target)" when the cursor is on a square that is not valid.
After every update the tty puts the cursor on the hero (curs_on_u); a blinking block on most terminals. During getpos it marks the square being chosen; at prompts it is at the end of the message line.
Quotes from NetHack
Put the cursor on the hero. Flush all accumulated glyphs before doing it.
5 more quotes
pline("Move cursor to %s:", goal);
putstr(tmpwin, 0, "Or enter a background symbol (ex. '<').");
for a time S_goodpos was a question mark, but dollar sign is the default keystroke for getpos() to toggle goodpos glyphs on or off
when 'bgcolors' is On, there are three states and showing them via setting background color becomes the default
Sprintf(sbuf, "Use '%s' to toggle marking of valid locations.",
Decisions
When the game asks for a position, the arrows are plain map directions.
Left as the terminal shows itFull text
When the game asks for a position (farlook, travel, teleport), arrows are plain 2D map directions and the camera does not turn.
Backlog decisions: D-14In Codex
While a square is chosen, a pulsing gold frame lies on its floor, or on top of its wall.
Builtneeds reviewCamera or view
Details
While the game asks for a position, a thin flat gold frame lies over the floor of the square the cursor is on, gently pulsing, unlit, not fogged and casting no shadow; each bar about 3.5 pixels of 800 on the screen at any distance, slantwise or straight on, and its sides kept clear of a wall's rough foot beside the square. On a wall's square it rises onto the wall's top as the view has cut it as the eye rises above that top (the views from behind and above, N-678); in first person it stays on the floor. Where the corner map's dark plate lies over it, it is cut away, so it never shows through the panel (N-5313). Seen on the right square in all four views (V-7: minimap-turned's views of a near square, a wall and a newt; nh-plays' the_cursor_is_seen_where_a_player_looks_for_it). The camera does not follow it (D-14): a square off the screen is found on the corner map, whose box blinks as the terminal's cursor does.
- Id
codex.floor_cursor- Exact state
- Built, not reviewed
- Playtests
minimap-turned- Code
crates/nh-plays/src/underway/mapping.rs,crates/nh-plays/src/picture/mapping.rs,crates/codex-client/src/draw/mapping.rs,crates/codex-client/src/draw/world.rs,crates/codex-client/src/minimap.rs,crates/nh-scene/src/mesh/things.rs
| V-7 | Built, not reviewed | 3D farlook cursor appears on the right square. |
| N-678 | Built, not reviewed | With farlook's cursor on a wall square, no cursor box is seen in the world from close third (features-minimap's review) Built: |
While the game asks for a position, the minimap boxes the cursor's square in gold.
In progressCamera or view
Details
While the game asks for a position, the minimap boxes the cursor's square in gold, aligned to the font's measured advance and kept inside the cropped minimap even where nothing has been seen. Arrows move it correctly; its alignment awaits a close look (V-6).
- Id
codex.minimap_cursor- Exact state
- In progress
- Playtests
journey-game- Code
crates/codex-client/src/hud.rs
| V-6 | Built, not reviewed | Minimap farlook cursor lines up with the glyphs. |
Applies to everything on the map (2)
- Altars, thrones, graves, sinks and traps stay letters that stand upright on the floor.
- Every symbol is a plain keyboard character, even when the player's symbol set draws lines.
Accepted pictures and playtests
Playtests: minimap-turned, journey-game
Details for builders
Id: cursor. Lexicon subjects: effect.cursor, effect.goodpos, chrome.cursor.
Design notes from NetHack
The cursor is on the hero except at a position prompt (looking or aiming), when it follows the keys. See chrome.cursor and chrome.prompt.getpos.
Every valid square is marked in bright blue (HI_ZAP), as a background or as '$' glyphs; the '$' key cycles between these and no marking.
Backlog rows
| V-7 | Built, not reviewed | 3D farlook cursor appears on the right square. |
| N-678 | Built, not reviewed | With farlook's cursor on a wall square, no cursor box is seen in the world from close third (features-minimap's review) Built: |
| V-6 | Built, not reviewed | Minimap farlook cursor lines up with the glyphs. |
