-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsettings.py
42 lines (34 loc) · 1.72 KB
/
settings.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
" Settings for the AI-Mario-Party project."
from typing import List
from pydantic_settings import BaseSettings
class Settings(BaseSettings):
"""Base Settings for configuring the AI-Mario-Party project.
To configure the settings in this project the [BaseSettings class from
pydantic is used](https://docs.pydantic.dev/usage/settings/).
This class will read the environment variables and will validate them.
!!! Abstract "Environment Variables to configure the project."
The following table shows the environment variables that
can be used to configure the project:
| Environment Variable | Description | Default |
|----------------------|-------------| ------- |
| SECONDARY_DISPLAY| If there are two screens, this variable must \
be set to True. | False |
| MAIN_SCREEN | Main screen location on the total screen. [TL_x, TL_y, w, h] \
| [ 0, 0, 1920, 1080 ] |
| MAIN_SCREEN_SCALE | Scale of the main screen. | 1.0 |
| SUB_SCREEN | Secondary screen location on the total screen. \
[TL_x, TL_y, w, h]. If there is no second screen, leave its \
default value. | [ 1920, 1080, 1920, 1080 ] |
| SUB_SCREEN_SCALE | Scale of the second screen. If there is no second \
screen, leave its default value. | 1.0 |
| DS_WIDTH | Width of the standard DS screen. | 256 |
| DS_HEIGHT | Height of the standard DS screen. | 192 |
"""
SECONDARY_DISPLAY: bool = False
MAIN_SCREEN: List = [0, 0, 1920, 1080]
MAIN_SCREEN_SCALE: float = 1.0
SUB_SCREEN: List = [1920, 0, 1920, 1080]
SUB_SCREEN_SCALE: int = 1.0
DS_WIDTH: int = 256
DS_HEIGHT: int = 192
settings = Settings()