Skip to content

Commit

Permalink
polished things up again
Browse files Browse the repository at this point in the history
  • Loading branch information
ganelonhb committed Jan 7, 2024
1 parent 0d16631 commit 8ecb735
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
7 changes: 5 additions & 2 deletions gamedata/invaders.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ def main():

if f'--{line_tuple[0].strip()}' not in raw_args:
try:
typecast = type(var_args[line_tuple[0].strip()])
typecast = type(var_args[line_tuple[0].strip()]) if var_args[line_tuple[0].strip()] is not None else str
lt_strplo = None if typecast is not bool else line_tuple[1].strip().lower()

skip = typecast is list
Expand All @@ -212,7 +212,10 @@ def main():

val = typecast(line_tuple[1])
else:
val = typecast(line_tuple[1].strip())
if typecast is None:
val = str(line_tuple[1].strip())
else:
val = typecast(line_tuple[1].strip())

if not skip:
var_args[line_tuple[0].strip()] = val
Expand Down
2 changes: 1 addition & 1 deletion gamedata/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

setup(
name="invaderclone",
version="0.9.3",
version="0.9.4",
python_requires=">=3.5.0",
description="A module Space Invaders clone in Python Pygame",
long_description=DESCRIPTION,
Expand Down

0 comments on commit 8ecb735

Please sign in to comment.