|
|
(229 intermediate revisions by 2 users not shown) |
Line 1: |
Line 1: |
| local p = {}; | | local p = require("Module:Move") |
| local cargo = mw.ext.cargo
| | p.game = require("Module:Game").Tekken7 |
| local tables = 'MoveDataCargoTest'
| |
| | |
| p.fields = 'id,input,target,damage,startup'
| |
| | |
| p.queryOverride = function(frame)
| |
| local args = frame:getParent().args
| |
| local id = args['id']
| |
| if id == nil then
| |
| return "Error: no id"
| |
| end
| |
|
| |
| local root = mw.html.create('div')
| |
| for rowName, row in pairs(cargo.query(tables, p.fields, { where = "id = '" .. id .. "'" })) do
| |
| local rowNode = mw.html.create('div'):wikitext('row: ' .. rowName)
| |
| root:node(rowNode)
| |
| for k, v in pairs(row) do
| |
| rowNode:node(mw.html.create('div'):wikitext(k .. ": " .. v))
| |
| end
| |
| end
| |
|
| |
| return root
| |
| end
| |
| | |
| return p | | return p |