Y Dice  

A poker-oriented game of chance using virtual dice

Objective:
To get as many points by rolling the dice to fulfill one of 13 scenarios.

The Rules:
The game consists of 13 rounds. The player is given 3 chances, or rolls of the dice, in each round to obtain the most favorable die values that can be used to score for each round. Every round has its own target, but the target is set by the player, usually selecting the most beneficial target to maximize the points that can be scored for that round.
Operating the Game:
Use the Roll button to get a new set of five dice. Look over the dice and determine what combination is favorable. Then select the dice you wish to keep. If the dice presented match one of the targets, then select the target you wish to apply the dice combination to, using the appropriate radio button. Then select the appropriate checkboxes for each die you wish to keep. If all dice are to be kept, then press the Keep All button. If you make a mistake, press the Clear Keeps button to uncheck all of the checkboxes.
Once you have selected a target and are satisfied you have the best combination of dice for the target, then press the Commit button. This will commit the dice to a target, and bring up a new round. If you are not satisfied with the dice combination that were presented the first roll, then select the die you wish to keep and press the Roll button again. You can do this up to three times for a round. On the third round, the Roll button will be disabled, and you will be forced to commit the dice to a target.
If you have no combination worth keeping, then you must select a target that will be wasted, and have zero points applied towards it. This is done be leaving all checkboxes cleared, selecting a target to waste, and then pressing the Commit button. You will be asked to confirm that you will apply zero points to a certain target.
The game will end after thirteen rounds, which will cover the thirteen targets. Your total score will appear at the end.
Under the Hood:
YDice was written as a training tool for learning how to create a simple XML application. Feel free to look at the code and the supporting stylesheets. At the conclusion of a game, the user will be presented with a button to save the game data as an XML file.
Note that at this time an HTML INPUT tag was used to provide for the file selection browse button, but it will not allow one to enter a non-existing filename. The button still works if you use it to browse to the folder where the XML file is to be saved. Then right click in the folder and select "New - Text Document". Name the text file to the name of the desired XML file, and this button will work. Otherwise, do not bother with the browse button, and just type the entire path and filename into the textbox provided.

Page last updated: 9-December-2004 16:46