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

Game Attack Combos : WPF Hybrid Smart Client for Combo Calculations

, 23 May 2009
A WPF hybrid smart client for calculating attack combos in the Prince of Persia game.
Prize winner in Competition "Smart Client Article Contest"
GameAttackCombos_Src.zip
ComboServices
App_Data
ComboPackagesService.svc
GameAttackCombos.snk
Properties
GameAttackCombos.mdf
GameAttackCombos_log.LDF
Packages
PrinceOfPersia2008.gcp
PrinceOfPersia2010.gcp
PackageComboFiles
Properties
ServiceData
GameAttackCombosModel.edmx
Properties
Assets
Button Icons.design
Game Attack Combos Icon.design
Game Attack Combos Icon.ico
Prince of Persia 2008
Prince of Persia 2010
PrinceOfPersia2010Background.png
PrinceOfPersia2010Icon.png
PrinceOfPersia2008Background.png
PrinceOfPersia2008Icon.png
ComboClient
Game Attack Combos Icon.ico
Properties
Resources
Service References
Supporting
Themes
ComboServices
ComboPackagesService.disco
ComboPackagesService.wsdl
ComboPackagesService1.wsdl
configuration.svcinfo
configuration91.svcinfo
Reference.svcmap
app.manifest
ComboLogic
Properties
GameAttackCombos_Standalone.zip
Packages
PrinceOfPersia2008.gcp
PrinceOfPersia2010.gcp
Resources
//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//     Runtime Version:2.0.50727.3082
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

[assembly: global::System.Data.Objects.DataClasses.EdmSchemaAttribute()]
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("GG.GameAttackCombos.Data", "FK_GameDisc_Game", "Game", global::System.Data.Metadata.Edm.RelationshipMultiplicity.One, typeof(GG.GameAttackCombos.Data.Game), "GameDisc", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(GG.GameAttackCombos.Data.GameDisc))]

// Original file name:
// Generation date: 4/20/2009 10:05:47 AM
namespace GG.GameAttackCombos.Data
{
    
