Difference between revisions of "Template:MatchMaps"

From comp.tf
Jump to navigation Jump to search
m (Test to add details)
 
(66 intermediate revisions by 3 users not shown)
Line 1: Line 1:
<includeonly>{{#if:{{{date|}}}|<tr>
+
<includeonly>{{#if:{{{date|}}}|<tr><!--
<td colspan="4" style="font-weight:bold; background-color:#f2f2f2; font-size:85%; line-height:90%; height:13px;"><div style="float:left;width:20%;min-height:16px;"><!--
+
-->{{#vardefine:timezone|{{#explode:{{#explode:{{{date|}}}|data-tz="|1}}|"|0}}}}<!--
Icons for VODs
+
-->{{#vardefine:Match_date|{{#replace:{{#explode:{{{date|}}}|<|0}}|-}}}}<!--
-->{{#if:{{{log|}}} {{{log1|}}} {{{log2|}}} {{{tftv|}}} {{{esea|}}} {{{esea1|}}} {{{etf2l|}}}|<span style="float:left;"><!--
+
-->{{#vardefine:Raw_Match_date|{{#explode:{{{date|TBD}}}|<|0}}}}<!--
-->{{#if:{{{tftv|}}}|[[File:TeamfortressTV icon.png|link=http://www.teamfortress.tv/thread/{{{tftv}}}|16px|TF.TV matchpage]]}} <!--
+
--><td colspan="4" style="font-weight:bold; background-color:#f2f2f2; font-size:85%; line-height:90%; height:13px;"><center>{{#ifeq:{{{finished|}}}|true|{{{date}}}|<span class="streamLink">{{{stream|}}}</span><span class="datetime">{{{date}}}</span><br /><span class="countdown" style="font-weight:normal"></span>}}</center></td>
-->{{#if:{{{esea|}}}|[[File:ESEA icon.png|link=http://play.esea.net/index.php?s=stats&d=match&id={{{esea}}}|Match page and stats on ESEA]]}} <!--
+
</tr><!--
-->{{#if:{{{esea1|}}}|[[File:EseaLogo.png|link=http://play.esea.net/index.php?s=stats&d=match&id={{{esea1}}}|Match page and stats for game 1 on ESEA]]}} <!--
+
-->}}<tr class="match-row">
-->{{#if:{{{esea2|}}}|[[File:EseaLogo.png|link=http://play.esea.net/index.php?s=stats&d=match&id={{{esea2}}}|Match page and stats for game 2 on ESEA]]}} <!--
+
<td class="matchlistslot" width="42%" align="right" {{#ifeq:{{{winner|}}}|1|style="font-weight:bold; background-color:#cfc"}}{{#ifeq:{{{winner|}}}|draw|style="font-weight:bold; background-color:#FFFFBB"}}><!--
-->{{#if:{{{esea3|}}}|[[File:EseaLogo.png|link=http://play.esea.net/index.php?s=stats&d=match&id={{{esea3}}}|Match page and stats for game 3 on ESEA]]}} <!--
+
--> {{#if:{{{team1|}}}|{{team2/{{lc:{{{team1}}}}}}}}} <!--
-->{{#if:{{{etf2l|}}}|[[File:ETF2L-Icon.png|link=http://etf2l.org/matches/{{{etf2l}}}|16px|Match page on ETF2L]]}} <!--
+
--> {{#if:{{{team1tf|}}}|{{team2/tf|{{{team1tf}}}}}}} <!--
-->{{#if:{{{log|}}}|[[File:Logs.tf icon.png|link=http://logs.tf/{{{log}}}|16px|Game logs]]}} <!--
+
--></td>
-->{{#if:{{{loggc|}}}|[[File:Logs.tf icon.png|link=http://logs.tf/{{{loggc}}}|16px|Golden Cap Game logs]]}} <!--
+
<td width="8%" align="center" {{#switch:{{{default|}}}|1=style="font-weight:bold;"> W|2=> -|{{#ifeq:{{{winner|}}}|1|style="font-weight:bold;"}}{{#ifeq:{{{winner|}}}|draw|style="font-weight:bold;"}}> {{#if:{{{games1|}}}|{{{games1}}}|0}}}}<!--
-->{{#if:{{{log1|}}}|[[File:Logs.tf icon.png|link=http://logs.tf/{{{log1}}}|16px|Logs for game 1]]}} <!--
 
-->{{#if:{{{log1gc|}}}|[[File:Logs.tf icon.png|link=http://logs.tf/{{{log1gc}}}|16px|Logs for game 1 golden cap]]}} <!--
 
-->{{#if:{{{log2|}}}|[[File:Logs.tf icon.png|link=http://logs.tf/{{{log2}}}|16px|Logs for game 2]]}} <!--
 
-->{{#if:{{{log2gc|}}}|[[File:Logs.tf icon.png|link=http://logs.tf/{{{log2gc}}}|16px|Logs for game 2 golden cap]]}} <!--
 
-->{{#if:{{{log3|}}}|[[File:Logs.tf icon.png|link=http://logs.tf/{{{log3}}}|16px|Logs for game 3]]}} <!--
 
-->{{#if:{{{log3gc|}}}|[[File:Logs.tf icon.png|link=http://logs.tf/{{{log3gc}}}|16px|Logs for game 3 golden cap]]}}</span>}}</div><!--
 
--><div style="float:left;width:60%;height:{{#ifeq:{{{approx-time|}}}|true|32px|auto}};"><center style="margin-top:3px;">{{#if:{{{finished|}}}|{{{date}}}|{{#ifeq:{{{approx-time|}}}|true|~ }}{{{date}}}<span class="streamLink">{{{stream|}}}</span><span class="datetime" style="display:none">{{{date}}}</span><span style="padding:5px 0px 0px 0px; display:block;" class="countdown"></span>}}</center></div><div style="float:left;width:20%;height:auto;"><!--
 
Icons for stats, HLTV, etc.
 
-->{{#if:{{{vod|}}} {{{youtube|}}} {{{youtube1|}}} {{{youtube2|}}} {{{youtube3|}}} {{{youtube4|}}}|<span style="float:right;margin-top:2px;"> <!--
 
-->{{#if:{{{vod|}}}|[[File:VOD_icon.png|link={{{vod}}}|15px|Game VOD]]}} <!--
 
-->{{#if:{{{youtube|}}}|[[File:Youtube_icon.png|link=https://youtu.be/{{{youtube1}}}|Game VOD]]}} <!--
 
-->{{#if:{{{youtubegc|}}}|[[File:Youtube_icon.png|link=https://youtu.be/{{{youtube1gc}}}|Game VOD for golden cap]]}} <!--
 
-->{{#if:{{{youtube1|}}}|[[File:Youtube_icon.png|link=https://youtu.be/{{{youtube1}}}|VOD for game 1]]}} <!--
 
-->{{#if:{{{youtube1gc|}}}|[[File:Youtube_icon.png|link=https://youtu.be/{{{youtube1gc}}}|VOD for game 1 golden cap]]}} <!--
 
-->{{#if:{{{youtube2|}}}|[[File:Youtube_icon.png|link=https://youtu.be/{{{youtube2}}}|VOD for game 2]]}} <!--
 
-->{{#if:{{{youtube2gc|}}}|[[File:Youtube_icon.png|link=https://youtu.be/{{{youtube2gc}}}|VOD for game 2 golden cap]]}} <!--
 
-->{{#if:{{{youtube3|}}}|[[File:Youtube_icon.png|link=https://youtu.be/{{{youtube3}}}|VOD for game 3]]}} <!--
 
-->{{#if:{{{youtube3gc|}}}|[[File:Youtube_icon.png|link=https://youtu.be/{{{youtube3gc}}}|VOD for game 3 golden cap]]}} <!--
 
-->{{#if:{{{interview|}}}|[[File:Int_Icon.png|link={{{interview}}}|15px|Interview]]}} </span>}}</div></td>
 
</tr>}}<!--
 
--><tr>
 
<td class="matchlistslot" width="44%" align="right" {{#ifeq:{{{winner|}}}|1|style="font-weight:bold; background-color:#dfd"}}{{#ifeq:{{{winner|}}}|draw|style="font-weight:bold; background-color:#ffd"}}><!--
 
--> {{#if:{{{T1|}}}|{{Team2/{{{T1}}}}}}}</td>
 
<td width="6%" align="center" {{#switch:{{{default|}}}|1=style="font-weight:bold;"> W|2=>|{{#ifeq:{{{winner|}}}|1|style="font-weight:bold;"}}{{#ifeq:{{{winner|}}}|draw|style="font-weight:bold;"}}>
 
{{{games1|0 [[Category:Template MatchMaps missing scores]]}}}}}</td>
 
 
-->{{#if:{{{details|}}}|<div class="bracket-game-details" style="margin-left:{{#expr:({{{width|300}}}-580)/2}}px;">
 
-->{{#if:{{{details|}}}|<div class="bracket-game-details" style="margin-left:{{#expr:({{{width|300}}}-580)/2}}px;">
 
<div class="header">
 
<div class="header">
<div class="left">{{#if:{{{team1|}}}|{{team2/{{lc:{{{team1}}}}}}}|&nbsp;}}</div>
+
<div class="left">{{#if:{{{team1|}}}|{{team2/{{lc:{{{team1}}}}}}}}} <!--
<div class="right">{{#if:{{{team2|}}}|{{team1/{{lc:{{{team2}}}}}}}|&nbsp;}}</div>
+
--> {{#if:{{{team1tf|}}}|{{team2/tf|{{{team1tf}}}}}}} </div>
 +
<div class="right">{{#if:{{{team2|}}}|{{team1/{{lc:{{{team2}}}}}}}}} <!--
 +
--> {{#if:{{{team2tf|}}}|{{team1/tf|{{{team2tf}}}}}}} </div>
 
</div>
 
</div>
 
{{{details}}}<!--
 
{{{details}}}<!--
 
--> </div>}}<!--
 
--> </div>}}<!--
 
--></td>
 
--></td>
<td width="6%" align="center" {{#switch:{{{default|}}}|2=style="font-weight:bold;"> W|1=>|{{#ifeq:{{{winner|}}}|2|style="font-weight:bold;"}}{{#ifeq:{{{winner|}}}|draw|style="font-weight:bold;"}}>
+
<td width="8%" align="center" {{#switch:{{{default|}}}|2=style="font-weight:bold;"> W|1=> -|{{#ifeq:{{{winner|}}}|2|style="font-weight:bold;"}}{{#ifeq:{{{winner|}}}|draw|style="font-weight:bold;"}}> {{#if:{{{games2|}}}|{{{games2}}}|0}}}}</td>
{{{games2|0}}}}}</td>
+
<td class="matchlistslot" width="42%" {{#ifeq:{{{winner|}}}|2|style="font-weight:bold; background-color:#cfc"}}{{#ifeq:{{{winner|}}}|draw|style="font-weight:bold; background-color:#FFFFBB"}}><!--
<td class="matchlistslot" width="44%" {{#ifeq:{{{winner|}}}|2|style="font-weight:bold; background-color:#dfd"}}{{#ifeq:{{{winner|}}}|draw|style="font-weight:bold; background-color:#ffd"}}><!--
+
-->{{#if:{{{team2|}}}|{{team1/{{lc:{{{team2}}}}}}}}} <!--
--> {{#if:{{{T2|}}}|{{Team1/{{{T2}}}}}}}</td>
+
--> {{#if:{{{team2tf|}}}|{{team1/tf|{{{team2tf}}}}}}}</td>
{{#if:{{{map1|}}} {{{map2|}}} {{{map3|}}} {{{map4|}}} {{{map5|}}} {{{map6|}}} {{{map7|}}} {{{map8|}}} {{{map9|}}} |</tr><tr class="maprow">
+
</tr><!--
<td colspan="4" style="font-size:85%; line-height:130%; text-align:left;">
+
 
{{#if:{{{map1|}}}|{{MapWinner|{{{map1|}}}|{{{map1win|}}}}}}}{{#if:{{{map1score|}}}|<div style="text-align:center;">{{{map1score}}}</div>}}<!--
+
Variables transformations
-->{{#if:{{{map2|}}}|{{MapWinner|{{{map2|}}}|{{{map2win|}}}}}}}{{#if:{{{map2score|}}}|<div style="text-align:center;">{{{map2score}}}</div>}}<!--
+
-->{{#vardefine:team1|{{#if:{{{team1tf|}}}|{{{team1tf|}}}|{{#ifeq:{{{team1|}}}||TBD|{{#ifeq:{{{team1|}}}|&nbsp;|TBD|{{#ifexist:Template:Team/{{{team1|}}}|{{#explode:{{#explode:{{Team/{{{team1|}}}}}|link=|1}}|]]|0}}|{{{team1|}}}}} }}}}}}}}<!--
-->{{#if:{{{map3|}}}|{{MapWinner|{{{map3|}}}|{{{map3win|}}}}}}}{{#if:{{{map3score|}}}|<div style="text-align:center;">{{{map3score}}}</div>}}<!--
+
-->{{#vardefine:team2|{{#if:{{{team2tf|}}}|{{{team2tf|}}}|{{#ifeq:{{{team2|}}}||TBD|{{#ifeq:{{{team2|}}}|&nbsp;|TBD|{{#ifexist:Template:Team/{{{team2|}}}|{{#explode:{{#explode:{{Team/{{{team2|}}}}}|link=|1}}|]]|0}}|{{{team2|}}}}} }}}}}}}}<!--
-->{{#if:{{{map4|}}}|{{MapWinner|{{{map4|}}}|{{{map4win|}}}}}}}{{#if:{{{map4score|}}}|<div style="text-align:center;">{{{map4score}}}</div>}}<!--
+
 
-->{{#if:{{{map5|}}}|{{MapWinner|{{{map5|}}}|{{{map5win|}}}}}}}{{#if:{{{map5score|}}}|<div style="text-align:center;">{{{map5score}}}</div>}}<!--
+
SMW storage
-->{{#if:{{{map6|}}}|{{MapWinner|{{{map6|}}}|{{{map6win|}}}}}}}{{#if:{{{map6score|}}}|<div style="text-align:center;">{{{map6score}}}</div>}}<!--
+
-->{{#subobject:{{#var:team1|TBD}}_vs_{{#var:team2|TBD}}_at_{{#var:Raw_Match_date|TBD}}{{#var:timezone|}}_in_Match_{{#var:match_number|TBD}}
-->{{#if:{{{map7|}}}|{{MapWinner|{{{map7|}}}|{{{map7win|}}}}}}}{{#if:{{{map7score|}}}|<div style="text-align:center;">{{{map7score}}}</div>}}<!--
+
|is map number=1
-->{{#if:{{{map8|}}}|{{MapWinner|{{{map8|}}}|{{{map8win|}}}}}}}{{#if:{{{map8score|}}}|<div style="text-align:center;">{{{map8score}}}</div>}}<!--
+
|has team left={{#var:team1|TBD}}
-->{{#if:{{{map9|}}}|{{MapWinner|{{{map9|}}}|{{{map9win|}}}}}}}{{#if:{{{map9score|}}}|<div style="text-align:center;">{{{map9score}}}</div>}}</td>}}
+
|has team right={{#var:team2|TBD}}
</tr></includeonly><noinclude>{{documentation}}[[Category:Source Liquipedia]]</noinclude>
+
|Has sub={{#var:sub1}}
 +
|Has sub={{#var:sub2}}
 +
|Has sub={{#var:sub3}}
 +
|Has sub={{#var:sub4}}
 +
|Has sub={{#var:sub5}}
 +
|Has replaced={{#var:replaced1|}}
 +
|Has replaced={{#var:replaced2|}}
 +
|Has replaced={{#var:replaced3|}}
 +
|Has replaced={{#var:replaced4|}}
 +
|Has replaced={{#var:replaced5|}}
 +
|Has map date={{#var:Match_date}}{{#var:timezone}}
 +
|Has tournament={{FULLPAGENAME}}
 +
|Has tournament tier={{#var:tournament_tier|}}
 +
|Has match stream={{{stream|{{#var:stream|}}}}}
 +
|Has tournament name={{#var:tournament_ticker_name|{{#var:tournament_name|{{FULLPAGENAME}}}}}}
 +
|Is part of series={{#var:tournament_series|}}
 +
|Has tournament icon={{#var:tournament_icon|}}
 +
|Is finished={{#ifeq:{{#var:finished|}}|true|true|{{#if:{{#var:Match_date|}}|{{#ifexpr:({{#time:U}}-{{#time:U|{{#var:Match_date}}{{#var:timezone}}}}) > 30800|true|false}}|false}}}}
 +
|Has team left score={{{games1|0}}}
 +
|Has team right score={{{games2|0}}}
 +
|Has default={{{default|}}}<!--  
 +
|Has details={{{details|}}} -->
 +
|has exact time={{#if:{{#var:timezone|}}|true|false}}
 +
}}{{#vardefine:games1|0}}{{#vardefine:games2|0}}{{#vardefine:finished|false}}</includeonly><noinclude>{{documentation}}[[Category:Source Liquipedia]]</noinclude>

Latest revision as of 16:48, 5 March 2017

(view - edit) Documentation

This template is used by: