Module:Seeds

From Plants vs. Zombies Wiki
Jump to navigation Jump to search

Winter Melon New Wild West Seed Packet.png Primal Sunflower Jurassic Marsh Seed Packet.png Rotobaga New Frostbite Caves Seed Packet.png Peashooter Seed Packet.png Split Pea New Wild West Seed Packet.png Spring Bean New Pirate Seas Seed Packet.png Sunflower Seed Packet.png Primal Wall-nut Jurassic Marsh Seed Packet.png Pepper-pult New Frostbite Caves Seed Packet.png Spikerock New Pirate Seas Seed Packet.png Grimrose Seed Packet.png Spikeweed New Pirate Seas Seed Packet.png Split Pea New Wild West Seed Packet.png Split Pea New Wild West Seed Packet.png Lily Pad Big Wave Beach Seed Packet.png Guacodile Big Wave Beach Seed Packet.png Banana Launcher Big Wave Beach Seed Packet.png Tile Turnip New Far Future Seed Packet.png Citron New Far Future Seed Packet.png Blover New Far Future Seed Packet.png Stunion New Frostbite Caves Seed Packet.png Garlic Neon Mixtape Tour Seed Packet.png A.K.E.E. Lost City Seed Packet.png E.M.Peach New Far Future Seed Packet.png Sun Bean Dark Ages Seed Packet.png Sun Bean Dark Ages Seed Packet.png Squash New Premium Seed Packet.png Spear-mint New Premium Seed Packet.png Bombard-mint New Premium Seed Packet.png Sun-shroom Dark Ages Seed Packet.png


local p = {}
local getArgs = require('Dev:Arguments').getArgs
local modern = {
		"Peashooter", "Sunflower", "Wall-nut", "Potato Mine", "Cabbage-pult",
		"Moonflower", "Nightshade", "Shadow-shroom", "Dusk Lobber", "Grimrose"}
local egypt = {
		"Bloomerang", "Iceberg Lettuce", "Grave Buster", "Bonk Choy",
		"Repeater", "Twin Sunflower"}
local pirate = {
		"Kernel-pult", "Snapdragon", "Spikeweed", "Spring Bean",
		"Coconut Cannon", "Threepeater", "Spikerock", "Cherry Bomb"}
local west = {
		"Split Pea", "Chili Bean", "Pea Pod", "Lightning Reed", "Melon-pult",
		"Tall-nut", "Winter Melon"}
local frost = {
		"Hot Potato", "Pepper-pult", "Chard Gard", "Stunion", "Rotobaga"}
local lost = {
		"Red Stinger", "A.K.E.E.", "Endurian", "Stallia", "Gold Leaf"}
local future = {
		"Laser Bean", "Blover", "Citron", "E.M.Peach", "Infi-nut",
		"Magnifying Grass", "Tile Turnip"}
local dark = {
		"Sun-shroom", "Puff-shroom", "Fume-shroom", "Sun Bean", "Magnet-shroom"}
local neon = {
		"Phat Beet", "Celery Stalker", "Thyme Warp", "Garlic", "Spore-shroom",
		"Intensive Carrot"}
local jurassic = {
		"Primal Peashooter", "Primal Wall-nut", "Perfume-shroom",
		"Primal Sunflower", "Primal Potato Mine"}
local wave = {
		"Lily Pad", "Tangle Kelp", "Bowling Bulb", "Guacodile",
		"Banana Launcher"}
local premium = {"Blockoli", "Blooming Heart", "Boingsetta", "Boom Balloon Flower", "Bramble Bush", "Bun Chi", "Buttercup", "Chilly Pepper", "Dartichoke", "Draftodil", "Enlighten-mint", "Explode-o-Vine", "Gloom Vine", "Gumnut", "Headbutter Lettuce", "Heath Seeker", "Hocus Crocus", "Ice Bloom", "Iceweed", "Imp Pear", "Inferno", "Levitater", "Mega Gatling Pea", "Meteor Flower", "Murkadamia Nut", "Noctarine", "Olive Pit", "Pokra", "Power Vine", "Puffball", "Pumpkin", "Pyre Vine", "Rhubarbarian", "Shine Vine", "Shrinking Violet", "Solar Sage", "Stickybomb Rice", "Teleportato Mine", "Tomb Tangler", "Tumbleweed", "Turkey-pult", "Ultomato", "Vamporcini"}
local newPremium = {
		"Ail-mint", "Aloe", "Appease-mint", "Apple Mortar", "Arma-mint", "Blastberry Vine", "Bombard-mint", "Cactus", "Caulipower", "Chomper",
		"Cold Snapdragon", "Conceal-mint", "Contain-mint", "Dandelion", "Dazey Chain", "Electric Blueberry", "Electric Currant", "Electric Peashooter", "Electrici-tea", "Enchant-mint", "Enforce-mint", "Escape Root", "Explode-o-nut", "Fila-mint", "Fire Peashooter", "Ghost Pepper", "Gold Bloom", "Goo Peashooter", "Grapeshot", "Holly Barrier", "Homing Thistle", "Hot Date", "Hurrikale", "Hypno-shroom", "Imitater", "Jack O' Lantern", "Jalapeno", "Kiwibeast", "Lava Guava", "Parsnip", "Pea-nut", "Pepper-mint", "Power Lily", "Bombegranate", "Reinforce-mint", "Sap-fling", "Shadow Peashooter", "Sling Pea", "Snap Pea", "Snow Pea", "Solar Tomato", "Spear-mint", "Squash", "Starfruit", "Strawburst", "Sweet Potato", "Toadstool", "Torchwood", "Wasabi Whip", "Winter-mint", "Witch Hazel", "Zoybean Pod"}
