Click here to Skip to main content
Click here to Skip to main content
Add your own
alternative version
Go to top

Reversi for Windows Mobile

, 12 May 2009
The game Reversi for Windows Mobile using the Compact Framework.
using System;
using System.Linq;
using System.Collections.Generic;
using System.Text;

namespace GameExample.Reversi
{
    /// <summary>
    /// The game options.
    /// </summary>
    public class GameOptions
    {
        /// <summary>
        /// Gets or sets the width of the board.
        /// </summary>
        /// <value>The width of the board.</value>
        public int BoardWidth { get; set; }
        /// <summary>
        /// Gets or sets the height of the board.
        /// </summary>
        /// <value>The height of the board.</value>
        public int BoardHeight { get; set; }
        
        /// <summary>
        /// Gets or sets a value indicating whether [sounds enabled].
        /// </summary>
        /// <value><c>true</c> if [sounds enabled]; otherwise, <c>false</c>.</value>
        public bool SoundsEnabled { get; set; }

        /// <summary>
        /// Gets or sets the player one.
        /// </summary>
        /// <value>The player one.</value>
        public PlayerType PlayerOne { get; set; }

        /// <summary>
        /// Gets or sets the player two.
        /// </summary>
        /// <value>The player two.</value>
        public PlayerType PlayerTwo { get; set; }

        /// <summary>
        /// Gets the default.
        /// </summary>
        /// <value>The default.</value>
        public static GameOptions Default
        {
            get {
                return new GameOptions() { BoardHeight = 8, BoardWidth = 8, SoundsEnabled = true,
                PlayerOne = PlayerType.Person, PlayerTwo = PlayerType.Computer};
            }
        }
    }
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Ziad Elmalki

United States United States
No Biography provided

| Advertise | Privacy | Mobile
Web01 | 2.8.140926.1 | Last Updated 13 May 2009
Article Copyright 2009 by Ziad Elmalki
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid