You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The way Godot parses hex Color strings is different in 4.0 (ARGB vs RGBA).
HEX string
Godot 3
Godot 4
00FFFFFF
Color(1,1,1,0)
Color(0,1,1,1)
0FFF
Color(1,1,1,0)
Color(0,1,1,1)
I think the project converter can look for the Color constructor and modify the string.
Something along the lines of /Color\("#?([a-fA-F0-9]{8}|[a-fA-F0-9]{4})"\)/gm.
Also, exported colors seem to reset their value because of an "@" in the tscn file. (@exported_color instead of exported_color)
Steps to reproduce
Open MRP in Godot 3 and look at output.
Upgrade the project using the conversion tool.
Open it in Godot 4 and notice how the colors are now totally different.
Godot version
4.0.dev.dfdda9629
System information
Windows 10
Issue description
The way Godot parses hex Color strings is different in 4.0 (ARGB vs RGBA).
I think the project converter can look for the Color constructor and modify the string.
Something along the lines of
/Color\("#?([a-fA-F0-9]{8}|[a-fA-F0-9]{4})"\)/gm
.Also, exported colors seem to reset their value because of an "@" in the
tscn
file. (@exported_color
instead ofexported_color
)Steps to reproduce
Minimal reproduction project
color_conversion.zip
The text was updated successfully, but these errors were encountered: