summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Game Test.py1053
-rw-r--r--castle1.gifbin0 -> 274812 bytes
-rw-r--r--cave1.gifbin0 -> 73550 bytes
-rw-r--r--cave2.gifbin0 -> 79223 bytes
-rw-r--r--cave3.gifbin0 -> 60235 bytes
-rw-r--r--cave_enternace.gifbin0 -> 245898 bytes
-rw-r--r--cave_exit.gifbin0 -> 94032 bytes
-rw-r--r--chest1.gifbin0 -> 1401 bytes
-rw-r--r--chest2.gifbin0 -> 1463 bytes
-rw-r--r--d_sword.gifbin0 -> 4998 bytes
-rw-r--r--d_sword2.gifbin0 -> 7481 bytes
-rw-r--r--d_sword_icon.gifbin0 -> 1217 bytes
-rw-r--r--forest1.gifbin0 -> 256312 bytes
-rw-r--r--forest2.gifbin0 -> 247560 bytes
-rw-r--r--forest3.gifbin0 -> 263212 bytes
-rw-r--r--forest4.gifbin0 -> 258816 bytes
-rw-r--r--forest5.gifbin0 -> 254847 bytes
-rw-r--r--forest6.gifbin0 -> 258935 bytes
-rw-r--r--forest7.gifbin0 -> 247677 bytes
-rw-r--r--forest8.gifbin0 -> 249470 bytes
-rw-r--r--heal_potion_icon.gifbin0 -> 1370 bytes
-rw-r--r--menu1.gifbin0 -> 46545 bytes
-rw-r--r--menu2.gifbin0 -> 48953 bytes
-rw-r--r--sack.gifbin0 -> 1001 bytes
-rw-r--r--sword.gifbin0 -> 4921 bytes
-rw-r--r--sword2.gifbin0 -> 7730 bytes
-rw-r--r--towel_icon.gifbin0 -> 1353 bytes
27 files changed, 1053 insertions, 0 deletions
diff --git a/Game Test.py b/Game Test.py
new file mode 100644
index 0000000..a03ce50
--- /dev/null
+++ b/Game Test.py
@@ -0,0 +1,1053 @@
+import turtle
+import time
+import random
+
+window = turtle.Screen()
+window.setup(1280, 720)
+window.bgcolor("black")
+window.title("Rise of Todmoldren [BETA]")
+
+window.register_shape("forest1.gif")
+window.register_shape("forest2.gif")
+window.register_shape("forest3.gif")
+window.register_shape("forest4.gif")
+window.register_shape("forest5.gif")
+window.register_shape("forest6.gif")
+window.register_shape("forest7.gif")
+window.register_shape("forest8.gif")
+
+window.register_shape("sword.gif")
+window.register_shape("sword2.gif")
+
+window.register_shape("d_sword.gif")
+window.register_shape("d_sword2.gif")
+
+window.register_shape("heal_potion_icon.gif")
+window.register_shape("towel_icon.gif")
+window.register_shape("d_sword_icon.gif")
+
+window.register_shape("sack.gif")
+
+window.register_shape("chest1.gif")
+window.register_shape("chest2.gif")
+
+window.register_shape("castle1.gif")
+
+window.register_shape("cave_enternace.gif")
+window.register_shape("cave1.gif")
+window.register_shape("cave2.gif")
+window.register_shape("cave3.gif")
+window.register_shape("cave_exit.gif")
+
+window.register_shape("menu1.gif")
+window.register_shape("menu2.gif")
+
+window.bgpic("menu2.gif")
+
+hp = 100
+
+xp = 0
+
+level = 1
+
+levelAttack = 0
+
+hpE = 10
+hpE2 = 15
+
+hPotion = 3
+
+money = 0
+
+alive = False
+
+characters = True
+
+towel = False
+d_Sword = False
+
+Market = False
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+loader = turtle.Turtle()
+loader.hideturtle()
+loader.penup()
+
+player = turtle.Turtle()
+player.hideturtle()
+player.speed(10)
+player.penup()
+player.hideturtle()
+player.speed(10)
+
+Pick = turtle.Turtle()
+Pick.hideturtle()
+Pick.penup()
+Pick.speed(10)
+Pick.goto(0, 0)
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+def start():
+ player.forward(10)
+
+turtle.listen()
+turtle.onkey(start, "")
+
+while characters == True:
+
+ loader.forward(1)
+ if abs(player.pos() - Pick.pos()) > 5:
+ characters = False
+ else:
+ time.sleep(0.5)
+
+
+alive = True
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+window.bgpic("forest1.gif")
+
+up = True
+right = True
+left = True
+cave = False
+hrad = False
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+hpU = turtle.Turtle()
+hpU.speed(10)
+hpU.hideturtle()
+hpU.pu()
+hpU.turtlesize
+hpU.color("red")
+hpU.goto(-625, -350)
+hpU.write(hp, font=("Impact", 60, "normal"))
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+ #GUI
+
+
+sword = turtle.Turtle()
+sword.speed(10)
+sword.penup()
+sword.hideturtle()
+sword.shape("sword.gif")
+sword.goto(500, -225)
+sword.showturtle()
+
+healPotion = turtle.Turtle()
+healPotion.hideturtle()
+healPotion.speed(10)
+healPotion.penup()
+healPotion.shape("heal_potion_icon.gif")
+healPotion.color("red")
+healPotion.turtlesize(3)
+healPotion.goto(0, -275)
+healPotion.showturtle()
+
+healPotionNumber = turtle.Turtle()
+healPotionNumber.speed(10)
+healPotionNumber.penup()
+healPotionNumber.hideturtle()
+healPotionNumber.color("white")
+healPotionNumber.goto(-10, -350)
+healPotionNumber.write(hPotion, font=("Impact", 25, "normal"))
+
+
+
+coin = turtle.Turtle()
+coin.speed(10)
+coin.penup()
+coin.hideturtle()
+coin.shape("sack.gif")
+coin.turtlesize(1)
+coin.goto(-615, -240)
+coin.showturtle()
+
+coinNumber = turtle.Turtle()
+coinNumber.speed(10)
+coinNumber.penup()
+coinNumber.hideturtle()
+coinNumber.color("yellow")
+coinNumber.goto(-590, -260)
+coinNumber.write(money, font=("Impact", 25, "normal"))
+
+xpNumber = turtle.Turtle()
+xpNumber.speed(10)
+xpNumber.penup()
+xpNumber.hideturtle()
+xpNumber.color("green")
+xpNumber.goto(-500, -260)
+xpNumber.write(xp, font=("Impact", 25, "normal"))
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+enemy = turtle.Turtle()
+enemy.speed(10)
+enemy.shape("circle")
+enemy.color("green")
+enemy.hideturtle()
+enemy.penup()
+enemy.turtlesize(6)
+
+enemyD = turtle.Turtle()
+enemyD.speed(10)
+enemyD.hideturtle()
+enemyD.penup()
+
+enemyHP = turtle.Turtle()
+enemyHP.speed(10)
+enemyHP.hideturtle()
+enemyHP.color("red")
+enemyHP.penup()
+enemyHP.goto(0, -100)
+enemyHP.clear()
+enemyHP.write(hpE, font=("Impact", 25, "normal"))
+enemyHP.clear()
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+chest = turtle.Turtle()
+chest.speed(10)
+chest.hideturtle()
+chest.shape("chest1.gif")
+chest.penup()
+
+chestCheck = turtle.Turtle()
+chestCheck.speed(10)
+chestCheck.hideturtle()
+chestCheck.penup()
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+sword_i = turtle.Turtle()
+sword_i.penup()
+sword_i.hideturtle()
+sword_i.shape("d_sword_icon.gif")
+sword_i.goto(0, 75)
+
+towel_i = turtle.Turtle()
+towel_i.penup()
+towel_i.hideturtle()
+towel_i.shape("towel_icon.gif")
+towel_i.hideturtle()
+towel_i.goto(150, 75)
+
+potion_i = turtle.Turtle()
+potion_i.penup()
+potion_i.hideturtle()
+potion_i.shape("heal_potion_icon.gif")
+potion_i.goto(-150, 75)
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+#up = turtle.Turtle()
+#up.color("white")
+#up.hideturtle()
+#up.penup()
+#up.setheading(90)
+#up.shape("square")
+#up.goto(0, 800)
+#up.turtlesize(50)
+
+#right = turtle.Turtle()
+#right.color("white")
+#right.hideturtle()
+#right.penup()
+#right.setheading(90)
+#right.shape("square")
+#right.goto(800, 0)
+#right.turtlesize(25)
+
+#left = turtle.Turtle()
+#left.color("white")
+#left.hideturtle()
+#left.penup()
+#left.setheading(90)
+#left.shape("square")
+#left.goto(-800, 0)
+#left.turtlesize(25)
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+check = turtle.Turtle()
+check.hideturtle()
+check.penup()
+check.goto(0, 0)
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+def dev_cords(x, y):
+ player.goto(x, y)
+ print(player.pos())
+
+def action(x, y):
+ player.goto(x, y)
+
+def attack(x, y):
+ player.goto(x, y)
+ if d_Sword == True:
+ sword.shape("d_sword2.gif")
+ if d_Sword == False:
+ sword.shape("sword2.gif")
+ player.goto(0, 0)
+ enemyD.forward(10)
+
+def open_chest(x, y):
+ player.goto(x, y)
+ player.goto(0, 0)
+ chest.shape("chest2.gif")
+ chestCheck.forward(10)
+
+
+#########################################################################################################################
+
+
+
+#########################################################################################################################
+
+while alive == True:
+ if xp >= 50 and level == 1:
+ xp = xp - 50
+
+ level = 2
+
+ xpNumber.clear()
+ xpNumber.write("Level Up!", font=("Impact", 25, "normal"))
+ time.sleep(2)
+ xpNumber.clear()
+ xpNumber.write(xp, font=("Impact", 25, "normal"))
+
+ levelAttack = levelAttack + 1
+
+ if xp >= 100 and level == 2:
+ xp = xp - 100
+
+ level = 3
+
+ xpNumber.clear()
+ xpNumber.write("Level Up!", font=("Impact", 25, "normal"))
+ time.sleep(2)
+ xpNumber.clear()
+ xpNumber.write(xp, font=("Impact", 25, "normal"))
+
+ levelAttack = levelAttack + 1
+
+ if xp >= 150 and level == 3:
+ xp = xp - 150
+
+ level = 4
+
+ xpNumber.clear()
+ xpNumber.write("Level Up!", font=("Impact", 25, "normal"))
+ time.sleep(2)
+ xpNumber.clear()
+ xpNumber.write(xp, font=("Impact", 25, "normal"))
+
+ levelAttack = levelAttack + 1
+
+ if xp >= 200 and level == 4:
+ xp = xp - 200
+
+ level = 5
+
+ xpNumber.clear()
+ xpNumber.write("Level Up!", font=("Impact", 25, "normal"))
+ time.sleep(2)
+ xpNumber.clear()
+ xpNumber.write(xp, font=("Impact", 25, "normal"))
+
+ levelAttack = levelAttack + 1
+
+ if xp >= 250 and level == 5:
+ xp = xp - 250
+
+ level = 5
+
+ xpNumber.clear()
+ xpNumber.write("Level Up!", font=("Impact", 25, "normal"))
+ time.sleep(2)
+ xpNumber.clear()
+ xpNumber.write(xp, font=("Impact", 25, "normal"))
+
+ levelAttack = levelAttack + 1
+
+#########################################################################################################################
+#########################################################################################################################
+#########################################################################################################################
+
+ if Market == True:
+ if d_Sword == False:
+ sword_i.showturtle()
+ if towel == False:
+ towel_i.showturtle()
+
+ potion_i.showturtle()
+
+ if abs(player.pos() - sword_i.pos()) < 45 and money >= 15 and sword_i.isvisible():
+ money = money - 15
+ coinNumber.clear()
+ coinNumber.write(money, font=("Impact", 25, "normal"))
+ d_Sword = True
+ sword.shape("d_sword.gif")
+ sword_i.hideturtle()
+
+ if abs(player.pos() - towel_i.pos()) < 45 and money >= 10 and towel_i.isvisible():
+ money = money - 10
+ coinNumber.clear()
+ coinNumber.write(money, font=("Impact", 25, "normal"))
+ towel = True
+ towel_i.hideturtle()
+
+ if abs(player.pos() - potion_i.pos()) < 45 and money >= 5 and potion_i.isvisible():
+ money = money - 5
+ coinNumber.clear()
+ coinNumber.write(money, font=("Impact", 25, "normal"))
+ hPotion = hPotion + 1
+ healPotionNumber.clear()
+ healPotionNumber.write(hPotion, font=("Impact", 25, "normal"))
+
+ if Market == False:
+ sword_i.hideturtle()
+ potion_i.hideturtle()
+ towel_i.hideturtle()
+
+ if enemy.isvisible():
+ time.sleep(0.5)
+ window.onclick(attack)
+
+ if chest.isvisible():
+ window.onclick(open_chest)
+
+
+ if abs(chestCheck.pos() - check.pos()) > 5:
+ chestCheck.goto(0, 0)
+ hPotion = hPotion + 1
+ healPotionNumber.clear()
+ healPotionNumber.write(hPotion, font=("Impact", 25, "normal"))
+ time.sleep(1.5)
+ chest.shape("chest1.gif")
+ time.sleep(0.5)
+ chest.hideturtle()
+
+
+ if abs(enemyD.pos() - check.pos()) > 5 and d_Sword == False:
+ hpE = hpE - (random.randint(1, 10))
+ hpE = hpE - levelAttack
+ enemyHP.clear()
+ enemyHP.write(hpE, font=("Impact", 25, "normal"))
+ if d_Sword == False:
+ sword.shape("sword.gif")
+ print(hpE)
+ hp = hp - (random.randint(1, 15))
+ hpU.clear()
+ hpU.write(hp, font=("Impact", 60, "normal"))
+ enemyD.goto(0, 0)
+ if hpE <= 0:
+ enemy.hideturtle()
+ enemyHP.clear()
+ money = money + (random.randint(1, 8))
+ coinNumber.clear()
+ coinNumber.write(money, font=("Impact", 25, "normal"))
+ xp = xp + (random.randint(1, 15))
+ xpNumber.clear()
+ xpNumber.write(xp, font=("Impact", 25, "normal"))
+ hPotion = hPotion + 1
+ healPotionNumber.clear()
+ healPotionNumber.write(hPotion, font=("Impact", 25, "normal"))
+ hpE = 10
+
+ if abs(enemyD.pos() - check.pos()) > 5 and d_Sword == True:
+ hpE = hpE - (random.randint(5, 15))
+ enemyHP.clear()
+ enemyHP.write(hpE, font=("Impact", 25, "normal"))
+ sword.shape("d_sword.gif")
+ print(hpE)
+ hp = hp - (random.randint(1, 15))
+ hpU.clear()
+ hpU.write(hp, font=("Impact", 60, "normal"))
+ enemyD.goto(0, 0)
+ if hpE <= 0:
+ enemy.hideturtle()
+ enemyHP.clear()
+ money = money + (random.randint(1, 8))
+ coinNumber.clear()
+ coinNumber.write(money, font=("Impact", 25, "normal"))
+ hPotion = hPotion + 1
+ healPotionNumber.clear()
+ healPotionNumber.write(hPotion, font=("Impact", 25, "normal"))
+ hpE = 10
+
+
+
+ window.update()
+ #window.onclick(dev_cords)
+ window.onclick(action)
+
+ if abs(player.pos() - healPotion.pos()) < 45 and hPotion > 0 and Market == False:
+ player.goto(0, 0)
+ hPotion = hPotion - 1
+ healPotionNumber.clear()
+ healPotionNumber.write(hPotion, font=("Impact", 25, "normal"))
+ hp = hp + 10
+ if hp > 100:
+ hp = 100
+ hpU.clear()
+ hpU.write(hp, font=("Impact", 60, "normal"))
+
+ if player.ycor() >= 300 and player.xcor() >= -500 and player.xcor() <= 500 and up == True and cave == False and hrad == False:
+ co = random.randint(1, 10)
+ if co == 1:
+ window.bgpic("forest1.gif")
+ up = True
+ right = True
+ left = True
+
+ if co == 2:
+ window.bgpic("forest2.gif")
+ up = True
+ right = True
+ left = True
+
+ if co == 3:
+ window.bgpic("forest3.gif")
+ up = True
+ right = True
+ left = True
+
+ if co == 4:
+ window.bgpic("forest4.gif")
+ up = True
+ right = True
+ left = False
+
+ if co == 5:
+ window.bgpic("forest5.gif")
+ up = False
+ right = True
+ left = True
+
+ if co == 6:
+ window.bgpic("forest6.gif")
+ up = True
+ right = False
+ left = True
+
+ if co == 7:
+ window.bgpic("forest7.gif")
+ up = False
+ right = False
+ left = True
+
+ if co == 8:
+ window.bgpic("forest8.gif")
+ up = False
+ right = True
+ left = False
+
+ if co == 9:
+ window.bgpic("castle1.gif")
+ up = True
+ right = False
+ left = False
+ hrad = True
+ Market = True
+
+ if co == 10:
+ window.bgpic("cave_enternace.gif")
+ up = True
+ right = False
+ left = False
+ cave = True
+ player.goto(0, 0)
+
+ Wchest = random.randint(1, 6)
+ yeno = random.randint(1, 6)
+
+ if Wchest == yeno:
+ chest.showturtle()
+
+ underAttack = random.randint(1, 3)
+ yn = random.randint(1, 3)
+ if underAttack == yn and hrad == False:
+ enemy.showturtle()
+ if towel == True:
+ hp = hp - (random.randint(1, 8))
+ print("mas ochranu ručníku")
+ else:
+ hp = hp - (random.randint(1, 15))
+
+ hpU.clear()
+ hpU.write(hp, font=("Impact", 60, "normal"))
+ print("Nepřítel!")
+ if hp <= 0:
+ alive = False
+
+
+
+
+
+ player.goto(0, 0)
+
+ if player.xcor() >= 550 and player.ycor() >= -250 and player.ycor() <= 250 and right == True and cave == False and hrad == False:
+ co = random.randint(1, 10)
+ if co == 1:
+ window.bgpic("forest1.gif")
+ up = True
+ right = True
+ left = True
+
+ if co == 2:
+ window.bgpic("forest2.gif")
+ up = True
+ right = True
+ left = True
+
+ if co == 3:
+ window.bgpic("forest3.gif")
+ up = True
+ right = True
+ left = True
+
+ if co == 4:
+ window.bgpic("forest4.gif")
+ up = True
+ right = True
+ left = False
+
+ if co == 5:
+ window.bgpic("forest5.gif")
+ up = False
+ right = True
+ left = True
+
+ if co == 6:
+ window.bgpic("forest6.gif")
+ up = True
+ right = False
+ left = True
+
+ if co == 7:
+ window.bgpic("forest7.gif")
+ up = False
+ right = False
+ left = True
+
+ if co == 8:
+ window.bgpic("forest8.gif")
+ up = False
+ right = True
+ left = False
+
+ if co == 9:
+ window.bgpic("castle1.gif")
+ up = True
+ right = False
+ left = False
+ hrad = True
+ Market = True
+
+
+
+ if co == 10:
+ window.bgpic("cave_enternace.gif")
+ up = True
+ right = False
+ left = False
+ cave = True
+ player.goto(0, 0)
+
+ Wchest = random.randint(1, 6)
+ yeno = random.randint(1, 6)
+
+ if Wchest == yeno:
+ chest.showturtle()
+
+ underAttack = random.randint(1, 3)
+ yn = random.randint(1, 3)
+ if underAttack == yn and hrad == False:
+ enemy.showturtle()
+ if towel == True:
+ hp = hp - (random.randint(1, 8))
+ print("mas ochranu ručníku")
+ else:
+ hp = hp - (random.randint(1, 15))
+
+ hpU.clear()
+ hpU.write(hp, font=("Impact", 60, "normal"))
+ print("Nepřítel!")
+ if hp <= 0:
+ alive = False
+
+ player.goto(0, 0)
+
+ if player.xcor() <= -550 and player.ycor() >= -250 and player.ycor() <= 250 and left == True and cave == False and hrad == False:
+ co = random.randint(1, 10)
+ if co == 1:
+ window.bgpic("forest1.gif")
+ up = True
+ right = True
+ left = True
+
+ if co == 2:
+ window.bgpic("forest2.gif")
+ up = True
+ right = True
+ left = True
+
+ if co == 3:
+ window.bgpic("forest3.gif")
+ up = True
+ right = True
+ left = True
+
+ if co == 4:
+ window.bgpic("forest4.gif")
+ up = True
+ right = True
+ left = False
+
+ if co == 5:
+ window.bgpic("forest5.gif")
+ up = False
+ right = True
+ left = True
+
+ if co == 6:
+ window.bgpic("forest6.gif")
+ up = True
+ right = False
+ left = True
+
+ if co == 7:
+ window.bgpic("forest7.gif")
+ up = False
+ right = False
+ left = True
+
+ if co == 8:
+ window.bgpic("forest8.gif")
+ up = False
+ right = True
+ left = False
+
+ if co == 9:
+ window.bgpic("castle1.gif")
+ up = True
+ right = False
+ left = False
+ hrad = True
+ Market = True
+
+
+ if co == 10:
+ window.bgpic("cave_enternace.gif")
+ up = True
+ right = False
+ left = False
+ cave = True
+ player.goto(0, 0)
+
+ Wchest = random.randint(1, 6)
+ yeno = random.randint(1, 6)
+
+ if Wchest == yeno:
+ chest.showturtle()
+
+ underAttack = random.randint(1, 3)
+ yn = random.randint(1, 3)
+ if underAttack == yn and hrad == False:
+ enemy.showturtle()
+ if towel == True:
+ hp = hp - (random.randint(1, 8))
+ print("mas ochranu ručníku")
+ else:
+ hp = hp - (random.randint(1, 15))
+
+ hpU.clear()
+ hpU.write(hp, font=("Impact", 60, "normal"))
+ print("Nepřítel!")
+ if hp <= 0:
+ alive = False
+
+ player.goto(0, 0)
+
+ if player.ycor() >= 300 and player.xcor() >= -500 and player.xcor() <= 500 and up == True and cave == True:
+ co = random.randint(1, 4)
+ c_exit = random.randint(1, 4)
+ if co == 1:
+ window.bgpic("cave1.gif")
+ up = True
+ right = False
+ left = True
+ cave = True
+ if co == 2:
+ window.bgpic("cave2.gif")
+ up = True
+ right = True
+ left = False
+ cave = True
+ if co == 3:
+ window.bgpic("cave3.gif")
+ up = True
+ right = False
+ left = False
+ cave = True
+ if co == c_exit:
+ window.bgpic("cave_exit.gif")
+ up = True
+ right = False
+ left = False
+ cave = False
+
+ underAttack = random.randint(1, 3)
+ yn = random.randint(1, 3)
+ if underAttack == yn and hrad == False:
+ enemy.showturtle()
+ if towel == True:
+ hp = hp - (random.randint(1, 8))
+ print("mas ochranu ručníku")
+ else:
+ hp = hp - (random.randint(1, 15))
+
+ hpU.clear()
+ hpU.write(hp, font=("Impact", 60, "normal"))
+ print("Nepřítel!")
+ if hp <= 0:
+ alive = False
+
+ player.goto(0, 0)
+
+ if player.xcor() >= 550 and player.ycor() >= -250 and player.ycor() <= 250 and right == True and cave == True:
+ co = random.randint(1, 4)
+ c_exit = random.randint(1, 4)
+ if co == 1:
+ window.bgpic("cave1.gif")
+ up = True
+ right = False
+ left = True
+ cave = True
+ if co == 2:
+ window.bgpic("cave2.gif")
+ up = True
+ right = True
+ left = False
+ cave = True
+ if co == 3:
+ window.bgpic("cave3.gif")
+ up = True
+ right = False
+ left = False
+ cave = True
+ if co == c_exit:
+ window.bgpic("cave_exit.gif")
+ up = True
+ right = False
+ left = False
+ cave = False
+
+ underAttack = random.randint(1, 3)
+ yn = random.randint(1, 3)
+ if underAttack == yn and hrad == False:
+ enemy.showturtle()
+ if towel == True:
+ hp = hp - (random.randint(1, 8))
+ print("mas ochranu ručníku")
+ else:
+ hp = hp - (random.randint(1, 15))
+
+ hpU.clear()
+ hpU.write(hp, font=("Impact", 60, "normal"))
+ print("Nepřítel!")
+ if hp <= 0:
+ alive = False
+
+ player.goto(0, 0)
+
+ if player.xcor() <= -550 and player.ycor() >= -250 and player.ycor() <= 250 and left == True and cave == True:
+ co = random.randint(1, 4)
+ c_exit = random.randint(1, 4)
+ if co == 1:
+ window.bgpic("cave1.gif")
+ up = True
+ right = False
+ left = True
+ cave = True
+ if co == 2:
+ window.bgpic("cave2.gif")
+ up = True
+ right = True
+ left = False
+ cave = True
+ if co == 3:
+ window.bgpic("cave3.gif")
+ up = True
+ right = False
+ left = False
+ cave = True
+ if co == c_exit:
+ window.bgpic("cave_exit.gif")
+ up = True
+ right = False
+ left = False
+ cave = False
+
+ underAttack = random.randint(1, 3)
+ yn = random.randint(1, 3)
+ if underAttack == yn and hrad == False:
+ enemy.showturtle()
+ if towel == True:
+ hp = hp - (random.randint(1, 8))
+ print("mas ochranu ručníku")
+ else:
+ hp = hp - (random.randint(1, 15))
+
+ hpU.clear()
+ hpU.write(hp, font=("Impact", 60, "normal"))
+ print("Nepřítel!")
+ if hp <= 0:
+ alive = False
+
+ player.goto(0, 0)
+
+ if player.ycor() >= 300 and player.xcor() >= -500 and player.xcor() <= 500 and up == True and cave == False and hrad == True:
+ Market = False
+ co = random.randint(1, 10)
+ if co == 1:
+ window.bgpic("forest1.gif")
+ up = True
+ right = True
+ left = True
+ hrad = False
+
+ if co == 2:
+ window.bgpic("forest2.gif")
+ up = True
+ right = True
+ left = True
+ hrad = False
+
+ if co == 3:
+ window.bgpic("forest3.gif")
+ up = True
+ right = True
+ left = True
+ hrad = False
+
+ if co == 4:
+ window.bgpic("forest4.gif")
+ up = True
+ right = True
+ left = False
+ hrad = False
+
+ if co == 5:
+ window.bgpic("forest5.gif")
+ up = False
+ right = True
+ left = True
+ hrad = False
+
+ if co == 6:
+ window.bgpic("forest6.gif")
+ up = True
+ right = False
+ left = True
+ hrad = False
+
+ if co == 7:
+ window.bgpic("forest7.gif")
+ up = False
+ right = False
+ left = True
+ hrad = False
+
+ if co == 8:
+ window.bgpic("forest8.gif")
+ up = False
+ right = True
+ left = False
+ hrad = False
+
+ if co == 9:
+ window.bgpic("castle1.gif")
+ up = True
+ right = False
+ left = False
+ hrad = True
+ Market = True
+
+
+ if co == 10:
+ window.bgpic("cave_enternace.gif")
+ up = True
+ right = False
+ left = False
+ hrad = False
+ cave = True
+ player.goto(0, 0)
+
+ Wchest = random.randint(1, 6)
+ yeno = random.randint(1, 6)
+
+ if Wchest == yeno:
+ chest.showturtle()
+
+ underAttack = random.randint(1, 3)
+ yn = random.randint(1, 3)
+ if underAttack == yn and hrad == False:
+ enemy.showturtle()
+ if towel == True:
+ hp = hp - (random.randint(1, 8))
+ print("mas ochranu ručníku")
+ else:
+ hp = hp - (random.randint(1, 15))
+
+ hpU.clear()
+ hpU.write(hp, font=("Impact", 60, "normal"))
+ print("Nepřítel!")
+ if hp <= 0:
+ alive = False
+
+ #if abs(mobE.pos() - kontrola.pos()) > 5:
+ # hp = hp - (random.randint(1, 10))
+ # mobE.goto(0, 0)
+
+ #if abs(hpH.pos() - kontrola.pos()) > 5:
+ # hp = hp + 10
+ # if hp > 100:
+ # hp = 100
+ #hpH.goto(0, 0) \ No newline at end of file
diff --git a/castle1.gif b/castle1.gif
new file mode 100644
index 0000000..7867d71
--- /dev/null
+++ b/castle1.gif
Binary files differ
diff --git a/cave1.gif b/cave1.gif
new file mode 100644
index 0000000..608cfad
--- /dev/null
+++ b/cave1.gif
Binary files differ
diff --git a/cave2.gif b/cave2.gif
new file mode 100644
index 0000000..09aba2a
--- /dev/null
+++ b/cave2.gif
Binary files differ
diff --git a/cave3.gif b/cave3.gif
new file mode 100644
index 0000000..bbf4a74
--- /dev/null
+++ b/cave3.gif
Binary files differ
diff --git a/cave_enternace.gif b/cave_enternace.gif
new file mode 100644
index 0000000..5ff3aaf
--- /dev/null
+++ b/cave_enternace.gif
Binary files differ
diff --git a/cave_exit.gif b/cave_exit.gif
new file mode 100644
index 0000000..d12e383
--- /dev/null
+++ b/cave_exit.gif
Binary files differ
diff --git a/chest1.gif b/chest1.gif
new file mode 100644
index 0000000..6adbae9
--- /dev/null
+++ b/chest1.gif
Binary files differ
diff --git a/chest2.gif b/chest2.gif
new file mode 100644
index 0000000..9200cc8
--- /dev/null
+++ b/chest2.gif
Binary files differ
diff --git a/d_sword.gif b/d_sword.gif
new file mode 100644
index 0000000..57ab08a
--- /dev/null
+++ b/d_sword.gif
Binary files differ
diff --git a/d_sword2.gif b/d_sword2.gif
new file mode 100644
index 0000000..5dc41ac
--- /dev/null
+++ b/d_sword2.gif
Binary files differ
diff --git a/d_sword_icon.gif b/d_sword_icon.gif
new file mode 100644
index 0000000..71e2dcd
--- /dev/null
+++ b/d_sword_icon.gif
Binary files differ
diff --git a/forest1.gif b/forest1.gif
new file mode 100644
index 0000000..bef0017
--- /dev/null
+++ b/forest1.gif
Binary files differ
diff --git a/forest2.gif b/forest2.gif
new file mode 100644
index 0000000..bfd4d6b
--- /dev/null
+++ b/forest2.gif
Binary files differ
diff --git a/forest3.gif b/forest3.gif
new file mode 100644
index 0000000..c8166dc
--- /dev/null
+++ b/forest3.gif
Binary files differ
diff --git a/forest4.gif b/forest4.gif
new file mode 100644
index 0000000..1e2df0d
--- /dev/null
+++ b/forest4.gif
Binary files differ
diff --git a/forest5.gif b/forest5.gif
new file mode 100644
index 0000000..92d988e
--- /dev/null
+++ b/forest5.gif
Binary files differ
diff --git a/forest6.gif b/forest6.gif
new file mode 100644
index 0000000..c013c24
--- /dev/null
+++ b/forest6.gif
Binary files differ
diff --git a/forest7.gif b/forest7.gif
new file mode 100644
index 0000000..54fefa6
--- /dev/null
+++ b/forest7.gif
Binary files differ
diff --git a/forest8.gif b/forest8.gif
new file mode 100644
index 0000000..7430d09
--- /dev/null
+++ b/forest8.gif
Binary files differ
diff --git a/heal_potion_icon.gif b/heal_potion_icon.gif
new file mode 100644
index 0000000..0013ccf
--- /dev/null
+++ b/heal_potion_icon.gif
Binary files differ
diff --git a/menu1.gif b/menu1.gif
new file mode 100644
index 0000000..fec6da6
--- /dev/null
+++ b/menu1.gif
Binary files differ
diff --git a/menu2.gif b/menu2.gif
new file mode 100644
index 0000000..79a7dfb
--- /dev/null
+++ b/menu2.gif
Binary files differ
diff --git a/sack.gif b/sack.gif
new file mode 100644
index 0000000..b9ace16
--- /dev/null
+++ b/sack.gif
Binary files differ
diff --git a/sword.gif b/sword.gif
new file mode 100644
index 0000000..20b7418
--- /dev/null
+++ b/sword.gif
Binary files differ
diff --git a/sword2.gif b/sword2.gif
new file mode 100644
index 0000000..6f5de1b
--- /dev/null
+++ b/sword2.gif
Binary files differ
diff --git a/towel_icon.gif b/towel_icon.gif
new file mode 100644
index 0000000..52e64d5
--- /dev/null
+++ b/towel_icon.gif
Binary files differ