mitay-walle / com.mitay-walle.gradient-texture

Unity Gradient Texture generator
MIT License
86 stars 12 forks source link

Enable Copy/Paste for Gradient Fields #25

Closed cihadturhan closed 11 months ago

cihadturhan commented 11 months ago

Thanks for the asset it works perfect. I realized right click -> copy on gradient fields didn't work.

I'm not sure what GradientUsage(true) does but it disables right click on gradients. Removed it and it worked!

https://github.com/mitay-walle/com.mitay-walle.gradient-texture/assets/3739536/6033a9a7-02a6-4ae5-958b-478d83c85cda

mitay-walle commented 11 months ago

Thank you for a feedback. This Attribute allow select HDR colors in gradients. https://docs.unity3d.com/ScriptReference/GradientUsageAttribute-hdr.html

Of course it better to be optional. But I've tried to not over complicate inspector script (preview is exception).

  1. Copy/paste support at this case fully on Unity-developers side, unfortunately.
  2. Also you still can use copy / paste in Inspector Debug mode https://docs.unity3d.com/Manual/InspectorOptions.html

Glad that you find solution for your case 😄

about pull request:

Some people can use this asset with direct git dependecy, so disabling hdr can corrupt their data.

Split this by versions can help safely support before/after states, but someone still can lose HDR-values if migrate with mistakes. So to behave consistant, I wouldn't merge it.

Better Unity implement copy/paste on GradientUsageAttribute + HDR-gradient. May be already with newer versions?

Thanks for participance! Good luck with your development

cihadturhan-st commented 11 months ago

Thanks for the explanation. I disabled that in my code as I don’t need hdr for my project and shared as PR if anyone needs.

Yes, I agree that this is on unity :)