def main():

    print_banner()

    user_name = input_name()

    if 'Q' == user_name:
        return

    welcome(user_name)

    while True:
        sel = load_game()
        if '1' == sel:
            g1()
        elif '2' == sel:
            g2()
        elif '3' == sel:
            g3()
        elif '3' == sel:
            return
        elif 'Q' == sel:
            return
Beispiel #2
0
def main():
    screen_cleaner()

    print(f"""
    Welcome to the
    
 _       __           __    __         ____                                  
| |     / /___  _____/ /___/ /  ____  / __/  ____ _____ _____ ___  ___  _____
| | /| / / __ \/ ___/ / __  /  / __ \/ /_   / __ `/ __ `/ __ `__ \/ _ \/ ___/
| |/ |/ / /_/ / /  / / /_/ /  / /_/ / __/  / /_/ / /_/ / / / / / /  __(__  ) 
|__/|__/\____/_/  /_/\__,_/   \____/_/     \__, /\__,_/_/ /_/ /_/\___/____/  
                                          /____/
""")
    print(welcome("Tsahhi"))
    go_for_play = True
    while go_for_play:
        game_index, difficulty = load_game()
        if game_index == 1:
            game_to_play = MemoryGame
        elif game_index == 2:
            game_to_play = GuessGame
        else:
            game_to_play = CurrencyRouletteGame

        won_the_game = game_to_play(difficulty).play()

        if won_the_game:
            add_score(difficulty)
            print("Way to go, you winner! dare for another round?")
        else:
            print("Better luck next time- want to take this time right now?")
        continue_str = "Please enter Y or N: "
        should_continue = input(continue_str).lower().strip()
        valid_options = ['y', 'n']
        while should_continue not in valid_options:
            should_continue = input(continue_str).lower().strip()
        go_for_play = should_continue == 'y'

    print("Thank you for playing in the World of Games!")
Beispiel #3
0
class MainGame:
    welcome(name=input("Please Enter You Name:" + "\n"))

    game_number = load_game()

    difficulty = choose_level()

    if int(game_number) == 1:
        MemoryGame.play(difficulty)

    elif int(game_number) == 2:
        GuessGame.play(difficulty)

    elif int(game_number) == 3:
        CurrencyRouletteGame.play(difficulty)

#print result and add score
    if status:
        add_score(game_difficulty, user_name)
        print("Great job , you won")
    else:
        print("You lost , try again")

    p_continue = input("do you want to play again y or n ?")
Beispiel #4
0
from Live import welcome, load_game, difficulty

print(welcome('Evgeny'))
print('\n')
print(load_game())
print('\n')
print(difficulty())

Beispiel #5
0
def main():
    print(welcome("Player"))
    load_game()
Beispiel #6
0
from Live import load_game, welcome
from colorama import init

init()  # colors for prints (Mandatory!!)

print(welcome("ishai")[0])
print(welcome("ishai")[1])
try:
    load_game()

except ValueError:
    print("please enter a valid number")
Beispiel #7
0
from Live import load_game, welcome

# Start the game.
welcome("Yahel")
load_game()
Beispiel #8
0
def main():
    print(welcome('Guy'))
    while True:
        load_game()
Beispiel #9
0
from Live import load_game,welcome

# starts the game process
print(welcome("Eldad"))
load_game()

Beispiel #10
0
from Live import load_game, welcome
print(welcome())
load_game()
Beispiel #11
0
from Live import load_game, welcome,choose_level
from GuessGame import ggplay
from MemoryGame import mgplay
from CurrencyRouletteGame import crgpaly
from Utils import Screen_cleaner
from Score import add_score

p_continue = 'y'
user_name = "asa" #input('insert your name:')

while p_continue == 'y':
    Screen_cleaner()
    print(welcome(user_name))
    #get game number and level
    game_number = load_game()
    game_difficulty = choose_level()


    if int(game_number)==1:
        status = ggplay(game_difficulty)
    elif int(game_number)==2:
        status = mgplay(game_difficulty)
    elif int(game_number)==3:
        status = crgpaly(game_difficulty)

    #print result and add score
    if status:
        add_score(game_difficulty,user_name)
        print("Great job , you won")
    else:
        print("You lost , try again")
Beispiel #12
0
from Live import welcome, load_game, level
from Utils import score_file_name
from e2e import main_function
import time

