FANDOM


local p = {}
 
local iconTip = {
    -- Plateformes
    ["android"]              = "SE Android|plateforme",
    ["windowsphone"]         = "Windows Phone|plateforme",
    ["apple"]                = "Apple iOS|plateforme",
    ["switch"]               = "Nintendo Switch|plateforme",
    ["pc"]                   = "PC|plateforme",
    ["mac"]                  = "Macintosh Classic ou Mac OS X|plateforme",
    ["macclassic"]           = "Macintosh Classic (≤ MacOS 9)|plateforme",
    ["xbox360"]              = "Xbox 360|plateforme",
    ["xboxone"]              = "Xbox One|plateforme",
    ["ps3"]                  = "PlayStation 3|plateforme",
    ["ps4"]                  = "PlayStation 4|plateforme",
 
    -- Publications
    ["AR"]                   = "All Roads",
    ["FB"]                   = "Fallout Bible",
    ["OMACP"]                = "One Man, and a Crate of Puppets",
 
    -- Jeux distribués
    ["FO1"]                  = "Fallout",
    ["FO2"]                  = "Fallout 2",
    ["FO3"]                  = "Fallout 3",
    ["FO3BS"]                = "Broken Steel (extension)",
    ["FO3MZ"]                = "Mothership Zeta (extension)",
    ["FO3OA"]                = "Operation: Anchorage (extension)",
    ["FO3PL"]                = "Point Lookout (extension)",
    ["FO3TP"]                = "The Pitt (extension)",
    ["FNV"]                  = "Fallout: New Vegas",
    ["FNVCS"]                = "Courier Stash (extension)",
    ["FNVDM"]                = "Dead Money (extension)",
    ["FNVGRA"]               = "Arsenal des Gun Runners (extension)",
    ["FNVHH"]                = "Honest Hearts (extension)",
    ["FNVLR"]                = "Lonesome Road (extension)",
    ["FNVOWB"]               = "Old World Blues (extension)",
    ["FO4"]                  = "Fallout 4",
    ["FO4AUT"]               = "Automatron (extension)",
    ["FO4CC"]                = "Creation Club",
    ["FO4CW"]                = "Contraptions Workshop",
    ["FO4FH"]                = "Far Harbor (extension)",
    ["FO4NW"]                = "Nuka-World (extension)",
    ["FO4VR"]                = "Fallout 4 VR",
    ["FO4VW"]                = "Vault-Tec Workshop",
    ["FO4WW"]                = "Wasteland Workshop",
    ["FO76"]                 = "Fallout 76",
    ["FO76WA"]               = "Wild Appalachia (extension)",  
    ["FO76NW"]               = "Nuclear Winter (extension)",
    ["FO76WL"]               = "Wastelanders (extension)",
    ["FO76LR"]               = "The Legendary Run",
    ["FO76OW"]               = "One Wasteland For All",
    ["FO76FS"]               = "Fractured Steel",
    ["FOBOS"]                = "Fallout: Brotherhood of Steel",
    ["FOBOS2"]               = "Fallout: Brotherhood of Steel 2",
    ["FOS"]                  = "Fallout Shelter",
    ["FOT"]                  = "Fallout Tactics",
    ["FOT2"]                 = "Fallout Tactics 2",
 
    -- Jeux annulés
    ["VB"]                   = "Van Buren",
    ["TORN"]                 = "Jeu TORN",
    ["PV13"]                 = "Projet V13",
    ["TAR"]                  = "Projet V13",
    ["FOX"]                  = "Fallout Extreme",
 
    -- Autres projets
    ["JES"]                  = "Jeu de Rôle Fallout de J.E. Sawyer",
    ["LH"]                   = "Lionheart",
    ["FOD20"]                = "Fallout Pen and Paper d20",
    ["FILM"]                 = "Fallout (Le Film)",
    ["FJP"]                  = "Fallout: Le Jeu de Plateau",
    ["FJPNC"]                = "Fallout: New California (extension)",
    ["FWW "]                 = "Fallout: Wasteland Warfare",
    ["FWWRPG"]               = "Fallout: Wasteland Warfare Roleplaying Game",
 
    -- Réseaux sociaux
    ["facebook"]             = "Facebook",
    ["instagram"]            = "Instagram",
    ["linkedin"]             = "Linkedin",
    ["myspace"]              = "Myspace",
    ["tumblr"]               = "Tumblr",
    ["twitch"]               = "Twitch",
    ["twitter"]              = "Twitter",
 
    -- Réactions
    ["adore"]                = "Adore",
    ["aime"]                 = "Apprécie",
    ["aimepas"]              = "N'apprécie pas",
    ["déteste"]              = "Déteste",
    ["indifférent"]          = "Indifférent",
 
    -- Artisanat
    ["atelier"]              = "Atelier",
    ["atarmes"]              = "Atelier d'armes",
    ["atarmures"]            = "Atelier d'armures",
    ["atrobot"]              = "Atelier de robotique",
    ["fabrication"]          = "Fabrication",
    ["poscuis"]              = "Poste de cuisine",
    ["stchim"]               = "Station de chimie",
    ["starmass"]             = "Station d'armure assistée",
    ["nukamix"]              = "Station de Nuka Mixer",
    ["prnour"]               = "Processeur de nourriture",
    ["fabrexpl"]             = "Fabrique d'explosifs",
    ["brico"]                = "Bricolage",
 
    -- Gameplay
    ["niveau"]               = "Niveau",
    ["pa"]                   = "Points d'Action",
    ["px"]                   = "Points d'Expérience",
    ["pv"]                   = "Points de vie",
    ["dégâts"]               = "Dégâts",
    ["dgtcrit"]              = "Dégâts critiques",
    ["effetcrit"]            = "Effet critique",
    ["effetbonus"]           = "Effet bonus",
    ["dpa"]                  = "Dégâts par Point d'Action",
    ["saignement"]           = "Saignement",
    ["poids"]                = "Poids",
    ["munitions"]            = "Munitions",
    ["soins"]                = "Régénération de santé",
    ["dispersion"]           = "Dispersion",
    ["dps"]                  = "Dégâts par seconde",       
    ["effet"]                = "Effet",
    ["radiations"]           = "Radiations",
    ["atome"]                = "Atome",
    ["distance"]             = "Distance",
    ["détection|vision"]     = "Détection",
    ["capachargeur"]         = "Capacité du chargeur",
    ["portée"]               = "Portée",
    ["rareté"]               = "Rareté",
    ["ratio"]                = "Ratio",
    ["poison"]               = "Poison",
    ["froid"]                = "Froid",
    ["acide"]                = "Acide",
    ["attaque"]              = "Attaque",
    ["chance"]               = "Chances",
    ["ca"]                   = "Classe d'armure",
    ["rd"]                   = "Résistance aux dégâts",
    ["sd"]                   = "Seuil de dégâts",
    ["capacité"]             = "Capacité",
    ["explosion"]            = "Explosion",
    ["feu"]                  = "Feu",
    ["poing"]                = "Poing",
    ["gaz"]                  = "Gaz",
    ["défense"]              = "Défense",
 
    -- Type d'arme
    ["arme"]                 = "Arme à feu",
    ["armelourde"]           = "Armes lourdes, attaque directe",
    ["armelourdeaoe"]        = "Armes lourdes, zone d'effet",
    ["lame"]                 = "Arme de mêlée tranchante",
    ["contondante"]          = "Arme de mêlée contondante",
    ["sansarmes"]            = "Sans armes",
    ["cac"]                  = "Corps à corps",
    ["fusil"]                = "Fusil",
    ["pompe"]                = "Fusil à pompe",
    ["pm"]                   = "Pistolet-mitrailleur",
    ["laser"]                = "Laser",
    ["plasma"]               = "Plasma",
    ["électrique"]           = "Électrique",
    ["énergie"]              = "Énergie",
    ["grenade"]              = "Grenade",
    ["mine"]                 = "Mine",
    ["iem"]                  = "IEM",
 
    -- Personnages
    ["boss"]                 = "Personnage Haut Niveau",
    ["caravan"]              = "Joue au Caravan",
    ["cartes"]               = "Cartes",
    ["compagnon"]            = "Compagnon",
    ["confiance"]            = "Confiance",
    ["docteur"]              = "Docteur",
    ["marchand"]             = "Marchand",
    ["groupe"]               = "Groupe",
    ["FNVww"]                = "Wild Wasteland",
 
    -- Objets
    ["mod"]                  = "Avec mods",
    ["FO4chaine01"]          = "Porte-clés quatre",
    ["FO4chaine02"]          = "Porte-clés cinq",                
    ["FO4clégen"]            = "Clé générique",
    ["FO4holo"]              = "Holobande",
    ["FO4clé01"]             = "Clé Quantum",
    ["FO4clé02"]             = "Clé du jouet fusée",
    ["FO4clé03"]             = "Clé Vault Boy",
    ["FO4note"]              = "Note",
    ["FO4abriID"]            = "Carte d'identification d'Abri",
    ["jeupb"]                = "Jeu Pip-Boy",
    ["gold bullion"]         = "Gold Bullion",
 
    -- Conditions
    ["requis"]               = "Requis",
    ["semirequis"]           = "Parfois requis ou requis au moins une fois",
    ["optionnel"]            = "Optionnel",
 
    -- État
    ["mort"]                 = "Décédé",
    ["temporaire"]           = "Temporaire",
    ["oui"]                  = "Validé",
    ["ouitemp"]              = "Validé temporairement",
    ["non"]                  = "Non",
    ["vert"]                 = "Fait fiable",
    ["ambre"]                = "Fait non corroboré",
    ["rouge"]                = "Fait peu fiable ou incorrect",
    ["question"]             = "Point d'interrogation",
    ["mentionné"]            = "Mentionné",
    ["répétable"]            = "Répétable",
    ["réparable"]            = "Réparable",
    ["neutre"]               = "Neutre",
    ["essentiel"]            = "Essentiel",
    ["asservissable"]        = "Peut être assujetti",
 
    -- Intra Wiki
    ["WIKI"]                 = "L'Abri",
    ["son"]                  = "Son",
    ["apparition"]           = "Apparition",
    ["texte"]                = "Texte",
    ["séquence"]             = "Séquence",
    ["sic"]                  = "Épellation, ponctuation et/ou grammaire dans le jeu",
    ["coupé"]                = "Contenu coupé",
    ["haché"]                = "Haché",
    ["dial"]                 = "Dialogue",
    ["image"]                = "Image",
    ["infos"]                = "Informations",
 
    -- Succès
    ["gamerscore"]           = "Gamerscore",
    ["tropheebronze"]        = "Trophée Bronze",
    ["tropheeargent"]        = "Trophée Argent",
    ["tropheeor"]            = "Trophée Or",
    ["tropheeplatine"]       = "Trophée Platine",
 
    ["jury"]                 = "Jury Rigging",
    ["temporaire"]           = "Icon limitedtime.png",
 
}
 
