Skip to content

Commit

Permalink
Merge pull request #9379 from Booplicate/NoU
Browse files Browse the repository at this point in the history
Some more NOU improvements
  • Loading branch information
ThePotatoGuy authored Sep 18, 2022
2 parents 29b9347 + c064134 commit f8f8b7a
Show file tree
Hide file tree
Showing 3 changed files with 259 additions and 98 deletions.
45 changes: 26 additions & 19 deletions Monika After Story/game/script-moods.rpy
Original file line number Diff line number Diff line change
Expand Up @@ -602,7 +602,15 @@ label mas_mood_lazy:
return

init 5 python:
addEvent(Event(persistent._mas_mood_database,eventlabel="mas_mood_bored",prompt="...bored.",category=[store.mas_moods.TYPE_NEUTRAL],unlocked=True),code="MOO")
addEvent(
Event(
persistent._mas_mood_database,eventlabel="mas_mood_bored",
prompt="...bored.",
category=[store.mas_moods.TYPE_NEUTRAL],
unlocked=True
),
code="MOO"
)

label mas_mood_bored:
if mas_isMoniAff(higher=True):
Expand Down Expand Up @@ -637,16 +645,19 @@ label mas_mood_bored:
return "quit"

python:
unlockedgames = [
game_ev.prompt.lower()
for game_ev in mas_games.game_db.itervalues()
# build mapping from game label to display name for game
unlocked_games = {
# use display name, or lowercase prompt as backup
ev_label: game_ev.rules.get("display_name", game_ev.prompt.lower())

for ev_label, game_ev in mas_games.game_db.iteritems()
if mas_isGameUnlocked(game_ev.prompt)
]
}

gamepicked = renpy.random.choice(unlockedgames)
display_picked = gamepicked
picked_game_label = renpy.random.choice(list(unlocked_games.keys()))
picked_game_name = unlocked_games[picked_game_label]

if gamepicked == "piano":
if picked_game_label == "mas_piano":
if mas_isMoniAff(higher=True):
m 3eub "You could play something for me on the piano!"

Expand All @@ -658,28 +669,22 @@ label mas_mood_bored:

else:
if mas_isMoniAff(higher=True):
m 3eub "We could play a game of [display_picked]!"
m 3eub "We could play a game of [picked_game_name]!"

elif mas_isMoniNormal(higher=True):
m 4eka "Maybe we could play a game of [display_picked]?"
m 4eka "Maybe we could play a game of [picked_game_name]?"

else:
m 2rkc "Maybe we could play a game of [display_picked]..."
m 2rkc "Maybe we could play a game of [picked_game_name]..."

$ chosen_nickname = mas_get_player_nickname()
m "What do you say, [chosen_nickname]?{nw}"
$ _history_list.pop()
menu:
m "What do you say, [chosen_nickname]?{fast}"
"Yes.":
if gamepicked == "pong":
call game_pong
elif gamepicked == "chess":
call game_chess
elif gamepicked == "hangman":
call game_hangman
elif gamepicked == "piano":
call mas_piano_start
$ MASEventList.push(picked_game_label, skipeval=True)

"No.":
if mas_isMoniAff(higher=True):
m 1eka "Okay..."
Expand All @@ -699,6 +704,8 @@ label mas_mood_bored:
else:
m 2ekc "Fine..."
m 2dkc "Let me know if you ever actually want to do anything with me."

$ del unlocked_games, picked_game_label, picked_game_name
return

init 5 python:
Expand Down
Loading

0 comments on commit f8f8b7a

Please sign in to comment.