    /// <summary>
    /// There are no comments for GameAttackCombosEntities in the schema.
    /// </summary>
    public partial class GameAttackCombosEntities : global::System.Data.Objects.ObjectContext
    {
        /// <summary>
        /// Initializes a new GameAttackCombosEntities object using the connection string found in the 'GameAttackCombosEntities' section of the application configuration file.
        /// </summary>
        public GameAttackCombosEntities() : 
                base("name=GameAttackCombosEntities", "GameAttackCombosEntities")
        {
            this.OnContextCreated();
        }
        /// <summary>
        /// Initialize a new GameAttackCombosEntities object.
        /// </summary>
        public GameAttackCombosEntities(string connectionString) : 
                base(connectionString, "GameAttackCombosEntities")
        {
            this.OnContextCreated();
        }
        /// <summary>
        /// Initialize a new GameAttackCombosEntities object.
        /// </summary>
        public GameAttackCombosEntities(global::System.Data.EntityClient.EntityConnection connection) : 
                base(connection, "GameAttackCombosEntities")
        {
            this.OnContextCreated();
        }
        partial void OnContextCreated();
        /// <summary>
        /// There are no comments for Game in the schema.
        /// </summary>
        public global::System.Data.Objects.ObjectQuery<Game> Game
        {
            get
            {
                if ((this._Game == null))
                {
                    this._Game = base.CreateQuery<Game>("[Game]");
                }
                return this._Game;
            }
        }
        private global::System.Data.Objects.ObjectQuery<Game> _Game;
        /// <summary>
        /// There are no comments for GameDisc in the schema.
        /// </summary>
        public global::System.Data.Objects.ObjectQuery<GameDisc> GameDisc
        {
            get
            {
                if ((this._GameDisc == null))
                {
                    this._GameDisc = base.CreateQuery<GameDisc>("[GameDisc]");
                }
                return this._GameDisc;
            }
        }
        private global::System.Data.Objects.ObjectQuery<GameDisc> _GameDisc;
        /// <summary>
        /// There are no comments for Game in the schema.
        /// </summary>
        public void AddToGame(Game game)
        {
            base.AddObject("Game", game);
        }
        /// <summary>
        /// There are no comments for GameDisc in the schema.
        /// </summary>
        public void AddToGameDisc(GameDisc gameDisc)
        {
            base.AddObject("GameDisc", gameDisc);
        }
    }
    /// <summary>
    /// There are no comments for GG.GameAttackCombos.Data.Game in the schema.
    /// </summary>
    /// <KeyProperties>
    /// GameId
    /// </KeyProperties>
    [global::System.Data.Objects.DataClasses.EdmEntityTypeAttribute(NamespaceName="GG.GameAttackCombos.Data", Name="Game")]
    [global::System.Runtime.Serialization.DataContractAttribute(IsReference=true)]
    [global::System.Serializable()]
    public partial class Game : global::System.Data.Objects.DataClasses.EntityObject
    {
        /// <summary>
        /// Create a new Game object.
        /// </summary>
        /// <param name="gameId">Initial value of GameId.</param>
        /// <param name="title">Initial value of Title.</param>
        /// <param name="comboPackageFileName">Initial value of ComboPackageFileName.</param>
        public static Game CreateGame(int gameId, string title, string comboPackageFileName)
        {
            Game game = new Game();
            game.GameId = gameId;
            game.Title = title;
            game.ComboPackageFileName = comboPackageFileName;
            return game;
        }
        /// <summary>
        /// There are no comments for Property GameId in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(EntityKeyProperty=true, IsNullable=false)]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public int GameId
        {
            get
            {
                return this._GameId;
            }
            set
            {
                this.OnGameIdChanging(value);
                this.ReportPropertyChanging("GameId");
                this._GameId = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
                this.ReportPropertyChanged("GameId");
                this.OnGameIdChanged();
            }
        }
        private int _GameId;
        partial void OnGameIdChanging(int value);
        partial void OnGameIdChanged();
        /// <summary>
        /// There are no comments for Property Title in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public string Title
        {
            get
            {
                return this._Title;
            }
            set
            {
                this.OnTitleChanging(value);
                this.ReportPropertyChanging("Title");
                this._Title = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value, false);
                this.ReportPropertyChanged("Title");
                this.OnTitleChanged();
            }
        }
        private string _Title;
        partial void OnTitleChanging(string value);
        partial void OnTitleChanged();
        /// <summary>
        /// There are no comments for Property ComboPackageFileName in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public string ComboPackageFileName
        {
            get
            {
                return this._ComboPackageFileName;
            }
            set
            {
                this.OnComboPackageFileNameChanging(value);
                this.ReportPropertyChanging("ComboPackageFileName");
                this._ComboPackageFileName = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value, false);
                this.ReportPropertyChanged("ComboPackageFileName");
                this.OnComboPackageFileNameChanged();
            }
        }
        private string _ComboPackageFileName;
        partial void OnComboPackageFileNameChanging(string value);
        partial void OnComboPackageFileNameChanged();
        /// <summary>
        /// There are no comments for GameDisc in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmRelationshipNavigationPropertyAttribute("GG.GameAttackCombos.Data", "FK_GameDisc_Game", "GameDisc")]
        [global::System.Xml.Serialization.XmlIgnoreAttribute()]
        [global::System.Xml.Serialization.SoapIgnoreAttribute()]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public global::System.Data.Objects.DataClasses.EntityCollection<GameDisc> GameDisc
        {
            get
            {
                return ((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.GetRelatedCollection<GameDisc>("GG.GameAttackCombos.Data.FK_GameDisc_Game", "GameDisc");
            }
            set
            {
                if ((value != null))
                {
                    ((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.InitializeRelatedCollection<GameDisc>("GG.GameAttackCombos.Data.FK_GameDisc_Game", "GameDisc", value);
                }
            }
        }
    }
    /// <summary>
    /// There are no comments for GG.GameAttackCombos.Data.GameDisc in the schema.
    /// </summary>
    /// <KeyProperties>
    /// GameDiscCode
    /// </KeyProperties>
    [global::System.Data.Objects.DataClasses.EdmEntityTypeAttribute(NamespaceName="GG.GameAttackCombos.Data", Name="GameDisc")]
    [global::System.Runtime.Serialization.DataContractAttribute(IsReference=true)]
    [global::System.Serializable()]
    public partial class GameDisc : global::System.Data.Objects.DataClasses.EntityObject
    {
        /// <summary>
        /// Create a new GameDisc object.
        /// </summary>
        /// <param name="gameDiscCode">Initial value of GameDiscCode.</param>
        public static GameDisc CreateGameDisc(string gameDiscCode)
        {
            GameDisc gameDisc = new GameDisc();
            gameDisc.GameDiscCode = gameDiscCode;
            return gameDisc;
        }
        /// <summary>
        /// There are no comments for Property GameDiscCode in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(EntityKeyProperty=true, IsNullable=false)]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public string GameDiscCode
        {
            get
            {
                return this._GameDiscCode;
            }
            set
            {
                this.OnGameDiscCodeChanging(value);
                this.ReportPropertyChanging("GameDiscCode");
                this._GameDiscCode = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value, false);
                this.ReportPropertyChanged("GameDiscCode");
                this.OnGameDiscCodeChanged();
            }
        }
        private string _GameDiscCode;
        partial void OnGameDiscCodeChanging(string value);
        partial void OnGameDiscCodeChanged();
        /// <summary>
        /// There are no comments for Game in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmRelationshipNavigationPropertyAttribute("GG.GameAttackCombos.Data", "FK_GameDisc_Game", "Game")]
        [global::System.Xml.Serialization.XmlIgnoreAttribute()]
        [global::System.Xml.Serialization.SoapIgnoreAttribute()]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public Game Game
        {
            get
            {
                return ((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.GetRelatedReference<Game>("GG.GameAttackCombos.Data.FK_GameDisc_Game", "Game").Value;
            }
            set
            {
                ((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.GetRelatedReference<Game>("GG.GameAttackCombos.Data.FK_GameDisc_Game", "Game").Value = value;
            }
        }
        /// <summary>
        /// There are no comments for Game in the schema.
        /// </summary>
        [global::System.ComponentModel.BrowsableAttribute(false)]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public global::System.Data.Objects.DataClasses.EntityReference<Game> GameReference
        {
            get
            {
                return ((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.GetRelatedReference<Game>("GG.GameAttackCombos.Data.FK_GameDisc_Game", "Game");
            }
            set
            {
                if ((value != null))
                {
                    ((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.InitializeRelatedReference<Game>("GG.GameAttackCombos.Data.FK_GameDisc_Game", "Game", value);
                }
            }
        }
    }
}

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)

About the Author

Matt Sollars
Web Developer
United States United States
I began programming on my Commodore 64 at around the age of 12. After migrating to DOS and then Windows, I decided to take on the Web. Several languages and platforms later, I have settled in with .NET nicely. I am currently the owner of a software consulting company and lead application developer for a learning-based technology consultation company.
 
The love of a finished application is usually at war with the desire to improve it as soon as it's released (they're never really finished).

| Advertise | Privacy | Mobile
Web04 | 2.8.140721.1 | Last Updated 23 May 2009
Article Copyright 2009 by Matt Sollars
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid