public async Task Recent([Remainder] string arg = "") { OsuArg osuDiscordArg = null; try { osuDiscordArg = new OsuArg(arg, false); } catch (CakeException e) { await Context.Channel.SendMessageAsync(e.Message); } catch (Exception e) { _logger.LogException(e); } await _service.GetUserRecent(osuDiscordArg.GetUserId(), osuDiscordArg.UseUsername()); var mapId = GetMapId(); if (mapId != null) { await SaveMapId(Context.Channel.Id, Context.Guild.Id, (int)mapId); } }
public async Task GetCompare([Remainder] string arg = "") { OsuArg osuDiscordArg = null; try { osuDiscordArg = new OsuArg(arg, false); } catch (CakeException e) { await Context.Channel.SendMessageAsync(e.Message); } catch (Exception e) { _logger.LogException(e); } await _service.GetCompare(osuDiscordArg.GetUserId(), osuDiscordArg.UseUsername()); }
public async Task GetUserBest([Remainder] string arg = "") { OsuArg osuDiscordArg = null; try { osuDiscordArg = new OsuArg(arg, true); } catch (CakeException e) { await Context.Channel.SendMessageAsync(e.Message); } catch (Exception e) { _logger.LogException(e); } if (osuDiscordArg != null) { await _service.GetUserBest(osuDiscordArg.GetUserId(), osuDiscordArg.UseUsername(), osuDiscordArg.IsRecent(), osuDiscordArg.GetPlayNumber()); } }