Difference between revisions of "Hex Codes"

From The Wajas Wiki
m (Text replace - "colour" to "color")
Line 17: Line 17:
  
  
The above colours, especially the white, black, red, blue, green, and yellow are sometimes referred to by players as "pure" colours.  So if someone says "pure black", they probably mean that the hex code should be #000000.  It is important to note that how colors mix on a computer (using light) is not always exactly the same as how they would mix with paints (using pigments). For example, breeding yellow and blue will not get you green as you might expect, but rather a murky gray color.
+
The above colors, especially the white, black, red, blue, green, and yellow are sometimes referred to by players as "pure" colors.  So if someone says "pure black", they probably mean that the hex code should be #000000.  It is important to note that how colors mix on a computer (using light) is not always exactly the same as how they would mix with paints (using pigments). For example, breeding yellow and blue will not get you green as you might expect, but rather a murky gray color.
  
  

Revision as of 22:52, 30 March 2014

Wajas are able to have a variety of features in any color of the rainbow. When making customs, you enter colors for the markings, mutations, base color, and eye color of your waja through hex codes. When dyeing Wajas, you enter the color of the dye marking with a hex code.

Additionally, when breeding wajas the colors of features on the offspring are determined by mixing the hex codes of the equivalent features on the parents. As a result, understanding hex codes and color mixing can greatly improve the results of your breedings.

What are Hex Codes?

Hex Codes are codes in the format of a pound sign(#) followed by six characters ranging from 0-9 and A-F. In Wajas, hex codes are used to define the colors of Wajas' markings, mutations, base color, and eye color.

Basic Hexes

  1. White = #FFFFFF
  2. Black = #000000
  3. Red = #FF0000
  4. Yellow = #FFFF00
  5. Green = #00FF00
  6. Blue = #0000FF
  7. Magenta = #FF00FF
  8. Turquoise = #0FF0F0


The above colors, especially the white, black, red, blue, green, and yellow are sometimes referred to by players as "pure" colors. So if someone says "pure black", they probably mean that the hex code should be #000000. It is important to note that how colors mix on a computer (using light) is not always exactly the same as how they would mix with paints (using pigments). For example, breeding yellow and blue will not get you green as you might expect, but rather a murky gray color.


Hex Codes in Breeding

When considering breeding wajas, you could look at the hex codes to get an idea of what a pup's color would be like. For example, if you breed two markingless wajas with an Ancient Love Pear, and one has a base of #FF0000 and another has a based of #0000FF, you know the pup's base color will be close to the average base color of the parents.

ColorSelector.png

Hexadecimal color codes are averaged by averaging the individual components of each color. So, in our example, you would get:

  • Parent 1 has FF red (255), 00 green (0), and 00 blue (0).
  • Parent 2 has 00 red (0), 00 green (0), and FF blue (255).
  • Value of red for pup: (FF + 00) / 2 = (255 + 0) / 2 = 127.5 = 128 or 127 = 80 or 7F
  • Value of green for pup: (00 + 00) / 2 = (0 + 0) / 2 = 0 = 00
  • Value of blue for pup: (00 + FF) / 2 = (0 + 255) / 2 = 127.5 = 128 or 127 = 80 or 7F

So, we know the pup's base color will be somewhere close to #800080 or about 128 red, 0 green, and 128 blue. This color would be close to a medium dark purple, which you probably could have guessed if you realized the parents were a pure blue Waja and a pure red Waja.

However, the results of mixing hex codes is not always obvious. Take the previous example, for instance, and change the pure blue parents' hex code to #00FFFF (pure cyan). Since cyan is a color that's rather similar to blue, you might expect the pup to be close to purple in color also. If we average the hexes again though, we would get a color close to #808080. This color is actually a shade of gray right between black and white.

This color selector is present when selecting colors for custom wajas and dyes.]] Wajas offers a great convenience to its users by allowing them to select colors from a dynamic color palette. This color selector tool lets users choose colors then fills in the hex codes for them. Because of the convenience of this tool, Wajas users can easily play the game, create customs, and add dyes to wajas without ever having to understand how to read hex codes. Because of this, hex codes may seem like mysterious strings of numbers and letters that somehow represent colors to users.

However, understanding hex codes is actually quite simple and is covered on this page in the section Hexadecimal Numbers (Hex Codes in Depth)


Color Mixer

The color mixer is a tool that can be used to determine the range of colors that are possible between two given hex codes. This is accessed under the help tab. When using this, you will take the hex codes for a particular feature in each parent (such as the base color, or the color of a shared marking) and put them in the two input fields. Once you have the appropriate hex codes entered, press the "Generate Sample Spectrum" button to get a range of possible colors that fall between the parent's colors.

For information regarding using this tool for pup predictions, please see Pup Predicting.


Hexadecimal Numbers (Hex Codes in Depth)

Every color that displays on your computer monitor is created by mixing red, green, and blue. The use of red, green, and blue to make all colors is called the RGB color model. When a computer interprets a hex code, it's actually reading for a value of red from 0 to 255, a value of green from 0 to 255, and, yes, a value of blue from 0 to 255. Hex codes are in the format of a pound sign ('#') followed by six characters that range from 0-9 and A-F. The 'hex' in hex codes is short for hexadecimal. Although you don't actually type the '#' in front of a hex code while entering colors on Wajas, the pound sign is used to tell the computer that you are talking in hexadecimal numbers.

Basically, with hexadecimal number system, bases of 16 are used instead of bases of 10. The letters in the numbers are used to represent single digits that are higher than 9. Therefore:

  • A represents 10
  • B represents 11
  • C represents 12
  • D represents 13
  • E represents 14
  • F represents 15

In the hexadecimal system, 255 is a similar number to what 99 is in the decimal system. The decimal number 255 is represented by the hexadecimal number FF. To understand the conversion from hexadecimal to decimal see that:

  • FF = F * 16 + F = 15 * 16 + 15 = 255
  • DD = D * 16 + D = 13 * 16 + 13 = 221
  • FD = F * 16 + D = 15 * 16 + 13 = 253
  • DF = D * 16 + F = 13 * 16 + 16 = 223

Note that in the examples above, the first digit is multiplied by 16 each time. This is similar to how we normally multiply digits by 10 for each place value the digit has. For comparison:

  • 255 = 2 * 10 * 10 + 50 * 10 + 5 = 255
  • 221 = 2 * 10 * 10 + 2 * 10 + 1 = 221
  • 253 = 2 * 10 * 10 + 5 * 10 + 3 = 253
  • 223 = 2 * 10 * 10 + 2 * 10 + 3 = 223

When a computer is reading a hex color code, it's basically looking at a string of three numbers. The first two digits represent the amount of red in the color, the second two digits represent the amount of green in the color, and the last two digits represent the amount of blue in the color.

Take the hex code #FF00EE for example. You get:

  • FF or 255 red
  • 00 or 0 green
  • EE or 238 blue


See Also