FANDOM


local Box = {}
local Navbox = require('Module:Navbox')
local HF = require('Module:HF')
local L = require('Module:List')
 
local data = mw.loadData( 'Module:HF/data' )
local Episodes = data.Episodes
local MainCharacters = data.MainCharacters
local Cast = data.Cast
 
function Box.character( frame )
    local outer = { 
        name = 'Template:Navbox/Character',
        title = '[[:Category:Characters|Characters]]',
        state = 'expanded',
        listclass = 'hlist hwrap',
        bodyclass = 'navbox-footer',
        evenodd = 'off',
        image = '[[File:Stock person bw.png|100px|link=]]',
        navbar = 'off',
        group1 = '[[Murder House (story)|Murder House]]',
        group2 = '[[Asylum (story)|Asylum]]',
        -- group3 = '[[Coven (story)|Coven]]',
        -- group4 = '[[Freak Show (story)|Freak Show]]',
    --    group5 = '[[Hotel (story)|Hotel]]'
    }
    local inner_S1 = {
         border = 'subgroup',
         navbar = 'off',
         evenodd = 'off',
         group1 = '[[:Category:Murder House (story)/Characters|Residents]]',
         group2 = 'Recurring',
         list1 = L.makeList( 'horizontal' , HF.explode( ';', MainCharacters['Murder House Residents'] ) ),
         list2 = frame.args['S1_Recurring'] or 'Recurring'
    }
    local inner_S2 = {
        border = 'subgroup',
        navbar = 'off',
        evenodd = 'off',
        group1 = '[[:Category:Briarcliff Staff|Staff]]',
        group2 = '[[:Category:Briarcliff Inmates|Inmates]]',
        group3 = 'Recurring',
        list1  = L.makeList( 'horizontal' , HF.explode( ';', MainCharacters['Briarcliff Staff'] ) ),
        list2  = L.makeList( 'horizontal' , HF.explode( ';', MainCharacters['Briarcliff Inmates'] ) ),
        list3  = frame.args['S2_Recurring'] or 'Recurring'
    }
    local inner_S3 = {
         border = 'subgroup',
         navbar = 'off',
         evenodd = 'off',
         group1 = '[[:Category:Coven (story)/Characters|Main]]',
         group2 = 'Recurring',
         list1 = L.makeList( 'horizontal' , HF.explode( ';', MainCharacters['Coven'] ) ),
         list2 = frame.args['S3_Recurring'] or 'Recurring'
    }
    local inner_S4 = {
         border = 'subgroup',
         navbar = 'off',
         evenodd = 'off',
         group1 = '[[:Category:Freak Show (story)/Characters|Main]]',
         group2 = 'Recurring',
         list1 = L.makeList( 'horizontal' , HF.explode( ';', MainCharacters['Freak Show'] ) ),
         list2 = frame.args['S4_Recurring'] or 'Recurring'
    }
    local inner_S5 = {
         border = 'subgroup',
         navbar = 'off',
         evenodd = 'off',
         group1 = '[[:Category:Hotel (story)/Characters|Main]]',
         group2 = 'Recurring',
         list1 = L.makeList( 'horizontal' , HF.explode( ';', MainCharacters['Hotel'] ) ),
         list2 = frame.args['S5_Recurring'] or 'Recurring'
    }
    local inner_S6A = {
         border = 'subgroup',
         navbar = 'off',
         evenodd = 'off',
         group1 = '[[:Category:Roanoke (story)/Characters|Main]]',
         group2 = 'Recurring',
         list1 = L.makeList( 'horizontal' , HF.explode( ';', MainCharacters['Hotel'] ) ),
         list2 = frame.args['S6A_Recurring'] or 'Recurring'
    }
    outer.list1 = Navbox._navbox( inner_S1 )
    outer.list2 = Navbox._navbox( inner_S2 )
    -- outer.list3 = Navbox._navbox( inner_S3 )
    -- outer.list4 = Navbox._navbox( inner_S4 )
    -- outer.list5 = Navbox._navbox( inner_S5 )
    return Navbox._navbox(outer)
 
end
 
function Box.episode( frame )
    local outer = { 
        name = "Template:Navbox/Episode", 
        title = "[[:Category:Episodes|Episodes]]", 
        state = "expanded", 
        navbar = 'off',
        image = "[[File:Television.svg|100x100px|link=]]", 
        listclass = "hlist mhlist hwrap", 
        evenodd = "off", 
        group1 = "[[:Category:Murder House (story)|Murder House]]", 
        group2 = "[[:Category:Asylum (story)|Asylum]]", 
        group3 = "[[:Category:Coven (story)|Coven]]", 
        group4 = "[[:Category:Freak Show (story)|Freak Show]]", 
        group5 = "[[:Category:Hotel (story)|Hotel]]", 
        group6 = "[[:Category:Roanoke (story)|Roanoke]]", 
        navbar = "plain",
        list1 = L.makeList( "horizontal" , HF.explode( ";", Episodes['Murder House'] ) ),
        list2 = L.makeList( "horizontal" , HF.explode( ";", Episodes['Asylum'] ) ),
        list3 = L.makeList( "horizontal" , HF.explode( ";", Episodes['Coven'] ) ),
        list4 = L.makeList( "horizontal" , HF.explode( ";", Episodes['Freak Show'] ) ),
        list5 = L.makeList( "horizontal" , HF.explode( ";", Episodes['Hotel'] ) ),
        list6 = L.makeList( "horizontal" , HF.explode( ";", Episodes['Roanoke'] ) )
    }
    return Navbox._navbox(outer)
end
 
function Box.cast( frame )
    local outer = { 
        name = "Template:Navbox/Cast", 
        title = "[[:Category:Cast|Cast]]", 
        state = "expanded", 
        image = "[[File:P culture.svg|100px|link=]]", 
        listclass = "hlist mhlist hwrap", 
        evenodd = "off", 
        group1 = "[[:Category:Murder House (story)|Murder House]]", 
        group2 = "[[:Category:Asylum (story)|Asylum]]", 
        group3 = "[[:Category:Coven (story)|Coven]]", 
        group4 = "[[:Category:Freak Show (story)|Freak Show]]", 
        group5 = "[[:Category:Hotel (story)|Hotel]]", 
        group6 = "[[:Category:Roanoke (story)|Roanoke]]", 
        navbar = "off",
        list1 = L.makeList( "horizontal" , HF.explode( ";", Cast['Murder House'] ) ),
        list2 = L.makeList( "horizontal" , HF.explode( ";", Cast['Asylum'] ) ),
        list3 = L.makeList( "horizontal" , HF.explode( ";", Cast['Coven'] ) ),
        list4 = L.makeList( "horizontal" , HF.explode( ";", Cast['Freak Show'] ) ),
        list5 = L.makeList( "horizontal" , HF.explode( ";", Cast['Hotel'] ) ),
        list6 = L.makeList( "horizontal" , HF.explode( ";", Cast['Roanoke'] ) )
    }
    return Navbox._navbox(outer)
end
return Box

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.