Remoting.Value<bool> IVerify.Login(string name, string password) { Remoting.Value<bool> returnValue = new Remoting.Value<bool>(); ; Remoting.Value<Data.Account> val = _Storage.FindAccount(name); val.OnValue += (account) => { returnValue.SetValue(_Verify(account, password)); }; return returnValue; }
public ActorCast(Serializable.Skill skill, ActorPropertyAbility actor, Remoting.Value<CastResult> return_value) { _Actor = actor; this._Skill = skill; this._ReturnValue = return_value; _Done = false; _Machine = new Utility.StageMachine(); _Step = CastStep.NotYet; }
Regulus.Remoting.Value<IBattlerBehavior> IBattleAdmissionTickets.Visit(Pet pet) { Regulus.Remoting.Value<IBattlerBehavior> rce = new Remoting.Value<IBattlerBehavior>(); ReadyInfomation ri = (from readyInfomation in _ReadyInfomations where readyInfomation.Battler.Id == pet.Owner && readyInfomation.Pet == null select readyInfomation).FirstOrDefault(); if (ri != null) { ri.Pet = pet; ri.BattleBehavior = rce; _Count++; } return rce; }
Remoting.Value<IBattleAdmissionTickets> IZone.Open(BattleRequester requester) { Remoting.Value<IBattleAdmissionTickets> ret = new Remoting.Value<IBattleAdmissionTickets>(); var field = new Field(requester.Battlers.ToArray()); field.EndEvent += () => { _Fields.RemoveFramework(field); }; field.FirstEvent += (val) => { ret.SetValue(val); }; _Fields.AddFramework(field); return ret; }
public SkillHitToIdleBehaviorHandler(Entity entity, Remoting.Value<CastResult> result) { this._Entity = entity; this._Result = result; }
Remoting.Value<CastResult> IActorPropertyAbility.Cast(int id) { Remoting.Value<CastResult> returnValue = new Remoting.Value<CastResult>(); var skill = _FindSkill(id); if (skill != null) { _CurrentActorCast = new ActorCast(skill, this, returnValue); _Updater.Add(_CurrentActorCast); } else { returnValue.SetValue(CastResult.Miss); } return returnValue; }
void ISessionResponse.No() { _Response.SetValue(false); _Response = null; _Binder.Unbind<ISessionResponse>(this); }
internal Remoting.Value<bool> RequestOpenRoom(Remoting.Value<bool> answer) { if (_Response != null) { _Binder.Unbind<ISessionResponse>(this); _Response.SetValue(false); } _Binder.Bind<ISessionResponse>(this); _Response = answer; return _Response; }
void ISessionResponse.Yes() { _Response.SetValue(true); _Response = null; _Binder.Unbind<ISessionResponse>(this); }
private void _UnbindSessionRequester(bool obj) { _Requester = null; }
internal void TeacherBusy() { _Binder.Bind<ISessionRequester>(this); //_Requester.SetValue(false); _Requester = null; }
internal void NoCoin() { _Binder.Bind<ISessionRequester>(this); _Requester.SetValue(false); _Requester = null; }
Remoting.Value<bool> ISessionRequester.Requester(string target, int coin) { var lession = (from l in Lession.Lessions where l.Coin <= coin orderby l.Coin descending select l).FirstOrDefault(); if (_Requester != null) _Requester.SetValue(false); _Requester = new Remoting.Value<bool>(); _Requester.OnValue += _UnbindSessionRequester; _ResuestLession = new RequestLession() { Name = target, Lession = lession.Name, Answer = _Requester }; return _Requester; }