Difference between revisions of "Template:CurrEpNum"

From The Star Wars Minute Wiki
Jump to navigation Jump to search
Line 1: Line 1:
{{#ifexpr:{{#expr:({{LOCALWEEK}}-5)*5+{{#ifexpr:{{LOCALDOW}}=6|5|{{#ifexpr:{{LOCALDOW}}=0|5|{{LOCALDOW}} }} }} }}>152|152|{{#expr:({{LOCALWEEK}}-5)*5+{{#ifexpr:{{LOCALDOW}}=6|5|{{#ifexpr:{{LOCALDOW}}=0|5|{{LOCALDOW}} }} }} }}}}
{{#ifexpr:{{{1}}}=1|122|
  {{#ifexpr:{{{1}}}=2|125|
    {{#ifexpr:{{{1}}}=3|132|
      {{#ifexpr:{{{1}}}=4|137|
        {{#ifexpr:{{{1}}}=5|143|
          {{#ifexpr:{{{1}}}=6|141|
            {{#ifexpr:{{{1}}}=7|139|
              {{#ifexpr:{{{1}}}=8|134|
                {{#ifexpr:{{{1}}}=9|152|{{#expr: {{{LOCALWEEK}}}*7+{{LOCALDOW}}-{{{2}}}*)7-{{{3}}})}}
<noinclude>
Calculates the latest episode number given the season of the show you're interested int.
 
Inputs:
1=Season of the show
2=Start week of current season
3=Start date of current season[[Category:Wiki]]</noinclude>

Revision as of 10:04, 6 January 2022

{{#ifexpr:{{{1}}}=1|122|

 {{#ifexpr:{{{1}}}=2|125|
   {{#ifexpr:{{{1}}}=3|132|
     {{#ifexpr:{{{1}}}=4|137|
       {{#ifexpr:{{{1}}}=5|143|
         {{#ifexpr:{{{1}}}=6|141|
           {{#ifexpr:{{{1}}}=7|139|
             {{#ifexpr:{{{1}}}=8|134|
               {{#ifexpr:{{{1}}}=9|152|Expression error: Unrecognized punctuation character "{".

Calculates the latest episode number given the season of the show you're interested int.

Inputs: 1=Season of the show 2=Start week of current season 3=Start date of current season