Difference between revisions of "ConvertRating/Single"

From Sega Retro

Line 21: Line 21:
  
 
|0-6={{#vardefine:displayRating|{{#var:value}}/6}}{{#vardefine:score|{{#expr:{{#var:value}}*(100/6)}}}}
 
|0-6={{#vardefine:displayRating|{{#var:value}}/6}}{{#vardefine:score|{{#expr:{{#var:value}}*(100/6)}}}}
 +
 +
|1-6={{#vardefine:displayRating|{{#var:value}}/6}}{{#vardefine:score|{{#expr:({{#var:value}}-1)*20}}}}
  
 
|0-7={{#vardefine:displayRating|{{#var:value}}/7}}{{#vardefine:score|{{#expr:{{#var:value}}*(100/7)}}}}
 
|0-7={{#vardefine:displayRating|{{#var:value}}/7}}{{#vardefine:score|{{#expr:{{#var:value}}*(100/7)}}}}

Revision as of 07:35, 14 June 2020

Rating conversion code for when there's only one value - stops Mediawiki from complaining about recursion.