Commit 7d71704f authored by Julia Santos's avatar Julia Santos

Moxie can now only leave the front door if she has the trash, or has found Banana

parent d6c5e0f3
......@@ -34,6 +34,7 @@ onready var lockedNotepad #if ur locked from certain areas bc u havent gotten th
onready var labNotes = 0
onready var clothes = 0
onready var bathroomClean = 0
onready var canFrontDoor = false
#items in the rooms that need access to the event handler
export(Array, NodePath) onready var eventItems
......@@ -86,9 +87,9 @@ func _eaten(): # completing first "Eat" quest
func _start_lab(): # trying the lab the first time, adds the new quests
if !quests.hasQuest("Eat") and !quests.hasQuest("Do laundry"):
quests.add("Clean bathroom")
quests.add("Take care of plants")
quests.add("Repot plants")
quests.add("Figure out what's making that noise")
quests.add("Feed Nana")
quests.add("Feed Banana")
newQuests = true
func _add_quest(questName):
......@@ -183,9 +184,16 @@ func _balcony_exit():
livingRoom.show()
func _living_to_hallway():
if ((inventory.hasItem("Trash") != -1) || (!quests.hasQuest("Find Banana") && quests.hasQuest("Feed Banana"))):
canFrontDoor = true
if canFrontDoor:
movementHandle.disableMovement()
livingRoom.hide()
hallway.show()
canFrontDoor = true
else:
dialogue.text = "You know, my philosophy has always been, 'If there's no reason to leave my apartment, why leave?'"
func _hallway_to_living():
movementHandle.enableMovement()
......
......@@ -3,6 +3,7 @@ onready var unlocked = false
signal enter
signal foundBanana
# Called when the node enters the scene tree for the first time.
func _ready():
pass # Replace with function body.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment