Merge remote-tracking branch 'MaD_CaT/master'

This commit is contained in:
sasha80
2025-03-11 09:02:21 +03:00
3 changed files with 34 additions and 7 deletions

View File

@@ -70,7 +70,12 @@ func _ready() -> void:
temp_array.append([])
for i in len(json_data[key]) - 1:
if tools.type_is_num(json_data[key][i+1]) == tools.type_is_num(UnitProfiles[key][2][i]):
temp_array[1].append(json_data[key][i+1])
if typeof(UnitProfiles[key][2][i]) == TYPE_INT:
temp_array[1].append(int(json_data[key][i+1]))
elif typeof(UnitProfiles[key][2][i]) == TYPE_FLOAT:
temp_array[1].append(float(json_data[key][i+1]))
else:
set_from_file = false
elif typeof(json_data[key][i+1]) == typeof(UnitProfiles[key][2][i]):
temp_array[1].append(json_data[key][i+1])
else: