feature/class-wiki-spell-progression (#13)
Reviewed-on: https://gitea.westgate.pw/ShadowsOverWestgate/sow-tools/pulls/13 Co-authored-by: vickydotbat <vickydotbat@tutamail.com> Co-committed-by: vickydotbat <vickydotbat@tutamail.com>
This commit is contained in:
@@ -106,7 +106,7 @@ func loadWikiDataProviders(path string) (map[string]wikiDataProviderDefinition,
|
||||
if def.ItemsPerColumn <= 0 {
|
||||
return nil, fmt.Errorf("wiki data providers %s: provider %s items_per_column must be a positive integer", path, name)
|
||||
}
|
||||
case "class_feats", "class_skills", "class_summary", "race_feats", "race_name_forms":
|
||||
case "class_feats", "class_skills", "class_summary", "class_spellbook", "race_feats", "race_name_forms":
|
||||
if len(def.ClassFeats.Fields) > 0 {
|
||||
return nil, fmt.Errorf("wiki data providers %s: provider %s class feat projections require source class_progression", path, name)
|
||||
}
|
||||
@@ -163,6 +163,11 @@ func (ctx *wikiContext) wikiDataProviderRows(name string, page wikiTemplatePage)
|
||||
return nil, nil
|
||||
}
|
||||
return ctx.classSummaryRows(page.Row), nil
|
||||
case "class_spellbook":
|
||||
if page.Category != "classes" {
|
||||
return nil, nil
|
||||
}
|
||||
return ctx.classSpellbookRows(page.Key, page.Row), nil
|
||||
case "race_feats":
|
||||
if page.Category != "racialtypes" {
|
||||
return nil, nil
|
||||
|
||||
Reference in New Issue
Block a user