Модуль:Entity Sprite: различия между версиями
Pok (обсуждение | вклад) Нет описания правки |
Pok (обсуждение | вклад) мНет описания правки |
||
| Строка 17: | Строка 17: | ||
return nil | return nil | ||
end | end | ||
local id = entry.id | |||
local sprite = entry.Sprite.sprite | |||
local result = {} | local result = {} | ||
table.insert(result, mw.getCurrentFrame():preprocess("{{Entity Sprite|" .. | table.insert(result, mw.getCurrentFrame():preprocess("{{Entity Sprite|" .. id .. "|" .. sprite .. "}}")) | ||
table.insert(result, mw.getCurrentFrame():preprocess("{{LinkСard|SideStyle=1|image=" .. id .. ".png|name=Имя: {{#invoke:Entity Lookup|getname|" .. id .. "}}<br>Путь: [[:Файл:" .. id .. ".png]]}}")) | |||
table.insert(result, "<div class=\"entity-sprite__strings no-margin-edges\" style=\"white-space: pre; font-family: monospace; background: #d0d0ff0b; padding: 12px 8px;\">") | |||
table.insert(result, "== Краткое описание ==\n{{Файл\n|Описание = \n|Id = " .. id .. "\n|Сервера = {{abb|SS14}}\n|Источник = \n|Путь = Resources/Textures/" .. id .. ".rsi\n|Теги = \n}}\n") | |||
table.insert(result, "== Лицензирование ==\n{{CC-BY-SA-3.0}}") | |||
table.insert(result, "</div>") | |||
return table.concat(result) | return table.concat(result) | ||
end | end | ||