local gameIcon = {
    ["capacité"]        = "Icon ability.png",
    ["bronzeca"]        = "Icon shield bronze.png",
    ["acide"]           = "Icon acid.png",
    ["pa"]              = "Icon action.png",
    ["ambre"]           = "Icon amber.png",
    ["munitions"]       = "icon ammo.png",
    ["android"]         = "icon android.png",
    ["apple"]           = "icon appleios.png",
    ["AR"]              = "gametitle-AR.png",
    ["atarmures"]       = "Fo4_Armor_Work_Icon.png",
    ["atome"]           = "Icon Fo76 Atom.png",
    ["attaque"]         = "Icon attack.png",
    ["armelourde"]      = "Icon heavy weapon.png",
    ["armelourdeaoe"]   = "Icon big gun.png",
    ["lame"]            = "Icon blade.png",
    ["saignement"]      = "Icon bleed.png",
    ["contondante"]     = "Icon blunt.png",
    ["effetbonus"]      = "Icon bonus effect.png",
    ["boss"]            = "FoS Boss.png",
    ["tropheebronze"]   = "Bronze.png",
    ["caravan"]         = "Icon cards.png",
    ["cartes"]          = "Icon cards.png",
    ["chance"]          = "Icon chance.png",
    ["oui"]             = "Icon check.png",
    ["ouitemp"]         = "Icon check temp.png",
    ["stchim"]          = "Fo4_Chem_Work_Icon.png",
    ["compagnon"]       = "Icon companion.png",
    ["confiance"]       = "Icon confidence.png",
    ["poscuis"]         = "Fo4_Cook_Work_Icon.png",
    ["fabrication"]     = "Icon crafting.png",
    ["effetcrit"]       = "Icon crit effect.png",
    ["dgtcrit"]         = "Icon critical damage.png",
    ["non"]             = "Icon cross.png",
    ["attaque"]         = "Icon attack.png",
    ["coupé"]           = "Icon cut.png",
    ["FOD20"]           = "gametitle-D20.png",
    ["dégâts"]          = "Icon damage.png",
    ["dpa"]             = "Icon dap.png",
    ["mort"]            = "Icon dead.png",
    ["défense"]         = "Icon shield silver.png",
    ["détection"]       = "Icon eye.png",
    ["dial"]            = "Icon dialogue.png",
    ["aimepas"]         = "Dislike.svg",
    ["distance"]        = "Icon range.png",
    ["docteur"]         = "Icon doctor.png",
    ["dps"]             = "Icon dps.png",
    ["ca"]              = "Icon shield bronze.png",
    ["rd"]              = "Icon shield silver.png",
    ["sd"]              = "Icon shield gold.png",
    ["effet"]           = "Icon effect.png",
    ["électrique"]      = "Icon electrical.png",
    ["iem"]             = "Icon EMP.png",
    ["énergie"]         = "Icon electrical.png",
    ["asservissable"]   = "Icon cage.png",
    ["essentiel"]       = "Icon essential.png",
    ["px"]              = "Icon XP.png",
    ["fabrexpl"]        = "Icon fo4cw builder.png",
    ["explosion"]       = "Icon explosion.png",
    ["facebook"]        = "FacebookIcon.png",
    ["FB"]              = "gametitle-FB.png",
    ["FJP"]             = "gametitle-FBG.png",
    ["FJPNC"]           = "gametitle-FBGNC.png",
    ["FJPWW"]           = "gametitle-FBGWW.png",
    ["FILM"]            = "Film.png",
    ["feu"]             = "Icon fire.png",
    ["poing"]           = "Icon fist.png",
    ["FNV"]             = "gametitle-FNV.png",
    ["FNVCS"]           = "gametitle-FNV_CS.png",
    ["FNVDM"]           = "gametitle-FNV_DM.png",
    ["FNVGRA"]          = "gametitle-FNV_GRA.png",
    ["FNVHH"]           = "gametitle-FNV_HH.png",
    ["FNVLR"]           = "gametitle-FNV_LR.png",
    ["FNVOWB"]          = "gametitle-FNV_OWB.png",
    ["FNVww"]           = "Perk wild wasteland.png",
    ["FO"]              = "gametitle-FO1.png",
    ["FO1"]             = "gametitle-FO1.png",
    ["FO2"]             = "gametitle-FO2.png",
    ["FO3"]             = "gametitle-FO3.png",
    ["FO3BS"]           = "gametitle-FO3_BS.png",
    ["FO3MZ"]           = "gametitle-FO3_MZ.png",
    ["FO3OA"]           = "gametitle-FO3_OA.png",
    ["FO3PL"]           = "gametitle-FO3_PL.png",
    ["FO3TP"]           = "gametitle-FO3_TP.png",
    ["FO4"]             = "gametitle-FO4.png",
    ["FO4AUT"]          = "gametitle-FO4_AUT.png",
    ["FO4CC"]           = "gametitle-FO4_CC.png",
    ["FO4chaine01"]     = "icon Fo4 chain01.png",
    ["FO4chaine02"]     = "icon Fo4 chain02.png",
    ["FO4CW"]           = "gametitle-FO4_CW.png",
    ["FO4FH"]           = "gametitle-FO4_FH.png",
    ["FO4clégen"]       = "icon Fo4 gen keycard.png",
    ["FO4holo"]         = "icon Fo4 holotape.png",
    ["FO4clé01"]        = "icon Fo4 key01.png",
    ["FO4clé02"]        = "icon Fo4 key02.png",
    ["FO4clé03"]        = "icon Fo4 key03.png",
    ["FO4note"]         = "icon Fo4 note.png",
    ["FO4NW"]           = "gametitle-FO4_NW.png",
    ["FO4abriID"]       = "icon Fo4 vaultid.png",
    ["FO4VR"]           = "gametitle-FO4VR.png",
    ["FO4VW"]           = "gametitle-FO4_VW.png",
    ["FO4WW"]           = "gametitle-FO4_WW.png",
    ["FO76"]            = "gametitle-FO76.png",
    ["FO76WA"]          = "gametitle-FO76 WA.png",
    ["FO76NW"]          = "gametitle-FO76 NW.png",
    ["FO76WL"]          = "gametitle-FO76 WL.png",
    ["FO76LR"]          = "gametitle-FO76 LR.png",
    ["FO76OW"]          = "gametitle-FO76 One Wasteland.png",
    ["FO76FS"]          = "gametitle-FO76 Fractured Steel.png",
    ["FOBOS"]           = "gametitle-FOBOS.png",
    ["FOBOS2"]          = "gametitle-FOBOS2.png",
    ["prnour"]          = "Icon fo4cw builder.png",
    ["FOS"]             = "gametitle-FOS.png",
    ["FOT"]             = "gametitle-FOT.png",
    ["FOT2"]            = "gametitle-FOT2.png",
    ["FOW"]             = "gametitle-FOW.png",
    ["FOX"]             = "gametitle-FOX.png",
    ["FPB"]             = "gametitle-FPB.png",
    ["froid"]           = "Icon effect.png",
    ["FWW"]             = "gametitle-FWW.png",
    ["FWWRPG"]          = "gametitle-FWWRPG.png",
    ["gamerscore"]      = "Gamerscore.svg",
    ["gaz"]             = "Icon gas.png",
    ["tropheeor"]       = "Gold.png",
    ["gold bullion"]    = "Fo76 Icon Gold Bullion.png",
    ["vert"]            = "Icon green.png",
    ["grenade"]         = "Icon grenade.png",
    ["groupe"]          = "Icon group.png",
    ["arme"]            = "Icon gun.png",
    ["déteste"]         = "Hate.svg",
    ["soins"]           = "Icon healing.png",
    ["haché"]           = "Fire axe icon.png",
    ["pv"]              = "Icon heart.png",
    ["image"]           = "Icon image.png",
    ["infos"]           = "Icon info.png",
    ["instagram"]       = "Instagram icon.jpg",
    ["JES"]             = "gametitle-JES.png",
    ["jury"]            = "JuryRigging.png",
    ["laser"]           = "Icon laser.png",
    ["niveau"]          = "Icon level.png",
    ["LH"]              = "gametitle-LH.png",
    ["aime"]            = "Like.svg",
    ["linkedin"]        = "Linkedin icon.png",
    ["adore"]           = "Love.svg",
    ["temporaire"]      = "Icon limitedtime.png",
    ["mac"]             = "Icon mac.png",
    ["macclassic"]      = "Icon mac.png",
    ["capachargeur"]    = "Assault carbine extended magazines.png",
    ["cac"]             = "Icon melee.png",
    ["mentionné"]       = "Icon mentioned.png",
    ["marchand"]        = "Icon merchant.png",
    ["mine"]            = "Icon mine.png",
    ["mod"]             = "Icon plus.png",
    ["myspace"]         = "Myspace icon.png",
    ["neutre"]          = "Icon neutral.png",
    ["indifférent"]     = "Neutral.svg",
    ["non"]             = "Icon cross.png",
    ["nukamix"]         = "Icon Nuka-mixer station.png",
    ["optionnel"]       = "Icon optional.png",
    ["OMACP"]           = "Penny Arcade.gif",
    ["starmass"]        = "Fo4_Power_Work_Icon.png",
    ["jeupb"]           = "Fo4_Pip-Boy game.png",
    ["pc"]              = "Icon pc.png",
    ["plasma"]          = "Icon plasma.png",
    ["tropheeplatine"]  = "Plat.png",
    ["poison"]          = "Icon poison.png",
    ["ps3"]             = "Icon ps3.png",
    ["ps4"]             = "Icon ps4.png",
    ["PV13"]            = "PV13.png",
    ["radiations"]      = "Icon radiation.png",
    ["portée"]          = "Icon range.png",
    ["rareté"]          = "Icon rarity.png",
    ["ratio"]           = "Icon ratio.png",
    ["rouge"]           = "Icon red.png",
    ["réparable"]       = "Icon repair.png",
    ["répétable"]       = "Icon repeat.png",
    ["requis"]          = "Icon required.png",
    ["fusil"]           = "Icon rifle.png",
    ["atrobot"]         = "Icon robot workbench.png",
    ["semirequis"]      = "Icon semi-required.png",
    ["séquence"]        = "Icon sequence.png",
    ["pompe"]           = "Icon shotgun.png",
    ["sic"]             = "Icon sic.png",
    ["tropheeargent"]   = "Silver.png",
    ["pm"]              = "Icon smg.png",
    ["son"]             = "Icon sound.png",
    ["apparition"]      = "Icon spawn.png",
    ["dispersion"]      = "Icon spread.png",
    ["switch"]          = "Nintendo Switch icon.png",
    ["TAR"]             = "gametitle-TAR.jpg",
    ["texte"]           = "Icon text.png",
    ["TORN"]            = "gametitle-TORN.png",
    ["tumblr"]          = "Tumblr Icon.png",
    ["twitch"]          = "Twitch icon.png",
    ["twitter"]         = "Twitter icon.png",
    ["sansarmes"]       = "Icon unarmed.png",
    ["VB"]              = "gametitle-VB.png",
    ["atarmes"]         = "Fo4_Weapon_Work_Icon.png",
    ["poids"]           = "Icon weight.png",
    ["WIKI"]            = "gametitle-Wiki.png",
    ["windows"]         = "Icon windows.png",
    ["atelier"]         = "Icon workshop.png",
    ["xbox360"]         = "Icon xbox360.png",
    ["xboxone"]         = "Icon xboxone.png"
}
 
