Skip to content

Style Configuration

Style files are located at:

config/stylizeddamage/styles/<style_name>.json

Each file defines the visual appearance for a damage number. The filename (without .json) is the style name.

Style Properties

PropertyTypeDefaultDescription
colorstring"#FFFFFF"Text color (solid/rainbow)
fontSizefloat1.0Font size multiplier
fontStylestring"bold"Font style
shadowbooleantrueText shadow
outlineColorstring/nullnullOutline color
backgroundColorstring/nullnullBackground color
soundstring/nullnullSound effect on spawn
prefixstring""Text prefix
suffixstring""Text suffix
iconstring/null"" (empty string, treated as no icon)Icon texture path
iconPositionstring"right"Icon position: "left" or "right"
iconOffsetXfloat0Horizontal damage-number icon offset in pixels
iconOffsetYfloat4Vertical damage-number icon offset in pixels
hudIconOffsetXfloat0Horizontal total-damage HUD icon offset in pixels (independent of iconOffsetX)
hudIconOffsetYfloat0Vertical total-damage HUD icon offset in pixels (independent of iconOffsetY)
killTextstring/null"kill!" (generated default file value; omitted files fall back to null and show the damage number)Text for kill-type numbers (replaces damage value)
bypassDisplayOpacitybooleanfalseWhen true, ignores global displayOpacity config
decimalPlacesint1Decimal places for damage numbers; integer damage values are always shown without decimals; values below 0 fall back to 1
animationobjectAnimation config
damageScaleobjectDamage-based scaling

Color Formats

Solid:

json
"color": "#FF4444"

Rainbow:

json
"color": "rainbow:speed:10"

Font Styles

ValueEffect
"normal"Normal
"bold"Bold
"italic"Italic
"bold_italic"Bold Italic

Damage Scale

Automatically scales font size and increases hold time based on damage amount.

json
"damageScale": {
  "enabled": true,
  "baseFontSize": 1.0,
  "stepSize": 10,
  "sizeOffsetPerStep": 1,
  "maxSize": 2.5,
  "holdBase": 0,
  "holdOffsetPerStep": 10,
  "holdMax": 20
}
ParameterTypeDefaultDescription
enabledbooleantrueEnable damage scaling
baseFontSizefloat1.0Base font size at zero damage
stepSizefloat10Damage points per scaling step
sizeOffsetPerStepfloat1Font size added per step
maxSizefloat2.5Maximum font size multiplier
holdBasefloat0Base extra hold ticks
holdOffsetPerStepfloat10Extra hold ticks added per step
holdMaxfloat20Maximum extra hold ticks

Formulas

fontSize = clamp(baseFontSize + (damage / stepSize) × sizeOffsetPerStep, baseFontSize, maxSize)
holdExtra = clamp(round((damage / stepSize) × holdOffsetPerStep), 0, holdMax - holdBase)

Total hold time = animation hold + holdExtra.

Note: The generated default default.json uses holdOffsetPerStep: 5; if a style file omits the entire damageScale block, the code fallback default is 10. It is recommended to write this field explicitly to avoid ambiguity.

Number Decimals

Controls how damage numbers are rounded for display.

json
"decimalPlaces": 1
  • Default is 1, i.e. one decimal place (12.3412.3).
  • Integer damage values always drop the decimal part (12.012).
  • Fractional damage is rounded to the configured number of decimal places (decimalPlaces: 212.34512.35).
  • Values below 0 fall back to the default (1).

See Animation Guide for detailed animation configuration.

Released under the MIT License