nd-seat for axil-nd, ported from SIC to libxylem.
git clone https://github.com/tty-pt/nd-seatDocumentation
axil-nd-seat
nd-seat for axil-nd, ported from SIC to libxylem.
Owns sitting: the sitter and seat tables, the sitting query, and the stand-up path. Its one combat role is co-implementing nd-fight's on_will_attack chain โ stand the target up silently, then pass the hit through unchanged โ reading fight's hit with nd_last().
Install
make install
Installs:
lib/libnd-seat.so
include/nd/seat.h
There is deliberately no lib/nd-seat.so symlink (see axil-nd-wts for why: mods.load names the installed filename, and the OpenBSD packing list never lists a symlink).
Also packaged across all 9 platforms (deb, apk, rpm, pacman, brew, openbsd, winget + Scoop, android-lib, and ios-lib + SwiftPM XCFramework) from a v* tag.
Build from source
make
Needs libxylem and the engine's game API, <nd/xy.h>, plus <nd/fight.h> for the hit_t this module passes through โ from a checkout beside this repo or from the installed package:
git clone https://github.com/tty-pt/nd-seat && cd nd-seat
git clone https://github.com/tty-pt/axil-nd ../axil-nd
git clone https://github.com/tty-pt/nd-fight ../axil-nd-fight
make
Both the checkout -I flags and the installed-package paths are on the command line at once (see Makefile), and a missing -I is ignored, so the same command works either way. CI names the deps explicitly (axil-nd,libxylem,nd-fight).
What it does
xy_install()registers thesittertable (au32map, player โ seat)
and the seat table (one seat_t per seat).
sittinganswers whether a player is seated;on_before_leavestands them
up; on_will_attack stands the target up silently and returns the hit unchanged; on_examine reports the seat; on_add initializes rows.
In-Game Commands (man-src/)
| Command | Section | Description |
|---|---|---|
sit | 10 | Take a seat on furniture or resting spot to regenerate resources |
stand | 10 | Rise from a seated position to resume walking or combat |
Testing
There is no test.sh here. Behaviour is asserted by the engine's own suite:
cd ../axil-nd
make && ./test.sh
Notes from the port
SIC_DEFโXY_IMPL,mod_installโxy_install,call_f(...)โ
f(...). call_verb/call_verb_to never existed; sit/stand messages go out as nd_printf + nd_rwrite via OBJ.location.
- Because this TU
XY_IMPLson_will_attackfrom<nd/fight.h>, it defines
FIGHT_IMPL before including it, and defines SEAT_IMPL for its own <nd/seat.h>.
- The link line is libxylem alone.
NEEDEDislibxylem.soandlibc.so.6.
License
BSD 2-Clause, carried over from tty-pt/nd-seat. See LICENSE.