Type.registerNamespace('Games');
Games.Draughts=function() {
Games.Draughts.initializeBase(this);
this._timeout = 0;
this._userContext = null;
this._succeeded = null;
this._failed = null;
}
Games.Draughts.prototype={
NewGame:function(Difficulty,succeededCallback, failedCallback, userContext) {
return this._invoke(Games.Draughts.get_path(), 'NewGame',false,{Difficulty:Difficulty},succeededCallback,failedCallback,userContext); },
MovePiece:function(fromIndex,toIndex,succeededCallback, failedCallback, userContext) {
return this._invoke(Games.Draughts.get_path(), 'MovePiece',false,{fromIndex:fromIndex,toIndex:toIndex},succeededCallback,failedCallback,userContext); },
MoveForMe:function(succeededCallback, failedCallback, userContext) {
return this._invoke(Games.Draughts.get_path(), 'MoveForMe',false,{},succeededCallback,failedCallback,userContext); }}
Games.Draughts.registerClass('Games.Draughts',Sys.Net.WebServiceProxy);
Games.Draughts._staticInstance = new Games.Draughts();
Games.Draughts.set_path = function(value) { 
var e = Function._validateParams(arguments, [{name: 'path', type: String}]); if (e) throw e; Games.Draughts._staticInstance._path = value; }
Games.Draughts.get_path = function() { return Games.Draughts._staticInstance._path; }
Games.Draughts.set_timeout = function(value) { var e = Function._validateParams(arguments, [{name: 'timeout', type: Number}]); if (e) throw e; if (value < 0) { throw Error.argumentOutOfRange('value', value, Sys.Res.invalidTimeout); }
Games.Draughts._staticInstance._timeout = value; }
Games.Draughts.get_timeout = function() { 
return Games.Draughts._staticInstance._timeout; }
Games.Draughts.set_defaultUserContext = function(value) { 
Games.Draughts._staticInstance._userContext = value; }
Games.Draughts.get_defaultUserContext = function() { 
return Games.Draughts._staticInstance._userContext; }
Games.Draughts.set_defaultSucceededCallback = function(value) { 
var e = Function._validateParams(arguments, [{name: 'defaultSucceededCallback', type: Function}]); if (e) throw e; Games.Draughts._staticInstance._succeeded = value; }
Games.Draughts.get_defaultSucceededCallback = function() { 
return Games.Draughts._staticInstance._succeeded; }
Games.Draughts.set_defaultFailedCallback = function(value) { 
var e = Function._validateParams(arguments, [{name: 'defaultFailedCallback', type: Function}]); if (e) throw e; Games.Draughts._staticInstance._failed = value; }
Games.Draughts.get_defaultFailedCallback = function() { 
return Games.Draughts._staticInstance._failed; }
Games.Draughts.set_path("/Draughts/Draughts.asmx");
Games.Draughts.NewGame= function(Difficulty,onSuccess,onFailed,userContext) {Games.Draughts._staticInstance.NewGame(Difficulty,onSuccess,onFailed,userContext); }
Games.Draughts.MovePiece= function(fromIndex,toIndex,onSuccess,onFailed,userContext) {Games.Draughts._staticInstance.MovePiece(fromIndex,toIndex,onSuccess,onFailed,userContext); }
Games.Draughts.MoveForMe= function(onSuccess,onFailed,userContext) {Games.Draughts._staticInstance.MoveForMe(onSuccess,onFailed,userContext); }
var gtc = Sys.Net.WebServiceProxy._generateTypedConstructor;
if (typeof(Games.MoveResult) === 'undefined') {
Games.MoveResult=gtc("Games.MoveResult");
Games.MoveResult.registerClass('Games.MoveResult');
}
