Momentum
On this page(9)
An enchant with mode: momentum builds a value while the player keeps fighting. The value
drives boosters: more souls, more damage, more of any target. When the player stops, it decays and
the run ends. The shipped momentum gives souls and damage.
modules/sword/enchants/momentum.yml (shipped)
display-name: '&6&lMomentum'
max-level: 1000
chance: 100
trigger: swing
cost: { currency: souls, starting-cost: 250, increase-cost-by: 100 }
mode: momentum
momentum:
start: 0.1
max: 10
cap-at-level-1: 0.1
min: 0
active-window-seconds: 2.5
gain:
per-proc: 0
per-interval: 0.1
interval-seconds: 15
decay:
delay-seconds: 10
interval-seconds: 10
step: 0.1
boosts:
- { target: currency:souls, per-point: 0.01, max-bonus: 0, stacking: additive }
- { target: damage, per-point: 0.02, stacking: multiplicative }
booster-name: '&6Momentum'
bossbar:
enabled: true
title: '&6Momentum &e{value}&7/&e{cap} &7({percent}%)'
color: YELLOW
style: SOLID
messages:
start: '&6Momentum &7is building up.'
decay-start: '&7Your momentum &cfades&7...'
finish: '&7Your momentum &cran out&7.'
milestones:
25: ''
50: '&6Momentum &7at &e50%&7.'
75: ''
100: '&6Momentum &7at its cap: &e{value}&7!'The run
- Start. The first proc of a run sets the value to
start. - Keep alive. Every proc keeps the run alive and adds
gain.per-proc. The player counts as active foractive-window-secondsafter each proc. - Grow. While active, the value gains
gain.per-intervaleverygain.interval-seconds, up to the cap of the player's level. - Decay. After
decay.delay-secondswithout being active, it losesdecay.stepeverydecay.interval-seconds, down tomin. - End. At 0 the run ends. A quit also ends it.
Values move in tenths. The cap is a line from cap-at-level-1 at level 1 to max at
max-level: only max-level reaches max.
With chance: 100 and no cooldown, every swing keeps the run alive. A lower chance makes momentum
harder to hold, which suits a slower, longer build.
Keys
| Key | Default | What it does |
|---|---|---|
momentum.start | 0.1 | The value of the first proc of a run |
momentum.max | 10 | The cap at max-level (up to 1000000) |
momentum.cap-at-level-1 | 0.1 | The cap at level 1; the levels between go up in a line |
momentum.min | 0 | Decay stops here; 0 = the run ends at 0 |
momentum.active-window-seconds | 2.5 | How long after a proc the player counts as active |
momentum.gain.per-proc | 0 | Added on every proc but the first (0 = off) |
momentum.gain.per-interval | 0.1 | Added every interval while active (0 = off) |
momentum.gain.interval-seconds | 15 | 0.25 or more |
momentum.decay.delay-seconds | 10 | Inactive this long: the decay starts |
momentum.decay.interval-seconds | 10 | Every this long it takes a step (0.25 or more) |
momentum.decay.step | 0.1 | What one decay step takes |
momentum.booster-name | '&6Momentum' | The name of its boosters in /boosts (1 to 128 characters) |
All plain numbers. Out of range is clamped, with a warning.
Boosts
boosts is a list of boosters that follow the value, at most 16.
| Key | Default | What it does |
|---|---|---|
target | required | damage, swings, enchants, luck, enchant:<id>, currency:<id> or a currency id |
per-point | 0.01 | The bonus per point of value (above 0) |
max-bonus | 0 | The most bonus (0 = no cap) |
stacking | additive | additive = a bonus of value x per-point to the base; multiplicative = a factor of 1 + that bonus |
With the shipped file at a value of 5, souls get +0.05 (additive). Damage gets a factor of 1 + 5 x 0.02 = 1.1.
These boosters live in memory only (never written to the database). They show in /boosts and
the boost placeholders like any. See Boosters.
Boss bar
Only the player sees it, while the run lasts.
| Key | Default | Values |
|---|---|---|
bossbar.enabled | true | |
bossbar.title | '&6Momentum &e{value}/{cap}' | A text |
bossbar.color | YELLOW | PINK, BLUE, RED, GREEN, YELLOW, PURPLE, WHITE |
bossbar.style | SOLID | SOLID, SEGMENTED_6, SEGMENTED_10, SEGMENTED_12, SEGMENTED_20 |
The player hides it with the sword.momentum-bar setting.
Messages
| Key | Sent |
|---|---|
messages.start | When a run starts |
messages.decay-start | When the decay starts |
messages.finish | When the run ends |
messages.milestones.25, 50, 75, 100 | Once per run, when the value reaches that percent of the cap |
'' = no message. The texts take {value}, {cap}, {percent}, {enchant}, {player}, then
PlaceholderAPI and colors.
Actions
A momentum enchant needs no actions. Actions you add run on every proc, like any enchant. A
momentum enchant without actions never takes a sequence slot.
What moves it
Only the player's own fight. A hit of an AFK clone or a hero never starts, raises or keeps alive a momentum run. Neither does an enchant such a hit procs. A momentum enchant with actions still runs them there.
A quit ends every run of the player. /dungeons reload ends the runs of an enchant that is no longer
momentum. A changed one keeps its value, cut to the new cap. Make as many momentum enchants as you
want, one file each.
Placeholders
| Placeholder | Value |
|---|---|
%sndungeons_momentum_<enchant>_value% | The current value |
%sndungeons_momentum_<enchant>_cap% | The cap at the player's level |
%sndungeons_momentum_<enchant>_percent% | The value in percent of the cap, 0 to 100 |
%sndungeons_momentum_<enchant>_active% | true while active |
%sndungeons_momentum_<enchant>_bonus_<n>% | The bonus of the n-th boost (bonus_1 = the first) |
Admin
/dungeons admin sword momentum <player> <enchant|all> [value|max|clear|+N|-N]Without a value it shows the player's momentum. A number sets it (cut to the cap) and max maxes it. +N and -N add or take, and clear or 0 ends the run. The player must be online.