Module:EpisodeLink

-- This module was taken and adapted from the unOrdinary Wiki & True Beauty Wiki -- -- -- -- This module needs to be updated every Saturday when the new Naver and LINE episodes are released. -- -- How webtoon numbering for LINE is calculated: -- Episodes 1 onwards: episode # -- -- local p = {}

function p.getLatest return 49 -- Update this on Saturdays - most recent episode # end function p.GetNumber( frame ) local site = frame.args[1] local anchor = frame.args[2] local episode = frame.args[3] local LinkNumber = 0 local LinkTxt = "Something went wrong." -- Get the link number. episode = tonumber( episode ) -- Return LINE link if (site == "line") then if (anchor == "1") then LinkNumber = episode end if (episode <= p.getLatest) then LinkTxt = "[http://webtoons.com/viewer?titleNo=1663&episodeNo=" .. LinkNumber .. " LINE]" else LinkTxt = "Not yet available on LINE" end end return LinkTxt end return p

--