Home Discord Store Get ClothesPlus Login
Esc

Shading & Color Tinting

Grayscale overlay tinting, shading templates, and the shading_config.yml reference.

Overview

ClothesPlus supports color tinting for grayscale overlays, shading templates that add realistic lighting to character skins, and an advanced shading configuration with blend modes and color correction.

Grayscale Tinting

Create overlays in grayscale and they can be tinted to any color by the plugin. This allows a single overlay file to produce dozens of color variants without creating separate PNGs for each.

How It Works

  1. Create your overlay PNG in grayscale (shades of gray only)
  2. The plugin tints the overlay using a target color
  3. Brightness values determine how the tint is applied:
  • 128 (mid-gray) = neutral tint color
  • > 128 (lighter) = lighter than base color (highlights)
  • < 128 (darker) = darker than base color (shadows)

This is great for clothing items like t-shirts where you want players to choose their own color — one grayscale overlay can produce unlimited color options.

Shading Templates

Shading templates add realistic light and shadow to the base skin. They are applied as a separate layer to create depth.

Default templates are included in the shading/ folder:

  • shading
    • steveshade.png
    • alexshade.png

The shading layer uses the same brightness-based system:

  • Pixels brighter than 128 → lighten the underlying skin
  • Pixels darker than 128 → darken the underlying skin
  • Pixel at 128 → no change

Require Shading

When base_skin is set to false in config.yml, you can require players to select a shading before wearing clothes:

yaml
require_shading: true

Players must run /clothes shading before they can equip any overlays.

shading_config.yml

The shading_config.yml file provides advanced control over how shading is applied:

yaml
defaults:
  # Blend mode: MULTIPLY | OVERLAY | SOFT_LIGHT
  blend-mode: MULTIPLY
  opacity: 1.0

  coverage:
    head: true
    torso: true
    arms: true
    legs: true
    hands: true

  # Which pixel to sample the player's skin tone from
  color-sample-pixel:
    x: 11
    y: 12

  # Color correction prevents shading from making skin look gray
  color-correction:
    enabled: true
    saturation-preservation: 0.85
    saturation-boost: 0.1
    lock-hue: false
Blend ModeEffect
MULTIPLYDarkens skin (classic shading, good for shadows)
OVERLAYContrast-boost (mid-tones pop, highlights stay bright)
SOFT_LIGHTGentle tonal shift (subtle shading)

Per-Shading Overrides

You can override defaults for specific shading files. Use . as separator in key names:

yaml
shadings:
  female_alex.shading1:
    display-name: "Soft Shade"
    blend-mode: SOFT_LIGHT
    opacity: 0.85
    color-correction:
      saturation-preservation: 0.9
      saturation-boost: 0.15

Color Palette

Use /clothes palette to generate and manage color palettes for tinting. This command requires the wardrobeclothes.palette permission.