local iconSize = {
    ["petit"]           = "x10px",
    ["medium"]          = "x14px",
    ["normal"]          = "x14px",
    ["gros"]            = "x20px"
}
 
function p.Icons(frame)
    local iconList = mw.text.split(frame.args[1], ",")
    local parserError = ""
    local iconSetting
    if frame.args[2] ~= nil and string.len(frame.args[2]) > 0 then
        iconSetting = tostring(frame.args[2])
    else
        iconSetting = iconSize["medium"]
    end
 
    local iconLinks
    if frame.args[3] ~= nil then
        iconLinks = mw.text.split(frame.args[3], ",")
    end
 
    local tipOverride 
    if frame.args[4] ~= nil then
        tipOverride = mw.text.split(frame.args[4], ",")
    end
 
    local n = 1
    local result = ""
 
    while n <= table.getn(iconList) do
        newIcon = iconList[n]
        if gameIcon[newIcon] ~= nil then
            currentIcon = gameIcon[newIcon]
            if tipOverride ~= nil and tipOverride[n] ~= nil then
                currentTip = tipOverride[n]
            else
                if iconLinks ~= nil and iconLinks[n] ~= nil then
                    currentTip = iconLinks[n]
                else
                    splitTip = mw.text.split(iconTip[newIcon], "|")
                    currentTip = splitTip[1]
                end
            end
        else
            currentIcon = "Icon question.png"
            currentTip = "Unrecognized icon name"
        end
 
        result = result .. '<span style="display: none;">' .. currentTip .. '</span>'
        result = result .. '<span class="va-icon" title="' .. currentTip .. '">'
        result = result .. '[' .. '[File:' .. currentIcon .. '|' .. iconSetting
        if iconLinks ~= nil and iconLinks[n] ~= nil and iconLinks[n] ~= "" then
            result = result .. '|link=' .. iconLinks[n]
        else
            result = result .. '|link='
        end
        if currentTip ~= nil then
            result = result .. '|' .. currentTip
        end
 
        result = result .. ']]</span>'
        n = n + 1
    end
 
    return result .. parserError
 
