repl.it
Python

mkmn

fork
loading
Files
  • main.py
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
 
 
 
import cmd
import textwrap
import sys
import os
import time
import random
 
screen_width = 100
 
#### Player Setup ####
class player:
   def __init__(self):
     self.name = ''
     self.hp = 0
     self.mp = 0
     self.status_effects = []
myPlayer = player()
 
#### Title Screen ####
def title_screeb_selections():
 option = input ("> ")
 if option.lower() == ("play")
   start_game() #placeholder until write
 elif option.lower() == ("help"):
   help_menu()
 elif option.lower() == ("quit")
   sys.exit()
 while option.lower() not in ['play', 'help', 'quit']:
   print("Plese enter a valid option.")
   option = input("> ")
   if option.lower() == ("play"):
     start_game() #placeholder until write
   elif option,lower() == ("help"):
     help_menu()
   elif option.lower() == ("quit"):
     sys.exit()
 
 
def title_screen():
 os.system('clear')
 print('##########################')
 print('# Welcom to the Text RPG #')
 print('##########################')
 print('#         -Play-         #')
 print('#         -Help-         #')
 print('#         -Quit-         #')
 print('# copyright 2019         #')
 title_screen_selections()
 
def help_menu():
 print('##########################')
 print('# Welcom to the Text RPG #')
 print('##########################')
 print('-Use up, down, left, right to move')
 print('- Type your commands to do them')
 print('- Use "look" to inspect something')
 print('- Good luck and have fun!')
 title_screen_selections()
 
def start_game():
 print('Welcome to the Beginning')