Dungeons: stay in lobby after a run

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
rope 2026-10-27 21:46:07 +00:00
parent 2597a1d7e7
commit 13371ec269
3 changed files with 19 additions and 10 deletions

10
game.py
View file

@ -3097,7 +3097,7 @@ def gain_xp(world: dict, player: dict, skill: str, xp: float, now: float, summar
def empty_summary() -> dict:
return {"done": 0, "items": {}, "overflow": {}, "xp": {}, "levels": [], "eaten": {}, "used": {}, "damage": 0,
"gold": 0, "wins": 0, "losses": 0, "lucky": 0, "stopped": None, "resumed": None, "skipped": [],
"gold": 0, "wins": 0, "losses": 0, "lucky": 0, "stopped": None, "resumed": None, "run_over": None, "skipped": [],
"sold": {}, "sold_gold": 0, "pp_spent": 0, "pp_gained": 0, "prayer_out": False, "second_wind": 0,
"kept": 0, "potions_drunk": {}, "potion_out": [], "labour": 0}
@ -3574,11 +3574,10 @@ def _advance_run(world: dict, party: dict, action: dict, fight: dict, members: l
return
reason = f"Wiped {DUNGEON_WIPES} times at {spec['pulls'][run['pull']][0]}"
log(world, now, "party", f"{names}: {reason.lower()} in {spec['name']}")
del world["parties"][party["id"]]
# Back to the lobby, together: the leader can take the group in again, and others can join.
del party["run"]
for player in members:
summary = player.setdefault("away", empty_summary())
if not finish_once(world, player, now, reason, summary):
summary["stopped"] = reason
player.setdefault("away", empty_summary())["run_over"] = reason
def _clear_bonus(world: dict, player: dict, spec: dict, now: float, rng: random.Random) -> None:
@ -6276,6 +6275,7 @@ ORDER_RECIPES, ORDER_RAW = _order_sources()
# line here (new / balance / fix), and a new release a new entry on top.
PATCH_NOTES = [
{"date": "2026-10-27", "title": "Prayer", "notes": [
("new", "Group stays in lobby after finishing dungeon"),
("new", "Added \"Drink all\" option to potions in the bank."),
("new", "Firekeeping: Tend all fires. Each log goes on the lowest fire with room in your pile."),
("new", "Added resource dumps for Leatherworking: Guard Jerkins"),