Commit 63c0696d authored by Julia Santos's avatar Julia Santos

Can now finish yoga quest, as well as travel to own balcony from neighbor's balcony

parent d19d7e6b
...@@ -134,9 +134,19 @@ func finished2ndRound(): ...@@ -134,9 +134,19 @@ func finished2ndRound():
desk.get_node("Laptop").tired() desk.get_node("Laptop").tired()
func _self_care(): func _self_care():
livingRoom.get_node("Yoga mat").flavorText = "How do you do yoga again? I think that yoga guy posted a new video on some poses earlier."
livingRoom.get_node("Yoga mat").canYoga()
quests.add("Eat something") quests.add("Eat something")
quests.add("Do something relaxing") quests.add("Do something relaxing")
func _balcony_outer_lock():
livingRoom.get_node("Balcony door").outerLock()
neighborsBalcony.hide()
balcony.show()
movementHandle.setRoom(3)
movementHandle.disableMovement()
if !quests.hasQuest("Clean bathroom"):
inventory.remove_item_name("Plunger")
# ----------------- Cutscene initiators ----------------- # ----------------- Cutscene initiators -----------------
func _start_cutscene_1(): func _start_cutscene_1():
cutsceneHandler.get_node("1").show() cutsceneHandler.get_node("1").show()
...@@ -218,7 +228,7 @@ func _enter_notebook_plants(): # trying to engage in the notebook puzzle for doi ...@@ -218,7 +228,7 @@ func _enter_notebook_plants(): # trying to engage in the notebook puzzle for doi
return "Awww my babies are growing up so fast. Looks like they've outgrown their pots. Time for some big boy pants!" return "Awww my babies are growing up so fast. Looks like they've outgrown their pots. Time for some big boy pants!"
func _plants_finished(): func _plants_finished():
quests.finishQuest("Repot plants") #quests.finishQuest("Repot plants")
livingRoom.get_node("Plants").interactable = false livingRoom.get_node("Plants").interactable = false
livingRoom.get_node("Plants").retrievable = true livingRoom.get_node("Plants").retrievable = true
livingRoom.get_node("Plants").flavorText = "Time to bring these outside for some sunlight!" livingRoom.get_node("Plants").flavorText = "Time to bring these outside for some sunlight!"
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
[ext_resource path="res://assets/Thesis Clickables/yoga mat.png" type="Texture" id=2] [ext_resource path="res://assets/Thesis Clickables/yoga mat.png" type="Texture" id=2]
[ext_resource path="res://assets/Thesis Clickables/Balcony door.png" type="Texture" id=3] [ext_resource path="res://assets/Thesis Clickables/Balcony door.png" type="Texture" id=3]
[ext_resource path="res://assets/Thesis Clickables/plants.png" type="Texture" id=4] [ext_resource path="res://assets/Thesis Clickables/plants.png" type="Texture" id=4]
[ext_resource path="res://Item.gd" type="Script" id=5] [ext_resource path="res://Scripts/Yoga mat.gd" type="Script" id=5]
[ext_resource path="res://assets/Thesis Clickables/Lab Notes.png" type="Texture" id=6] [ext_resource path="res://assets/Thesis Clickables/Lab Notes.png" type="Texture" id=6]
[ext_resource path="res://assets/Thesis Clickables/front door.png" type="Texture" id=7] [ext_resource path="res://assets/Thesis Clickables/front door.png" type="Texture" id=7]
[ext_resource path="res://Scripts/Movement scripts/Balcony door.gd" type="Script" id=8] [ext_resource path="res://Scripts/Movement scripts/Balcony door.gd" type="Script" id=8]
...@@ -110,7 +110,7 @@ __meta__ = { ...@@ -110,7 +110,7 @@ __meta__ = {
"_edit_group_": true "_edit_group_": true
} }
interactable = true interactable = true
flavorText = "Why is the Living Room so crowded? It's like a jungle in here! I can barely move... I don't think I can do my yoga like this." flavorText = "Yoga always calms me down. But I can't do that now, I have things to do!"
[node name="CollisionShape2D" type="CollisionShape2D" parent="Yoga mat"] [node name="CollisionShape2D" type="CollisionShape2D" parent="Yoga mat"]
position = Vector2( -16.8367, -2.11676 ) position = Vector2( -16.8367, -2.11676 )
......
[gd_scene load_steps=10 format=2] [gd_scene load_steps=11 format=2]
[ext_resource path="res://assets/Thesis Clickables/nana from a distance.png" type="Texture" id=1] [ext_resource path="res://assets/Thesis Clickables/nana from a distance.png" type="Texture" id=1]
[ext_resource path="res://Scripts/Dialogue control/Dialogue Control - Neighbor's balcony.gd" type="Script" id=2] [ext_resource path="res://Scripts/Dialogue control/Dialogue Control - Neighbor's balcony.gd" type="Script" id=2]
[ext_resource path="res://assets/Thesis Clickables/other balcony.png" type="Texture" id=3] [ext_resource path="res://assets/Thesis Clickables/other balcony.png" type="Texture" id=3]
[ext_resource path="res://Item.gd" type="Script" id=4] [ext_resource path="res://Item.gd" type="Script" id=4]
[ext_resource path="res://Scripts/Movement scripts/Balcony to neighbor's room.gd" type="Script" id=5] [ext_resource path="res://Scripts/Movement scripts/Balcony to neighbor's room.gd" type="Script" id=5]
[ext_resource path="res://Scripts/Other balcony.gd" type="Script" id=6]
[sub_resource type="RectangleShape2D" id=1] [sub_resource type="RectangleShape2D" id=1]
extents = Vector2( 44.7209, 45.4241 ) extents = Vector2( 44.7209, 45.4241 )
...@@ -35,7 +36,7 @@ __meta__ = { ...@@ -35,7 +36,7 @@ __meta__ = {
position = Vector2( 785.279, 249.088 ) position = Vector2( 785.279, 249.088 )
scale = Vector2( 0.829244, 0.829244 ) scale = Vector2( 0.829244, 0.829244 )
input_pickable = true input_pickable = true
script = ExtResource( 4 ) script = ExtResource( 6 )
__meta__ = { __meta__ = {
"_edit_group_": true "_edit_group_": true
} }
......
...@@ -138,7 +138,7 @@ __meta__ = { ...@@ -138,7 +138,7 @@ __meta__ = {
"_edit_group_": true "_edit_group_": true
} }
retrievable = true retrievable = true
flavorText = "I would've called it to find it but I always put it on silent. And I only have one phone." flavorText = "I would've called it to find it but I always put it on silent. And I only have one phone. Oh hey, an upload notif from that yoga dude."
[node name="CollisionShape2D" type="CollisionShape2D" parent="Cellphone"] [node name="CollisionShape2D" type="CollisionShape2D" parent="Cellphone"]
position = Vector2( 0.842377, -0.977234 ) position = Vector2( 0.842377, -0.977234 )
......
...@@ -58,3 +58,7 @@ func finishTutorial(): ...@@ -58,3 +58,7 @@ func finishTutorial():
func checkRoom(): func checkRoom():
moxiePath.set_path(rooms[current].get_name()) moxiePath.set_path(rooms[current].get_name())
moxiePath.hardMove(0) moxiePath.hardMove(0)
func setRoom(num):
current = num
check_arrows()
...@@ -147,7 +147,7 @@ items = [ NodePath("Nana from afar"), NodePath("Other balcony"), NodePath("Balco ...@@ -147,7 +147,7 @@ items = [ NodePath("Nana from afar"), NodePath("Other balcony"), NodePath("Balco
[node name="Event Handler" type="Node2D" parent="."] [node name="Event Handler" type="Node2D" parent="."]
position = Vector2( 460.602, 18.6417 ) position = Vector2( 460.602, 18.6417 )
script = ExtResource( 12 ) script = ExtResource( 12 )
eventItems = [ NodePath("../Laundry basket/To do list"), NodePath("../Bedroom/Laundry basket"), NodePath("../Laundry basket/Return"), NodePath("../Fridge/Return"), NodePath("../Kitchen/Fridge"), NodePath("../Laundry area/Groceries"), NodePath("../Fridge/Energy handler"), NodePath("../Laundry area/Laundry door"), NodePath("../Laundry - Notepad/Return"), NodePath("../Laundry - Notepad/Dialogue control"), NodePath("../Bedroom/Bathroom door"), NodePath("../Bathroom/Door - to Bedroom"), NodePath("../Living room/Balcony door"), NodePath("../Balcony/Door to living room"), NodePath("../Living room/Front door"), NodePath("../Hallway/Door to Moxie"), NodePath("../Hallway/Door to neighbor"), NodePath("../Neighbor\'s room/Neighbor to hallway"), NodePath("../Neighbor\'s balcony/Balcony to neighbor\'s room"), NodePath("../Neighbor\'s room/Neighbor to balcony"), NodePath("../Bedroom/Laptop"), NodePath("../Desk/Return"), NodePath("../Inside cabinet/Return"), NodePath("../Kitchen/Cabinet"), NodePath("../Desk/Laptop"), NodePath("../Bedroom/Terrarium"), NodePath("../Bathroom/Lab Note - Bathroom"), NodePath("../Inside cabinet/Lab notes"), NodePath("../Living room/Lab notes"), NodePath("../Bedroom/Pants"), NodePath("../Bedroom/Shirt"), NodePath("../Bedroom/Sando"), NodePath("../Bedroom/Towel"), NodePath("../Bathroom/Sink"), NodePath("../Bathroom/Toilet"), NodePath("../Bathroom/Mirror"), NodePath("../Bathroom/Mess on floor"), NodePath("../Hallway/Trash chute"), NodePath("../Neighbor\'s room/Ladder"), NodePath("../Living room - Notepad/Return"), NodePath("../Living room/Plants"), NodePath("../Living room - Notepad/Dialogue control"), NodePath("../Balcony/Other plants") ] eventItems = [ NodePath("../Laundry basket/To do list"), NodePath("../Bedroom/Laundry basket"), NodePath("../Laundry basket/Return"), NodePath("../Fridge/Return"), NodePath("../Kitchen/Fridge"), NodePath("../Laundry area/Groceries"), NodePath("../Fridge/Energy handler"), NodePath("../Laundry area/Laundry door"), NodePath("../Laundry - Notepad/Return"), NodePath("../Laundry - Notepad/Dialogue control"), NodePath("../Bedroom/Bathroom door"), NodePath("../Bathroom/Door - to Bedroom"), NodePath("../Living room/Balcony door"), NodePath("../Balcony/Door to living room"), NodePath("../Living room/Front door"), NodePath("../Hallway/Door to Moxie"), NodePath("../Hallway/Door to neighbor"), NodePath("../Neighbor\'s room/Neighbor to hallway"), NodePath("../Neighbor\'s balcony/Balcony to neighbor\'s room"), NodePath("../Neighbor\'s room/Neighbor to balcony"), NodePath("../Bedroom/Laptop"), NodePath("../Desk/Return"), NodePath("../Inside cabinet/Return"), NodePath("../Kitchen/Cabinet"), NodePath("../Desk/Laptop"), NodePath("../Bedroom/Terrarium"), NodePath("../Bathroom/Lab Note - Bathroom"), NodePath("../Inside cabinet/Lab notes"), NodePath("../Living room/Lab notes"), NodePath("../Bedroom/Pants"), NodePath("../Bedroom/Shirt"), NodePath("../Bedroom/Sando"), NodePath("../Bedroom/Towel"), NodePath("../Bathroom/Sink"), NodePath("../Bathroom/Toilet"), NodePath("../Bathroom/Mirror"), NodePath("../Bathroom/Mess on floor"), NodePath("../Hallway/Trash chute"), NodePath("../Neighbor\'s room/Ladder"), NodePath("../Living room - Notepad/Return"), NodePath("../Living room/Plants"), NodePath("../Living room - Notepad/Dialogue control"), NodePath("../Balcony/Other plants"), NodePath("../Living room/Yoga mat"), NodePath("../Neighbor\'s balcony/Other balcony") ]
[node name="Moxie" type="Control" parent="."] [node name="Moxie" type="Control" parent="."]
margin_left = 513.815 margin_left = 513.815
......
...@@ -23,7 +23,10 @@ func finishQuest(q): # removes a quest from the list ...@@ -23,7 +23,10 @@ func finishQuest(q): # removes a quest from the list
print("Quest found, will remove " + quest) print("Quest found, will remove " + quest)
showQuests() showQuests()
found = true found = true
energyBar.value -= 10 if q == "Do something relaxing" or q == "Eat a snack":
energyBar.value += 30
else:
energyBar.value -= 10
index += 1 index += 1
if !found: if !found:
print("Unable to delete " + q) print("Unable to delete " + q)
......
...@@ -4,7 +4,7 @@ signal start_lab ...@@ -4,7 +4,7 @@ signal start_lab
signal tired signal tired
onready var started = false onready var started = false
onready var eventHandler onready var eventHandler
onready var givenTired = false
# This script signals to the eventHandler to give the player the 2nd phase of quests after finishing the first one # This script signals to the eventHandler to give the player the 2nd phase of quests after finishing the first one
# It will also signal the end of the game once all the lab notes have been collected # It will also signal the end of the game once all the lab notes have been collected
...@@ -23,11 +23,14 @@ func mouseInteraction(): ...@@ -23,11 +23,14 @@ func mouseInteraction():
if !started: # if the quests have been given yet if !started: # if the quests have been given yet
emit_signal("start_lab") emit_signal("start_lab")
else: else:
if flavorText == "Too tired. Gotta relax first. Need carbohydrates. Can't I do something less stressful first? Please and thank you.": if !givenTired and flavorText == "Too tired. Gotta relax first. Need carbohydrates. Can't I do something less stressful first? Please and thank you.":
emit_signal("tired") emit_signal("tired")
givenTired = true
.mouseInteraction() .mouseInteraction()
elif eventHandler.get_lab_notes() == 4: elif eventHandler.get_lab_notes() == 4:
emit_signal("finish_lab") emit_signal("finish_lab")
else:
.mouseInteraction()
func start(): func start():
......
...@@ -34,3 +34,5 @@ func objInteraction(selected): # when an object is used on it ...@@ -34,3 +34,5 @@ func objInteraction(selected): # when an object is used on it
dialogueBox.text = "No flavor text found" #can replace this later! dialogueBox.text = "No flavor text found" #can replace this later!
inventory.unselect_all() #unselect item inventory.unselect_all() #unselect item
func outerLock():
unlocked = true
extends "res://Item.gd"
signal plunger
# Called when the node enters the scene tree for the first time.
func _ready():
pass # Replace with function body.
func passEvent(handler):
connect("plunger", handler,"_balcony_outer_lock")
func objInteraction(selected): # when an object is used on it
var flavor = control.interaction(inventory.get_item_text(selected), self.get_name())
if inventory.get_item_text(selected) == "Plunger":
dialogueBox.text = "I can't believe that actually worked?!"
emit_signal("plunger")
elif typeof(flavor) != 0: #checks if there's coded flavor text for this interaction
dialogueBox.text = flavor
else:
dialogueBox.text = "No flavor text found" #can replace this later!
inventory.unselect_all() #unselect item
extends "res://Item.gd"
onready var yoga = false
signal finished
signal lab
# Called when the node enters the scene tree for the first time.
func _ready():
pass # Replace with function body.
func passEvent(handler):
connect("finished", handler,"_remove_quest")
connect("lab", handler, "_add_lab_note")
func objInteraction(selected): # when an object is used on it
var flavor = control.interaction(inventory.get_item_text(selected), self.get_name())
if inventory.get_item_text(selected) == "Cellphone":
if yoga:
dialogueBox.text = "Share with me your knowledge, yoga man. Oh, I had one last lab note on here!"
emit_signal("finished", "Do something relaxing")
emit_signal("lab")
else:
dialogueBox.text = "Why is the Living Room so crowded? It's like a jungle in here! I can barely move..."
elif typeof(flavor) != 0: #checks if there's coded flavor text for this interaction
dialogueBox.text = flavor
else:
dialogueBox.text = "No flavor text found" #can replace this later!
inventory.unselect_all() #unselect item
func canYoga():
yoga = true
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