spy mechanics WIP
This commit is contained in:
@@ -23,7 +23,6 @@ extends Control
|
||||
|
||||
var main: Node
|
||||
|
||||
|
||||
func _ready() -> void:
|
||||
|
||||
#Referencing main node
|
||||
@@ -110,7 +109,7 @@ func _on_call_next_patient_pressed(): #Brings in next patient and sets up the de
|
||||
#Starting Dialogue and hiding console screen
|
||||
computer.screen.hide()
|
||||
console_screen.hide()
|
||||
main.start_balloon("screening", "patient", Patient.dialogue_resource, "start")
|
||||
main.start_balloon("screening", "patient", Patient.dialogue_resource, Patient.dialogue_start)
|
||||
|
||||
#Showing Computer Tabs and showing Patient File Screen by default
|
||||
for tab in computer.tab_list:
|
||||
@@ -148,7 +147,10 @@ func _on_decision_made(choice: String):
|
||||
func _on_clear_patient(choice:String):
|
||||
|
||||
# Updating middle screen info and accurate_diagnoses value
|
||||
if (Patient.abnormal == true and choice == "terminate") or (Patient.abnormal == false and choice == "release"):
|
||||
if Patient.spy.order and Patient.spy.spy_check():
|
||||
Globals.accurate_diagnoses += 1
|
||||
Patient.spy.count += 1
|
||||
elif (Patient.abnormal == true and choice == "terminate") or (Patient.abnormal == false and choice == "release"):
|
||||
Globals.accurate_diagnoses += 1
|
||||
else:
|
||||
Globals.accurate_diagnoses = 0 # Resetting to 0 if the player makes a wrong diagnosis
|
||||
@@ -192,7 +194,7 @@ func _on_clear_patient(choice:String):
|
||||
func _on_color_change(color: String): #Modulating backroom and patient colors
|
||||
|
||||
var new_color: Color
|
||||
|
||||
|
||||
match color:
|
||||
"red":
|
||||
new_color = Color(1,0.1,0.1,1)
|
||||
@@ -227,17 +229,12 @@ func descend_floor(): #Descends to next floor
|
||||
|
||||
for node in [middle_screen, computer, console_screen, journal_layer]:
|
||||
node.reset() #Resetting the scene
|
||||
|
||||
|
||||
#Autosaving
|
||||
main.save_game(0)
|
||||
|
||||
#Selecting next event
|
||||
event_manager()
|
||||
main.save_game(0) #Autosaving
|
||||
event_manager() #Selecting next event
|
||||
|
||||
|
||||
#Resets to initial state
|
||||
func reset():
|
||||
for node in [patient, supervisor, journal_layer, computer, console_screen, middle_screen, release, terminate,
|
||||
for node in [patient, supervisor, Patient.spy, journal_layer, computer, console_screen, middle_screen, release, terminate,
|
||||
green_button, red_button, room_assets]:
|
||||
node.reset()
|
||||
|
||||
Reference in New Issue
Block a user