Mods
This commit is contained in:
parent
61403f0419
commit
8b96769a6b
|
@ -6,8 +6,9 @@ import appdirs # type: ignore
|
||||||
|
|
||||||
|
|
||||||
class Config:
|
class Config:
|
||||||
title: str = "Cromulant"
|
program: str
|
||||||
program: str = "cromulant"
|
title: str
|
||||||
|
version: str
|
||||||
width: int = 820
|
width: int = 820
|
||||||
height: int = 900
|
height: int = 900
|
||||||
here: Path
|
here: Path
|
||||||
|
@ -93,3 +94,6 @@ class Config:
|
||||||
Config.logo_path = Config.here / "img" / "logo_3.jpg"
|
Config.logo_path = Config.here / "img" / "logo_3.jpg"
|
||||||
|
|
||||||
Config.manifest = Storage.get_manifest()
|
Config.manifest = Storage.get_manifest()
|
||||||
|
Config.title = Config.manifest["title"]
|
||||||
|
Config.program = Config.manifest["program"]
|
||||||
|
Config.version = Config.manifest["version"]
|
||||||
|
|
|
@ -430,8 +430,9 @@ class Game:
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def intro() -> None:
|
def intro() -> None:
|
||||||
version = Config.manifest["version"]
|
title = Config.title
|
||||||
Game.message(f"Welcome to Cromulant v{version}")
|
version = Config.version
|
||||||
|
Game.message(f"Welcome to {title} v{version}")
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def menu() -> None:
|
def menu() -> None:
|
||||||
|
@ -520,7 +521,7 @@ class Game:
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def about() -> None:
|
def about() -> None:
|
||||||
lines = [
|
lines = [
|
||||||
f"Cromulant v{Config.manifest["version"]} {Config.ant}",
|
f"{Config.title} v{Config.version} {Config.ant}",
|
||||||
"Listen to the ants and watch them go.",
|
"Listen to the ants and watch them go.",
|
||||||
"Just run it and leave it open on your screen.",
|
"Just run it and leave it open on your screen.",
|
||||||
"5% of revenue goes to the local ant shelter.",
|
"5% of revenue goes to the local ant shelter.",
|
||||||
|
|
|
@ -18,8 +18,8 @@ from .filter import Filter
|
||||||
def main() -> None:
|
def main() -> None:
|
||||||
Config.prepare()
|
Config.prepare()
|
||||||
|
|
||||||
program = Config.manifest["program"]
|
program = Config.program
|
||||||
title = Config.manifest["title"]
|
title = Config.title
|
||||||
|
|
||||||
pid = f"{program}.pid"
|
pid = f"{program}.pid"
|
||||||
pid_file = Path(tempfile.gettempdir(), pid)
|
pid_file = Path(tempfile.gettempdir(), pid)
|
||||||
|
|
Loading…
Reference in New Issue