local p = {}
local modmodElements = require( 'Module:Elements' ) ▼
▲ local mod = require( 'Module:Elements' )
▲function p.main( f , categories )
local args = f:getParent().args
local dlc = mw.text.split( args[1], '%s' )
local _i = ''
local _c = ''
local nompage = mw.title.getCurrentTitle()
nompage = nompage.text
page = modmodElements.page( nompage )
if page.existe and not mw.title.namespace then
_c = '[[Catégorie:Modèle dlc mal utilisé|' .. nompage .. ']]'
elseif dlc[1] == 'a+' then
_c_i = '<span title="Afterbirth †-contenu exclusif" style="cursor:help">[[Fichier:Afterbirth†_Indicator.png|lien=]]</span>'
elseif dlc[1] == 'no-a+' then
_c_i = '<span title="Rebirth-contenu exclusif" style="cursor:help">[[Fichier:NoDLC†_Indicator.png|lien=]]</span>'
elseif dlc[1] == 'a-no-a+' then
_c_i = '<span title="Rebirth-contenu exclusif" style="cursor:help">[[Fichier:NoDLC†_Indicator.png|lien=]]</span>[[Catégorie:Modèle dlc mal utilisé|' .. nompage .. ']]'
elseif dlc[1] == 'bp' then
_c_i = '<span title="Booster Pack ' .. dlc[2] .. '-contenu exclusif" style="cursor:help">[[Fichier:Afterbirth†_Booster_Pack_Indicator.png|lien=]]</span>'
else
_c = '[[Catégorie:Dlc inconnu]]'
_c = '[[Catégorie:Modèle dlc mal utilisé|' .. nompage .. ']]'
elseif dlc[1] == 'bp' then
_c_i = '<span title="Booster Pack ' .. dlc[2] .. '-contenu exclusif" style="cursor:help">[[Fichier:Booster_Pack_Indicator.png|lien=]]</span>'
else
_c = '[[Catégorie:Dlc inconnu]]'
else
if dlc[1] == 'a' then
_c_i = '<span title="Afterbirth-contenu exclusif" style="cursor:help">[[Fichier:DLC.png|lien=]]</span>'
elseif dlc[1] == 'no-a' then
_c_i = '<span title="Rebirth-contenu exclusif" style="cursor:help">[[Fichier:NoDLC_Indicator.png|lien=]]</span>'
elseif dlc[1] == 'a+' then
_c_i = '<span title="Afterbirth †-contenu exclusif" style="cursor:help">[[Fichier:Afterbirth†_Indicator.png|lien=]]</span>'
elseif dlc[1] == 'no-a+' then
_c_i = '<span title="Rebirth-contenu exclusif" style="cursor:help">[[Fichier:NoDLC†_Indicator.png|lien=]]</span>'
elseif dlc[1] == 'a-no-a+' then
_c_i = '<span title="Afterbirth-contenu exclusif" style="cursor:help">[[Fichier:DLC.png|lien=]]</span><span title="Afterbirth-contenu exclusif" style="cursor:help">[[Fichier:NoDLC†_Indicator.png|lien=]]</span>'
elseif dlc[1] == 'bp' then
_c_i = '<span title="Booster Pack ' .. dlc[2] .. '-contenu exclusif" style="cursor:help">[[Fichier:Afterbirth†_Booster_Pack_Indicator.png|lien=]]</span>'
else
_c = '[[Catégorie:Dlc inconnu]]'
else
if dlc[1] == 'a' then
_c_i = '<span title="Afterbirth-contenu exclusif" style="cursor:help">[[Fichier:DLC.png|lien=]]</span>'
elseif dlc[1] == 'no-a' then
_c_i = '<span title="Rebirth-contenu exclusif" style="cursor:help">[[Fichier:NoDLC_Indicator.png|lien=]]</span>'
elseif dlc[1] == 'a+' then
_c_i = '<span title="Afterbirth †-contenu exclusif" style="cursor:help">[[Fichier:Afterbirth†_Indicator.png|lien=]]</span>'
elseif dlc[1] == 'no-a+' then
_c_i = '<span title="Rebirth-contenu exclusif" style="cursor:help">[[Fichier:NoDLC†_Indicator.png|lien=]]</span>'
elseif dlc[1] == 'a-no-a+' then
_c_i = '<span title="Afterbirth-contenu exclusif" style="cursor:help">[[Fichier:DLC.png|lien=]]</span><span title="Afterbirth-contenu exclusif" style="cursor:help">[[Fichier:NoDLC†_Indicator.png|lien=]]</span>'
elseif dlc[1] == 'bp' then
_c_i = '<span title="Booster Pack ' .. dlc[2] .. '-contenu exclusif" style="cursor:help">[[Fichier:Afterbirth†_Booster_Pack_Indicator.png|lien=]]</span>'
else
_c = '[[Catégorie:Dlc inconnu]]'
end
if categories then
return _c .. page.autres ▼
return _i .. _c .. page.autres
else
▲ return _c_i .. page.autres
end
end
function p.icon( f )
localif argsf ~= mw.text.split(nil or f, ~= '%s' )then
local args = mw.text.split( f, '%s' )
if args[1] ~= nil or args[1] ~= '' then
if args[1] == 'Afterbirth' then
return '<span title="Afterbirth-contenu exclusif" style="cursor:help">[[Fichier:DLC.png|lien=]]</span>'
|