 |
Daagar Magician
Joined: 25 Oct 2000 Posts: 461 Location: USA
|
Posted: Sun Mar 17, 2002 4:46 pm
Simple DB |
I'm a bit stumped about how to go about setting up a very simple database. Note that I'm not attempting to parse any 'identify' output... there are plenty of example for doing that. Here is what I'm after:
I would simply like to track Mobs, their location on the automapper (ie., zone and optionally room), and any items they are carrying. I also want to be able to keep track of items that aren't necessarily carried by mobs at all, simply keeping track of zone and optionally room.
The need for room being optional is for the case of wandering mobs... they'll always be in a certain zone, but not always the same room.
I'm assuming I need two database, one for items and one for mobs. I'll need a view for adding mobs without rooms, and one with rooms.
The big question I guess, is how do I associate items in the item database with mobs in the mob database? It is possible I'll have items in my possession prior to my knowledge of which mob it comes from, so I need to be able to add that information later if necessary. Thanks! |
|
|
 |
Troubadour GURU
Joined: 14 Oct 2000 Posts: 556 Location: USA
|
Posted: Sun Mar 17, 2002 11:58 pm |
At this time, Views can only be associated with one database (table).
What you could do is to create two databases, Mobs and Items. In the Mobs db, create a text field named Possessions. You can then either put a string list of items by name "sword|shield|helm" OR a string list of the record numbers for those items "14It|234It|77It". Likewise in the Items db, create a text field named Source. In it you can put the name of the Mob or the record number of the mob in Mob db, i.e. "138Mo". You'll then have to create an alias to parse and display the actual record information.
Troubadour  |
|
|
 |
Daagar Magician
Joined: 25 Oct 2000 Posts: 461 Location: USA
|
Posted: Mon Mar 18, 2002 1:50 am |
Thanks... this is the path I've pretty much gone down. Just wanted to be sure I wasn't making life hard on myself. I even simplified things a bit further: I let items have a mob record (on the assumption that most items will be associated with a single mob), but I don't bother with mobs having an item list at all.
This will allow me to do basic simple operations (find what mob carries a specific item, and the zone/room it is in). It is less important at the moment that I can query against the mob table, which is why I can forgo the 'possesions' list. Thanks! |
|
|
 |
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|