end
 
function p.documentation()
    keys = {}
    for k in pairs(gameIcon) do
        table.insert(keys, k)
    end
 
 
    table.sort(keys)
 
    result = '{| class="va-table va-table-full"\n|-\n !prefix!!Icon!!prefix!!Icon!!prefix!!Icon\n|-\n'
 
    set = 1
    for k,v in ipairs(keys) do
 
        result = result .. "||'''" .. v .. "'''"
        result = result .. "||[[File:" .. gameIcon[v] .. "|25px]]"
 
        if set == 3 then
            result = result .. "\n|-\n"
        end
 
        if set < 3 then
            set = set + 1
        else
            set = 1
        end
    end
 
    result = result .. "\n|}"
 
    return result
 
end
 
function p.plateformes(frame)
    local icons = mw.text.split(frame.args[1], ",")
    local iconCount = 1
    local platformCheck = ""
    local result = ""
 
    while iconCount <= table.getn(icons) do
        currentIcon = iconTip[icons[iconCount]]
        platformCheck = mw.text.split(currentIcon, "|")
        if platformCheck[2] ~= nil then
            result = result .. '<span style="display: none;">' .. platformCheck[1] .. '</span>'
            result = result .. '<span class="va-icon" title="' .. platformCheck[1] .. '">'
            result = result .. "[".."[File:" .. gameIcon[icons[iconCount]] .. "|x14px|link=]]"
            result = result .. '</span>'
            result = result .. " "
        end
        iconCount = iconCount + 1
    end
    if result == "" then
        result = '<sup>[Plateformes nécessaires]</sup>[[Catégorie:Plateformes nécessaires]]'
    end
 
    return result
end    
 
function p.test(frame)
 
    return frame.args[1]
end
 
return p
Sauf mention contraire, le contenu de la communauté est disponible sous licence CC-BY-SA .