TinTin++ Configs for DiscworldMUD
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

269 lines
13 KiB

6 years ago
  1. # DiscworldMUD-TinTin
  2. Created by [Ruhsbaar](http://discworld.starturtle.net/lpc/secure/finger.c?player=ruhsbaar) of the Venerable Council of Seers.
  3. ## Overview
  4. A collection of configurations and scripts for use with [DiscworldMUD](http://discworld.starturtle.net) in the [TinTin++](https://tintin.sourceforge.io) MUD client. Many features are meant to be run in their own "miniwindow" for which I make liberal use of Tmux panes.
  5. For reference, I host this configuration on a Linux VPS and thus am able to "take over" the Tmux session as I move between devices/lose internet without being disconnected from the game. This may help to explain some decisions made.
  6. ![Screenshot](https://i.imgur.com/WVZaQwn.png)
  7. ## Features and Bits
  8. ### Windows
  9. * Chat Monitor
  10. * Map Door Text parser
  11. * Hotspot timers
  12. * ASCII map
  13. ### Commands and Scripts
  14. #### Dead Letter Solver
  15. * Command: `sl`
  16. * File: `src/deadletter.tin`
  17. Read a letter in your inventory and print a solution, with the term to scry highlighted. Mostly uses the data from the Dead Letters page on the [wiki](https://dwwiki.mooo.com/wiki/Dead_letter_office_jobs). Works only for **difficult customers** and **distant lands**.
  18. #### Prompt: TPA/XP Monitor
  19. * Files: `src/prompt.tin`, `src/xpmonitor.tin`, `src/tpamonitor.tin`
  20. A tintin++ split across the top of the MUD window proper that displays a few bits of information:
  21. 1) How long has the session been running
  22. 2) How much XP you've earned total this session
  23. 3) The average XP/hour rate over that time
  24. 4) Do you have a TPA active
  25. 5) What colour is your TPA currently
  26. #### Map Door Text GMCP Parser
  27. * Files: `src/mdtparse.py`, `mdtconfig.json`, `src/gmcp.tin`
  28. * Blatantly copied from [Quow's](http://quow.co.uk) wonderful work for his MUSHclient configs.
  29. This python script (`src/mdtparse.py`) parses the mapdoortext data delivered by GMCP as you move rooms and displays a nice formatted list. Customizable with a configuration file (`mdtconfig.json`) that allows for picking out particular NPCs, assigning them point values, and colouring.
  30. #### Item/NPC/Room Search
  31. * Files: `src/quow.tin`
  32. * Made possible by [Quow's](http://quow.co.uk) fantastic data collection and publicly available database.
  33. A series of TinTin aliases that invoke SQLite to search through Quow's database and retrieve various information about game items, people and places.
  34. ##### Item Search
  35. > `db item sword`, `db npcitem sword`
  36. ```
  37. Results for items matching "sword":
  38. [0]: sword necklace (A$4.25) found in occult jewellery stall, Ankh-Morpork
  39. [1]: short sword (2,66Gl) found in dwarfish blacksmith's, Genua
  40. [2]: long sword (4,0Gl) found in dwarfish blacksmith's, Genua
  41. [3]: bastard sword (20Rh 100s) found in illegal contraband stall, Bes Pelargic
  42. [4]: double-edged broad sword (A$112.50) found in weapon shop, Ankh-Morpork
  43. [5]: watered-steel long sword (A$180) found in weapon shop, Ankh-Morpork
  44. [6]: rose-hilted long sword (A$180) found in weapon shop, Ankh-Morpork
  45. [7]: heavy sword [build-a-bear] (8Rh 60s) found in Assemble an Animal Workshop, Bes Pelargic
  46. [8]: short sword [build-a-bear] (8Rh 60s) found in Assemble an Animal Workshop, Bes Pelargic
  47. [9]: short sword scabbard (A$1) found in Sartorn and Son Scabbard Store, Ankh-Morpork
  48. ```
  49. The "item" keyword is searching shops, while "npcitem" searches NPC inventories.
  50. ##### NPC Search
  51. > `db npc villager`
  52. ```
  53. Results for NPCs matching "villager".
  54. [0]: villager [Hillshire] found in road running through Hillshire, Sto Plains Region
  55. [1]: bumpkin, local, oaf, peasant, villager, yokel found in commercial side street, Slippery Hollow
  56. [2]: villager found in western edge of the square, Bois
  57. [3]: Sheepridge villager found in Sheepridge village square, Sto Plains Region
  58. [4]: villager found in cobbled road in Blackglass, Uberwald Region
  59. [5]: villager [ramtop villages] found in road outside of Brass Neck, Ramtops Regions
  60. [6]: villager [Blackglass] found in cobbled road in Blackglass, Uberwald Region
  61. ```
  62. ##### Room Search
  63. > `db room launder`
  64. ```
  65. Results for rooms matching "launder".
  66. [0]: launder room (inside) found in AM Thieves
  67. [1]: launder room (inside) found in Genua Sewers
  68. ```
  69. ##### Gatherable Spice Search
  70. > `db gatherable thyme`
  71. ```
  72. Results for gatherables matching "thyme".
  73. [0]: some thyme found in garden, Bes Pelargic
  74. [1]: some thyme found in bottom part of the Temple gardens, Temple of Small Gods
  75. [2]: some thyme found in conservatory, BP Estates
  76. [3]: some thyme found in neat herb garden, Ramtops Regions
  77. [4]: some thyme found in service entrance to the Chronides farmstead, Klatchian Farmsteads
  78. [5]: some thyme found in northeast garden, Sto Plains Region
  79. [6]: some thyme found in garden, Ramtops Regions
  80. [7]: some thyme found in cottage herb garden, Ramtops Regions
  81. ```
  82. #### Speedwalking
  83. * Files: `src/maproute.py`, `src/gmcp.tin`, `src/quow.tin`
  84. * Route-finding logic and of course the database taken directly from [Quow's](http://quow.co.uk) lovely MUSHclient package.
  85. A python script (`src/maproute.py`) is handed the room_identifier of your current location and of your target location and attempts to create an alias to walk you there. This functionality can be invoked in-game with the `db route #` command, where `#` is the result number (0-9) that preceeds the results in any of the previously mentioned database search commands (`db item`, `db npc`, `db room`, `db gatherable`)
  86. **Example:**
  87. Here I am at Baldwin's smithy. But I need to make my way to the Mended Drum, let's speedwalk there (very contrived example but short and sweet).
  88. ```
  89. [smithy]
  90. @
  91. +
  92. This is a small, cramped room with a large, roaring fire blazing in the forge on the east wall of the room.
  93. There are various assorted tools of metalwork scattered around the fire and hanging on the walls, most notably
  94. the anvil in the centre of the room. The smithy is obviously very busy as there is a large, dirty order book
  95. lying open on a small desk near the door.
  96. There is one obvious exit: south.
  97. A cute goose, a young truffle pig, Baldwin "the Disemboweler" MacAvrik and Baldwin's apprentice are standing
  98. here.
  99. A piece of embroidered tartan is hanging on the wall and two iron chains and a copper short sword are on the
  100. floor.
  101. <unhurt | alert | rather warm | unburdened [25%] | 9626360xp>
  102. ```
  103. First lets search for the Mended Drum
  104. > `db room Mended Drum`
  105. ```
  106. Results for rooms matching "Mended Drum".
  107. [0]: north end of Short Street outside the Mended Drum (outside) found in Ankh-Morpork
  108. [1]: entrance to the Mended Drum (inside) found in AM Buildings
  109. [2]: bar of the Mended Drum (inside) found in AM Buildings
  110. [3]: western part of the Mended Drum (inside) found in AM Buildings
  111. [4]: toilets of the Mended Drum (inside) found in AM Buildings
  112. [5]: cubicle in the toilets of the Mended Drum (inside) found in AM Buildings
  113. [6]: cubicle in the toilets of the Mended Drum (inside) found in AM Buildings
  114. [7]: landing on the first floor in the Mended Drum (inside) found in AM Buildings
  115. [8]: front wall of the Mended Drum (outside) found in AM Buildings
  116. [9]: roof of the Mended Drum (outside) found in AM Buildings
  117. ```
  118. Great, we got a list of results back. Let's aim for the `entrance to the Mended Drum`, which is result number `1` in our list.
  119. > `db route 1`
  120. ```
  121. [speedwalk] Generating speedwalk from current location to entrance to the Mended Drum, AM Buildings...
  122. [speedwalk] A route was found, type "speedwalk" to fast travel.
  123. Changed alias "RuhsSpeedRun" from "nw;nw;w;nw;nw;sw;sw;sw $*$".
  124. <unhurt | fully rested | rather warm | unburdened [25%] | 9626384xp>
  125. alias RuhsSpeedRun
  126. RuhsSpeedRun: s;e;e;n $*$
  127. ```
  128. We found a way there, and our speedwalking alias was updated. Now typing `speedwalk` would walk us over to the Mended Drum (s;e;e;n).
  129. #### Hunting Hotspot Timers (with Syncing!)
  130. * File: `src/spottimers.tin`
  131. This set of configs is checking against a list of saved NPCs/Rooms (that I've determined, I think my hunting route is the bestest one, you might disagree, that's good for you) every time we see something die, or enter a new room, and records the time it happened.
  132. ```
  133. .:: Death Timers ::.
  134. - (99m) delbert
  135. - (11m) hlakket
  136. - (???) stables
  137. - (???) casino
  138. - (???) rogues
  139. - (???) grflx
  140. - (32m) shaker lions
  141. - (???) snail
  142. - (72m) dojo
  143. - (22m) medina boss
  144. - (???) zoon liar
  145. - (???) bandit leader
  146. - (???) cguards
  147. - (???) giant leader
  148. .:: Visit Timers ::.
  149. - (???) parades
  150. - (05m) offler
  151. - (09m) shades
  152. - (37m) smugglers
  153. - (???) black market
  154. ```
  155. Output like above is written to a file (so that it can be displayed next to the MUD, I keep it in a tintin pane above my ASCII map as you can see in the initial screenshot).
  156. Along with this come various commands to interact with the spot timers from within TinTin++ itself:
  157. ##### List timers in-line
  158. > `dt`
  159. The `dt` command will print the list of timers in the MUD output, allowing for them to be referenced even when not displaying the file output in real time. I make use of this when on mobile or having the MUD in a more compact window.
  160. ##### Reset all or individual timers
  161. > `dtreset all`, `dtreset hlakket`
  162. I've heard sometimes you can miss a spot or lose it to competition. Sounds like excuses to me, but just in case, you can note that you've lost a spot or otherwise know it went down by manually setting it's timer to "just now" with the `dtreset <spot_name>` command.
  163. Similarly, people tell me that on occasion real life requires that they *stop* hunting for a while, letting any previously recorded timers go stale and become useless. In this scenario you can use `dtreset all` to return all spots to the `Unseen/???` status and start fresh.
  164. ##### Share the timer list with your group
  165. > `gsdt`
  166. On occasion you have to group with folks who don't use my hotspot timer for TinTin++ or MUSHclient, leaving you unable to sync with them. You can take pity on these poor souls by sharing a snapshot of your current timers with them via group chat with the `gsdt` command.
  167. ```
  168. [groupname] Ruhsbaar: delbert: 99m | hlakket: 11m | stables: ??? | casino: ??? | rogues: ??? | grflx:
  169. ??? | shaker lions: 32m | snail: ??? | dojo: 72m | medina boss: 22m | zoon liar: ??? | bandit leader: ???
  170. | cguards: ??? | giant leader: ??? | parades: ??? | offler: 05m | shades: 09m | smugglers: 37m | black
  171. market: ???
  172. ```
  173. ##### Sync timers to another player
  174. > `dtsync <playername>`
  175. It's often useful to share your timers with another player, if they are freshly joining the group and taking a lead, or maybe you want to be nice and share with someone before going to bed! This can be done with the `dtsync` command.
  176. The syncing is done via a `tell` in game, and works between both my tt++ and MUSH plugins, allowing you to sync between players using the other client. When a players syncs their timers to yours, the plugin compares them to your existing values and only takes updates (e.g. if someone who killed Hlakket 90 minutes ago syncs to you, but you killed Hlakket 11 minutes ago, your 11 minute timer will not be overwritten).
  177. Note that because the tell containing sync information is full of lengthy unix timestamps, you'll need to make sure to set your `cols 999` in-game before having another player sync to you (this is only needed on tt++, MUSH handles this gracefully).
  178. ### Highlights/Actions/Other
  179. * HP loss and XP gain notifications
  180. * Dagger/Unarmed outgoing attacks
  181. * Outgoing special attempts/lands/fails
  182. * Outgoing backstabs
  183. * Incoming attacks
  184. * TPA shield drops
  185. * T-Shop rooms
  186. * Snatch/Filch
  187. * Rumbling doors
  188. * Inventory fumbles
  189. * Copperhead mines gases
  190. * Per day separated log files
  191. * More...
  192. ## Credit Where It's Due
  193. I've spent a lot of time and effort on this setup to make it perfect for my use and the contents herein have all been touched or modified by me in some way if not created outright, but I've been inspired by and blatantly stolen bits of it from two folks in particular:
  194. ### Quow
  195. You don't play this game without knowing who Quow is and at least having heard about all the work he's done on both various extensions for MUSHClient as well as the immense data collection effort that resulted in his database of rooms, npcs, items and more.
  196. The "mapdoortext" and "speedwalking" functionality present in my TinTin++ configurations is merely a port of the Lua code that exists in his plugins that I copied to and modified to work in my terminal-only environment.
  197. You can find Quow's work on his website: <http://quow.co.uk>
  198. ### Oki
  199. I've never even met Oki in game, but I stumbled upon their repository of tintin scripts some time ago and happily copied some of their magic/combat substitutions and highlights for my own use.
  200. There's some cool stuff in here I haven't gotten around to copying over yet but plan to, like Thief quota monitoring etc.
  201. You can find Oki's repository here: <https://git.tubul.net/richard/tt_dw.git>
  202. ## Disclaimer
  203. The files in this repository were created/modified/copied by me for my own personal use and come with no guarantee to work for you or your fairy godmother. I provide these files "as-is" and offer no support whatsoever to get them working.
  204. Any content herein that is my own is released under the terms and conditions of the [GNU Affero General Public Licence v3.0](https://www.gnu.org/licenses/agpl-3.0.en.html)