[Home] [Downloads] [Search] [Help/forum]

Gammon Forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  Suggestions
. . -> [Subject]  Plugin DBs
Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?

Plugin DBs

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page


Posted by WillFa   USA  (525 posts)  [Biography] bio
Date Tue 07 Jul 2009 12:50 AM (UTC)
Message
Since 4.42 seems to be adding a lot of database features for plugins, I thought it would be neat if the xml could be incorporated into a table named "Mushclient". The Add Plugin Dialog could then be pointed to a sqlite db, that would attach th db, look for the table, parse the embedded xml (I was thinking for simplicity that the Mushclient Table would have 2 columns (name, value), 6 records: Plugin, Triggers, Aliases, Timers, Variables, Script. Basically the top level xml tags with the xml in the value column.

Why distribute 2 files when you can distribute one? :)

[Go to top] top

Posted by Worstje   Netherlands  (899 posts)  [Biography] bio
Date Reply #1 on Tue 07 Jul 2009 05:25 PM (UTC)
Message
Why reinvent the filesystem, seriously? I can kind of see an advantage to zip, rar and other such compression formats, but an uncompressed DB makes no sense, sorry.

XML is useful because it is user readable and easy to edit. I don't want to have a 'compile' step after writing stuff, or need to edit stuff in a database.

One of the most made mistakes in websites with submitted files is that people put the files in the database. A database isn't made to store files - it is made to store data. If you want to fill blob fields with tons of data like XML, images, etc.. you are really missing the point of a database imo.
[Go to top] top

Posted by Fadedparadox   USA  (91 posts)  [Biography] bio
Date Reply #2 on Tue 07 Jul 2009 05:53 PM (UTC)
Message
I can see the use of things like distributing sounds/images, using one file instead of many, but I don't see the point of storing xml like that.
[Go to top] top

Posted by Nick Gammon   Australia  (21,322 posts)  [Biography] bio   Forum Administrator
Date Reply #3 on Tue 07 Jul 2009 11:21 PM (UTC)
Message
Quote:

A database isn't made to store files - it is made to store data. If you want to fill blob fields with tons of data like XML, images, etc.. you are really missing the point of a database imo.


Well, files contain data, right?

I got my inspiration somewhat from Blizzard. Their games that I have seen (eg. Diablo, World of Warcraft) store heaps of small files (graphics, sounds, and other things like landscapes) into .MPQ files. I am presuming that the MPQ files are a sort-of database. There are programs called MPQ-extractors that will pull out the individual .wav and other files that are stored in them.

I am guessing that internally the MPQ files are organized like a mini file-system, where the program can quickly access an individual item (eg. a sound) so it can be pulled out and played. These files are not pre-extracted, and thus the footprint for the gamer's file system is fairly low (ie. instead of tens of thousands of small files, they have a handful of MPQ files). Of course, they take up much the same amount of disk space.

Quote:

I don't want to have a 'compile' step after writing stuff, or need to edit stuff in a database.


I am inclined to agree with this. Whilst developing a plugin, it would be a pain to have to re-insert the XML every time you change a line of code. However the graphics and sounds are likely to be fairly static.

You could also conceivably have a few files, like this:


  • The core plugin as a .XML file
  • The graphics and sound effects in a database
  • Localized data (ie. help messages, prompts) translated into various languages. You would install the database relevant to your language.
  • User custom configurations (eg. position of windows, plugin options) in another database. The player could reset to default by simply deleting it.


- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Cbond   USA  (19 posts)  [Biography] bio
Date Reply #4 on Wed 08 Jul 2009 04:15 AM (UTC)
Message
Actually, the MPQ files are, essentially, archives that hold all the stuff which can go under a single type, like sounds. Bethesda Softworks uses something similar with their .bsa files. My ringtone was pulled from one of the BSA's for Fallout 3. "Death is preferable to communism".
[Go to top] top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


5,353 views.

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

Quick links: MUSHclient. MUSHclient help. Forum shortcuts. Posting templates. Lua modules. Lua documentation.

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.

[Home]


Written by Nick Gammon - 5K   profile for Nick Gammon on Stack Exchange, a network of free, community-driven Q&A sites   Marriage equality

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( https://gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Hosted at FutureQuest]