A project....
I decided to make a WIP thread for this. I honestly didn't think that my half-formed half-crazed idea would get the reception it has. Not only was there tremendous feedback in the previous thread about this, but I got a LOT of private communication about it. So I'm quote energized and excited about this now!
The General Idea
Imagine a website where you can view detailed stats about someone's Morrowind character, complete with a screenshot gallery. Now imagine that this website updates while you are playing. That's the general idea.
The Process
So you go to the GHF Census and Excise Office website and register for a new character. You are given a character ID, then you go play Morrowind. The mod setup process will ask you for this character ID, which it will use (obviously) to reference your character's stats online. As you are playing, every few minutes a few scripts will run and harvest a LOT of data about your character and game. This data will be passed through peachykeen's MWSQL into a local database and stored there. Now if you are connected to the internet, this data will be immediately uploaded to our server and displayed on your character's page. If not, you can log in later and manually upload it.
I have really given this a lot of thought over the past few days, and done a lot of research on the use of SQL databases. I have learned a lot; the most important being that the best place to start with such a project is determining which data you will store, and the structure in which it will be stored. All day at work today I was working on arranging the database tables.
I have never created an entire database from scratch before, so there may obviously be better ways to arrange this. I am open to suggestions. I did heavily base much of this on what I learned by thoroughly examining phpBB3 databases and how they correlated data between tables.
My proposed tables, followed by the rows:
(Items with a * next to it is something that the user can manually enter/edit on the site; will be necessary for custom modded things.)
Users //data for the site member
User ID
Username
Password
Email Address
Account Active
Account Level
Number of Characters
Number of Comments
Location
Gender
Website
Character //data for each character
Character ID
Owner's User ID
Is Active //has any data been uploaded yet?
Last Time DB Updated //can determine if the player is currently playing
Number of Screenshots
Number of Comments
Number of Page Views
Name
Avatar Image Path*
Race*
Gender
Class*
Class Description*
Birthsign*
Birthsign Image Path*
Major Skill 1
Major Skill 2
Major Skill 3
Major Skill 4
Major Skill 5
Minor Skill 1
Minor Skill 2
Minor Skill 3
Minor Skill 4
Minor Skill 5
Back Story *
Primary Residence*
Journal File Name //perhaps upload Journal.htm, remove unwanted characters (those around hotlinks) and rename with char ID; will display on a page separate from character screen
Level
Current Health //these will be shown graphically as well as as a fraction on character screen
Max Health
Current Fatigue
Max Fatigue
Current Magicka
Max Magicka
Skills //one row for each one
Attributes //one row for each
Attribute Fortified //one row for each, true/false, can use xGetBasixxx to tell, will determine font color when displaying attribute value
Attribute Damaged //one row for each, same as above
Reputation
Bounty
Current Encumbrance
Max Encumbrance
Current Cell ID
Has Common Disease
Has Blight Disease
Has Corprus Disease
Is/Was Werewolf
Is/Was Vampire
Is Clan Aundae
Is Clan Berne
Is Clan Quarra
Faction //row for each vanilla faction player can join, a dozen or so for custom factions
Faction Reputation //some of this faction stuff can't be acquired through scripting...I will work my genie magic on it, I think I have figured out how to make it work
Faction Rank //again, one row for each faction, for all of this faction stuff
Current Time //GameHour
Day
Month
Current Weather Conditions
Days Passed //game time since player was created
Hours Played //Real time game has been played
//Potentially other things, but this is all I can think of right now; please suggest any more that you may think of.
Inventory
Owner ID (character ID)
Equipped Weapon 1
Equipped Weapon 2 //for arrows, etc
Equipped Clothing //9 rows total
Equipped Armor //8 rows total
Gold Amount
Net Worth //total value of all items in inventory + gold
All Other Inventory Items //total of 1000 rows, one item in each row; string will contain item name and count (ie Silver Broadsword 2)
NPCs
Owner ID (character ID)
Hostile NPCs & Creatures //20 rows possible, not likely that there will be 20 hostiles at one time, game will probably CTD
Follower & Companions //20 rows
Mods //intend to find a way to read current mod list from Morrowind.ini
Owner ID (character ID)
Mod Filename //255 rows possible
//I want to be able to display all of the loaded mods on a separate page from the character screen; when you click on a mod file name, it will automatically use ES Search to find it
Screenshots
Owner ID (character ID)
Picture ID
Filename
Thumbnail Filename
Caption
Number of Views
Comments //members can leave comments on character page
Owner ID (character ID)
Comment ID
Author
Comment
I have been gradually working on building this; I've spent a bit of time working on the registration/login system. We'll move on from there.
I am to understand that peachykeen is working on making MWSQL compatible with MySQL. I believe that will make things a lot easier to come up with a way to upload the data. Dogsbody suggested in the last thread that we can use the local MySQL logs to copy the queries to the central database. That is certainly something I am going to be looking at. It will also be necessary for our program to acquire the mod list from Morrowind.ini and write it to the database as well.
I have set up a headless LAMP server here at my house and made it live. I don't have a static IP, so giving out my IP would be pointless and stupid. But for those of you who are willing to get involved, I will set up a mailing list and keep you updated on how to access the server. I would rather build the whole system on my little dinky server here where I can make regular backups on multiple types of media, and won't risk screwing anything up or building security holes on the server that GHF resides on.
So who's excited for this?
Who wants to help?
One thing that would be nice to have right off the bat (it will help me with the site design overall) would be to have a site header image. Artistic freedom is given, the most appealing that is offered will be used. :hehe: