Store game edition and game expansion info in auxiliary file instead of hardcoding it #1314
Labels
area: assets
Involved with assets (images, sounds, ...)
good first issue
Suitable for newcomers
hacktoberfest
For newcomers from Hacktoberfest event
improvement
Enhancement of an existing component
lang: python
Done in Python code
Projects
Required skills: Python
Difficulty: Easy
openage currently stores information about a game edition or expansion inside an
Enum
, e.g. media paths, support status, etc. We should store this information in an auxiliary file instead, similar to #1312. That would make updating and correcting game information easier as we no longer have to replace chunks of code.The recommended approach is to transfer the information from the existing implementation into a simple data definition file format. TOML is prefered because we already use that elsewhere in the converter.
Example:
Since we cannot use Enums when we read the game versions from file, we would have to replace identity checks of the game version
Enum
value with an ID check. These checks happen when reading the.dat
format or in the service that acquires nyan object names. They should be easy to replace.Further Reading
The text was updated successfully, but these errors were encountered: