Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Pick Color" script menu option has issues. #89354

Open
MewPurPur opened this issue Mar 10, 2024 · 8 comments
Open

"Pick Color" script menu option has issues. #89354

MewPurPur opened this issue Mar 10, 2024 · 8 comments

Comments

@MewPurPur
Copy link
Contributor

Tested versions

Reproducible in 4.3.dev4

System information

Godot v4.3.dev4 - Pop!_OS 22.04 LTS - X11 - GLES3 (Compatibility) - Mesa Intel(R) Graphics (ADL GT2) () - 12th Gen Intel(R) Core(TM) i5-1235U (12 Threads)

Issue description

After you use Pick Color once, it starts considering the last color you picked instead of the one you right-clicked. It seems like only if the color syntax is Color(R, G, B[, A]) this updates.

image

The colors it produces are so crazy precise that they make the option essentially unusable if I don't copy the color from it.

image

Steps to reproduce

Type var lmofa = Color(), right-click "Color", and try out the things I described above.

Minimal reproduction project (MRP)

N/A

@nongvantinh
Copy link
Contributor

I have only a limited time to work on this, but I believe I can fix it. However, I'm not sure how to replicate the issue. Having a video recording of your actions would be really helpful.

@MewPurPur
Copy link
Contributor Author

You should type var lmofa = Color() and right-click the "Color" part. No selections, just somewhere inside the word, right-click it. There's a Pick Color option at the bottom of the right-click menu.

@nongvantinh
Copy link
Contributor

Perhaps this issue is platform-specific. I tested it with both the dev4 (mono and standard) versions but couldn't reproduce it on my Windows 11 system.

Untitled.video.-.Made.with.Clipchamp.1.mp4

@MewPurPur
Copy link
Contributor Author

You are getting colors with 14 digits of precision. And as you clicked on a Color() which is supposed to be black, you got some sort of green that you likely recently worked with. These are the exact things I reported.

@jsjtxietian
Copy link
Contributor

You are getting colors with 14 digits of precision.

Yes this is annoying.

And as you clicked on a Color() which is supposed to be black, you got some sort of green that you likely recently worked with

I still can't reproduce this issue, maybe it's related to how to operate?

@MewPurPur
Copy link
Contributor Author

You reproduced it in your own video. Color() is the same as Color.BLACK, so when you press Pick Color, the color picker's starting color should be a pure black. But this doesn't happen in your video and it's a bug. Only if the color is formatted with RGB, the color picker starts off with the correct color.

@ajreckof
Copy link
Member

You reproduced it in your own video. Color() is the same as Color.BLACK, so when you press Pick Color, the color picker's starting color should be a pure black. But this doesn't happen in your video and it's a bug. Only if the color is formatted with RGB, the color picker starts off with the correct color.

I'm not sure I agree with you on this and I think this would warrant a proposal. When Color() is written it might be that the user wanted black but in most cases this means he just hasn't placed any values yet. Keeping the last value is then a good thing as thanks to that you can quickly choose a color then create a new variable and modify the previous color.

@MewPurPur
Copy link
Contributor Author

MewPurPur commented Apr 14, 2024

Or they really wanted black, otherwise they'd duplicate it.

To me, showing the actual color always seems like the correct solution every time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants