Difference between revisions of "ConvertRating"
From Sega Retro
Line 68: | Line 68: | ||
|gamepro={{ConvertRating/GamePro|{{#var:value}}}} | |gamepro={{ConvertRating/GamePro|{{#var:value}}}} | ||
+ | |||
+ | |german={{#switch:{{#var:value}} | ||
+ | |1+={{#vardefine:displayRating|1+}}{{#vardefine:score|100}} | ||
+ | |1={{#vardefine:displayRating|1}}{{#vardefine:score|{{#expr:(4/15) * 100}}}} | ||
+ | |1-={{#vardefine:displayRating|1-}}{{#vardefine:score|{{#expr:(13/15) * 100}}}} | ||
+ | |2+={{#vardefine:displayRating|2+}}{{#vardefine:score|80}} | ||
+ | |2={{#vardefine:displayRating|2}}{{#vardefine:score|{{#expr:(11/15) * 100}}}} | ||
+ | |2-={{#vardefine:displayRating|2-}}{{#vardefine:score|{{#expr:(10/15) * 100}}}} | ||
+ | |3+={{#vardefine:displayRating|3+}}{{#vardefine:score|60}} | ||
+ | |3={{#vardefine:displayRating|3}}{{#vardefine:score|{{#expr:(8/15) * 100}}}} | ||
+ | |3-={{#vardefine:displayRating|3-}}{{#vardefine:score|{{#expr:(7/15) * 100}}}} | ||
+ | |4+={{#vardefine:displayRating|4+}}{{#vardefine:score|40}} | ||
+ | |4={{#vardefine:displayRating|4}}{{#vardefine:score|{{#expr:(5/15) * 100}}}} | ||
+ | |4-={{#vardefine:displayRating|4-}}{{#vardefine:score|{{#expr:(4/15) * 100}}}} | ||
+ | |5+={{#vardefine:displayRating|5+}}{{#vardefine:score|20}} | ||
+ | |5={{#vardefine:displayRating|5}}{{#vardefine:score|{{#expr:(2/15) * 100}}}} | ||
+ | |5-={{#vardefine:displayRating|5-}}{{#vardefine:score|{{#expr:(1/15) * 100}}}} | ||
+ | |6={{#vardefine:displayRating|6}}{{#vardefine:score|0}} | ||
+ | |#default={{#vardefine:displayRating|Unknown value!}}{{#vardefine:score|}} | ||
+ | }} | ||
|#default={{#vardefine:displayRating|Unknown system! ("{{#var:system}}")}}{{#vardefine:score|}} | |#default={{#vardefine:displayRating|Unknown system! ("{{#var:system}}")}}{{#vardefine:score|}} |
Revision as of 14:10, 22 April 2020
This task is unfinished This is a wiki task that requires more thought or peer review. An important issue that needs to be solved, which will appear at the top of Sega Retro:Todo until this message is removed. |
A template for converting a rating, as printed in a magazine into:
- something nice to display ({{#var:displayRating}})
- a value out of 100 for use in Sega Retro averages ({{#var:score}})
it should be able to detect if a given value is invalid. Some magazines could be using multiple systems depending on context.
The user should not be expected to calculate anything.
TODO: multiple instances of the above (e.g. support "1,2,3,4" for EGM)
added text. e.g. later issues of the UK Official Dreamcast magazine, 7 = "good".
Working values
0-4s
Input | Display | Score |
---|---|---|
0 | 0 | |
1 | 25 | |
2 | 50 | |
3 | 75 | |
4 | 100 |
1-5s
Input | Display | Score |
---|---|---|
1 | 0 | |
2.5 | 37.5 | |
3 | 50 | |
4.5 | 87.5 | |
5 | 100 |
1-10
Input | Display | Score |
---|---|---|
1 | 1/10 | 0 |
2.5 | 2.5/10 | 16.666666666667 |
4 | 4/10 | 33.333333333333 |
7.5 | 7.5/10 | 72.222222222222 |
10 | 10/10 | 100 |
A-F
Input | Display | Score |
---|---|---|
A | A | 100 |
B | B | 75 |
C | C | 50 |
D | D | 25 |
F | F | 0 |
GamePro
Input | Display | Score | ||||
---|---|---|---|---|---|---|
1,2,3,4,5 |
| |||||
1,2,3,4,adj |
|