lundi 5 octobre 2020

I want to figure out how to add a result in the end, how should I go about it?

I want it to be that if the player roles a dice, there is a certian reaction, I was thinking about it being like if(x>=4 and x<=6): print("Player1 wounds another player, eliminating one more person in THE THUNDERDOME")

 #This is the program I have so far
    #5 if statments or more, use at least one a"nd" or "or" (Elif and else statments will not count)
    
    print("__________________________")
    print("WELCOME TO THE THUNDERDOME")
    print("__________________________ \n")
    
    n1 = input("Enter player 1 name: ")
    n2 = input("Enter player 2 name: ")
    n3 = ("Oliver Sanchez")
    n4 = ("Lily Stones")
    n5 = ("Peter Piper")
    n6 = ("Dylan Sky")
    n7 = ("Kathy Evans")
    n8 = ("Eric Lovelace")
    n9 = ("Eva Hart")
    n10 = ("Bella Gabreilla")
    n11 = ("Cassi Haul")
    n12 = ("Lane Davidson")
    print("Group One")
    print(n1 + ", " + n2)
    print("Group Two")
    print(n3 + ", " + n4)
    print("Group Three")
    print(n5 + ", " + n6)
    print("Group Four")
    print(n7 + ", " + n8)
    print("Group Five")
    print(n9 + ", " + n10)
    print("Group Six")
    print(n11 + ", " + n12)
    
    # this peice is supposed to have player1 either role a dice, or skip
    
    import random
    yn = input("Player 1 role a dice for your move? YES/NO ")
    x = random.randint(1,6)
    if(yn == "YES"):
        print("Player 1 roles a dice: " + str(x))
    if(yn == "NO"):
        print(n1 + " hides in the trees for a day.")
        
    # the rest of the program is yet to be written 

Aucun commentaire:

Enregistrer un commentaire