public void HandleCurrencyAccountList(ICommandContext context) { TextTable tt = GameTableManager.Instance.GetTextTable(context.Language); foreach (AccountCurrencyTypeEntry entry in GameTableManager.Instance.AccountCurrencyType.Entries) { context.SendMessage($"ID {entry.Id}: {tt.GetEntry(entry.LocalizedTextId)}"); } }
public void HandleGenericUnlockList(ICommandContext context) { context.SendMessage("Acquired generic unlock entries:"); TextTable tt = GameTableManager.Instance.GetTextTable(context.Language); foreach (GenericUnlock unlock in context.GetTargetOrInvoker <Player>().Session.GenericUnlockManager) { string name = tt.GetEntry(unlock.Entry.LocalizedTextIdDescription); context.SendMessage($"{unlock.Entry.Id}, {unlock.Type}, {name}"); } }
public async Task ListUnlocksSubCommand(CommandContext context, string command, string[] parameters) { await context.SendMessageAsync("Acquired generic unlock entries:"); TextTable tt = GameTableManager.GetTextTable(context.Language); foreach (GenericUnlock unlock in context.Session.GenericUnlockManager) { string name = tt.GetEntry(unlock.Entry.LocalizedTextIdDescription); await context.SendMessageAsync($"{unlock.Entry.Id}, {unlock.Type}, {name}"); } }
public void HandleHouseDecorLookup(ICommandContext context, [Parameter("Name or partial name of the housing decor item to search for.")] string name) { var sw = new StringBuilder(); sw.AppendLine("Decor Lookup Results:"); TextTable tt = GameTableManager.Instance.GetTextTable(context.Language); foreach (HousingDecorInfoEntry decorEntry in SearchManager.Instance.Search <HousingDecorInfoEntry>(name, context.Language, e => e.LocalizedTextIdName, true)) { string text = tt.GetEntry(decorEntry.LocalizedTextIdName); sw.AppendLine($"({decorEntry.Id}) {text}"); } context.SendMessage(sw.ToString()); }
public Task DecorLookupSubCommandHandler(CommandContext context, string command, string[] parameters) { if (parameters.Length != 1) { return(Task.CompletedTask); } var sw = new StringWriter(); sw.WriteLine("Decor Lookup Results:"); TextTable tt = GameTableManager.Instance.GetTextTable(context.Language); foreach (HousingDecorInfoEntry decorEntry in SearchManager.Instance.Search <HousingDecorInfoEntry>(parameters[0], context.Language, e => e.LocalizedTextIdName, true)) { string text = tt.GetEntry(decorEntry.LocalizedTextIdName); sw.WriteLine($"({decorEntry.Id}) {text}"); } context.SendMessageAsync(sw.ToString()); return(Task.CompletedTask); }