/// <summary> /// Constructs a Riot Client with given implemented service for each Riot service group. /// </summary> /// <param name="champion">The champion.</param> /// <param name="currentGame">The current game.</param> /// <param name="featuredGames">The featured games.</param> /// <param name="game">The game.</param> /// <param name="league">The league.</param> /// <param name="lolStaticData">The lol static data.</param> /// <param name="lolStatus">The lol status.</param> /// <param name="match">The match.</param> /// <param name="matchHistory">The match history.</param> /// <param name="matchList">The match list.</param> /// <param name="stats">The stats.</param> /// <param name="summoner">The summoner.</param> /// <param name="team">The team.</param> public RiotClient(IChampion champion, ICurrentGame currentGame, IFeaturedGames featuredGames, IGame game, ILeague league, ILolStaticData lolStaticData, ILolStatus lolStatus, IMatch match, IMatchHistory matchHistory, IMatchList matchList, IStats stats, ISummoner summoner, ITeam team) { this.Champion = champion; this.CurrentGame = currentGame; this.FeaturedGames = featuredGames; this.Game = game; this.League = league; this.LolStaticData = lolStaticData; this.LolStatus = lolStatus; this.Match = match; this.MatchHistory = matchHistory; this.MatchList = matchList; this.Stats = stats; this.Summoner = summoner; this.Team = team; }
/// <summary> /// Constructs a Riot Client with given implemented service for each Riot service group. /// </summary> /// <param name="champion">The champion.</param> /// <param name="currentGame">The current game.</param> /// <param name="featuredGames">The featured games.</param> /// <param name="game">The game.</param> /// <param name="league">The league.</param> /// <param name="lolStaticData">The lol static data.</param> /// <param name="lolStatus">The lol status.</param> /// <param name="match">The match.</param> /// <param name="matchHistory">The match history.</param> /// <param name="matchList">The match list.</param> /// <param name="stats">The stats.</param> /// <param name="summoner">The summoner.</param> /// <param name="team">The team.</param> public RiotClient(IChampion champion, ICurrentGame currentGame, IFeaturedGames featuredGames, IGame game, ILeague league, ILolStaticData lolStaticData, ILolStatus lolStatus, IMatch match, IMatchHistory matchHistory, IMatchList matchList, IStats stats, ISummoner summoner, ITeam team) { //we need to let Ninject know which concrete type to use to satisfy the interface. this.Champion = champion; this.CurrentGame = currentGame; this.FeaturedGames = featuredGames; this.Game = game; this.League = league; this.LolStaticData = lolStaticData; this.LolStatus = lolStatus; this.Match = match; this.MatchHistory = matchHistory; this.MatchList = matchList; this.Stats = stats; this.Summoner = summoner; this.Team = team; }
public static async Task <string> GetProfileIconUrlAsync( this ISummoner summoner, RegionEnum?region = null, string dataDragonVersion = null) { if (summoner == null) { throw new ArgumentNullException("summoner"); } var staticService = new StaticService(summoner.ApiConfiguration); return(await GetImageUrlAsync( "profileicon", string.Format("{0}.png", summoner.ProfileIconId), staticService, region, dataDragonVersion)); }
/// <summary> /// May be executed from outside of this Character's map's context /// </summary> /// <param name="summoner"></param> /// <param name="timeoutSeconds"></param> public void StartSummon(ISummoner summoner, int timeoutSeconds) { m_summonRequest = new SummonRequest { ExpiryTime = DateTime.Now.AddSeconds(timeoutSeconds), TargetPos = summoner.Position, TargetZone = summoner.Zone, TargetMap = summoner.Map }; // make sure the Map was set or else the summoner was disposed before the Request completed if (m_summonRequest.TargetMap != null) { var client = m_client; if (client != null) { CharacterHandler.SendSummonRequest(client, summoner, summoner.Zone != null ? summoner.ZoneTemplate.Id : ZoneId.None, timeoutSeconds * 1000); } } else { //log.Warn("Tried to teleport {0} to a Summoner without a Map: {1}", this, summoner); } }
/// <summary> /// May be executed from outside of this Character's map's context /// </summary> public void StartSummon(ISummoner summoner) { StartSummon(summoner, SummonRequest.DefaultTimeout); }
/// <summary> /// </summary> /// <param name="owner"> /// </param> public Pet(ISummoner owner) { this.owner = owner; }
/// <summary> /// Constructs a Riot Client with given implemented service for each Riot service group. /// </summary> /// <param name="champion">The champion.</param> /// <param name="currentGame">The current game.</param> /// <param name="featuredGames">The featured games.</param> /// <param name="game">The game.</param> /// <param name="league">The league.</param> /// <param name="lolStaticData">The lol static data.</param> /// <param name="lolStatus">The lol status.</param> /// <param name="match">The match.</param> /// <param name="matchHistory">The match history.</param> /// <param name="matchList">The match list.</param> /// <param name="stats">The stats.</param> /// <param name="summoner">The summoner.</param> /// <param name="team">The team.</param> /// <param name="championMastery">Champion Masteries</param> public RiotClient(IChampion champion, ICurrentGame currentGame, IFeaturedGames featuredGames, IGame game, ILeague league, ILolStaticData lolStaticData, ILolStatus lolStatus, IMatch match, IMatchList matchList, IStats stats, ISummoner summoner, ITeam team, IChampionMastery championMastery) { this.Champion = champion; this.CurrentGame = currentGame; this.FeaturedGames = featuredGames; this.Game = game; this.League = league; this.LolStaticData = lolStaticData; this.LolStatus = lolStatus; this.Match = match; this.MatchList = matchList; this.Stats = stats; this.Summoner = summoner; this.Team = team; this.ChampionMastery = championMastery; }