This commit is contained in:
Maurane
2026-08-16 01:06:53 +02:00
parent d0cdec4a6a
commit 59e9cb30a5
362 changed files with 4139 additions and 4487 deletions
+20 -10
View File
@@ -3,14 +3,15 @@ extends Node
#Variables for gameplay
var floor_count : int = -1
var patient_count : int = 1
var its_patient_count : int = 0
var accurate_diagnoses : int = 0
var diagnoses_quota : int = 1
var misdiagnoses : int = 0
var misdiagnoses_game_over : bool = true
var patient_quota : int = 1
var misdiagnoses_allowed : int = 2
var daily_patient_limit : int = 3
var patient_list = []
var event_index : String = ""
var supervisor_index : int = 1
var objective_list : Array[String]
#Variables for UI
var save_slot_count = 4 #How many save slots there are in the game, in addition to the autosave slot
@@ -21,11 +22,12 @@ var directives = "\n[center][font_size=22]INSTRUCTIONS[/font_size][/center]
\n\n[font_size=18][color=forest_green]RELEASE[/color] HUMANS, [color=red]TERMINATE[/color] ABNORMALS
\n\nIF A SUBJECT HAS [color=dark_orange]SYMPTOMS[/color] IT SHOULDN'T HAVE,
\n [color=red]IT IS NOT HUMAN[/color]
\n\nREFER TO THE [color=royal_blue]MANUAL[/color] FOR [color=dark_orange]SYMPTOMS[/color] DETAILS
\n\nMAKE ENOUGH [color=green_yellow]ACCURATE DIAGNOSES[/color] IN A ROW
\nTO GET TO THE NEXT FLOOR[/font_size]"
\n\nREFER TO THE [color=royal_blue]MANUAL[/color] FOR [color=dark_orange]SYMPTOMS[/color] DETAILS"
var release_messages: Array[String]
var terminate_messages: Array[String]
var default_patient_file = "[center][color=orange_red]NO SUBJECT SELECTED IN DATABASE[/color][/center]"
var default_recording_fil
var buttons_activated: bool = true
var entities = [] #Entities list for the journal
@@ -42,18 +44,21 @@ signal terminate_display
signal its_end
signal next_event
signal add_entity
signal add_objective
# Called when the node enters the scene tree for the first time.
func _ready() -> void:
release_messages.resize(3)
terminate_messages.resize(3)
release_messages[0] = Globals.colorize("- ASSESSMENT MADE -\n\n- LOADING RELEASE PROTOCOL... -", "green_yellow")
release_messages[0] = "EVALUATION RECORDED" + "\n\nPATIENT STATUS: " + Globals.colorize("HUMAN", "green") + "\n\nUPDATING DATABASE...\n\n\n\n" + Globals.colorize("INITIATING RELEASE SEQUENCE", "green_yellow")
release_messages[1] = Globals.colorize("- RELEASING SUBJECT -", "green_yellow")
release_messages[2] = "EVALUATION RECORDED" + "\n\nPATIENT STATUS: " + Globals.colorize("HUMAN", "green") + "\n\nUPDATING DATABASE...\n\n" + Globals.colorize("INITIATING RELEASE SEQUENCE", "green_yellow")
terminate_messages[0] = Globals.colorize("- ASSESSMENT MADE -\n\n- LOADING TERMINATION PROTOCOL... -", "orange_red")
terminate_messages[0] = "EVALUATION RECORDED" + "\n\nPATIENT STATUS: " + Globals.colorize("ABNORMAL", "red") + "\n\nUPDATING DATABASE...\n\n\n\n" + Globals.colorize("INITIATING TERMINATION SEQUENCE", "orange_red")
terminate_messages[1] = Globals.colorize("- TERMINATING SUBJECT -", "orange_red")
terminate_messages[2] = "EVALUATION RECORDED" + "\n\nPATIENT STATUS: " + Globals.colorize("ABNORMAL", "red") + "\n\nUPDATING DATABASE...\n\n" + Globals.colorize("INITIATING TERMINATION SEQUENCE", "orange_red")
#Generating patient list
Globals.patient_list.clear()
@@ -61,6 +66,11 @@ func _ready() -> void:
for i in range(35,52):
patient_id = "patient_" + str(i)
Globals.patient_list.append(patient_id)
for i in range(1,5):
patient_id = "patient_its_" + str(i)
Globals.patient_list.append(patient_id)
patient_id = "patient_ite_" + str(i)
Globals.patient_list.append(patient_id)
#Gets the current time and day of the year
+24 -22
View File
@@ -53,20 +53,19 @@ func _ready() -> void:
func _on_new_game_pressed():
#Setting/Resetting game parameters
Globals.floor_count = -5
Globals.floor_count = -1
Globals.patient_count = 0
Globals.accurate_diagnoses = 0
Globals.diagnoses_quota = 2
Globals.misdiagnoses = 0
Globals.patient_quota = 2
Globals.misdiagnoses_allowed = 2
Globals.daily_patient_limit = 6
Globals.event_index = "interfloor"
Globals.objective_list.clear()
for i in range(len(Patient.patient_list)):
Patient.patient_list[i] = Patient.og_patient_list[i]
Patient.its_list = Patient.og_its_list
Patient.patients_seen.clear()
Patient.its_seen.clear()
Patient.spy.order = false
Patient.spy.count = 0
Patient.spy.reset()
UI.in_title_screen = false
# DISABLED FOR NOW SINCE THERE'S NO INTRO ANYMORE
#Offering to skip the introduction
#var choice_text = "Do you wish to skip the introduction ?"
@@ -119,18 +118,16 @@ func save_game(save_slot_number:int):
"supervisor_index": Globals.supervisor_index,
"patient_count": Globals.patient_count,
"accurate_diagnoses": Globals.accurate_diagnoses,
"diagnoses_quota": Globals.diagnoses_quota,
"misdiagnoses": Globals.misdiagnoses,
"patient_quota": Globals.patient_quota,
"misdiagnoses_allowed": Globals.misdiagnoses_allowed,
"daily_patient_limit": Globals.daily_patient_limit,
"patient_list": Patient.patient_list,
"its_list": Patient.its_list,
"ite_list": Patient.ite_list,
"patients_seen": Patient.patients_seen,
"its_seen": Patient.its_seen,
"ite_seen": Patient.ite_seen,
"spy_order": Patient.spy.order,
"spy_count": Patient.spy.count,
"journal_entities": $ScreeningDesk.journal_layer.journal.entities_page.text,
"spy_symptoms": Patient.spy.symptoms,
"spy_threshold": Patient.spy.threshold,
"objective_list": Globals.objective_list,
"save_date": Globals.get_save_date()
}
#Creating save file
@@ -162,6 +159,7 @@ func load_game(load_slot_number:int):
#Hiding loading menus and masks
UI.masks.mask.hide()
UI.pause_menu.reset()
UI.in_title_screen = false #Leaving title_screen
#Opening save file
var file = FileAccess.open("res://Saves/save_" + str(load_slot_number) + ".json", FileAccess.READ)
@@ -177,20 +175,20 @@ func load_game(load_slot_number:int):
Globals.supervisor_index = load_data["supervisor_index"]
Globals.patient_count = load_data["patient_count"]
Globals.accurate_diagnoses = load_data["accurate_diagnoses"]
Globals.diagnoses_quota = load_data["diagnoses_quota"]
Globals.misdiagnoses = load_data["misdiagnoses"]
Globals.patient_quota = load_data["patient_quota"]
Globals.misdiagnoses_allowed = load_data["misdiagnoses_allowed"]
Globals.daily_patient_limit = load_data["daily_patient_limit"]
Patient.patient_list.clear()
Patient.patient_list.append_array(load_data["patient_list"])
print (Patient.patient_list)
Patient.its_list = load_data["its_list"]
Patient.ite_list = load_data["ite_list"]
Patient.patients_seen = load_data["patients_seen"]
Patient.its_seen = load_data["its_seen"]
Patient.ite_seen = load_data["ite_seen"]
Patient.spy.order = load_data["spy_order"]
Patient.spy.count = load_data["spy_count"]
$ScreeningDesk.journal_layer.journal.entities_page.text = load_data["journal_entities"]
Patient.spy.symptoms.clear()
Patient.spy.symptoms.append_array(load_data["spy_symptoms"])
Patient.spy.threshold = load_data["spy_threshold"]
Globals.objective_list.clear()
Globals.objective_list.append_array(load_data["objective_list"])
else:
print("Failed to parse Loading Data.")
@@ -207,6 +205,9 @@ func _on_main_menu_pressed():
#Clearing balloon
clear_balloon()
#Setting boolean
UI.in_title_screen = true
#Going back to main menu
var scenes_to_hide = [$ScreeningDesk, $TextScreens, $TextScreens/Day, UI.game_over, UI.pause_menu.menu_button]
var scenes_to_show = [$TitleScreen]
@@ -264,7 +265,8 @@ func start_balloon(balloon_type:String, patient_type:String, dialogue_resource:
DialogueManager.got_dialogue.connect($ScreeningDesk.computer._recording_text)
"supervisor":
DialogueManager.got_dialogue.connect($ScreeningDesk.supervisor._change_emotion)
DialogueManager.got_dialogue.connect($ScreeningDesk.computer._recording_text)
#Applies text settings to the balloon
balloon.dialogue_label.seconds_per_step = UI.pause_menu.settings.text_speed
#balloon.dialogue_line.time = UI.auto_speed