Refactor tools
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env python3
|
||||
"""
|
||||
paths.py — Path constants for The Chaos game engine.
|
||||
config_paths.py — Path constants for The Chaos game engine.
|
||||
|
||||
Shared by engine.py, run.py, and all sub-modules.
|
||||
"""
|
||||
@@ -1,18 +1,18 @@
|
||||
#!/usr/bin/env python3
|
||||
"""
|
||||
draw.py — Draw a card from The Chaos deck.
|
||||
draw_card.py — Draw a card from The Chaos deck.
|
||||
|
||||
Usage:
|
||||
python3 draw.py <deck> <table> [count]
|
||||
python3 draw_card.py <deck> <table> [count]
|
||||
|
||||
Decks: souls, cook, creatures, curiosities
|
||||
Tables: see the YAML files (e.g. traits, rumours, type, drink_or_drug)
|
||||
|
||||
Examples:
|
||||
python3 draw.py souls thing
|
||||
python3 draw.py cook rumours 3
|
||||
python3 draw.py creatures type appearance
|
||||
python3 draw.py curiosities creepy_vibe
|
||||
python3 draw_card.py souls thing
|
||||
python3 draw_card.py cook rumours 3
|
||||
python3 draw_card.py creatures type appearance
|
||||
python3 draw_card.py curiosities creepy_v<NEW_CHAR_HERE>_vibe
|
||||
"""
|
||||
|
||||
import sys
|
||||
+1
-1
@@ -29,7 +29,7 @@ Wrap in ```tool to perform an action:
|
||||
- **world_update** — content: "full world" (if NPCs/locations/threads change)
|
||||
- **journal_update** — add: [...], done: [...]
|
||||
|
||||
You have the full state above — no need to look anything up. Just write the story and use tools when the player's action changes something.
|
||||
You have the full state above — no need to look anything up. Just write the story and use tools when the player's action changes something. If a player action is impossible (e.g. they try to use an item they don't have), narrate the failure and DO NOT use any state-changing tools.
|
||||
|
||||
## State
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
#!/usr/bin/env python3
|
||||
"""
|
||||
roll.py — Roll dice for The Chaos TTRPG.
|
||||
roll_dice.py — Roll dice for The Chaos TTRPG.
|
||||
|
||||
Usage:
|
||||
python3 roll.py <formula> [modifier]
|
||||
python3 roll_dice.py <formula> [modifier]
|
||||
|
||||
Formulas:
|
||||
1d6 Roll 1 six-sided die
|
||||
@@ -18,11 +18,11 @@ Modifier: +/- number added to total
|
||||
|
||||
Examples:
|
||||
python3 roll.py 1d6
|
||||
python3 roll.py 3d6
|
||||
python3 roll.py 2d6x10
|
||||
python3 roll.py odds
|
||||
python3 roll.py trait 9
|
||||
python3 roll.py 1d6 +1
|
||||
python3 roll_dice.py 3d6
|
||||
python3 roll_dice.py 2d6x10
|
||||
python3 roll_dice.py odds
|
||||
python3 roll_dice.py trait 9
|
||||
python3 roll_dice.py 1d6 +1
|
||||
"""
|
||||
|
||||
import sys
|
||||
@@ -7,7 +7,7 @@ import ast
|
||||
|
||||
MODULES = [
|
||||
'engine.py',
|
||||
'paths.py',
|
||||
'config_paths.py',
|
||||
'models.py',
|
||||
'prompts.py',
|
||||
'state.py',
|
||||
|
||||
Reference in New Issue
Block a user