Skip to content

Commit

Permalink
Merge pull request ClanGenOfficial#2165 from sedgestripe/bugfixing
Browse files Browse the repository at this point in the history
fixes: keybinds and loner backstory
  • Loading branch information
Ryos00 authored Mar 31, 2024
2 parents 025d116 + 3f4a924 commit 9fa0961
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 11 deletions.
6 changes: 3 additions & 3 deletions resources/dicts/patrols/new_cat_welcoming.json
Original file line number Diff line number Diff line change
Expand Up @@ -2100,7 +2100,7 @@
"exp": 10,
"weight": 20,
"new_cat": [
["loner"]
["loner", "backstory:loner1"]
],
"relationships": [
{
Expand All @@ -2124,7 +2124,7 @@
"exp": 10,
"weight": 5,
"new_cat": [
["loner"]
["loner", "backstory:loner1"]
],
"relationships": [
{
Expand All @@ -2149,7 +2149,7 @@
"weight": 20,
"stat_skill": ["SPEAKER,1"],
"new_cat": [
["loner"]
["loner", "backstory:loner1"]
],
"relationships": [
{
Expand Down
22 changes: 14 additions & 8 deletions scripts/screens/ProfileScreen.py
Original file line number Diff line number Diff line change
Expand Up @@ -220,15 +220,21 @@ def handle_event(self, event):
pass

elif event.key == pygame.K_LEFT:
self.clear_profile()
game.switches['cat'] = self.previous_cat
self.build_profile()
self.update_disabled_buttons_and_text()
if isinstance(Cat.fetch_cat(self.previous_cat), Cat):
self.clear_profile()
game.switches['cat'] = self.previous_cat
self.build_profile()
self.update_disabled_buttons_and_text()
else:
print("invalid previous cat", self.previous_cat)
elif event.key == pygame.K_RIGHT:
self.clear_profile()
game.switches['cat'] = self.next_cat
self.build_profile()
self.update_disabled_buttons_and_text()
if isinstance(Cat.fetch_cat(self.next_cat), Cat):
self.clear_profile()
game.switches['cat'] = self.next_cat
self.build_profile()
self.update_disabled_buttons_and_text()
else:
print("invalid next cat", self.previous_cat)

elif event.key == pygame.K_ESCAPE:
self.close_current_tab()
Expand Down

0 comments on commit 9fa0961

Please sign in to comment.