1
0
Fork 0
mirror of https://github.com/Orama-Interactive/Pixelorama.git synced 2025-02-20 12:33:14 +00:00
This commit is contained in:
Manolis Papadeas 2020-10-23 18:11:08 +03:00
parent cce4fa4cbb
commit df7a650137

View file

@ -258,6 +258,8 @@ func import_gpl(path : String, text : String) -> Palette:
elif line_number > 0 && line.length() >= 9:
line = line.replace("\t", " ")
var color_data : PoolStringArray = line.split(" ", false, 4)
if color_data.size() < 3:
continue
var red : float = color_data[0].to_float() / 255.0
var green : float = color_data[1].to_float() / 255.0
var blue : float = color_data[2].to_float() / 255.0