async def interface():
global game_running
try:
while game_running:
os.system("cls")
print(f"I-------------------------------------I")
print(f"I Сырье\tI\t{resoucres["сырье"]}I")
print(f"I Сырье\tI\t{resoucres["детали"]}I")
print(f"I Сырье\tI\t{resoucres["деньги"]}I")
print(f"I-------------------------------------I")
await asyncio.sleep(0.1)
except asyncio.CancelledError:
pass
async def main():
try:
await asyncio.gather(
raw_material(),
item_assemble(),
seller(),
interface(),
)
except KeyboardInterrupt:
global game_running
game_running = False
print("Конец игры")
if __name__ == "__main__":
asyncio.run(main())