Difference between pages "Module:GetReleaseDate" and "File:CodeGenerator-LOD2-EN-VG.png"

From Yugipedia
(Difference between pages)
Jump to: navigation, search
m (Remove TODO; this is the dedicated script.)
 
(Restoring revision 4473481 by User:CardKBot on 2020-04-18 02:55:28. "{{OCG-TCG card image | name = Code Generator }} {{Fair use rationale | Description = "Code Generator" | Source = ''[[Yu-Gi-Oh! Legacy of the Duelist: Link E...)
 
Line 1: Line 1:
-- <pre>
+
== Summary ==
--[=[Doc
+
{{OCG-TCG card image
@module Data/getReleaseDate
+
| name = Code Generator
@description Returns the release date of an issue in a given region.
+
}}
@author [[User:Becasita]]
+
{{Fair use rationale
@contact [[User talk:Becasita]]
+
| Description      = "[[Code Generator]]"
]=]
+
| Source            = ''[[Yu-Gi-Oh! Legacy of the Duelist: Link Evolution]]''
 
+
| Portion          = Portion of a screenshot.
local DATA = require( 'Module:Data' )
+
| Purpose          = To visualize the card art.
 
+
| Resolution        = High.
local REGION_WORLDWIDE_ENGLISH = DATA.getRegion( 'English' )
+
| Replaceability    = No free alternative available.
 
+
}}
--[[Doc
 
@function getReleaseDate
 
@description gets the release date for `pagename` in the given `region`.
 
@parameter {string} pagename Name of the issue to get the date.
 
@parameter {string} regionFull .
 
@return {string|nil} Date.
 
]]
 
local function getReleaseDate( pagename, regionFull )
 
local prop = table.concat{ regionFull, ' release date' }
 
 
 
local askResult = mw.smw.ask{
 
table.concat{ '[[', pagename, ']]' },
 
table.concat{ '?', prop, '#ISO' },
 
mainlabel = '-',
 
}
 
 
 
local dateInfo = askResult and askResult[ 1 ] or {}
 
 
 
-- TODO: remove when the sets store the Sneak Peek dates separately.
 
return type( dateInfo[ prop ] ) == type( {} )
 
and dateInfo[ prop ][ 1 ]
 
or dateInfo[ prop ]
 
end
 
 
 
--[[Doc
 
@description gets the release date for `pagename` in the given `region`.
 
@parameter {string} pagename Name of the issue to get the date for.
 
@parameter {Region} region
 
@return {string} Date.
 
]]
 
return function( pagename, region )
 
return getReleaseDate( pagename, region.full )
 
or ( region.full == REGION_WORLDWIDE_ENGLISH.full
 
and getReleaseDate( pagename, 'English' )
 
) or ''
 
end
 
-- </pre>
 

Revision as of 01:29, 16 March 2023

Summary

Licensing

Non-free media information and use rationale
Description

"Code Generator"

Source

Yu-Gi-Oh! Legacy of the Duelist: Link Evolution

Portion used

Portion of a screenshot.

Low resolution?

High.

Purpose of use

To visualize the card art.

Replaceable?

No free alternative available.

Fair useFair use of copyrighted materialhttps://yugipedia.com/wiki/File:CodeGenerator-LOD2-EN-VG.png