Update browser.py

This commit is contained in:
Vishal 2024-01-11 22:33:03 +05:30 committed by GitHub
parent 203f659aac
commit 7b2879275e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -501,7 +501,7 @@ class CoopBrowserWindow(bui.Window):
def _set_campaign_difficulty( def _set_campaign_difficulty(
self, self,
difficulty: str, difficulty: str,
check: bool | True check: bool
) -> None: ) -> None:
# pylint: disable=cyclic-import # pylint: disable=cyclic-import
from bauiv1lib.purchase import PurchaseWindow from bauiv1lib.purchase import PurchaseWindow
@ -519,8 +519,7 @@ class CoopBrowserWindow(bui.Window):
if check: if check:
PurchaseWindow(items=['pro']) PurchaseWindow(items=['pro'])
return return
else: difficulty = 'easy'
difficulty = 'easy'
bui.getsound('gunCocking').play() bui.getsound('gunCocking').play()
if difficulty not in ('easy', 'hard'): if difficulty not in ('easy', 'hard'):
print('ERROR: invalid campaign difficulty:', difficulty) print('ERROR: invalid campaign difficulty:', difficulty)