public GameEffectInstance StartInstance(params string[] parameters) { var instance = new GameEffectInstance(Name) { Parameters = new Dictionary <string, string>().Parse(parameters) }; instance.CreationTime = DateTime.Now; return(StartInstance(instance)); }
public GameEffectInstance StartInstance(GameEffectInstance instance) { if (instance.Parameters.ContainsKey("Overwrite")) { throw new NotImplementedException(); } else { GameEffect.AllInstances.Add(instance); } OnStart.Raise(instance); return(instance); }
public GameEffectInstance EndInstance(GameEffectInstance inst) { GameEffect.AllInstances.Remove(inst); OnEnd.Raise(inst); return(inst); }
public GameEffectInstance ChangeInstance(GameEffectInstance instance, Action <GameEffectInstance> changeToMake) { changeToMake?.Invoke(instance); OnChange.Raise(instance); return(instance); }
public GameEffectInstance ChangeInstance(GameEffectInstance instance, params string[] parameters) { instance.Parameters = instance.Parameters.Parse(parameters); OnChange.Raise(instance); return(instance); }
public void AnnounceEnd(GameEffectInstance instance) { OnEnd.Raise(instance); }
public void AnnounceChange(GameEffectInstance instance) { OnChange.Raise(instance); }
public void AnnounceStart(GameEffectInstance instance) { OnStart.Raise(instance); }
public abstract void OnReceiving2(GameEffectInstance instance);