Module:Infobox/Personnage

De Les Archives de Vault-Tec
Documentation du module

Ce module contient le paramétrage de l'infobox {{Infobox personnage}}.

Documentation transclues de Module:Infobox/Personnage/doc.
local localdata = require('Module:Infobox/Localdata')

function buildSkills(localdata)
	local skills = nil
	
	if localdata['compétences'] then
		skills = ''
		if localdata['classe'] then
			skills = localdata['classe'].." :<br/>"
		end
		skills = skills..localdata['compétences']
	end
	
	return skills
end

return {
	parts = {
		{ type = 'title', value = 'nom', subtitle = 'sous-titre', icon = 'icône', subhead = { games = 'jeux', subject = 'Personnage', link = 'Personnages' }},
		{ type = 'images', imageparameters = { 'image', 'image2', 'image3', 'image4', 'image5' }, captionparameter = { 'légende', 'image desc' }},
		{ type = 'table', title = 'Apparence', collapseparameters = { collapsible = true, collapsed = true }, rows = {
			{ type = 'row', label = 'Espèce', value = { 'race', 'espèce' }},
			{ type = 'row', label = 'Genre', value = 'genre' },
			{ type = 'row', label = 'Taille', value = 'taille' },
			{ type = 'row', label = 'Style de cheveux', value = 'style cheveux' },
			{ type = 'row', label = 'Couleur de cheveux', value = 'couleur cheveux' },
			{ type = 'row', label = 'Couleur des yeux', value = 'couleur yeux' },
			{ type = 'row', label = 'Pilosité', value = 'pilosité' }
		}},
		{ type = 'table', title = 'Biographie', collapseparameters = { collapsible = true }, rows = {
			{ type = 'row', label = 'Âge', value = 'âge' },
			{ type = 'row', label = 'Naissance', value = 'naissance' },
			{ type = 'row', label = 'Mort', value = { 'mort', 'décès', 'deces' }},
			{ type = 'row', label = 'Surnom', value = { 'surnom', 'alias' }},
			{ type = 'row', label = 'Localisation', value = 'localisation' },
			{ type = 'row', label = 'Affiliation', value = 'affiliation' },
			{ type = 'row', label = 'Rôle', value = 'rôle' },
			{ type = 'row', label = 'Rang', value = 'rang' },
			{ type = 'row', label = 'Famille', value = 'famille' }
		}},
		{ type = 'table', title = 'Apparitions', rows = {
			{ type = 'row', label = 'Mentions', value = function(localdata) return require('Module:Abréviation').links({ localdata['mentions'], sep = '<br/>' }) end },
			{ type = 'row', label = 'Quêtes', value = 'quêtes' },
			{ type = 'row', label = 'Missions', value = 'missions' }
		}},
		{ type = 'table', title = 'Statistiques', collapseparameters = { collapsible = true, collapsed = true }, rows = {
			{ type = 'row', label = 'Alignement', value = 'alignement' },
			{ type = 'row', label = '[[SPECIAL]]', value = 'special' },
			{ type = 'row', label = '[[Statistiques dérivées]]', value = 'dérivées' },
			{ type = 'row', label = 'Compétences', value = function(localdata) return buildSkills(localdata) end },
			{ type = 'row', label = 'Traits', value = 'traits' },
			{ type = 'row', label = 'Aptitudes', value = 'aptitudes' },
			{ type = 'row', label = 'Niveau', value = 'niveau' }
		}},
		{ type = 'table', title = 'Technique', collapseparameters = { collapsible = true, collapsed = true }, rows = {
			{ type = 'row', label = 'Style de combat', value = 'style combat' },
			{ type = 'row', label = '[[Agressivité]]', value = 'agressivité' },
			{ type = 'row', label = '[[Assurance]]', value = { 'assurance', 'confiance' }},
			{ type = 'row', label = '[[Assistance]]', value = 'assistance' },
			{ type = 'row', label = 'GECK factions', value = 'geck factions' },
			{ type = 'row', label = 'GECK race', value = 'geck race' },
			{ type = 'row', label = 'Editor ID', value = 'editorid' },
			{ type = 'row', label = '[[Form ID|Form ID]]', value = { 'formid', 'baseid' }},
			{ type = 'row', label = '[[Form ID|Ref ID]]', value = 'refid' },
			{ type = 'row', label = 'Proto ID', value = 'proto' },
			{ type = 'row', label = 'Fichier dialogue', value = 'dialogue' },
			{ type = 'row', label = 'Acteur', value = 'acteur' },
			{ type = 'row', label = 'Acteur anglais', value = 'acteur vo' },
			{ type = 'row', label = 'Acteur français', value = { 'doubleur', 'acteur vf' }},
			{ type = 'row', label = 'Concepteur', value = { 'designer', 'concepteur' }}
		}},
		{ type = 'text', value = 'pied' }
	}
}