Difference between revisions of "User:Aemony/Sandbox/Infobox game"
From PCGamingWiki, the wiki about fixing PC games
< User:Aemony | Sandbox
m (d) |
m (t) |
||
Line 42: | Line 42: | ||
-->{{#if: {{#var:OS X native}}|{{#vardefine:OS X DOSBox|}}}}<!-- | -->{{#if: {{#var:OS X native}}|{{#vardefine:OS X DOSBox|}}}}<!-- | ||
-->{{#if: {{#var:Linux native}}|{{#vardefine:Linux DOSBox|}}}}<!-- | -->{{#if: {{#var:Linux native}}|{{#vardefine:Linux DOSBox|}}}}<!-- | ||
− | -->}}<!-- | + | -->}} |
+ | |||
+ | <!-- Reception --> | ||
+ | {{#if: {{{metacritic|}}}{{{opencritic|}}}{{{igdb|}}} | | ||
+ | <tr> | ||
+ | <th class="template-infobox-header" colspan="2">Reception</th> | ||
+ | </tr> | ||
+ | {{#if: {{{metacritic|}}}| | ||
+ | <td class="template-infobox-type">Metacritic</td> | ||
+ | <td class="template-infobox-info">{{#if: {{{metacritic score|}}} | [https://www.metacritic.com/game/pc/{{{metacritic}}} {{{metacritic score}}}] | [[Category:Invalid template usage (infobox game)]]<div title="Error: 'metacritic score' is undefined" class="svg-icon svg-25 tickcross-error"></div> }}</td> | ||
+ | }} | ||
+ | {{#if: {{{opencritic|}}}| | ||
+ | <td class="template-infobox-type">Opencritic</td> | ||
+ | <td class="template-infobox-info">{{#if: {{{opencritic score|}}} | [https://opencritic.com/game/{{{opencritic}}} {{{opencritic score}}}] | [[Category:Invalid template usage (infobox game)]]<div title="Error: 'opencritic score' is undefined" class="svg-icon svg-25 tickcross-error"></div> }}</td> | ||
+ | }} | ||
+ | {{#if: {{{igdb|}}}| | ||
+ | <td class="template-infobox-type">IGDB</td> | ||
+ | <td class="template-infobox-info">{{#if: {{{metacritic score|}}} | [https://www.igdb.com/games/{{{igdb}}} {{{igdb score}}}] | [[Category:Invalid template usage (infobox game)]]<div title="Error: 'igdb score' is undefined" class="svg-icon svg-25 tickcross-error"></div> }}</td> | ||
+ | }} | ||
+ | }}<!-- | ||
Icons --> | Icons --> | ||
<!-- storing WSGF Link state -->{{#vardefine:WSGF Link|{{#show: {{PAGENAME}} | ?WSGF Link #}}}}<!-- | <!-- storing WSGF Link state -->{{#vardefine:WSGF Link|{{#show: {{PAGENAME}} | ?WSGF Link #}}}}<!-- | ||
− | storing IsThereAnyDeal ID | + | storing IsThereAnyDeal ID -->{{#if:{{{steam appid|}}}|{{#ifeq: {{#get_web_data:url=https://api.isthereanydeal.com/v02/game/plain/?key=ITAD_KEY&shop=steam&game_id=app/{{{steam appid|}}}|format=JSON|data=itad=data}}|<span class="error">Error: No contents found at URL <a rel="nofollow" class="external free" href="https://api.isthereanydeal.com/v02/game/plain/?key=ITAD_KEY&shop=steam&game_id=app/{{{steam appid|}}}">https://api.isthereanydeal.com/v02/game/plain/?key=ITAD_KEY&shop=steam&game_id=app/{{{steam appid|}}}</a>.</span>||{{#ifeq:{{#external_value:itad}}|<span class="error">Error: no local variable "itad" was set.</span>||{{#vardefine:ITAD match|{{#external_value:itad}}}}}}}}}}{{#if:{{#var:ITAD match}}||{{#vardefine:ITAD match|{{#show: {{PAGENAME}} | ?IsThereAnyDeal ID}}}}}}<!-- |
− | --> | ||
-->{{#if: {{{wikipedia|}}}{{{gogcom id|}}}{{{steam appid|}}}{{{winehq|}}}{{{strategywiki|}}}{{{mobygames|}}}{{#var:WSGF Link}}{{#var:ITAD match}}| | -->{{#if: {{{wikipedia|}}}{{{gogcom id|}}}{{{steam appid|}}}{{{winehq|}}}{{{strategywiki|}}}{{{mobygames|}}}{{#var:WSGF Link}}{{#var:ITAD match}}| | ||
<tr> | <tr> | ||
Line 58: | Line 76: | ||
|data=coopgameid=gameid,coopurl=urlSlug | |data=coopgameid=gameid,coopurl=urlSlug | ||
}} | <span class="error">Error: Invalid JSON.</span> ||<div title="{{PAGENAME}} on Co-Optimus" class="plainlinks template-infobox-icon svg-icon infobox-cooptimus">[https://www.co-optimus.com/game/{{#external_value:coopgameid}}/pc/{{#external_value:coopurl}}.html ]</div>}}<div title="{{PAGENAME}} on SteamDB" class="plainlinks template-infobox-icon svg-icon infobox-steamdb">[https://steamdb.info/app/{{{steam appid|}}}/ ]</div> }}<!-- | }} | <span class="error">Error: Invalid JSON.</span> ||<div title="{{PAGENAME}} on Co-Optimus" class="plainlinks template-infobox-icon svg-icon infobox-cooptimus">[https://www.co-optimus.com/game/{{#external_value:coopgameid}}/pc/{{#external_value:coopurl}}.html ]</div>}}<div title="{{PAGENAME}} on SteamDB" class="plainlinks template-infobox-icon svg-icon infobox-steamdb">[https://steamdb.info/app/{{{steam appid|}}}/ ]</div> }}<!-- | ||
− | -->{{#if: {{#var:ITAD match}} | <div title="{{PAGENAME}} on IsThereAnyDeal" class="plainlinks template-infobox-icon svg-icon infobox-itad">[https://isthereanydeal.com/game/{{#var:ITAD match}}/info/ ]</div>{{#vardefine:ITAD match|}}}}<!-- | + | -->{{#if: {{#var:ITAD match}} | {{#ifeq: {{#var:ITAD match}} | {{#external_value:itad}} | | <div title="{{PAGENAME}} on IsThereAnyDeal" class="plainlinks template-infobox-icon svg-icon infobox-itad">[https://isthereanydeal.com/game/{{#var:ITAD match}}/info/ ]</div>{{#vardefine:ITAD match|}}}}}}<!-- |
-->{{#if: {{{strategywiki|}}} | <div title="{{PAGENAME}} guide on StrategyWiki" class="template-infobox-icon svg-icon infobox-strategywiki">[[File:Icon overlay.png|link=strategywiki:{{{strategywiki}}}|{{PAGENAME}} guide on StrategyWiki]]</div>}}<!-- | -->{{#if: {{{strategywiki|}}} | <div title="{{PAGENAME}} guide on StrategyWiki" class="template-infobox-icon svg-icon infobox-strategywiki">[[File:Icon overlay.png|link=strategywiki:{{{strategywiki}}}|{{PAGENAME}} guide on StrategyWiki]]</div>}}<!-- | ||
-->{{#if: {{{mobygames|}}} | <div title="{{PAGENAME}} on MobyGames" class="template-infobox-icon svg-icon">[[File:MobyGames.png|link=https://www.mobygames.com/game/{{{mobygames}}}|{{PAGENAME}} on MobyGames]]</div>}}<!-- | -->{{#if: {{{mobygames|}}} | <div title="{{PAGENAME}} on MobyGames" class="template-infobox-icon svg-icon">[[File:MobyGames.png|link=https://www.mobygames.com/game/{{{mobygames}}}|{{PAGENAME}} on MobyGames]]</div>}}<!-- |
Revision as of 22:39, 1 April 2020
Error: #cargo_declare must be called from a template page.
Documentation for the above template (sometimes hidden from view).
Visit User:Aemony/Sandbox/Infobox game/Documentation to edit this text. (How does this work?)