Actions

Module

Difference between revisions of "Infobox NPC"

From ThornsWiki

(Created page with "local p = {} function p.default(frame) local capiunto = require 'capiunto' return capiunto.create( { top = tostring(mw.title.getCurrentTitle()), topStyle = 'background...")
 
 
(7 intermediate revisions by the same user not shown)
Line 5: Line 5:
 
return capiunto.create( {
 
return capiunto.create( {
 
top = tostring(mw.title.getCurrentTitle()),
 
top = tostring(mw.title.getCurrentTitle()),
topStyle = 'background:#937c54;color:#FFF;font-family:Metamorphous, serif;line-height:1.25em;',
+
topStyle = 'background:#5f5543;color:#FFF;font-family:Metamorphous, serif;line-height:1.25em;',
 
} )
 
} )
 
:addImage(
 
:addImage(
Line 11: Line 11:
 
frame.args["caption"] -- caption
 
frame.args["caption"] -- caption
 
)
 
)
 +
:addHeader('Play Status')
 +
:addRow('NPC Status', frame.args["status"])
 
:addHeader('Biographic Information')
 
:addHeader('Biographic Information')
 
:addRow('Age', frame.args["age"])
 
:addRow('Age', frame.args["age"])
 
:addRow('Birthday', frame.args["birthday"])
 
:addRow('Birthday', frame.args["birthday"])
:addRow('Born in', frame.args["born_in"])
+
:addRow('Place of Birth', frame.args["born_in"])
:addRow('Currently in', frame.args["currently_in"])
+
:addRow('Current Location', frame.args["currently_in"])
 
:addHeader('Physical Information')
 
:addHeader('Physical Information')
:addRow('Racee', frame.args["race"])
+
:addRow('Race', frame.args["race"])
 
:addRow('Gender', frame.args["gender"])
 
:addRow('Gender', frame.args["gender"])
 
:addRow('Height', frame.args["height"])
 
:addRow('Height', frame.args["height"])
 
:addRow('Hair Color', frame.args["hair_color"])
 
:addRow('Hair Color', frame.args["hair_color"])
 
:addRow('Eye Color', frame.args["eye_color"])
 
:addRow('Eye Color', frame.args["eye_color"])
:addRow('Distinguishing Marks', frame.args["marks"])
+
:addRow('Face Claim', frame.args["fc"])
 
:addHeader('Relationships')
 
:addHeader('Relationships')
 
:addRow('Family', frame.args["family"])
 
:addRow('Family', frame.args["family"])
:addRow('Other'), frame.args["other"]
 
 
:addHeader('Occupation')
 
:addHeader('Occupation')
 
:addRow('Job Title', frame.args["title"])
 
:addRow('Job Title', frame.args["title"])

Latest revision as of 00:34, 1 January 2019

Documentation for this module may be created at Module:Infobox NPC/doc

local p = {}
 
function p.default(frame)
	local capiunto = require 'capiunto'
	return capiunto.create( {
		top = tostring(mw.title.getCurrentTitle()),
		topStyle = 'background:#5f5543;color:#FFF;font-family:Metamorphous, serif;line-height:1.25em;',
	} )
	:addImage(
		string.format('[[File:%s|250px]]', frame.args["image"]), -- featured image
		frame.args["caption"] -- caption
	)
	:addHeader('Play Status')
	:addRow('NPC Status', frame.args["status"])
	:addHeader('Biographic Information')
	:addRow('Age', frame.args["age"])
	:addRow('Birthday', frame.args["birthday"])
	:addRow('Place of Birth', frame.args["born_in"])
	:addRow('Current Location', frame.args["currently_in"])
	:addHeader('Physical Information')
	:addRow('Race', frame.args["race"])
	:addRow('Gender', frame.args["gender"])
	:addRow('Height', frame.args["height"])
	:addRow('Hair Color', frame.args["hair_color"])
	:addRow('Eye Color', frame.args["eye_color"])
	:addRow('Face Claim', frame.args["fc"])
	:addHeader('Relationships')
	:addRow('Family', frame.args["family"])
	:addHeader('Occupation')
	:addRow('Job Title', frame.args["title"])
end

return p