Hoookay. So. I got the database done, that took me about 3 hours mainly because I'm so wiped out it was hard to concentrate and keep my thoughts in order. Especially when your editing a plain text file in Notepad :P Ugh. Another issue was remembering the various menu options and whatnot, luckily tho we have a very nice design document (which I will be updating) so I was able to reference it. Anyways here is the full database so far. I'll prob be adding more entries as development progresses but this is all I need for what I have right now. I'll cover it bit by bit mainly for my own reference - but if you wanna follow along be my guest. I'll be referencing this image throught, as well as the page I linked to above:
This record is for the Controller menu text and game setting. The text field is what is displayed on the menu, while the value field matches up with a numeric value in the game data. This way when a button is clicked the game data value is incremented/decremented and the text is updated accordingly. This is how all menu text works.
player count Table
Here's basically the same setup as before for the Player option on the menu. The value field tells the game how many players are chosen (I know 2 players isn't 0 but that's just an enumeration) while the text field displays that amount for the user to see.
Moving along we have here the record for the ingame music. The text and value fields play their normal roles, but this record has a unique field, profile. This field is the name of the AudioProfile datablock that was created for each game music, so that the game can control the selected music.
turn timer Table
The Turn Timer is a mechanism to make the games move faster. If you don't make a move in the allotted time, you lose your turn to the next player. In game modes where you only have a certain amount of peices to place (Domination and Equilibrium), you end up losing that peice as well! These are the various settings for the timer, from Off to 45 seconds. The data field is used by the game so it knows how many seconds to set the clock to. I use the data field elsewhere too, it's basically a version of the text field the computer can understand easier. I mean why bother parse the string "45 Sec" when you can just have another field with the value already there?
board size Table
Board Size can also determine the length of a game. The smaller the board and the more the players, the shorter the game. And vice-a-versa. We have the usual text/value duo at work here but instead of data we have desc field. This field serves a dual purpose: For the developer, it describes what this setting does in the database file. For the user, I use this field as help text.
game type Table
This record defines the various game types available. You can look at the desc field to see what each type is like. The only one to note is the last one, Blitzkreig. When this is selected the turn timer is locked at 5 seconds.
Here also is where I've started to deviate from the design doc. In the doc, it lists these under Victory Conditions instead of Game Types in the documentation for the setup menu, which isn't quite correct. They are victory conditions, but each game type is supposed to have tweakable conditions for victory. So where were they supposed to go? So I came up with the idea that the Victory Conditions options would change based on the Game Type that was selected. Here they are:
conquest victory condition Table
In a Conquest game, the object is to try and take over all the other player's peices (planets). No points, no territory counts. Just pure conquest. Even though that's a single objective, in this game that can sometimes take quite a while. So I've created a game timer victory condition as a way to allow users control over how long they want to play, if they want that control at all. If nobody conquers the rest of the players by game end? The game ends in a draw.
planet victory condition Table
These victory conditions apply to the Equilibrium (most points) and Domination (most territory) game types. Here instead of a game clock to limit play length we have a planet cap. Players each start with a set amount of planets and each turn they place one until everyone has run out. At that point the game is over and the winner is announced.
blitzkreig victory condition Table
The Blitzkreig game type threw me for a bit, because it's not really a game type in itself but rather a game constraint masquerading as a game type. So I decided to assign the game type through the victory condition. Now you know how the game will be played and by what rules the victor will be decided. Note also that the value fields here match the value fields for the game type record.
imperialism victory condition Table
Imperialism mode is my favorite, and it was inspired by Big Huge Game's Rise of Nations. In any other game you're allowed to place your peices anywhere you want on the board. However in this mode you can only place peices in squares that are shaded your color, which is your territory. This opens up a whole new strategy to playing the game.
game data Table
These are the values that are saved from game to game. These are the menu options that don't change a lot. The 'null' value for board type is a placeholder until I program in map loading. Then this field will hold the name of the last game map played.
So there it is. All done. Yey. Now I can go to bed. Egads I'm so tired, it's crazy! Tho I was up rather early today to hang up xmas lights. Oh boy don't even get me started there. I HATE hanging up lights. Luckily they're white lights so I don't have to take them back down till like, March when it's a bit warmer again.
Aiight I'm about to pass out in front of the comp so I better be going. I was hoping to actually code in the functionality tonight too but no way in hell that's gunna happen. Tomorrow then. Yes... tomorrow...