Open main menu
Home
Random
Nearby
Log in
Settings
About Kancolle Wiki
Disclaimers
Kancolle Wiki
Search
Changes
← Older edit
Newer edit →
Module:DropList
(view source)
Revision as of 05:09, 17 October 2015
120 bytes added
,
9 years ago
trying Ship module
Line 1:
Line 1:
local getArgs = require('Module:GetArgs')
local getArgs = require('Module:GetArgs')
+
+
local Ship = require('Module:Ship')
local DropList = {}
local DropList = {}
Line 41:
Line 43:
local ship, nodes = arg:match(args_grammar.ship_and_nodes)
local ship, nodes = arg:match(args_grammar.ship_and_nodes)
-- TODO: check ship existence?
-- TODO: check ship existence?
+
local ship_table = Ship:get_table(ship, "")
table.insert(tbl.rows, {})
table.insert(tbl.rows, {})
local row = tbl.rows[#tbl.rows]
local row = tbl.rows[#tbl.rows]
row.id = arg_name
row.id = arg_name
row.ship = ship
row.ship = ship
−
row.type = ''
+
row.type =
ship_table and ship_table._name or
'
?
'
row.nodes = {}
row.nodes = {}
for _, node in pairs(tbl.nodes) do
for _, node in pairs(tbl.nodes) do
がか
cssedit, gkautomate
7,064
edits