kai wrote: ↑Wed Jul 21, 2021 12:51 am
Hrmm have any updates been made to the storage script?
Currently you can't type li in any room that isn't a rent - in any part of your string.
Also I can't figure out, does this get put into a useable/readable file anywhere? I was able to find the db file but didn't know what to open it with
I made an alias that replaces li/lis/list with a list command. It basically tells the db to clear all items stored for that room, and then to send "list" to the MUD. So unless you use li/lis/list for something else, it should work.
I had the issue it would not allow "listen all' but corrected that (before I uploaded the script) by making sure the command is really li/lis/list and not anything else. I don't have issues typing list in any other room.
The database is an sql database. You can open it with, for example:
https://sqlitebrowser.org/
for completeness sake. The alias is called "replace list command"
syntax:
Code: Select all
(?:^|\W)li(?:$|\W)|(?:^|\W)lis(?:$|\W)|(?:^|\W)^list(?:$|\W)
and code:
Code: Select all
- this alias replaces the list command and ensures that when we send list, the database is emptied for the current room (this so that we can refill it afterwards with the current state)
-- firs we delete everything that's stored, so we always have an up to date list.
local myinn = db:get_database("inndatabase")
db:delete(myinn.Storage, db:eq(myinn.Storage.inn, getRoomName(getPlayerRoom())))
send('list')
If you have something else as syntax in the alias, then maybe I remembered wrongly and you could update it to this.