neelthee-mansion 3.7.0__tar.gz → 3.7.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (19) hide show
  1. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/PKG-INFO +1 -1
  2. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion/Mansion_of_Amnesia.py +2 -4
  3. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion/items.py +22 -20
  4. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion.egg-info/PKG-INFO +1 -1
  5. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/setup.py +1 -1
  6. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/README.md +0 -0
  7. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion/Quests.py +0 -0
  8. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion/Rooms.py +0 -0
  9. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion/__init__.py +0 -0
  10. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion/__main__.py +0 -0
  11. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion/all_game_utils.py +0 -0
  12. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion/creatures.py +0 -0
  13. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion/utils.py +0 -0
  14. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion.egg-info/SOURCES.txt +0 -0
  15. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion.egg-info/dependency_links.txt +0 -0
  16. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion.egg-info/entry_points.txt +0 -0
  17. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion.egg-info/requires.txt +0 -0
  18. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/neelthee_mansion.egg-info/top_level.txt +0 -0
  19. {neelthee_mansion-3.7.0 → neelthee_mansion-3.7.3}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: neelthee_mansion
3
- Version: 3.7.0
3
+ Version: 3.7.3
4
4
  Summary: A text-based adventure game set in Neel-thee’s mansion.
5
5
  Home-page: https://github.com/Flameblade375/neelthee_mansion
6
6
  Author: Alexander.E.F
@@ -435,10 +435,8 @@ def Examin(*Args):
435
435
  Name = ' '.join(Args)
436
436
  if player.inventory.index(Name):
437
437
  _ = player.inventory[player.inventory.index(Name)]
438
- if isinstance(_, Key):
439
- type_text("You look at your key and you figure out this about it:")
440
- revealer.reveal_key_code(_)
441
- elif isinstance(_, item):
438
+ type_text("You look at your item and you figure out this about it:")
439
+ if not revealer.reveal_key_code(_):
442
440
  if _.type == 'weapon':
443
441
  type_text(f"This item is a weapon that adds {_.value} damage.")
444
442
  elif Name in ROOMS[player.CURRENTROOM]['directions']:
@@ -63,26 +63,28 @@ class KeyRevealer:
63
63
  self.max_reveals = max_reveals
64
64
 
65
65
  def reveal_key_code(self, obj: Key, mask_char="="):
66
- if obj.reveal_count >= self.max_reveals:
67
- type_text(f"You can only reveal a Key Code twice.")
68
- type_text(f"Here is what you already know about this lock: {obj.CurentRevealStr}")
69
- return
70
-
71
- if not hasattr(obj, 'lock'):
72
- key_code = obj.value
73
- else:
74
- key_code = obj.lock.key_code
75
- one_third_length = len(key_code) // 3
76
- selected_indices = random.sample(range(len(key_code)), one_third_length)
77
-
78
- result = [
79
- key_code[i] if i in selected_indices else mask_char
80
- for i in range(len(key_code))
81
- ]
82
-
83
- obj.reveal_count += 1
84
- obj.CurentRevealStr = ''.join(result)
85
- return ''.join(result)
66
+ if isinstance(obj, Key):
67
+ if obj.reveal_count >= self.max_reveals:
68
+ type_text(f"You can only reveal a Key Code twice.")
69
+ type_text(f"Here is what you already know about this lock: {obj.CurentRevealStr}")
70
+ return
71
+
72
+ if not hasattr(obj, 'lock'):
73
+ key_code = obj.value
74
+ else:
75
+ key_code = obj.lock.key_code
76
+ one_third_length = len(key_code) // 3
77
+ selected_indices = random.sample(range(len(key_code)), one_third_length)
78
+
79
+ result = [
80
+ key_code[i] if i in selected_indices else mask_char
81
+ for i in range(len(key_code))
82
+ ]
83
+
84
+ obj.reveal_count += 1
85
+ obj.CurentRevealStr = ''.join(result)
86
+ return ''.join(result)
87
+ return
86
88
 
87
89
  class ShopItem:
88
90
  def __init__(self, item: item, price: int):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: neelthee-mansion
3
- Version: 3.7.0
3
+ Version: 3.7.3
4
4
  Summary: A text-based adventure game set in Neel-thee’s mansion.
5
5
  Home-page: https://github.com/Flameblade375/neelthee_mansion
6
6
  Author: Alexander.E.F
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
2
2
 
3
3
  setup(
4
4
  name='neelthee_mansion',
5
- version='3.7.0',
5
+ version='3.7.3',
6
6
  packages=find_packages(), # Automatically finds all packages and modules
7
7
  install_requires=[
8
8
  'wheel', 'psutil', 'playsound', 'requests', 'keyboard', 'pandas', 'validators', 'dicttoxml', 'pytz',