next_patient_type code
@@ -1,34 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://ccdjt6t0wgdo1"
|
||||
path="res://.godot/imported/patient_564.png-f939a362e5d94ad685373531cf17dc0b.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Art/Patients/patient_564/patient_564.png"
|
||||
dest_files=["res://.godot/imported/patient_564.png-f939a362e5d94ad685373531cf17dc0b.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
|
Before Width: | Height: | Size: 2.4 MiB |
|
Before Width: | Height: | Size: 231 KiB |
|
Before Width: | Height: | Size: 659 KiB |
|
Before Width: | Height: | Size: 2.4 MiB |
|
Before Width: | Height: | Size: 2.4 MiB |
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://c0ss3tjfygbkn"
|
||||
path="res://.godot/imported/patient_564_scared.png-ae3b888b68aaaf578da7958a2f43ed3b.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Art/Patients/patient_564/patient_564_scared.png"
|
||||
dest_files=["res://.godot/imported/patient_564_scared.png-ae3b888b68aaaf578da7958a2f43ed3b.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
|
Before Width: | Height: | Size: 1.7 MiB |
|
After Width: | Height: | Size: 16 KiB |
@@ -2,16 +2,16 @@
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://cfh3kumh31oqu"
|
||||
path="res://.godot/imported/patient_564_full.png-427197587e8d779d455b567f7c735561.ctex"
|
||||
uid="uid://b8ayjveljb6c"
|
||||
path="res://.godot/imported/patient_itl_abnormal1.png-640aa33577c3d3178c5883b548e2522e.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Art/Patients/patient_564/patient_564_full.png"
|
||||
dest_files=["res://.godot/imported/patient_564_full.png-427197587e8d779d455b567f7c735561.ctex"]
|
||||
source_file="res://Art/Patients/patient_itl/patient_itl_abnormal1.png"
|
||||
dest_files=["res://.godot/imported/patient_itl_abnormal1.png-640aa33577c3d3178c5883b548e2522e.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
|
After Width: | Height: | Size: 15 KiB |
@@ -2,16 +2,16 @@
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://ddddcly3c0ag3"
|
||||
path="res://.godot/imported/patient_564_angry.png-233db4ed2aa1c2073b958ddf3fc7fd0f.ctex"
|
||||
uid="uid://cum648nuaajmo"
|
||||
path="res://.godot/imported/patient_itl_angry.png-e51b56d47004a6b8f39dd77a0e869da2.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Art/Patients/patient_564/patient_564_angry.png"
|
||||
dest_files=["res://.godot/imported/patient_564_angry.png-233db4ed2aa1c2073b958ddf3fc7fd0f.ctex"]
|
||||
source_file="res://Art/Patients/patient_itl/patient_itl_angry.png"
|
||||
dest_files=["res://.godot/imported/patient_itl_angry.png-e51b56d47004a6b8f39dd77a0e869da2.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
|
After Width: | Height: | Size: 15 KiB |
@@ -2,16 +2,16 @@
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://uau6f4jn3v7j"
|
||||
path="res://.godot/imported/patient_564_smiling.png-89f34e1d6e52c0aa632dfb7d9c380d76.ctex"
|
||||
uid="uid://r8abdjqa308q"
|
||||
path="res://.godot/imported/patient_itl_neutral.png-b19645b7d20816f42ec0b6b010c64c93.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Art/Patients/patient_564/patient_564_smiling.png"
|
||||
dest_files=["res://.godot/imported/patient_564_smiling.png-89f34e1d6e52c0aa632dfb7d9c380d76.ctex"]
|
||||
source_file="res://Art/Patients/patient_itl/patient_itl_neutral.png"
|
||||
dest_files=["res://.godot/imported/patient_itl_neutral.png-b19645b7d20816f42ec0b6b010c64c93.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
|
After Width: | Height: | Size: 13 KiB |
@@ -2,16 +2,16 @@
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://dde2f1rn6vtpl"
|
||||
path="res://.godot/imported/patient_564_sad.png-e66ee7c3da902a9f0c5751be3544ba92.ctex"
|
||||
uid="uid://ctu2ydp2hhdok"
|
||||
path="res://.godot/imported/patient_itl_peaceful.png-06de28215d1a010cf988f74b5658b165.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Art/Patients/patient_564/patient_564_sad.png"
|
||||
dest_files=["res://.godot/imported/patient_564_sad.png-e66ee7c3da902a9f0c5751be3544ba92.ctex"]
|
||||
source_file="res://Art/Patients/patient_itl/patient_itl_peaceful.png"
|
||||
dest_files=["res://.godot/imported/patient_itl_peaceful.png-06de28215d1a010cf988f74b5658b165.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
|
After Width: | Height: | Size: 15 KiB |
@@ -2,16 +2,16 @@
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://ow1irc5345kv"
|
||||
path="res://.godot/imported/patient_564_neutral.png-b41269b93c0ebc8d180e6e089750a727.ctex"
|
||||
uid="uid://cryt2xni5xou"
|
||||
path="res://.godot/imported/patient_itl_smiling.png-9d595cafe252ee6cfe681d062b4d46a1.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Art/Patients/patient_564/patient_564_neutral.png"
|
||||
dest_files=["res://.godot/imported/patient_564_neutral.png-b41269b93c0ebc8d180e6e089750a727.ctex"]
|
||||
source_file="res://Art/Patients/patient_itl/patient_itl_smiling.png"
|
||||
dest_files=["res://.godot/imported/patient_itl_smiling.png-9d595cafe252ee6cfe681d062b4d46a1.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
@@ -10,7 +10,8 @@ var diagnoses_quota : int = 1
|
||||
var daily_patient_limit : int = 3
|
||||
var patient_list = ["42", "43", "44", "45", "46", "47", "48", "49", "50", "51"]
|
||||
var patients_seen = []
|
||||
var its_patients_seen = []
|
||||
var its_seen = []
|
||||
var it_seen = []
|
||||
var event_index = 0
|
||||
|
||||
#Variables for UI
|
||||
|
||||
@@ -118,9 +118,12 @@ func save_game(save_slot_number:int):
|
||||
"accurate_diagnoses": Globals.accurate_diagnoses,
|
||||
"diagnoses_quota": Globals.diagnoses_quota,
|
||||
"daily_patient_limit": Globals.daily_patient_limit,
|
||||
"patient_list": Globals.patient_list,
|
||||
"patients_seen": Globals.patients_seen,
|
||||
"its_patients_seen": Globals.its_patients_seen,
|
||||
"patient_list": Patient.patient_list,
|
||||
"its_list": Patient.its_list,
|
||||
"it_list": Patient.it_list,
|
||||
"patients_seen": Patient.patients_seen,
|
||||
"its_seen": Patient.its_seen,
|
||||
"it_seen": Patient.it_seen,
|
||||
"save_date": Globals.get_save_date()
|
||||
}
|
||||
#Creating save file
|
||||
@@ -169,9 +172,12 @@ func load_game(load_slot_number:int):
|
||||
Globals.accurate_diagnoses = load_data["accurate_diagnoses"]
|
||||
Globals.diagnoses_quota = load_data["diagnoses_quota"]
|
||||
Globals.daily_patient_limit = load_data["daily_patient_limit"]
|
||||
Globals.patient_list = load_data["patient_list"]
|
||||
Globals.patients_seen = load_data["patients_seen"]
|
||||
Globals.its_patients_seen = load_data["its_patients_seen"]
|
||||
Patient.patient_list = load_data["patient_list"]
|
||||
Patient.its_list = load_data["its_list"]
|
||||
Patient.it_list = load_data["it_list"]
|
||||
Patient.patients_seen = load_data["patients_seen"]
|
||||
Patient.its_seen = load_data["its_seen"]
|
||||
Patient.it_seen = load_data["it_seen"]
|
||||
Patient.update_patient_list()
|
||||
else:
|
||||
print("Failed to parse Loading Data.")
|
||||
|
||||
@@ -27,8 +27,11 @@ var symptoms_arrays: Array[Array] = [
|
||||
#Lists of possible patients sorted by floor
|
||||
var og_patient_list : Array[Dictionary]
|
||||
var patient_list: Array[Dictionary]
|
||||
var og_its_patient_list = ["its_01"]
|
||||
var its_patient_list = []
|
||||
var og_its_list = ["its_01"]
|
||||
var its_list = []
|
||||
var og_it_list = ["itl"]
|
||||
var it_list = []
|
||||
|
||||
|
||||
#Supervisor file path
|
||||
var supervisor_name = "loeveth"
|
||||
@@ -43,7 +46,8 @@ func _ready() -> void:
|
||||
#Setting up patient lists
|
||||
og_patient_list.resize(len(symptoms_arrays))
|
||||
patient_list.resize(len(symptoms_arrays))
|
||||
its_patient_list = og_its_patient_list
|
||||
its_list = og_its_list
|
||||
it_list = og_it_list
|
||||
|
||||
original_color = texture.modulate #Saving original modulation color to reset it after modification
|
||||
|
||||
@@ -189,7 +193,7 @@ func weighted_random(patients: Dictionary):
|
||||
return null
|
||||
|
||||
|
||||
func generate_patient_id() -> String: #Generates a patient ID
|
||||
func random_patient_id() -> String: #Generates a patient ID
|
||||
|
||||
#Generating patient_id
|
||||
var floor_index = -Globals.floor_count -1
|
||||
@@ -200,23 +204,47 @@ func generate_patient_id() -> String: #Generates a patient ID
|
||||
for i in range(len(patient_list)):
|
||||
if len(patient_list[i]) > 1:
|
||||
patient_list[i].erase(patient_id)
|
||||
print("Updated Floor " + str(i) + " list: " + str(patient_list[i]))
|
||||
|
||||
print("Updated Floor " + str(i) + " patient_list: " + str(patient_list[i]))
|
||||
|
||||
return patient_id
|
||||
|
||||
|
||||
func generate_its_patient_id() -> String: #Generates an ITS patient ID
|
||||
func random_its_id() -> String: #Generates an ITS patient ID
|
||||
|
||||
#Generating ITS patient ID
|
||||
var its_patient_id = its_patient_list.pick_random()
|
||||
print("ITS Patient selected: " + str(its_patient_id))
|
||||
var its_id = its_list.pick_random()
|
||||
print("ITS selected: " + str(its_id))
|
||||
#Remove picked ITS patient from ITS patient list
|
||||
if len(its_patient_list) > 1:
|
||||
its_patient_list.erase(its_patient_id)
|
||||
print("Updated ITS Patient list: " + str(its_patient_list))
|
||||
if len(its_list) > 1:
|
||||
its_list.erase(its_id)
|
||||
print("Updated ITS Patient list: " + str(its_list))
|
||||
|
||||
return its_patient_id
|
||||
return its_id
|
||||
|
||||
|
||||
func random_it_id():
|
||||
#Generating it_patient_id
|
||||
var floor_index = -Globals.floor_count -1
|
||||
print("Floor Index: " + str(floor_index))
|
||||
var it_id = it_list[floor_index].pick_random() #Picks a random patient depending on floor, with weighted odds
|
||||
|
||||
#Removes picked patient from patients list
|
||||
for i in range(len(it_list)):
|
||||
if len(it_list[i]) > 1:
|
||||
it_list[i].erase(it_id)
|
||||
print("Updated Floor " + str(i) + " it_list: " + str(it_list[i]))
|
||||
|
||||
return it_id
|
||||
|
||||
|
||||
func generate_next_id(patient_type: String):
|
||||
match patient_type:
|
||||
"patient":
|
||||
return random_patient_id()
|
||||
"its":
|
||||
return random_its_id()
|
||||
"it":
|
||||
return random_it_id()
|
||||
|
||||
|
||||
func next_patient() -> String: #Decides next patient ID
|
||||
@@ -227,16 +255,37 @@ func next_patient() -> String: #Decides next patient ID
|
||||
-2:
|
||||
if Globals.patient_count == 0:
|
||||
next_patient_id = "its_00"
|
||||
elif Globals.its_patient_count < 1:
|
||||
next_patient_id = generate_its_patient_id()
|
||||
else:
|
||||
next_patient_id = generate_patient_id()
|
||||
next_patient_id = generate_next_id(next_patient_type())
|
||||
_:
|
||||
next_patient_id = generate_patient_id()
|
||||
next_patient_id = generate_next_id(next_patient_type())
|
||||
|
||||
return next_patient_id
|
||||
|
||||
|
||||
#Randomizes next patient type (human, it, its)
|
||||
func next_patient_type():
|
||||
var type_list = []
|
||||
match Globals.floor_count:
|
||||
-1:
|
||||
return "patient"
|
||||
-2:
|
||||
return "patient"
|
||||
-3:
|
||||
type_list.append("its")
|
||||
for i in range(Globals.diagnoses_quota - 1):
|
||||
type_list.append("patient")
|
||||
return type_list.pick_random()
|
||||
_:
|
||||
for i in range(int(floor(Globals.diagnoses_quota/4))):
|
||||
type_list.append("its")
|
||||
type_list.append("it")
|
||||
for i in range(int(floor(Globals.diagnoses_quota/2))):
|
||||
type_list.append("patient")
|
||||
return type_list.pick_random()
|
||||
|
||||
|
||||
|
||||
func update_patient_list():
|
||||
|
||||
#Erasing patients already seen from patient lists
|
||||
@@ -246,10 +295,16 @@ func update_patient_list():
|
||||
patient_list[i].erase(patient_id)
|
||||
|
||||
#Erasing ITS patients already seen from ITS patient list
|
||||
for its_patient_id in Globals.its_patients_seen:
|
||||
if len(its_patient_list) > 1:
|
||||
its_patient_list.erase(its_patient_id)
|
||||
for its_id in Globals.its_seen:
|
||||
if len(its_list) > 1:
|
||||
its_list.erase(its_id)
|
||||
|
||||
#Erasing IT patients already seen from IT lists
|
||||
for it_id in Globals.it_seen:
|
||||
for i in range(len(it_list)):
|
||||
if len(it_list[i]) > 1:
|
||||
it_list[i].erase(it_id)
|
||||
|
||||
for j in range(len(patient_list)):
|
||||
print("Loaded Floor " + str(j) + " list: " + str(patient_list[j]))
|
||||
print("Loaded ITS Patient list: " + str(its_patient_list))
|
||||
print("Loaded ITS list: " + str(its_list))
|
||||
|
||||