Search Unity

Color Palette - Manage all your color palettes directly inside Unity!

Discussion in 'Assets and Asset Store' started by PygmyMonkey, Mar 18, 2015.

  1. KWaldt

    KWaldt

    Joined:
    Nov 1, 2013
    Posts:
    127
    Hi there!

    Just wanted to ask if this asset will ever support TextMeshPro? (More precisely, the vertex colour of the text, and the selection colour of the input field.)
    If not, I'll just write my custom handler, but I wouldn't be surprised if a lot of people use it.

    Best Regards,
    Kristina
     
  2. PygmyMonkey

    PygmyMonkey

    Joined:
    Jan 13, 2014
    Posts:
    306
    Hello!

    Sorry but no, it's not planned to support TextMeshPro for now :/
    But it should be pretty easy to do, you would just need to update the updateColor method of ColorPalette/Runtime/ColorPaletteObjects.cs, and add something like :
    Code (CSharp):
    1. else if (this.GetComponent<textMeshProComponent>() != null)
    2. {
    3.     this.GetComponent<textMeshProComponent>().vertexColour = color;
    4.     setDirty();
    5. }
    I don't know anything about TextMeshPro, so everything I wrote here is just an example :D
     
  3. RavenTravelStudios

    RavenTravelStudios

    Joined:
    Oct 15, 2015
    Posts:
    100
    Hi PygmyMonkey, your tool sounds great :) i was thinking about buying it but i have few questions before:
    - can it support bilinear filtering ?
    - how many colors each palette can support ?
    - how much it costs in terms of draw calls ?

    I'm planning to do an hi-res graphic game and i need to use bilinear and a very large palette settings, hence i can't turn to old-style palette swapping tools which requires to use point filtering and a limited admount of colors.

    Also, i read the tutorial and don't really get why you used three different sprites for the smiley, what i'm expecting to do is having a single sprite with his palette color ramp (where 0,1,2 are white,red,blue) and changing the color map at runtime with another palette (where 0,1,2 are yellow,green,purple) :)

    Thank you!
     
    Last edited: Jun 27, 2016
  4. PygmyMonkey

    PygmyMonkey

    Joined:
    Jan 13, 2014
    Posts:
    306
    Hey there!

    For the questions about bilinear filtering and draw calls, I don't think Color Palette has any of these issues, because Color Palette just handles some color data. You just define a colours to different palettes, and there's a simple api you can use to get these palettes and colours at runtime, so anything related to bilinear filtering or draw calls will be caused by your GameObjects, you Materials etc... but not color palette.

    And you should be able to define any number of colour you want per palette :)

    This is not a tool that allows you to paint on textures or something, it's really just a way to group colours inside different palettes. There's also a script that allows you to define the colour that a GameObject will use. You just say that you want to use the colour #4 on the current palette, and later in the game, if you change the color palette, the GameObject color will automatically pick the colour #4 on the new palette.

    I used the smiley on 3 different sprites because currently, the simple script I just talked about allows me to define the colour of a sprite, so I have 3 sprites, each having this script, and each using a different index to select a color in the palette, so when I switch palette, each sprite will have a new color (from the new palette).
    But there's currently no way to say, hey this particular sprite will use these 6 colours, and change them when you want.
    I just don't know how to do that... if you have a hint ;)

    The only way I can think of doing that, is if your sprite is using a texture, and this texture has only 6 colours, then I could read all the pixels from the texture and change red to blue, green to yellow etc... but that's not a super solution...
    Another solution would be to use shaders, but unfortunately I don't know a thing about shaders :(
     
  5. ctc5301

    ctc5301

    Joined:
    Jan 28, 2016
    Posts:
    16
    When I press "Update Scene", nothing happens.
    I am just a lazy user that require to beautify my UI and happened to purchase this asset.
    update: It doesn't not work with Text Mesh Pro. But work with standard components.
     
    Last edited: Jul 25, 2016
  6. PygmyMonkey

    PygmyMonkey

    Joined:
    Jan 13, 2014
    Posts:
    306
    Hello!
    Yes, there's no support for Text Mesh Pro, sorry :)
     
  7. jl008

    jl008

    Joined:
    Jan 31, 2013
    Posts:
    25
    Hi I'm getting numerous warnings when palette tab is in focus:

    Unable to find style 'AS TextArea' in skin 'LightSkin' Used
    UnityEngine.GUIStyle:eek:p_Implicit(String)
    PygmyMonkey.ColorPalette.Utils.GUIUtils:BeginContents() (at Assets/PygmyMonkey/ColorPalette/Editor/Utils/GUIUtils.cs:162)
    PygmyMonkey.ColorPalette.ColorPaletteDataRenderer:drawInspector() (at Assets/PygmyMonkey/ColorPalette/Editor/Renderer/ColorPaletteDataRenderer.cs:34)
    PygmyMonkey.ColorPalette.ColorPaletteWindow:drawContent() (at Assets/PygmyMonkey/ColorPalette/Editor/ColorPaletteWindow.cs:75)
    PygmyMonkey.ColorPalette.Utils.PMEditorWindow:OnGUI() (at Assets/PygmyMonkey/ColorPalette/Editor/Utils/PMEditorWindow.cs:111)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr)

    I'm on the latest version of unity and the plugin.
     
  8. jl008

    jl008

    Joined:
    Jan 31, 2013
    Posts:
    25
    To whoever runs into the issue above, just replace 'AS TextArea' to 'TextArea' and the warning will go away. The support seems to be unavailable for this asset.
     
    nahoy likes this.
  9. PygmyMonkey

    PygmyMonkey

    Joined:
    Jan 13, 2014
    Posts:
    306
    Hello,

    Yes, thanks for sharing this fix with everyone.
    Sorry I still didn't get time to submit updates for Unity 2017...
     
  10. sonicviz

    sonicviz

    Joined:
    May 19, 2009
    Posts:
    1,051
    >>Sorry I still didn't get time to submit updates for Unity 2017...

    I'm interested in this asset but it hasn't been updated since Version: 1.1.7 (May 09, 2016)
     
  11. PygmyMonkey

    PygmyMonkey

    Joined:
    Jan 13, 2014
    Posts:
    306
    An update is available on the Asset Store :)

    Version 1.1.8
    - NEW
    Added support for Unity 2017 & 2018
    - NEW Improved Demo2 scene with 3 buttons (each one downloading a palette from a supported website)
    - REMOVED Removed ColorCombos color palette parser

    Version 1.1.7
    - FIX
    Issue where the current palette was not saved
    - FIX Errors with WebPlayer and SamsungTV
     
  12. TanChoi

    TanChoi

    Joined:
    Jun 14, 2016
    Posts:
    15
    Hi,

    Is ColorPaletteObject Included on production build?
     
  13. dshook

    dshook

    Joined:
    Jul 14, 2015
    Posts:
    11
    I'm confused with the Color Palette Object script, when using the custom palette option the only palettes available to choose from are the default ones, not the ones that are currently set up.

    EDIT: deleting the ColorPaletteData resource fixed it
     
    Last edited: Jul 9, 2019
    PygmyMonkey likes this.
  14. dshook

    dshook

    Joined:
    Jul 14, 2015
    Posts:
    11
    Are there any plans to add undo support when you change a color in a palette? Supporting palette's of gradients would be a really nice feature too.

    Thanks!
     
  15. PygmyMonkey

    PygmyMonkey

    Joined:
    Jan 13, 2014
    Posts:
    306
    Sorry I completely missed your message...
    Yes ColorPaletteObject is included when you build. Do you have any issue with it?
     
  16. PygmyMonkey

    PygmyMonkey

    Joined:
    Jan 13, 2014
    Posts:
    306
    Hello!

    Sorry but undo support is not gonna happen anytime soon :(
    Also what do you mean supporting palette's of gradients? You can already create multiple palettes by giving a start and end color and it will automatically generates the colors of the gradient between.
     
  17. dshook

    dshook

    Joined:
    Jul 14, 2015
    Posts:
    11
  18. PygmyMonkey

    PygmyMonkey

    Joined:
    Jan 13, 2014
    Posts:
    306
    Unfortunately I don't make enough sales of this tool to spend more time on adding features :(
     
  19. PygmyMonkey

    PygmyMonkey

    Joined:
    Jan 13, 2014
    Posts:
    306
    An update will be available soon on the Asset Store

    Version 1.1.9
    - NEW: Added the ability to download palettes from colorhunt.co
    - REMOVED: Removed the ability to download palettes from colourlovers.com
    - NEW: Minimum version is now Unity 2018.1
     
  20. Justin_Wingfall

    Justin_Wingfall

    Joined:
    May 15, 2014
    Posts:
    125
    What If I want to swap colors for specific colors in sprite sheet, will this plugin work? I want to do old school pallets for characters in fighting games.

    Or does this plugin based only change tint of colors. I want to make decision soon before sale goes of, so I know if this is the right tool or not.
     
    Last edited: Dec 17, 2020
  21. lorewap3

    lorewap3

    Joined:
    Jun 24, 2020
    Posts:
    58
    I'm sure it's been long enough to where you may not care about the answer anymore, but just in case, to anyone else reading this, this tool only updates Tint colors in SpriteRenderer and the like. It's not a shader and won't do color swapping of sprites. Mainly an organizational tool.
     
    PygmyMonkey likes this.