FANDOM


local p = {}
local qrefExtRefs = {
    ["BOG"] = "<i>[[Berserk Official Guidebook]]</i>",
    ["SKQA2"] = "Walter Bennet (sender), Puella (translator). \"[http://www.skullknight.net/forum/index.php?topic=9513.msg166308#msg166308 Writing Miura]\". ''\"<nowiki>'Falcon' or 'Hawk', both mean [鷹] in Japanese. In some dictionaries, 'Falcon' is translated as [隼(はやぶさ)], but there's almost no difference. I used 'Falcon' from the great name of the 'Millennium Falcon' ship in Star Wars.</nowiki>\"'' SkullKnight.net.",
    ["SKQA9"] = "Walter Bennet (sender), Puella (translator). \"[http://www.skullknight.net/forum/index.php?topic=9513.msg166308#msg166308 Writing Miura]\". ''\"<nowiki>It\'s because I wanted Berserk\'s world to be revealed just that far, not any more than that. The appearance of god in the manga conclusively determines its range. I thought that might limit the freedom of the story development. I myself don't know if the Idea of Evil will show up again in the manga or not.</nowiki>\"'' SkullKnight.net.",
    ["SKDH"] = "Auturgist (creative consusltant to translator Duane Johnson).<br />\"[http://www.skullknight.net/forum/index.php?topic=6651.0 I'm a guy that works on Dark Horse's translations]\". ''\"<nowiki>So sometimes we\'ll work in some subtle reference to other awesome things.  For instance, when Guts first gets his iron arm, we had him saying, 'Groovy!'</nowiki>\"'' SkullKnight.net.",
}
local qrefErrorText = '<strong class="error"><span class="scribunto-error" id="mw-scribunto-error-0">Qref not found</span></strong>'
 
function p.qref(frame)
	local qrefArgKey = frame.args[1]
	local qrefKey = qrefArgKey:match('e([0-9A-P]*)') or qrefArgKey
	local qrefText 
 
	-- If qrefKey is an episode key
	if tonumber(qrefKey) or qrefKey:match('0[A-P]') then
	    local episodesManga = mw.loadData( 'Module:Episodes/mangaData' )
	    local episode = episodesManga[qrefKey]
	    qrefText = '<i>[[Berserk (Manga)|Berserk]]</i>, Volume ' .. episode['volume'] .. ', "[[Episode ' .. qrefKey .. ' (Manga)|' .. episode['ename'] .. ']]"'
	end
 
	return qrefText or qrefExtRefs[qrefKey] or qrefErrorMsg
end
 
return p
 
-- [[Category:Lua Modules]]
Community content is available under CC-BY-SA unless otherwise noted.