Latest revision |
Your text |
Line 12: |
Line 12: |
| local header = "<table class=\"wikitable sortable\"> \n " | | local header = "<table class=\"wikitable sortable\"> \n " |
| header = header .. "<tr> \n " | | header = header .. "<tr> \n " |
| header = header .. "<th rowspan=\"3\">Plant</th> \n " | | header = header .. "<th>Plant</th> \n " |
| header = header .. "<th rowspan=\"3\">Habitat</th> \n " | | header = header .. "<th>Temperature<br>Ranges</th> \n " |
| header = header .. "<th colspan=\"4\">Temperature Ranges (<sup>o</sup>C)</th> \n "
| | header = header .. "<th>Moisture<br>Ranges</th> \n " |
| header = header .. "<th colspan=\"4\">Moisture Ranges (%)</th> \n " | | header = header .. "<th>Salt<br>Ranges</th> \n " |
| header = header .. "<th colspan=\"4\">Salt Ranges (%)</th> \n "
| |
| header = header .. "<th rowspan=\"2\" colspan=\"2\">Pollution (%)</th> \n " | |
| header = header .. "<th rowspan=\"3\">Absorb<br>CO<sup>2</sup> (ppm)</th> \n "
| |
| header = header .. "<th rowspan=\"3\">Time to<br>Maturity<br>(Hours)</th> \n "
| |
| header = header .. "<th rowspan=\"2\" colspan=\"3\">Сollected<br>resources</th> \n "
| |
| | |
| | |
| header = header .. "</tr> \n " | | header = header .. "</tr> \n " |
| | | |
| header = header .. "<tr> \n " | | header = header .. "<tr> \n " |
| header = header .. "<th colspan=\"2\">Ideal</th> \n " | | header = header .. "<th></th> \n " |
| header = header .. "<th colspan=\"2\">Extreme</th> \n "
| | header = header .. "<th></th> \n " |
| header = header .. "<th colspan=\"2\">Ideal</th> \n "
| | header = header .. "<th></th> \n " |
| header = header .. "<th colspan=\"2\">Extreme</th> \n " | | header = header .. "<th></th> \n " |
| header = header .. "<th colspan=\"2\">Ideal</th> \n " | |
| header = header .. "<th colspan=\"2\">Extreme</th> \n " | |
| header = header .. "</tr> \n " | | header = header .. "</tr> \n " |
|
| |
|
| header = header .. "<tr> \n "
| |
| header = header .. "<th>Min</th> \n "
| |
| header = header .. "<th>Max</th> \n "
| |
| header = header .. "<th>Min</th> \n "
| |
| header = header .. "<th>Max</th> \n "
| |
| header = header .. "<th>Min</th> \n "
| |
| header = header .. "<th>Max</th> \n "
| |
| header = header .. "<th>Min</th> \n "
| |
| header = header .. "<th>Max</th> \n "
| |
| header = header .. "<th>Min</th> \n "
| |
| header = header .. "<th>Max</th> \n "
| |
| header = header .. "<th>Min</th> \n "
| |
| header = header .. "<th>Max</th> \n "
| |
| header = header .. "<th>Tolerance</th> \n "
| |
| header = header .. "<th>Max</th> \n "
| |
|
| |
| header = header .. "<th>Min</th> \n "
| |
| header = header .. "<th>Max</th> \n "
| |
| header = header .. "<th>Resources</th> \n "
| |
|
| |
|
|
| |
| header = header .. "</tr> \n "
| |
|
| |
|
| wiki = header | | wiki = header |
|
| |
|
| for k,v in pairs(plants) do
| |
| local row = ''
| |
| row = row .. "<tr> \n "
| |
|
| |
| row = row .. "<td>" .. "[[" .. k .. "]]" .. " </td> \n"
| |
|
| |
| if (v.isWater == nil) then v.isWater = 'On Land' end
| |
| row = row .. "<td>" .. v.isWater .. " </td> \n"
| |
|
| |
| row = row .. "<td>" .. v.idealTempMin * 40 - 10 .. " </td> \n"
| |
| row = row .. "<td>" .. v.idealTempMax * 40 - 10 .. " </td> \n"
| |
| row = row .. "<td>" .. v.extremeTempMin * 40 - 10 .. " </td> \n"
| |
| row = row .. "<td>" .. v.extremeTempMax * 40 - 10 .. " </td> \n"
| |
|
| |
| row = row .. "<td>" .. v.idealMoistureMin * 100 .. " </td> \n"
| |
| row = row .. "<td>" .. v.idealMoistureMax * 100 .. " </td> \n"
| |
| row = row .. "<td>" .. v.extremeMoistureMin * 100 .. " </td> \n"
| |
| row = row .. "<td>" .. v.extremeMoistureMax * 100 .. " </td> \n"
| |
|
| |
| row = row .. "<td>" .. v.idealSaltMin * 100 .. " </td> \n"
| |
| row = row .. "<td>" .. v.idealSaltMax * 100 .. " </td> \n"
| |
| row = row .. "<td>" .. v.extremeSaltMin * 100 .. " </td> \n"
| |
| row = row .. "<td>" .. v.extremeSaltMax * 100 .. " </td> \n"
| |
|
| |
| row = row .. "<td>" .. v.pollutionTolerance * 100 .. " </td> \n"
| |
| row = row .. "<td>" .. v.maxPollutionDensity * 100 .. " </td> \n"
| |
|
| |
| row = row .. "<td>" .. v.carbonRelease .. " </td> \n"
| |
| row = row .. "<td>" .. v.maturity * 24 .. " </td> \n"
| |
| row = row .. "<td>" .. math.ceil(v.resourceMin) .. " </td> \n"
| |
| row = row .. "<td>" .. math.ceil(v.resourceMax) .. " </td> \n"
| |
| row = row .. "<td>" .. v.resourceItem.. " </td> \n"
| |
|
| |
| row = row .. "</tr>"
| |
| wiki = wiki .. row
| |
| end
| |
|
| |
|
| wiki = wiki .. " </table>" | | wiki = wiki .. " </table>" |