Changes

no edit summary
Line 25: Line 25:  
if formNum == nil then  
 
if formNum == nil then  
 
if mw.ustring.find(shipmodule.data[shipNum]["name"][1], "zwei") ~= nil then
 
if mw.ustring.find(shipmodule.data[shipNum]["name"][1], "zwei") ~= nil then
formNum = mw.ustring.find(shipmodule.data[shipNum]["name"][1], "zwei")
+
kanji = mw.text.split(shipmodule.data[shipNum]["name"][1], "%s")[1]
kanji = mw.ustring.sub(shipmodule.data[shipNum]["name"][1], 1, formNum - 1)
+
form = " zwei"
form = mw.ustring.sub(shipmodule.data[shipNum]["name"][1], formNum , -1)
   
elseif mw.ustring.find(shipmodule.data[shipNum]["name"][1], "drei") ~= nil then
 
elseif mw.ustring.find(shipmodule.data[shipNum]["name"][1], "drei") ~= nil then
formNum = mw.ustring.find(shipmodule.data[shipNum]["name"][1], "drei")
+
kanji = mw.text.split(shipmodule.data[shipNum]["name"][1], "%s")[1]
kanji = mw.ustring.sub(shipmodule.data[shipNum]["name"][1], 1, formNum - 1)
+
form = " drei"
form = mw.ustring.sub(shipmodule.data[shipNum]["name"][1], formNum , -1)
   
elseif mw.ustring.find(shipmodule.data[shipNum]["name"][1], "due") ~= nil then
 
elseif mw.ustring.find(shipmodule.data[shipNum]["name"][1], "due") ~= nil then
formNum = mw.ustring.find(shipmodule.data[shipNum]["name"][1], "due")
+
kanji = mw.text.split(shipmodule.data[shipNum]["name"][1], "%s")[1]
kanji = mw.ustring.sub(shipmodule.data[shipNum]["name"][1], 1, formNum - 1)
+
form = " due"
form = mw.ustring.sub(shipmodule.data[shipNum]["name"][1], formNum , -1)
   
else
 
else
 
kanji = shipmodule.data[shipNum]["name"][1]
 
kanji = shipmodule.data[shipNum]["name"][1]
5,421

edits