10,992
editsAd placeholder
Module:ParseList: Difference between revisions
Jump to navigation
Jump to search
no edit summary
No edit summary |
No edit summary |
||
Line 22: | Line 22: | ||
-- pluralize in a listing. | -- pluralize in a listing. | ||
local specialPlurals = { | local specialPlurals = { | ||
-- Weapons | -- Weapons | ||
Quarterstaff = "Quarterstaves", | Quarterstaff = "Quarterstaves", | ||
quarterstaff = "quarterstaves", | quarterstaff = "quarterstaves", | ||
Staff = "Staves", | |||
staff = "staves", | |||
-- Races | -- Races | ||
Gith = "Gith", | Gith = "Gith", | ||
gith = "gith", | gith = "gith", | ||
Line 59: | Line 50: | ||
return sp | return sp | ||
end | end | ||
local lastLetter = str:sub(-1) | |||
if lastLetter == "y" then | |||
return str:sub(1, -2) .. "ies" | return str:sub(1, -2) .. "ies" | ||
elseif lastLetter == "f" then | |||
return str:sub(1, -2) .. "ves" | |||
end | end | ||
return str .. "s" | return str .. "s" |