local pvz2 = {"Peashooter", "Sunflower", "Wall-nut", "Potato Mine", "Cabbage-pult", "Bloomerang", "Grave Buster", "Bonk Choy", "Repeater", "Twin Sunflower", "Kernel-pult", "Snapdragon", "Spikeweed", "Coconut Cannon", "Threepeater", "Spikerock", "Cherry Bomb", "Split Pea", "Chili Bean", "Lightning Reed", "Melon-pult", "Tall-nut", "Winter Melon", "Red Stinger", "Endurian", "Laser Bean", "Blover", "Citron", "E.M.Peach", "Magnifying Grass", "Sun-shroom", "Puff-shroom", "Fume-shroom", "Magnet-shroom", "Garlic", "Lily Pad", "Tangle Kelp", "Buttercup", "Cactus", "Chilly Pepper", "Chomper", "Dandelion", "Explode-O-Nut", "Fire Peashooter", "Hypno-shroom", "Imitater", "Jalapeno", "Pumpkin", "Snow Pea", "Squash", "Starfruit", "Sweet Potato", "Torchwood", "Witch Hazel", 
}


function p.getLink(arg)
	for _, item in ipairs(pvz2) do
		if item == arg then
			return string.format("%s (PvZ2)", arg)
		end
	end
	return arg
end

function p.getBG(place, link)
	return string.format("[[File:%s Seed Packet.png|link=%s|100px]]", place, link)
end

function p.location(plant)
	for _, modernPlant in ipairs(modern) do if plant == modernPlant then return modernPlant end end
	for _, egyptPlant in ipairs(egypt) do if plant == egyptPlant then return string.format("%s New Ancient Egypt", egyptPlant) end end
	for _, piratePlant in ipairs(pirate) do if plant == piratePlant then return string.format("%s New Pirate Seas", piratePlant) end end
	for _, westPlant in ipairs(west) do if plant == westPlant then return string.format("%s New Wild West", westPlant) end end
	for _, frostPlant in ipairs(frost) do if plant == frostPlant then return string.format("%s New Frostbite Caves", frostPlant) end end
	for _, lostPlant in ipairs(lost) do if plant == lostPlant then return string.format("%s Lost City", lostPlant) end end
	for _, futurePlant in ipairs(future) do if plant == futurePlant then return string.format("%s New Far Future", futurePlant) end end
	for _, darkPlant in ipairs(dark) do if plant == darkPlant then return string.format("%s Dark Ages", darkPlant) end end
	for _, neonPlant in ipairs(neon) do if plant == neonPlant then return string.format("%s Neon Mixtape Tour", neonPlant) end end
	for _, jurassicPlant in ipairs(jurassic) do if plant == jurassicPlant then return string.format("%s Jurassic Marsh", jurassicPlant) end end
	for _, wavePlant in ipairs(wave) do if plant == wavePlant then return string.format("%s Big Wave Beach", wavePlant) end end
	for _, premiumPlant in ipairs(premium) do if plant == premiumPlant then return string.format("%s Premium", premiumPlant) end end
	for _, newPremiumPlant in ipairs(newPremium) do if plant == newPremiumPlant then return string.format("%s New Premium", newPremiumPlant) end end
	return "Mystery"
end

function p._main(args)
	local new = {}
	for _, item in ipairs(args) do
		if p.location(item) == "Mystery" then
			table.insert(new, p.getBG(p.location(item), ""))
		else
			table.insert(new, p.getBG(p.location(item), p.getLink(item)))
		end
	end
	return table.concat(new, " ")
		
end

function p.main(frame)
	return p._main(getArgs(frame))
end

return p