Différences entre les versions de « Module:OInfobox-Building »

Aller à la navigation Aller à la recherche
31 octets supprimés ,  19 avril 2025 à 08:32
m
aucun résumé de modification
m
Balise : Annulation
m
Ligne 172 : Ligne 172 :
         end
         end
         --/
         --/
--SECTION-REREQUISITES
--SECTION-PREQUISITES
         local prereqData = {}
         local prereqData = {}
          
          
Ligne 195 : Ligne 195 :
         end
         end
--/
--/
        --SECTION-PROSPERITY
        ---SECTION-UNLOCKING
        if #prereqData > 0 then
         if buildingData.influence then
            addSection(infobox, prereqData, 'Prerequisites')
             local unlockData = {}
        end
             for resource, amount in pairs(buildingData.influence) do
       
                 local resourceIcon = i.icon(resource, nil, nil, com.firstUpper({resource}), 'en')
         if buildingData.prosperity then
                table.insert(unlockData, {label = resourceIcon, value = amount})
             local prosperityData = {}
             for type, value in pairs(buildingData.prosperity) do
                 table.insert(prosperityData, {label = com.firstUpper({type}), value = value})
             end
             end
              
              
             if #prosperityData > 0 then
             if #unlockData > 0 then
                 addSection(infobox, prosperityData, 'Prosperity', 2)
                 addSection(infobox, unlockData, 'Unlocking Conditions', 2)
             end
             end
         end
         end
Ligne 220 : Ligne 217 :
              
              
             if #constructionData > 0 then
             if #constructionData > 0 then
                 addSection(infobox, constructionData, 'Construction Requirements', 2)
                 addSection(infobox, constructionData, 'Construction Resources', 2)
             end
             end
         end
         end
606

modifications

Menu de navigation