import random import time Hp = 2000 Baddy = 4000 def ELevel() : EnemyLevel = random.randint(1,5) return EnemyLevel def EAttack(EnemLevel) : EnemyAttack = random.randint(20,400) * EnemLevel / 1.5 return EnemyAttack def Heavy() : HeavyAttack = random.randint(100,999) print(" ") print(" -- Used Heavy -- ") return HeavyAttack def Light() : LightAttack = random.randint(350,500) print(" ") print(" -- Used Light -- ") return LightAttack def Heal() : Healing = random.randint(200,500) print(" ") print(" -- You Healed -- ") return Healing Badguylevel = ELevel() for i in range(1,4) : print("Make sure to type in lowercase!!!!!!!") print(" ") time.sleep(1.5) print("You incounter a level ", "- ", Badguylevel, " -"," crimanal") def Main(Hp, bad) : while True : Damage = EAttack(Badguylevel) print(" ") print("-- He attacked you! --") print("You took ", int(Damage), " damage -- you have ", (Hp - int(Damage)), "Hp remaining") print(" ") Hp -= int(Damage) if Hp < 1 : print(" ") print(" -- You DIED -- ") break print(" -- What attack do you do in return? -- ") SelectAttack = input("Heavy, Light, Heal -- ") print("") print("You inputed -- ", SelectAttack) if SelectAttack == "Heavy".casefold() : Attack = Heavy() print(" ") print(" -- Your Attack Did ", int(Attack), " Damage -- ") print(" ") print(" -- Bad guy has", (bad - int(Attack)), " Hp remaining -- ") bad -= int(Attack) elif SelectAttack == "Light".casefold() : LAttack = Light() print(" ") print(" -- Your Attack Did ", int(LAttack), " Damage -- ") print(" ") print(" -- Bad guy has", (bad - int(LAttack)), " Hp remaining -- ") bad -= int(LAttack) elif SelectAttack == "Heal".casefold() : HpIncrease = Heal() print(" ") print(" -- You healed yourself ", int(HpIncrease) ," -- ") print(" ") print(" -- You have", (Hp + int(HpIncrease)), " Hp remaining -- ") Hp += int(HpIncrease) if __name__ == "__main__" : Main(Hp, Baddy)