user_continue = 'y'
while user_continue == 'y':

    welcome()
    game_num = load_game()
    level(game_num)
    score_file_name()
    main_function()
    user_continue = input("Do you want to continue? y/n: ")
    if user_continue != 'y':
        print("Thank you for playing World of Games")
        time.sleep(3)
        exit(1)
Beispiel #13
0
# Include necessary modules and functions.
from Live import load_game, welcome
from Utils import screen_cleaner
from MainScores import score_server
import Score

# initialize Scores.txt to 0
Score.initialize_score(0)

# Clear the screen
screen_cleaner()
# Ask for player name (mandatory)
player_name = input("Please enter your name: ")

# Welcome message and games choice
print(welcome(player_name))
load_game()
score_server()

from Live import load_game, welcome

print(welcome("Appel Eran"))
load_game()
Beispiel #15
0
# This function run the program
from Live import welcome, load_game

print(welcome(input("Please enter your name : ")))
load_game()
Beispiel #16
0
def main():
    name = input("Welcome, please enter your name: ")
    print("\n" + welcome(name))
    load_game()
Beispiel #17
0
# MainGame.py

from Live import load_game, welcome
from Utils import screen_cleaner
from MainScores import score_server

gamer_name = str(input("Please enter your name: "))
screen_cleaner()
print(welcome(gamer_name))
load_game()
score_server()
Beispiel #18
0
from Live import load_game, welcome

print(welcome('Hodaya'))
load_game()
Beispiel #19
0
from Live import welcome, load_game

print(welcome(str(input("Enter your name: "))))
load_game()
Beispiel #20
0
# The purpose of this file is to call the functions from Live.py

from Live import welcome, load_game

#Calling starting functions welcome & load_game to start the game

name = input("What's your name? \n")
welcome(name)
result = 0
#Looping the load game in case of player's game over with loss.
while result == 0:
    result = load_game()



from Live import load_game , welcome

welcome('guy')
load_game()
Beispiel #22
0
from Live import load_game, welcome

print(welcome(name="Guy"))
load_game()
Beispiel #23
0
from Live import load_game, welcome
global difficulty
# difficulty = 0
print(welcome("Guy"))
load_game()
Beispiel #24
0
from Live import load_game, welcome

print(welcome("Daniel"))
load_game()
Beispiel #25
0
from Live import load_game, welcome

name = input("please enter your name: ")

print(welcome(name))

load_game()
Beispiel #26
0
def MainGame():
    name = str(input('give a name'))
    welcome(name)
Beispiel #27
0
from Live import welcome, load_game
from Score import add_score

print(welcome("Adi"))
game, level = load_game()

if game == 1:
    import MemoryGame

    game_res = MemoryGame.play(level)

    if game_res == True:
        add_score(points=level)
        print("You Won")
    else:
        print("You Lost")

elif game == 2:
    import GuessGame
    game_res = GuessGame.play(level)

    if game_res == True:
        add_score(points=level)
        print("You Won")
    else:
        print("You Lost")
Beispiel #28
0
import time
import os
from Live import load_game, welcome
from Score import create_score_file
create_score_file()
input_name = input('Enter yor name here: ')
start_over = 0

while start_over != str("exit"):
    time.sleep(2)
    os.system('cls')
    welcome(input_name)
    time.sleep(2)
    load_game()
    start_over = input('\n' + '\n' +
                       'Press Enter to start over or "exit" to Exit: ')
Beispiel #29
0
from Live import welcome, load_game
from GuessGame import GuessGame
from MemoryGame import MemoryGame
from CurrencyRouletteGame import CurrencyRouletteGame

welcome("Saggie")
gameNumber, gameDifficulty = load_game()

if gameNumber == 1:
    game = MemoryGame(gameDifficulty)
    game.play()
elif gameNumber == 2:
    game = GuessGame(gameDifficulty)
    game.play()
elif gameNumber == 3:
    game = CurrencyRouletteGame(gameDifficulty)
    game.play()
Beispiel #30
0
from Live import load_game, welcome
from Utils import screen_cleaner
from Utils import run_flask

screen_cleaner()  # Clean screen on new game
print(welcome("Ziv"))
load_game()
# run_flask()  # Rise web server to show game scores