Easy Placeholders
  • Easy Placeholders
  • Getting Started
    • Features
    • Installation Guide
      • Support
  • Customize!
    • Config.yml
      • Operators
      • Example Configs
    • Complicated Configs
      • Placeholder Splitting
      • Placeholder Combining
      • Placeholder Math
      • Multiple (Splitting + Combining)
    • Animated Placeholders
    • Formatting
  • Placeholder Editing
  • My Other Plugins
    • EasyBrushes
Powered by GitBook
On this page
  • Chance-Based Outputs
  • Math Operations
  1. Customize!
  2. Complicated Configs

Placeholder Math

Theres 2 sections, Math and Chance.


Chance-Based Outputs

Chance-based outputs allow randomized responses based on probability.

placeholders:
  random_greeting:
    chance_outputs:
      - chance: 50
        output: '<green>Hello %player_name%!'
      - chance: 30
        output: '<gold>Hi %player_name%!'
      - chance: 20
        output: '<red>Hey %player_name%!'

50% chance: <green>Hello Junkeh! 30% chance: <gold>Hi Junkeh! 20% chance: <red>Hey Junkeh!


Math Operations

Allows mathematical transformations on numeric placeholders.

placeholders:
  math_example:
    placeholders:
      - '%player_level%'
    math_operation: 'x2,+5,^2'
    output: '<red>Level transformed: {result}!'

Example Input: %player_level% = 3

Steps:

  • Multiply by 2 → 3 × 2 = 6

  • Add 5 → 6 + 5 = 11

  • Square the result → 11² = 121

Final Output: <red>Level transformed: 121!

PreviousPlaceholder CombiningNextMultiple (Splitting + Combining)

Last updated 2 months ago