public IEnumerable<Category> GetCategories(Habbo habbo) { CategoryHabboEventArgs eventArgs = new CategoryHabboEventArgs(habbo); _pluginInstance.EventFirer.Fire(_pluginInstance.Id + ":habbo_category_request:before", eventArgs); _pluginInstance.EventFirer.Fire(_pluginInstance.Id + ":habbo_category_request:after", eventArgs); return eventArgs.GetCategories(); }
private void LoadHabboCategoriesFromDatabase(CategoryHabboEventArgs eventArgs) { foreach (int categoryId in DatabaseActions.GetCategoryIdsFromHabboId(eventArgs.Habbo.Id)) { eventArgs.AddCategory(GetCategory(categoryId)); } }