the game I am working on is color based (you HAVE to be able to see the difference between colors to play it) and someone pointed out in the comments that it would be impossible for color blind people to play it.
Does anyone know how to make a color blind mode? should I use different gray tones, use different shapes as texture or something I have thought of yet?
thanks in advance:smile:
I designed a board game with colour as an identifier. I found under yellowish light (which is fairly common in home lighting) that blues and greens can be difficult to tell apart. I set the graphics to greyscale in Photoshop as a test. I then tried again and again with differing shades until they could be distinguished.
You could also use different textures to reinforce the differences. Tetris had to do this on the original Gameboy as there was no colour in the display.
I have protanopia â a red green color blindness. thanks for thinking of us gimps :')
the only thing I can really say to help is to continually check your art using www.vischeck.com - click on vischeck on the right hand side and then ârun imagesâ
I donât know how accurate that simulation is, but iâm sure itâs probably pretty damn good because when I run an image in it I canât tell the difference between the origional and the one it creates. weather or not itâs changing the image CORRECTLY, or in just a way I canât tell, is another question all together, but itâs irrelevant as well⌠if your art style is readible after being run through that filter, then youâre golden.
This problem isnât strictly Unity related (or even strictly electronic game related). Iâd suggest reading up on accessible gaming. See this blogpost on double coding. If you absolutely must use color (and you have Pro), this post-process effect from the Unity wiki will let you test what your game looks like to a color-blind person.
Personally i think you can make something like in zuma. I played before and it have this colorblind mode where those commonly mistaken colors are changed to shades of grey so instead of the normal yellow, it becomes say dark grey.
I recently had a similar comment from a customer, and so I devised a simple shader that lets me see what he sees. It basically combined Red/Green luminosity and sure enough, I cannot play my game now. Treat it all like a regular ImageEffect (so you need a render target texture and UnityPRO). I hope it helps.
hereâs the shader
Shader âHidden/Red Green Color Blindâ {
Properties {
_MainTex (âBase (RGB)â, 2D) = âwhiteâ {}
}
SubShader {
Pass {
ZTest Always Cull Off ZWrite Off
Fog { Mode off }
CGPROGRAM
#pragma vertex vert_img
#pragma fragment frag
#pragma fragmentoption ARB_precision_hint_fastest
#include âUnityCG.cgincâ
uniform sampler2D _MainTex;
fixed4 frag (v2f_img i) : COLOR
{
fixed4 original = tex2D(_MainTex, i.uv);
fixed4 output = original;
output.g = max( sqrt( ( original.r * original.r * 0.241 ) ), sqrt( original.g * original.g * 0.691 ) );
output.r = output.g;
return output;
}
ENDCG
}
}
Fallback off
}
And hereâs the C# code to bind to your camera.
using UnityEngine;
[ExecuteInEditMode]
[AddComponentMenu(âImage Effects/Red-Green Color Blindâ)]
public class RedGreenColorBlind : ImageEffectBase {
// Called by camera to apply image effect
void OnRenderImage (RenderTexture source, RenderTexture destination) {
Graphics.Blit (source, destination, material);
}
}
Check out also this shader&script:
Is there a mobile version?
Why not just use unityâs built in colour correction? This way you can have several schemes for colour blind people without any issues.
I found this useful blog discussing this problem, and it includes a Unity package that simulates some forms of colour blindness.
Iâve created an asset called âxCBM: Color Blindness Masterâ coming soon to Unity Asset Store.
It gives previews of different color blindness types so it is easy to identify what needs to be changed.
More features are planned.
âxCBM: Color Blindness Masterâ is now available at the Asset Store.
Take a look.